同步商品价格比例
This commit is contained in:
parent
970a7f07c5
commit
49d534a48d
@ -39,6 +39,13 @@ class StoreProductPriceLogic extends BaseLogic
|
||||
try {
|
||||
$model = StoreProductPrice::create($params);
|
||||
|
||||
StoreProductPriceList::where('product_id', $model['product_id'])->update([
|
||||
'supply_rate' => $params['purchase_lv'] * 100,
|
||||
'merchant_rate' => $params['cost_lv'] * 100,
|
||||
'vip_rate' => $params['vip_lv'] * 100,
|
||||
'price_rate' => $params['price_lv'] * 100,
|
||||
]);
|
||||
|
||||
$productPrice = StoreProduct::where('id', $model['product_id'])->value('vip_price');
|
||||
if ($productPrice != $model['vip_price']) {
|
||||
SqlChannelPriceLog($model['product_id'], 43, $productPrice, $model['vip_price']);
|
||||
|
Loading…
x
Reference in New Issue
Block a user