shish 3 år sedan
förälder
incheckning
70340cff8d

+ 20 - 0
biz-ghs/order/classes/StockInOrderClass.php

@@ -8,6 +8,7 @@ use biz\stat\classes\StatOutClass;
 use biz\stat\classes\StatStockInClass;
 use biz\stat\classes\StatStockOutClass;
 use bizGhs\item\classes\CostChangeClass;
+use bizGhs\item\classes\PriceChangeClass;
 use bizGhs\order\models\StockOutOrderItem;
 use bizGhs\order\traits\OrderTrait;
 use bizGhs\product\classes\ProductClass;
@@ -209,6 +210,25 @@ class StockInOrderClass extends BaseClass
                         'event' => $event,
                     ];
                     CostChangeClass::addData($changeData);
+                    if ($currentHdPrice > 0) {
+                        $changeData = [
+                            'ptStyle' => 2,
+                            'sjId' => $currentInfo->sjId ?? 0,
+                            'mainId' => $mainId,
+                            'itemId' => $currentInfo->id ?? 0,
+                            'ptItemId' => $currentInfo->itemId ?? 0,
+                            'price' => $currentHdPrice,
+                            'skPrice' => $currentSkPrice,
+                            'staffId' => $staffId,
+                            'staffName' => $staffName,
+                            'name' => $currentInfo->name ?? '',
+                            'cover' => $currentInfo->cover ?? '',
+                            'event' => $event,
+                            'targetId' => $orderId,
+                            'type' => 2,
+                        ];
+                        PriceChangeClass::addData($changeData);
+                    }
                 }
             }
             $stockInfo = ProductClass::addStockByItemNum($currentItemId, $v['itemNum']);

+ 1 - 2
biz-ghs/product/classes/ProductClass.php

@@ -632,11 +632,10 @@ class ProductClass extends BaseClass
             'staffName' => $staffName,
             'name' => $name,
             'cover' => $cover,
-            'event' => '修改价格',
+            'event' => '修改',
             'type' => 0,
         ];
         PriceChangeClass::addData($changeData);
-
     }
 
     //下单时计算商品的价格  lqh 2021.1.28