...
|
...
|
@@ -438,12 +438,11 @@ class Goods extends Model |
|
|
$activity_goods_sku_price = $activity['activity_goods_sku_price'];
|
|
|
$new_sku_price = [];
|
|
|
foreach ($sku_price as $s => $k) {
|
|
|
// $new_sku_price[$s] = $k;
|
|
|
// $new_sku_price[$s]['stock'] = 0;
|
|
|
// $new_sku_price[$s]['sales'] = 0;
|
|
|
$new_sku_price[$s] = $k;
|
|
|
$new_sku_price[$s]['stock'] = 0;
|
|
|
$new_sku_price[$s]['sales'] = 0;
|
|
|
foreach ($activity_goods_sku_price as $c) {
|
|
|
if ($k['id'] == $c['sku_price_id']) {
|
|
|
$new_sku_price[$s] = $k;
|
|
|
// 采用活动的 规格内容
|
|
|
$new_sku_price[$s]['stock'] = $c['stock'];
|
|
|
$new_sku_price[$s]['sales'] = $c['sales'];
|
...
|
...
|
@@ -466,13 +465,12 @@ class Goods extends Model |
|
|
$activity_goods_sku_price = $activity['activity_goods_sku_price'];
|
|
|
$new_sku_price = [];
|
|
|
foreach ($sku_price as $s => $k) {
|
|
|
// $new_sku_price[$s] = $k;
|
|
|
// $new_sku_price[$s]['stock'] = 0;
|
|
|
// $new_sku_price[$s]['sales'] = 0;
|
|
|
// $new_sku_price[$s]['groupon_price'] = $k['price'];
|
|
|
$new_sku_price[$s] = $k;
|
|
|
$new_sku_price[$s]['stock'] = 0;
|
|
|
$new_sku_price[$s]['sales'] = 0;
|
|
|
$new_sku_price[$s]['groupon_price'] = $k['price'];
|
|
|
foreach ($activity_goods_sku_price as $c) {
|
|
|
if ($k['id'] == $c['sku_price_id']) {
|
|
|
$new_sku_price[$s] = $k;
|
|
|
// 采用活动的 规格内容
|
|
|
$new_sku_price[$s]['stock'] = $c['stock'];
|
|
|
$new_sku_price[$s]['sales'] = $c['sales'];
|
...
|
...
|
|