wugg 3 年之前
父節點
當前提交
8de841e01e
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      app/admin/controller/Consult.php

+ 4 - 0
app/admin/controller/Consult.php

@@ -116,6 +116,8 @@ class Consult extends Base
             $value['can']= isset($value['cat_id']) && $value['cat_id'] !=0 ? made($value['cat_id']):[];
             $value['specinfo']=isset($value['specinfo'])&&$value['specinfo']!=""? json_decode($value['specinfo'],
                 true):[];
+            $brand = Db::name("brand")->where(['id'=>$value['brand_id']])->find();
+            $value['brand_name']= isset($brand['brand_name']) && $brand['brand_name']!='' ? $brand['brand_name']:"";
             $value['khname']="";
             if($value['khNo']!==""){
                 $kh=Db::name("customer_info")->where(['companyNo'=>$value['khNo']])->find();
@@ -1709,6 +1711,8 @@ class Consult extends Base
         $data=[];
         foreach ($list as $value){
             $value['can']= isset($value['cat_id']) && $value['cat_id'] !=0 ? made($value['cat_id']):[];
+            $brand = Db::name("brand")->where(['id'=>$value['brand_id']])->find();
+            $value['brand_name']= isset($brand['brand_name']) && $brand['brand_name']!='' ? $brand['brand_name']:"";
             $value['khname']="";
             $value['specinfo']=isset($value['specinfo'])&&$value['specinfo']!=""? json_decode($value['specinfo'],
                 true):[];