|
@@ -55,7 +55,7 @@ class CombindStock extends Base
|
|
|
if($stock< $param['stock_num'])return error_show(1004,'商品库存数不足');
|
|
|
}
|
|
|
|
|
|
- $combindList = $this->combind->where([["spuCode"=>$param["spuCode"],"is_del"=>0]])->select()->toArray();
|
|
|
+ $combindList = $this->combind->where(["spuCode"=>$param["spuCode"],"is_del"=>0])->select()->toArray();
|
|
|
if(empty($combindList)) return error_show(1004,"未找到组合商品的商品组合信息");
|
|
|
$childarr= Db::name('good')->whereIn('spuCode',array_unique(array_column($combindList,'childCode')))->column("spuCode,usable_stock,is_combind","spuCode");
|
|
|
|