|
@@ -141,6 +141,7 @@ class Good extends \app\BaseController
|
|
|
$value['unit'] =isset($unit['unit'])?$unit['unit']:"";
|
|
|
$company = Db::name("business")->where(["companyNo"=>$value['companyNo']])->find();
|
|
|
$value['company'] = isset($company['company'])?$company['company']:"";
|
|
|
+ $value['stock_total'] = Db::name("good_stock")->where(['spuCode'=>$value['spuCode'],"is_del"=>0])->sum("usable_stock");
|
|
|
$data[]=$value;
|
|
|
}
|
|
|
return app_show(0,"获取成功",['list'=>$data,'count'=>$count]);
|