Ver código fonte

改价后取消特价

shish 5 anos atrás
pai
commit
a09d74f25a
1 arquivos alterados com 5 adições e 0 exclusões
  1. 5 0
      biz-ghs/product/classes/ProductClass.php

+ 5 - 0
biz-ghs/product/classes/ProductClass.php

@@ -534,6 +534,11 @@ class ProductClass extends BaseClass
     {
     {
         $id = $product->id ?? 0;
         $id = $product->id ?? 0;
         $shopId = $product->shopId ?? 0;
         $shopId = $product->shopId ?? 0;
+
+        //改价后取消特价 shish 20210902
+        $product->discountPrice = 0;
+        $product->save();
+
         //2021.7.6 linqh 首店改价,同步到各个分店
         //2021.7.6 linqh 首店改价,同步到各个分店
         $res = ProductClass::updateByCondition(['id' => $id], ['price' => $price, 'priceLabel' => $priceLabel]);
         $res = ProductClass::updateByCondition(['id' => $id], ['price' => $price, 'priceLabel' => $priceLabel]);
         self::updateSyncProduct($id, $shopId, ['price' => $price, 'priceLabel' => $priceLabel]);
         self::updateSyncProduct($id, $shopId, ['price' => $price, 'priceLabel' => $priceLabel]);