|
@@ -403,6 +403,7 @@ class Good extends Base
|
|
$data['noble_name']=isset($data['noble_metal'])&&$data['noble_metal']!=0?$this->noble[$data['noble_metal']] :"";
|
|
$data['noble_name']=isset($data['noble_metal'])&&$data['noble_metal']!=0?$this->noble[$data['noble_metal']] :"";
|
|
$data['combind_list']=[];
|
|
$data['combind_list']=[];
|
|
$data['wsm_list']=[];
|
|
$data['wsm_list']=[];
|
|
|
|
+ $data['is_combind_child']=false;
|
|
if($data['is_combind']==1){
|
|
if($data['is_combind']==1){
|
|
$data['combind_list'] = (new GoodCombind())->where(['spuCode'=>$good_platform['spuCode'],'is_del'=>0])->select()->toArray();
|
|
$data['combind_list'] = (new GoodCombind())->where(['spuCode'=>$good_platform['spuCode'],'is_del'=>0])->select()->toArray();
|
|
foreach ($data['combind_list'] as &$item){
|
|
foreach ($data['combind_list'] as &$item){
|
|
@@ -411,7 +412,11 @@ class Good extends Base
|
|
$data['wsm_list']=(new GoodStock())->withJoin(['wsminfo'] , 'left')
|
|
$data['wsm_list']=(new GoodStock())->withJoin(['wsminfo'] , 'left')
|
|
->where(['spuCode'=>$good_platform['spuCode'] , 'wsm_type'=>[2 , 5]])
|
|
->where(['spuCode'=>$good_platform['spuCode'] , 'wsm_type'=>[2 , 5]])
|
|
->column('good_stock.id stock_id,name,good_stock.wsm_code,usable_stock');
|
|
->column('good_stock.id stock_id,name,good_stock.wsm_code,usable_stock');
|
|
|
|
+ }else{
|
|
|
|
+ $isCombind= (new GoodCombind())->where(['childCode'=>$good_platform['spuCode'],'is_del'=>0])->findOrEmpty();
|
|
|
|
+ $data['is_combind_child']=$isCombind->isEmpty();
|
|
}
|
|
}
|
|
|
|
+
|
|
if($data['brand_id']!=0){
|
|
if($data['brand_id']!=0){
|
|
$brand=Db::name("brand")->where(["id"=>$data['brand_id']])->find();
|
|
$brand=Db::name("brand")->where(["id"=>$data['brand_id']])->find();
|
|
$data["brand_name"]=isset($brand['brand_name'])?$brand['brand_name']:"";
|
|
$data["brand_name"]=isset($brand['brand_name'])?$brand['brand_name']:"";
|