shish hace 2 años
padre
commit
fdd8bf22ae
Se han modificado 1 ficheros con 7 adiciones y 0 borrados
  1. 7 0
      biz-ghs/product/classes/ProductClass.php

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

@@ -67,6 +67,13 @@ class ProductClass extends BaseClass
         $cover = $respond->cover ?? '';
         $staffId = $data['staffId'] ?? 0;
         $staffName = $data['staffName'] ?? '';
+
+        $ptItem = PtItemClass::getById($ptItemId, true);
+        if (!empty($ptItem)) {
+            $ptItem->useNum = 1;
+            $ptItem->save();
+        }
+
         if ($cost > 0) {
             $changeData = [
                 'ptStyle' => 2,