Forráskód Böngészése

修改扫码添加参数

linhaohong 1 éve
szülő
commit
944a67b04c
1 módosított fájl, 2 hozzáadás és 2 törlés
  1. 2 2
      Controller/CustomCustomer/CustomCustomerController.py

+ 2 - 2
Controller/CustomCustomer/CustomCustomerController.py

@@ -50,7 +50,7 @@ class CustomCustomerView(View):
                 return response.json(173)
             device_count = CustomCustomerDevice.objects.filter(c_id=custom_customer.id).count()
             custom_customer_data = {
-                'cId': custom_customer.id,
+                'cid': custom_customer.id,
                 'quantity': custom_customer.quantity,
                 'existsDeviceCount': device_count,
                 'unexistsDeviceCount': custom_customer.quantity - device_count
@@ -67,7 +67,7 @@ class CustomCustomerView(View):
         :return:
         """
         # 获取并验证请求中的必要参数
-        c_id = request_dict.get('cId')
+        c_id = request_dict.get('cid')
         full_code = request_dict.get('QRcode', '').strip()
 
         if not c_id or not full_code: