Selaa lähdekoodia

修改扫码添加参数

linhaohong 1 vuosi sitten
vanhempi
commit
944a67b04c
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      Controller/CustomCustomer/CustomCustomerController.py

+ 2 - 2
Controller/CustomCustomer/CustomCustomerController.py

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