更新获取委托商品详情
This commit is contained in:
parent
f4a1a74a25
commit
ac5da60d71
@ -812,6 +812,11 @@ class Community extends BaseController
|
||||
}
|
||||
$entrustDay = Db::name('entrust')->where('community_id', $id)->where('is_del', 0)->value('entrust_day');
|
||||
$communityInfo['entrust_day'] = $entrustDay;
|
||||
$communityInfo['product_list'] = Db::name('entrust')->alias('e')->leftJoin('store_product sp','e.product_id = sp.product_id')->leftJoin('store_product_attr_value spav','spav.unique = e.product_attr_unique')->where('e.community_id', $id)->where('sp.is_del', 0)->setOption('field', [])->field(['e.product_id, e.product_attr_unique, e.number, e.price, e.status, spav.price as old_price, sp.store_name, sp.image'])->select();
|
||||
if ($communityInfo['product_list']) $communityInfo['product_list'] = $communityInfo['product_list']->toArray();
|
||||
foreach($communityInfo['product_list'] as $k => $v) {
|
||||
$communityInfo['product_list'][$k]['image'] = explode(',', $v['image']);;
|
||||
}
|
||||
return app('json')->success($communityInfo);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user