...
|
...
|
@@ -214,13 +214,19 @@ class Goods extends Base |
|
|
foreach ($detail['sku_price'] as $v) {
|
|
|
$goods_sku_id_arr = array_merge($v['goods_sku_id_arr'],$goods_sku_id_arr);
|
|
|
}
|
|
|
$new_sku = [];
|
|
|
foreach ($detail['sku'] as $val) {
|
|
|
$new_content = [];
|
|
|
foreach ($val['content'] as $value){
|
|
|
if(!in_array($value['id'],$goods_sku_id_arr)){
|
|
|
unset($value);
|
|
|
if(in_array($value['id'],$goods_sku_id_arr)){
|
|
|
$new_content[] = $value;
|
|
|
}
|
|
|
}
|
|
|
$val['content'] = $new_content;
|
|
|
$new_sku[] = $val;
|
|
|
}
|
|
|
$detail['sku'] = $new_sku;
|
|
|
|
|
|
$this->success('商品详情', $detail);
|
|
|
}
|
|
|
|
...
|
...
|
|