...
|
...
|
@@ -3,7 +3,6 @@ |
|
|
|
|
|
namespace app\api\controller;
|
|
|
|
|
|
|
|
|
use app\api\model\Category;
|
|
|
use app\api\model\Goods;
|
|
|
use app\api\model\GoodsSpec;
|
...
|
...
|
@@ -111,6 +110,8 @@ class Classification extends Api |
|
|
->find();
|
|
|
$item['price'] = $goods_spec['goods_price'];
|
|
|
$item['line_price'] = $goods_spec['line_price'];
|
|
|
// 总库存
|
|
|
$item->append(['stock_num']);
|
|
|
});
|
|
|
}else{
|
|
|
$list = $model
|
...
|
...
|
@@ -132,6 +133,8 @@ class Classification extends Api |
|
|
->find();
|
|
|
$item['price'] = $goods_spec['goods_price'];
|
|
|
$item['line_price'] = $goods_spec['line_price'];
|
|
|
// 总库存
|
|
|
$item->append(['stock_num']);
|
|
|
});
|
|
|
}
|
|
|
$this->success('分类商品列表',['list'=>$list,'image'=>cdnurl(Config::get('site.advert'),true)]);
|
...
|
...
|
|