Explorar o código

新增客户,传introSjId、introShopId、introSjName 来实现

shizhongqi %!s(int64=4) %!d(string=hai) anos
pai
achega
ee633c0a2e

+ 1 - 1
app-ghs/controllers/CustomController.php

@@ -149,7 +149,7 @@ class CustomController extends BaseController
 
             //队列方式去处理
             $customerCachedKey = 'customers_list';
-            $value = $name . '_' . $mobile . '_' . $this->sjId . '_' . $this->shop['id'] . '_' .$this->shop['shopName'] . '_' . $this->shopAdminId;
+            $value = $name . '_' . $mobile . '_' . $this->sjId . '_' . $this->shop['id'] . '_' .$this->sj['name'] . '_' . $this->shopAdminId;
             Yii::$app->redis->executeCommand('LPUSH', [$customerCachedKey, $value]);
             Yii::info("添加客户:name - " . $name . ' == mobile - ' . $mobile);
             Yii::info("shopAdminId: " . $this->shopAdminId);

+ 4 - 4
console/controllers/CustomController.php

@@ -155,10 +155,10 @@ class CustomController extends Controller
             $customerInfo = explode('_', $customer);
 
             $post = []; // 组织表单数据
-            //$post['introSjId'] = $customerInfo[2];
-            //$post['introShopId'] = $customerInfo[3];
-            $post['ghsShopAdminId'] = $customerInfo[5]; // 取供应商的员工帐号id
-
+            $post['introSjId'] = $customerInfo[2];
+            $post['introShopId'] = $customerInfo[3];
+            $post['introSjName'] = $customerInfo['4'];
+            //$post['ghsShopAdminId'] = $customerInfo[5]; // 取供应商的员工帐号id
 
             $shopName = $customerInfo[0];
             $post['name'] = $shopName;