wupengfei 2 éve
szülő
commit
6ba25b452d

+ 3 - 2
.idea/workspace.xml

@@ -3,7 +3,8 @@
   <component name="ChangeListManager">
     <list default="true" id="1a36929e-c054-4875-a943-593a74e55fa4" name="Default Changelist" comment="">
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
-      <change beforePath="$PROJECT_DIR$/thinkphp/library/think/Request.php" beforeDir="false" afterPath="$PROJECT_DIR$/thinkphp/library/think/Request.php" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/application/operate/controller/SupplierGoods.php" beforeDir="false" afterPath="$PROJECT_DIR$/application/operate/controller/SupplierGoods.php" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/application/operate/view/supplier_goods/index.html" beforeDir="false" afterPath="$PROJECT_DIR$/application/operate/view/supplier_goods/index.html" afterDir="false" />
     </list>
     <option name="SHOW_DIALOG" value="false" />
     <option name="HIGHLIGHT_CONFLICTS" value="true" />
@@ -291,7 +292,7 @@
       <workItem from="1681348081818" duration="22448000" />
       <workItem from="1681434523223" duration="19578000" />
       <workItem from="1681463431612" duration="3188000" />
-      <workItem from="1681692707179" duration="18487000" />
+      <workItem from="1681692707179" duration="19088000" />
     </task>
     <servers />
   </component>

+ 11 - 0
application/operate/controller/SupplierGoods.php

@@ -154,6 +154,17 @@ class SupplierGoods extends Controller
      */
     protected function _form_filter(&$data)
     {
+        if($this->request->isGet())
+        {
+            $third_classify = input('third_classify');
+            if($third_classify) {
+                if($third_classify) $data['third_classify'] = $third_classify;
+                $third_info = \app\common\model\SupplierCate::where('id',$third_classify)->find()->toArray();
+                if($third_classify) $data['second_classify'] = $third_info['pid'];
+                $data['first_classify'] = \app\common\model\SupplierCate::where('id',$data['second_classify'])->value('pid');
+            }
+
+        }
         // 视频
         $this->video_list = \app\common\model\VideoIntro::with('videoArr')
             ->where(['is_deleted'=>0])->order('id desc')

+ 1 - 1
application/operate/view/supplier_goods/index.html

@@ -2,7 +2,7 @@
 
 {block name="button"}
 <a href="javascript:history.go(-1);"  data-title="返 回" class='layui-btn layui-btn-sm layui-btn-primary'>返 回</a>
-<button data-open='{:url("add")}?supplier_id={$Think.get.supplier_id}&company_id={$Think.get.company_id}&source={$Think.get.source}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
+<button data-open='{:url("add")}?supplier_id={$Think.get.supplier_id}&company_id={$Think.get.company_id}&source={$Think.get.source}&third_classify={$Think.get.third_classify}' data-title="添加" class='layui-btn layui-btn-sm layui-btn-primary'>添加</button>
 {/block}
 
 {block name="content"}