فهرست منبع

做到了余额变动明细

shish 1 سال پیش
والد
کامیت
148be47b46
1فایلهای تغییر یافته به همراه9 افزوده شده و 8 حذف شده
  1. 9 8
      app-mall/controllers/MemberChangeController.php

+ 9 - 8
app-mall/controllers/MemberChangeController.php

@@ -3,6 +3,7 @@
 namespace mall\controllers;
 
 use bizMall\custom\classes\CustomClass;
+use bizMall\hd\classes\HdClass;
 use bizMall\member\classes\MemberChangeClass;
 use common\components\dateUtil;
 use common\components\util;
@@ -26,17 +27,17 @@ class MemberChangeController extends BaseController
             $period = dateUtil::formatTime($searchTime, $startTime, $endTime);
             $where['addTime'] = ['between', [$period['startTime'], $period['endTime']]];
         }
-        $customId = $get['customId'] ?? 0;
-        if (!empty($customId)) {
-            $custom = CustomClass::getById($customId, true);
-            if (empty($custom)) {
-                util::fail('找不到客户');
+        $hdId = $get['hdId'] ?? 0;
+        if (!empty($hdId)) {
+            $hdInfo = HdClass::getById($hdId, true);
+            if (empty($hdInfo)) {
+                util::fail('找不到门店');
             }
             $shopId = $this->shopId;
-            if ($custom->shopId != $shopId) {
-                util::fail('不是你的客户');
+            if ($hdInfo->shopId != $shopId) {
+                util::fail('不是你的门店');
             }
-            $where['customId'] = $customId;
+            $where['hdId'] = $hdId;
         }
         $respond = MemberChangeClass::getChangeList($where);
         util::success($respond);