diff --git "a/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.py" "b/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.py" index fb3608e04ea6a2cbb668c49a9e8e91c916be70f4..45645001a9fbfca381a39dbabe33b9f3bdb82c70 100644 --- "a/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.py" +++ "b/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\345\220\246.py" @@ -48,7 +48,10 @@ for i in result1: company_id = i["companyId"] request_body = commonFuc().get_business_data(module, "payload", company_id) result = requests.get(url, params=request_body) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.text) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 @@ -59,7 +62,10 @@ for i in result1: company_id = i["companyId"] request_body = commonFuc().get_business_data(module, "payload", company_id) result = requests.get(url, params=request_body) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.text) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.py" "b/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.py" index cabab49ed67a6d6f9720db77e4ef365924588bf1..d70120c6dcb18bd35cfc580b6c6bf5a7e1cfef85 100644 --- "a/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.py" +++ "b/air_case/cmdc-qos/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.air/\345\277\253\351\200\237\344\270\213\345\215\225\346\235\203\351\231\220_\350\203\275.py" @@ -47,7 +47,10 @@ if quick_order_sign == 1: request_body = commonFuc().get_business_data(module, "payload", company_id) # 发送请求 result = requests.get(url, params=request_body) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.text) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # 断言实际结果中是否包含预期结果的内容 @@ -58,7 +61,10 @@ else: request_body = commonFuc().get_business_data(module, "payload", company_id) # 发送请求 result = requests.get(url, params=request_body) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.text) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_31st/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_31st/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..6708d956c7a61720854b8e7f3cd6f86daff2d452 --- /dev/null +++ "b/air_case/cmdc_31st/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点资料申请变更功能验证,31,31-5,sit,bs +主数据平台:后台运营系统站点资料申请变更接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步发起站点资料变更 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +""" + + 场景: 站点资料申请变更功能验证 + 用例名称:站点资料申请变更功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":"success"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict11") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" "b/air_case/cmdc_31st/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..1551930721f52d525e43b1678b6a846e4578c2a7 --- /dev/null +++ "b/air_case/cmdc_31st/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/ab_\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +import json + +""" +case_tag:cmdc_api,cmdc补货设置批量导入验证,31,31-25,sit,bs +主数据平台:后台运营系统补货设置批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import os + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/补货设置模板.xlsx" + +# 第二步补货设置批量导入验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") + +request_body = commonFuc().get_business_data(module, "payload26") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + 场景: 补货设置批量导入验证 + 用例名称:补货设置批量导入验证 + 输出:{"pacNo":"2016001"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +file.close() + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中新增补货设置对应的pacNo +sql = "SELECT t.pacNo FROM `cmdc-order`.tc_replenishment_setting t WHERE productCode = 10154719 and deleteSign = 0" +pac_no = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 实际结果 +result = {"pacNo": pac_no} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict26") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_31st/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..86862b378a6bdd4349d66f1cf29ea64f9086efd1 --- /dev/null +++ "b/air_case/cmdc_31st/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/ba_\350\241\245\350\264\247\350\256\276\347\275\256\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,90 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc补货设置更新功能验证,31,31-24,sit,bs +主数据平台:后台运营系统补货设置更新接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload27_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +print(result) + +# 获取补货设置信息 +id = result["data"]["list"][0]["id"] +supplier_code = result["data"]["list"][0]["supplierCode"] +supplier_name = result["data"]["list"][0]["supplierName"] + +# 第三步获取合同协议号 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +vpt_random = random.randint(0, len(result["data"])) +# 获取合同信息 +if result["data"][vpt_random]["tcacatt1DS"]: + pac_no = result["data"][vpt_random]["tcacatt1DS"] + project_code = result["data"][vpt_random]["tcir02"] + project_name = result["data"][vpt_random]["tcdl011"] + salesman_name = result["data"][vpt_random]["tcacatt4DS"] + business_department_name = result["data"][vpt_random]["tcalph"] + + # 第四步补货设置信息更新操作 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url27") + request_body = commonFuc().get_business_data(module, "payload27", id, pac_no, supplier_code, supplier_name, + project_name, project_code, salesman_name, business_department_name) + # print(request_body) + """ + + 场景: 补货设置更新功能验证 + 用例名称:补货设置更新功能验证 + 输出:{"pacNo":"%s"} + """ + + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + + # 断言实际结果 + result = {"pacNo": pac_no} + # print(result) + result["api_time"] = api_time + + # 数据库操作 + mysql_handle = mySql() + # 获取conf.ini文件中配置的数据库信息 + host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + + # 查询数据库中新增补货设置对应的pacNo + sql = "SELECT t.pacNo FROM `cmdc-order`.tc_replenishment_setting t WHERE productCode = 10154719 and deleteSign = 0" + pac_no = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict27", pac_no) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_31st/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..4ba293143ee43b87df0d5f81a6ab881fde6d9296 --- /dev/null +++ "b/air_case/cmdc_31st/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/bb_\350\241\245\350\264\247\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc补货设置删除功能验证,31,31-27,sit,bs +主数据平台:后台运营系统补货设置删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload27_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取补货设置信息 +id = result["data"]["list"][0]["id"] + +# 第四步补货设置信息删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") +request_body = {"ids": [id]} +# print(request_body) +""" + + 场景: 补货设置删除功能验证 + 用例名称:补货设置删除功能验证 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中被删除的补货设置对应的删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-order`.tc_replenishment_setting t WHERE id = {}".format(id) +sign = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 断言结果 +result = {"deleteSign": sign} +# 将接口响应时间添加至result中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict28") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" "b/air_case/cmdc_31st/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" new file mode 100644 index 0000000000000000000000000000000000000000..caa80847341cf48ae36d41e7f32726538e279aa8 --- /dev/null +++ "b/air_case/cmdc_31st/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\344\276\233\345\272\224\345\225\206\345\255\227\346\256\265\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc供应商字段必填校验_核验供应商证照,31,31-37,sit,bs +主数据平台:后台运营系统供应商证照核验接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单欠货明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35") + +""" + + 场景: 供应商字段必填校验_核验供应商证照 + 用例名称:供应商字段必填校验_核验供应商证照 + 输出:{"success":false,"code":"check","message":"供应商数据不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict35") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" "b/air_case/cmdc_31st/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" new file mode 100644 index 0000000000000000000000000000000000000000..3d680cf63badb204e41aadd108ee2e4d162f3956 --- /dev/null +++ "b/air_case/cmdc_31st/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.air/\345\210\206\345\205\254\345\217\270\347\274\226\347\240\201\345\277\205\345\241\253\346\240\241\351\252\214_\346\240\270\351\252\214\344\276\233\345\272\224\345\225\206\350\257\201\347\205\247.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc分公司编码必填校验_核验供应商证照,31,31-36,sit,bs +主数据平台:后台运营系统供应商证照核验接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单欠货明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url34") +request_body = commonFuc().get_business_data(module, "payload34") + +""" + + 场景: 分公司编码必填校验_核验供应商证照 + 用例名称:分公司编码必填校验_核验供应商证照 + 输出:{"success":false,"code":"check","message":"分公司编码不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict34") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.air/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.py" "b/air_case/cmdc_31st/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.air/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.py" new file mode 100644 index 0000000000000000000000000000000000000000..6ba30e28f04abaef34940566e3d4ceeaf867b067 --- /dev/null +++ "b/air_case/cmdc_31st/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.air/\345\217\221\350\265\267\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\347\224\263\350\257\267.py" @@ -0,0 +1,52 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc发起站点资料变更申请,31,31-13,sit,bs +主数据平台:后台运营系统发起站点资料变更申请接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步发起站点资料变更申请 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") + +""" + + 场景: 发起站点资料变更申请 + 用例名称:发起站点资料变更申请 + 输出:{"userName":"%s"} +""" + +# 发送请求 +result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取变更申请页面中userName +result = json.loads(result.content) +print(result) +result = {"userName": result["data"]["userName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict3", username) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..f48fc7579c2455d5102cf685336e25f19bfd8196 --- /dev/null +++ "b/air_case/cmdc_31st/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\345\255\220\351\234\200\346\261\202\345\215\225\345\257\274\345\207\272_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc子需求单导出_补货单列表,31,31-22,sit,bs +主数据平台:后台运营系统子需求单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import json +import os + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取子需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = commonFuc().get_business_data(module, "payload19") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取子需求单数量 +total = result["data"]["total"] + +# 第三步需求单导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22") + +""" + 场景: 子需求单导出_补货单列表 + 用例名称:子需求单导出_补货单列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/需求单导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中需求单个数 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"total": len(excel.read_data())} +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict22", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" "b/air_case/cmdc_31st/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..9fc8aa515eb6e92c191398e9ab749b2843ba5b68 --- /dev/null +++ "b/air_case/cmdc_31st/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" @@ -0,0 +1,52 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_获取补货单欠货明细,31,31-35,sit,bs +主数据平台:后台运营系统获取补货单欠货明细接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取补货信息 +uuid1 = "" + +# 第二步获取补货单欠货明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33", uuid1) + +""" + + 场景: 必填字段校验_获取补货单欠货明细 + 用例名称:必填字段校验_获取补货单欠货明细 + 输出:{"success":false,"code":"ERROR","message":"欠货唯一标识至少有一个不为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict33") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_31st/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.py" "b/air_case/cmdc_31st/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..f0bc39cbf3e2eee3508feb1eb2c01e7e0b62d74d --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\350\257\246\346\203\205.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查看站点资料变更详情,31,31-3,sit,bs +主数据平台:后台运营系统查看站点资料变更详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点资料变更列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +site_random = random.randint(0, len(result["data"]["list"]) - 1) +# print(site_random) +# 获取站点信息 +tripartite_id = result["data"]["list"][site_random]["tripartiteId"] + +# 第三步查询站点资料变更详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4", tripartite_id) + +""" + + 场景: 查询站点资料变更详情 + 用例名称:查询站点资料变更详情 + 输出:{"tripartiteId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取详情页中tripartiteId +result = json.loads(result.content) +# print(result) +result = {"tripartiteId": result["data"]["tripartiteId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict4", tripartite_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..3a57688dcc145bbec624a0cdfd4035b154110bf4 --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_变更审核列表,31,31-7,sit,bs +主数据平台:后台运营系统站点资料变更审核列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import datetime +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点资料变更审核列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +site_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +apply_no = result["data"]["list"][site_random]["applyNo"] +apply_time = result["data"]["list"][site_random]["createTime"][:10] + " 00:00:00" +now_time = datetime.datetime.now().strftime("%Y-%m-%d 00:00:00") +company_name = result["data"]["list"][site_random]["companyName"] +apply_status = result["data"]["list"][site_random]["applyStatus"] +site_type = result["data"]["list"][site_random]["siteType"] + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6", apply_no, company_name, apply_time, now_time, + apply_status, site_type) + +""" + + 场景: 查询条件验证_变更审核列表 + 用例名称:查询条件验证_变更审核列表 + 输出:{"applyNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中applyNo +result = json.loads(result.content) +# print(result) +result = {"applyNo": result["data"]["list"][0]["applyNo"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6", apply_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.py" "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..ce8afa4d675d2a662e09fcbe82968acc33f0f320 --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\347\256\241\347\220\206.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_站点管理,31,31-11,sit,bs +主数据平台:后台运营系统站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +website_name = result["data"]["list"][website_random]["websiteName"] +order_apportion_principle = result["data"]["list"][website_random]["orderApportionPrinciple"] +company_name = result["data"]["list"][website_random]["companyName"] +company_type = result["data"]["list"][website_random]["companyType"] + +# 第三步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url8") +request_body = commonFuc().get_business_data(module, "payload8", website_name, order_apportion_principle, company_name, + company_type) + +""" + + 场景: 验证站点管理列表查询条件可使用性 + 用例名称:查询条件验证_站点管理 + 输出:{"websiteName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中websiteName +result = json.loads(result.content) +result = {"websiteName": result["data"]["list"][0]["websiteName"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict8",website_name) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..42ea83d85fe24879325145728f40a074de71ddc9 --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250.py" @@ -0,0 +1,69 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_站点资料变更列表,31,31-2,sit,bs +主数据平台:后台运营系统获取站点资料变更列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点资料变更列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +site_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +apply_no = result["data"]["list"][site_random]["applyNo"] +apply_time = result["data"]["list"][site_random]["createTime"][:10] + " 00:00:00" +now_time = datetime.datetime.now().strftime("%Y-%m-%d 00:00:00") + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2", apply_no, apply_time, now_time) + +""" + + 场景: 验证获取站点资料变更列表查询条件的可使用性 + 用例名称:查询条件验证_站点资料变更列表 + 输出:{"applyNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中applyNo +result = json.loads(result.content) +# print(result) +result = {"applyNo": result["data"]["list"][0]["applyNo"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict2", apply_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..7814692d07fda2777095a4b23398571078f36eab --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,93 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_获取补货单列表,31,31-20,sit,bs +主数据平台:后台运营系统获取补货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import datetime +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 第二步获取补货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +rep_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货单信息 +product_line_code = func(result["data"]["list"][rep_random]["productLineCode"]) +pac_no = func(result["data"]["list"][rep_random]["pacNo"]) +specifications = func(result["data"]["list"][rep_random]["specifications"]) +manufacturer = func(result["data"]["list"][rep_random]["manufacturer"]) +material_code = func(result["data"]["list"][rep_random]["materialCode"]) +sync_sign = result["data"]["list"][rep_random]["syncSign"] +supplier_replenishment_code = func(result["data"]["list"][rep_random]["supplierReplenishmentCode"]) +replenishment_code = result["data"]["list"][rep_random]["replenishmentCode"] +or_code = func(result["data"]["list"][rep_random]["orCode"]) +product_info = result["data"]["list"][rep_random]["productCode"] +supplier_info = func(result["data"]["list"][rep_random]["supplierCode"]) +customer_info = func(result["data"]["list"][rep_random]["customerCode"]) +project_info = func(result["data"]["list"][rep_random]["projectCode"]) +creator_name = result["data"]["list"][rep_random]["creatorName"] +start_time = result["data"]["list"][rep_random]["createTime"][:10] +end_time = datetime.datetime.now().strftime("%Y-%m-%d") + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") +request_body = commonFuc().get_business_data(module, "payload18", product_line_code, pac_no, specifications, + manufacturer, + material_code, sync_sign, supplier_replenishment_code, replenishment_code, + or_code, product_info, supplier_info, customer_info, project_info, + creator_name, + start_time, end_time) + +""" + + 场景: 查询条件验证_获取补货单列表 + 用例名称:查询条件验证_获取补货单列表 + 输出:{"replenishmentCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取补货单信息replenishmentCode +result = json.loads(result.content) +result = {"replenishmentCode": result["data"]["list"][0]["replenishmentCode"]} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict18", replenishment_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.py" "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.py" new file mode 100644 index 0000000000000000000000000000000000000000..7cc0e6a7d987e409490555c558d71314dc4121bc --- /dev/null +++ "b/air_case/cmdc_31st/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\241\245\350\264\247\350\256\276\347\275\256.py" @@ -0,0 +1,85 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_补货设置,31,31-28,sit,bs +主数据平台:后台运营系统获取补货单设置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +set_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货设置信息 +product_name = func(result["data"]["list"][set_random]["productCode"]) +product_line_code = func(result["data"]["list"][set_random]["productLineCode"]) +supplier_name = func(result["data"]["list"][set_random]["supplierName"]) +pac_no = func(result["data"]["list"][set_random]["pacNo"]) +specifications = func(result["data"]["list"][set_random]["specifications"]) +manufacturer = func(result["data"]["list"][set_random]["manufacturer"]) +customer_name = func(result["data"]["list"][set_random]["customerName"]) +project_name = func(result["data"]["list"][set_random]["projectName"]) +material_code = func(result["data"]["list"][set_random]["materialCode"]) +creator_name = result["data"]["list"][set_random]["creatorName"] + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") +request_body = commonFuc().get_business_data(module, "payload16", product_name, product_line_code, supplier_name, + pac_no, + specifications, manufacturer, customer_name, project_name, material_code, + creator_name) +# print(request_body) +""" + + 场景: 查询条件验证_补货设置 + 用例名称:查询条件验证_补货设置 + 输出:{"productName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中补货设置信息 +result = json.loads(result.content) +# print(result) +result = {"productName": result["data"]["list"][0]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict16", product_name) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.air/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.air/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..30badef9f46d5e7234ba2dd82afefdc684dda7f6 --- /dev/null +++ "b/air_case/cmdc_31st/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.air/\346\240\271\346\215\256code\346\237\245\350\257\242\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据code查询补货设置信息,31,31-34,sit,bs +主数据平台:后台运营系统根据code查询补货设置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +set_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货设置信息 +customer_code = result["data"]["list"][set_random]["customerCode"] +product_code = result["data"]["list"][set_random]["productCode"] +supplier_code = result["data"]["list"][set_random]["supplierCode"] +company_code = result["data"]["list"][set_random]["companyCode"] + +# 第三步根据code查询补货设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url30") +request_body = commonFuc().get_business_data(module, "payload30", customer_code, product_code, supplier_code, + company_code) +""" + + 场景: 根据code查询补货设置信息 + 用例名称:根据code查询补货设置信息 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取补货设置信息 +result = json.loads(result.content) +# print(result) +result = {"productCode": result["data"]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict30", product_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.py" new file mode 100644 index 0000000000000000000000000000000000000000..b7d2bc7e614e37737526e449945723c96e471319 --- /dev/null +++ "b/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点资料变更列表获取,31,31-1,sit,bs +主数据平台:后台运营系统获取站点资料变更列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点资料变更列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") + +""" + + 场景: 验证获取站点资料变更列表接口连通性及数据正确性 + 用例名称:站点资料变更列表获取 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点变更记录数量 +result = json.loads(result.content) +print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点对应的站点资料变更记录数量 +sql = "SELECT count(t.tripartiteId) FROM `cmdc-user`.cmdc_tripartite_change t WHERE companyCode = 00111" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict1", total) +print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.py" new file mode 100644 index 0000000000000000000000000000000000000000..b36bb8a62b87b2cd681eb3bc40bde03aed99013b --- /dev/null +++ "b/air_case/cmdc_31st/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.air/\347\253\231\347\202\271\350\265\204\346\226\231\345\217\230\346\233\264\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点资料变更审核列表获取,31,31-6,sit,bs +主数据平台:后台运营系统站点资料变更审核列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点资料变更审核列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5") + +""" + + 场景: 站点资料变更审核列表获取 + 用例名称:站点资料变更审核列表获取 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict5") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..bb9f5d9fbf03c469ffd182f47bc0efe105f50ca4 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取供应商信息_补货单,31,31-30,sit,bs +主数据平台:后台运营系统获取供应商信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取供应商信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") +request_body = commonFuc().get_business_data(module, "payload24") + +""" + + 场景: 验证获取供应商信息接口连通性及数据正确性 + 用例名称:获取供应商信息_补货单 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点对应的供应商数量 +result = json.loads(result.content) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点对应的供应商数量 +sql = "SELECT count(t.id) FROM `cmdc-user`.cmdc_vptisupluer_jde t WHERE MCCO = 00111" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict24", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..77c4fcec850270079b9e2e28525df73cf9d5f8c3 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.air/\350\216\267\345\217\226\345\215\217\350\256\256\345\220\210\345\220\214\345\217\267\344\277\241\346\201\257_\350\241\245\350\264\247\345\215\225.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取协议合同号信息_补货单,31,31-31,sit,bs +主数据平台:后台运营系统获取协议合同号信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1_be") +# password = commonFuc().get_business_data(module, "password1_be") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第一步获取协议合同号信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") + +""" + + 场景: 验证获取协议合同号信息接口连通性及数据正确性 + 用例名称:获取协议合同号信息_补货单 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点对应的合同协议号数量 +result = json.loads(result.content) +result = {"total": len(result["data"])} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点对应的合同协议号数量 +sql = "SELECT count(t.TCUKID) FROM `cmdc-user`.cmdc_vptihtxy_jde t " \ + "WHERE TCDL011 IS NOT NULL AND TCDL01 IS NOT NULL AND TCEV02 != 'Y' AND TCE8HTSX = 'P'" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict25", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..2d360d0aed9900e35608e849daa718a52371aee9 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取子需求单列表_补货单列表,31,31-18,sit,bs +主数据平台:后台运营系统获取子需求单列表_补货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取子需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = commonFuc().get_business_data(module, "payload19") + +""" + + 场景: 获取子需求单列表_补货单列表 + 用例名称:获取子需求单列表_补货单列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict19") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..cfab84b7c6e2b479af31fcab6811c48c0a6139a2 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户已合作站点信息,31,31-15,sit,bs +主数据平台:多采商城获取用户已合作站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_31st" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取用户已合作站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14") +# print(request_body) +""" + + 场景: 获取用户已合作站点信息 + 用例名称:获取用户已合作站点信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户已合作站点数量 +result = json.loads(result.content) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库中对应采购计划修改记录数量 +sql = "SELECT count(t.companyId) FROM `cmdc-user`.cmdc_company_user t WHERE userId = 69" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..0f44eaaea096baeaab92ed9df22fde5c6c26b741 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\231\273\345\275\225\347\224\250\346\210\267\344\277\241\346\201\257.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取登录用户信息,31,31-14,sit,bs +主数据平台:多采商城获取登录用户信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取登录用户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13") +# print(request_body) +""" + + 场景: 获取登录用户信息 + 用例名称:获取登录用户信息 + 输出:{"userName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户信息中username +result = json.loads(result.content) +result = {"userName": result["data"]["userName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13", username) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..00e24f328917783d985605b6cf37de17f2535e80 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\210\227\350\241\250_\347\253\231\347\202\271\347\256\241\347\220\206.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点列表_站点管理,31,31-10,sit,bs +主数据平台:后台运营系统站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") + +""" + + 场景: 获取站点列表_站点管理 + 用例名称:获取站点列表_站点管理 + 输出:{"success":true,"code":"200","message":"操作成功"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict7") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..e093a94aaba9ec302f2220dca32ed342c4a1dbc7 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\344\277\241\346\201\257.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点证照信息,31,31-12,sit,bs +主数据平台:后台运营系统获取站点证照信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1_be1") +# password = commonFuc().get_business_data(module, "password1_be1") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第一步获取站点证照信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9") + +""" + + 场景: 获取站点证照信息 + 用例名称:获取站点证照信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict9") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..a9b5b06dd63de8bb5a4133f887c51a6cfefd45e9 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货单列表,31,31-17,sit,bs +主数据平台:后台运营系统获取补货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") + +""" + + 场景: 获取补货单列表 + 用例名称:获取补货单列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict17") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..4e387cde89454fb671788ca995f9f043971751ed --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\345\225\206\345\223\201\350\257\246\346\203\205.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货单商品详情,31,31-29,sit,bs +主数据平台:后台运营系统获取补货单商品详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表_客户查询维度 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31_1") +request_body = commonFuc().get_business_data(module, "payload31_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["debtProductVos"]["list"]) - 1) +# 获取商品信息 +customer_code = result["data"]["debtProductVos"]["list"][debt_random]["customerCode"] +distribution_type = result["data"]["debtProductVos"]["list"][debt_random]["distributionType"] +product_code = result["data"]["debtProductVos"]["list"][debt_random]["productCode"] +seller_company_code = result["data"]["debtProductVos"]["list"][debt_random]["sellerCompanyCode"] +shipment_type = result["data"]["debtProductVos"]["list"][debt_random]["shipmentType"] + +# 第三步获取补货单商品详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") +request_body = commonFuc().get_business_data(module, "payload31", customer_code, distribution_type, product_code, + seller_company_code, shipment_type) + +""" + + 场景: 获取补货单商品详情 + 用例名称:获取补货单商品详情 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取补货商品信息 +result = json.loads(result.content) +result = {"productCode": result["data"][0]["productCode"]} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict31", product_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..db54f6ca56b448aad4de3b8931e8c5bbac597ff1 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\346\254\240\350\264\247\346\230\216\347\273\206.py" @@ -0,0 +1,79 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货单欠货明细,31,31-33,sit,bs +主数据平台:后台运营系统获取补货单欠货明细接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表_客户查询维度 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31_1") +request_body = commonFuc().get_business_data(module, "payload31_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["debtProductVos"]["list"]) - 1) +# 获取商品信息 +customer_code = result["data"]["debtProductVos"]["list"][debt_random]["customerCode"] +distribution_type = result["data"]["debtProductVos"]["list"][debt_random]["distributionType"] +product_code = result["data"]["debtProductVos"]["list"][debt_random]["productCode"] +seller_company_code = result["data"]["debtProductVos"]["list"][debt_random]["sellerCompanyCode"] +shipment_type = result["data"]["debtProductVos"]["list"][debt_random]["shipmentType"] + +# 第三步获取补货单商品详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") +request_body = commonFuc().get_business_data(module, "payload31", customer_code, distribution_type, product_code, + seller_company_code, shipment_type) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取补货信息 +uuid1 = result["data"][0]["uuid"] + +# 第四步获取补货单欠货明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32", uuid1) + +""" + + 场景: 获取补货单欠货明细 + 用例名称:获取补货单欠货明细 + 输出:{"uuid":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取补货商品信息 +result = json.loads(result.content) +result = {"uuid": result["data"][0]["uuid"]} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict32", uuid1) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..2dbd92e64faf5be402d70b429bf312c7e754d0a0 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\256\276\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货单设置信息,31,31-16,sit,bs +主数据平台:后台运营系统获取补货单设置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15") + +""" + + 场景: 获取补货单设置信息 + 用例名称:获取补货单设置信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..9717b779df6eff5cff5f011c57d15ad7fd9c1ee7 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\241\245\350\264\247\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货单详情信息,31,31-19,sit,bs +主数据平台:后台运营系统获取补货单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import datetime +import random +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +rep_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货单信息 +replenishment_code = result["data"]["list"][rep_random]["replenishmentCode"] + +# 第三步获取补货单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") +request_body = commonFuc().get_business_data(module, "payload20", replenishment_code) + +""" + 场景: 获取补货单详情信息 + 用例名称:获取补货单详情信息 + 输出:{"replenishmentCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取补货单信息replenishmentCode +result = json.loads(result.content) +result = {"replenishmentCode": result["data"][0]["supplierInfo"]["replenishmentCode"]} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict20", replenishment_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" new file mode 100644 index 0000000000000000000000000000000000000000..40aa784a85f3991b8da79fe32155ed3f73fa4cb7 --- /dev/null +++ "b/air_case/cmdc_31st/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\350\216\267\345\217\226\350\241\245\350\264\247\350\256\276\347\275\256\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取补货设置批量导入日志,31,31-26,sit,bs +主数据平台:后台运营系统获取补货设置批量导入日志接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货设置批量导入日志 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url29") +request_body = commonFuc().get_business_data(module, "payload29") + +""" + + 场景: 获取补货设置批量导入日志 + 用例名称:获取补货设置批量导入日志 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict29") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_31st/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_31st/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..4834d0c02a7d21ae89fa77ee31fffd15defe8094 --- /dev/null +++ "b/air_case/cmdc_31st/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\241\245\350\264\247\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,72 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc补货单导出验证,31,31-20,sit,bs +主数据平台:后台运营系统补货单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +rep_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货单信息 +replenishment_code = result["data"]["list"][rep_random]["replenishmentCode"] + +# 第三步补货单导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21", replenishment_code) + +""" + 场景: 补货单导出验证 + 用例名称:补货单导出验证 + 输出:{"replenishmentCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/补货单导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中补货单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"replenishmentCode": excel.read_data()[0].get("补货单号")} +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict21", replenishment_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.air/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.py" "b/air_case/cmdc_31st/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.air/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.py" new file mode 100644 index 0000000000000000000000000000000000000000..6a03dd7d55badb153898633ffe186c5bd867b3e7 --- /dev/null +++ "b/air_case/cmdc_31st/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.air/\350\241\245\350\264\247\350\256\276\347\275\256\344\277\241\346\201\257\345\257\274\345\207\272.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc补货设置信息导出验证,31,31-23,sit,bs +主数据平台:后台运营系统补货设置信息导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取补货单设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +set_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取补货设置信息 +product_name = result["data"]["list"][set_random]["productCode"] + +# 第三步补货设置信息导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23", product_name) +# print(request_body) +""" + + 场景: 补货设置信息导出验证 + 用例名称:补货设置信息导出验证 + 输出:{"productName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/自动补货设置导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中补货单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"productName": excel.read_data()[0].get("商品编码")} +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict23", product_name) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_31st/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.air/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.py" "b/air_case/cmdc_31st/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.air/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.py" new file mode 100644 index 0000000000000000000000000000000000000000..2b8beb7f20744bddfae6da9439940db358ff8585 --- /dev/null +++ "b/air_case/cmdc_31st/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.air/\350\265\204\346\226\231\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\224\263\350\257\267\345\217\230\346\233\264.py" @@ -0,0 +1,58 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc资料上传接口验证_申请变更,31,31-4,sit,bs +主数据平台:后台运营系统资料上传接口接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + + +module = "cmdc_31st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件地址 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/test_file.jpg" + +# 进行图片附件上传操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 资料上传接口验证_申请变更 + 用例名称:资料上传接口验证_申请变更 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict10") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + +# 文件关闭 +file.close() \ No newline at end of file diff --git "a/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.py" "b/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..03fc2bab262636bc81ee2c083f7ee7c9178ec3ef --- /dev/null +++ "b/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\350\256\260\345\275\225.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_超发记录,32,32-15,sit,be +主数据平台:后台运营系统获取超发记录接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发记录 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +flow_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取超发记录信息 +custData = result["data"]["list"][flow_random]["customerCode"] +productData = result["data"]["list"][flow_random]["productName"] +demandCode = result["data"]["list"][flow_random]["demandCode"] +distributionCode = result["data"]["list"][flow_random]["distributionCode"] +startTime = result["data"]["list"][flow_random]["createTime"][:10] + " 00:00:00" +endTime = str(datetime.datetime.now().strftime("%Y-%m-%d")) + " 00:00:00" + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15", custData, productData, demandCode, + distributionCode, startTime, endTime) + +""" + + 场景: 列表查询条件验证_超发记录 + 用例名称:列表查询条件验证_超发记录 + 输出:{"productData":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取超发记录信息 +result = json.loads(result.content) +result = {"productData": result["data"]["list"][0]["productName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15", productData) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..c2056c704c4db14f0ae82e6f787518e855c1c639 --- /dev/null +++ "b/air_case/cmdc_32st/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -0,0 +1,67 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_超发配置列表,32,32-8,sit,be +主数据平台:后台运营系统获取超发配置列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发配置列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +super_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取超发配置信息 +strsQuery = result["data"]["list"][super_random]["productCode"] +materialCode = result["data"]["list"][super_random]["materialCode"] +productLineCode = (result["data"]["list"][super_random]["productLineCode"] if result["data"]["list"][super_random][ + "productLineCode"] else "") + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url8") +request_body = commonFuc().get_business_data(module, "payload8", strsQuery, materialCode, productLineCode) +# print(request_body) +""" + + 场景: 列表查询条件验证_超发配置列表 + 用例名称:列表查询条件验证_超发配置列表 + 输出:{"strsQuery":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取超发配置信息 +result = json.loads(result.content) +# print(result) +result = {"strsQuery": result["data"]["list"][0]["productCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict8", strsQuery) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" "b/air_case/cmdc_32st/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" new file mode 100644 index 0000000000000000000000000000000000000000..a4a2d4ed84cf563f6213411d50f0d7b0b200518f --- /dev/null +++ "b/air_case/cmdc_32st/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\256\242\346\210\267\347\274\226\347\240\201\346\210\226\351\207\207\350\264\255\345\215\217\350\256\256\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc客户编码或采购协议为空_采购协议批量导入,32,32-4,sit,be +主数据平台:后台运营系统采购协议批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购协议导入模板_必填字段空.xlsx" + +# 第二步进行采购协议的导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 客户编码或采购协议为空_采购协议批量导入 + 用例名称:客户编码或采购协议为空_采购协议批量导入 + 输出:{"success":false,"code":"stock","message":"第2行客户编码或采购协议为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict4") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" "b/air_case/cmdc_32st/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" new file mode 100644 index 0000000000000000000000000000000000000000..bf988347b6fe2104c3eaa71aa8e9114d21484ca4 --- /dev/null +++ "b/air_case/cmdc_32st/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\345\257\274\345\205\245\344\270\215\350\203\275\344\270\272\347\251\272\346\240\241\351\252\214_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" @@ -0,0 +1,56 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导入不能为空校验_采购协议批量导入,32,32-3,sit,be +主数据平台:后台运营系统采购协议批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购协议导入模板_空.xlsx" + +# 第二步进行采购协议的导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") +request_body = commonFuc().get_business_data(module, "payload3") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 导入不能为空校验_采购协议批量导入 + 用例名称:导入不能为空校验_采购协议批量导入 + 输出:{"success":false,"code":"stock","message":"导入数据不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict3") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" "b/air_case/cmdc_32st/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" new file mode 100644 index 0000000000000000000000000000000000000000..fbb566bac1534e1444bf1cf38f327ad8f572e710 --- /dev/null +++ "b/air_case/cmdc_32st/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.air/\346\225\260\346\215\256\351\207\215\345\244\215\346\240\241\351\252\214\346\213\246\346\210\252_\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc数据重复校验拦截_采购协议批量导入,32,32-5,sit,be +主数据平台:后台运营系统采购协议批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购协议导入模板_重复.xlsx" + +# 第二步进行采购协议的导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 数据重复校验拦截_采购协议批量导入 + 用例名称:数据重复校验拦截_采购协议批量导入 + 输出:{"success":false,"code":"stock","message":"客户编码:1000086对应采购协议重复","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict5") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.air/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.air/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..de6198bba1833c3da51a0cfdf00c568c8121b37f --- /dev/null +++ "b/air_case/cmdc_32st/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.air/\347\231\273\345\275\225\346\216\245\345\217\243\346\226\260\345\242\236\351\233\205\345\237\271\351\205\215\347\275\256\345\255\227\346\256\265\351\252\214\350\257\201.py" @@ -0,0 +1,67 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc登录接口新增雅培配置字段验证,32,32-1,sit,be +主数据平台:后台运营系统登录接口 +""" + +from common.common_func import commonFuc +import requests +import uuid +from common.verification_code_ocr import VerificationCodeOcr +import json +import os +import hashlib + +module = "cmdc_32st" + +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取唯一识别码 +uuid_handle = uuid.uuid4() +# 获取验证码报文 +param = {"uuid": uuid_handle} +# 获取登录页面获取验证码地址 +code_url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "getVerifyCode_url") +# 发送请求获取验证码 +result = requests.get(code_url, params=param) +# print(result.content) +# 获取当前文件路径 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) +code_path = BASE_DIR + "/verifycode.png" +# 获取到验证码存入本地文件 +with open(code_path, 'wb') as f: + f.write(result.content) +# 识别并获取验证码 +code = VerificationCodeOcr(code_path, "rainbow123","rainbow123").base64_api() +# 获取登录地址 +cmdc_url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "do_login_url") +md = hashlib.md5(password.encode()) # 创建md5对象 +EncryptPassword = md.hexdigest() # 登录密码进行md5加密 +print('加密后的密码', EncryptPassword) # 加密后的密码 +# 组装请求报文 +request_body = {"userName": username, "password": EncryptPassword, "validateCode": code, "uuid": uuid_handle} + + +""" + + 场景: 登录接口新增雅培配置字段验证 + 用例名称:登录接口新增雅培配置字段验证 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(cmdc_url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 新增雅培配置字段 +check_list = ["exceedSign", "examineSign", "materialSign", "purchaseSign"] +# 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(cmdc_access_token, result) +commonFuc().check_variable_exist(check_list, result["data"]) diff --git "a/air_case/cmdc_32st/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" "b/air_case/cmdc_32st/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" new file mode 100644 index 0000000000000000000000000000000000000000..0b842ac3fdcacc8bd77feaf4b7b4b373dcc1f38e --- /dev/null +++ "b/air_case/cmdc_32st/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\347\251\272\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" @@ -0,0 +1,72 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc空数据导入校验验证_超发配置导入,32,32-11,sit,be +主数据平台:后台运营系统超发配置导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 第二步获取商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10_1") +request_body = commonFuc().get_business_data(module, "payload10_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +productCode = result["data"]["list"][product_random]["productCode"] +productName = result["data"]["list"][product_random]["productName"] +specifications = result["data"]["list"][product_random]["specifications"] +num = random.randint(1, 5) +# print(productCode) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/超发配置导入模板_空.xlsx" + +# 第三步进行超发配置导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 空数据导入校验验证_超发配置导入 + 用例名称:空数据导入校验验证_超发配置导入 + 输出:{"success":false,"code":"EXCEL","message":"excel数据内容不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict11") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.air/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.py" "b/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.air/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..4c8fb134f7697d24e8961e25ef332d02f3468ece --- /dev/null +++ "b/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.air/\350\216\267\345\217\226\350\266\205\345\217\221\350\256\260\345\275\225.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取超发记录,32,32-14,sit,be +主数据平台:后台运营系统获取超发记录接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发记录 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14") +# print(request_body) +""" + + 场景: 获取超发记录 + 用例名称:获取超发记录 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取超发记录数量 +result = json.loads(result.content) +purchase_id = result["data"]["total"] + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库超发记录数量 +sql = "SELECT count(t.stayOverflowId) FROM `cmdc-order`.tc_stay_overflow t WHERE companyCode = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..7687e57a810e6df359420e6ed91b6f358b86282b --- /dev/null +++ "b/air_case/cmdc_32st/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\266\205\345\217\221\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取超发配置列表,32,32-7,sit,be +主数据平台:后台运营系统获取超发配置列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发配置列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# print(request_body) +""" + + 场景: 获取超发配置列表 + 用例名称:获取超发配置列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取超发配置数量 +result = json.loads(result.content) +purchase_id = result["data"]["total"] + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库超发配置数量 +sql = "SELECT count(t.superId) FROM `cmdc-order`.tc_supernova t WHERE companyCode = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict7", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..1112a13290f972a807fd779c684367348fd9433d --- /dev/null +++ "b/air_case/cmdc_32st/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\350\256\260\345\275\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc超发记录导出功能验证,32,32-15,sit,be +主数据平台:后台运营系统超发记录导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发记录 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +flow_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取超发记录信息 +demandCode = result["data"]["list"][flow_random]["demandCode"] + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") +request_body = commonFuc().get_business_data(module, "payload16", demandCode) + +""" + 场景: 超发记录导出功能验证 + 用例名称:超发记录导出功能验证 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/超发记录导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中子需求单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandCode": excel.read_data()[0].get("子需求单号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict16", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..2badf7ddd50c3bc74a53308bada64b1ded7bed4f --- /dev/null +++ "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,95 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc超发配置导入功能验证,32,32-10,sit,be +主数据平台:后台运营系统超发配置导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +from common.db.db import mySql +import random +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 第二步获取商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10_1") +request_body = commonFuc().get_business_data(module, "payload10_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +productCode = result["data"]["list"][product_random]["productCode"] +productName = result["data"]["list"][product_random]["productName"] +specifications = result["data"]["list"][product_random]["specifications"] +num = random.randint(1, 5) +# print(num) +# print(productCode) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/超发配置导入模板.xlsx" + +# 将商品信息写入文件中 +excel = HandleExcel(file_path, "Sheet1") + +excel.write_data(row=2, column=1, value=productCode) +excel.write_data(row=2, column=2, value=productName) +excel.write_data(row=2, column=3, value=specifications) +excel.write_data(row=2, column=4, value=num) +excel.write_data(row=2, column=5, value=num) + +# 第三步进行超发配置导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") +request_body = commonFuc().get_business_data(module, "payload10") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 超发配置导入功能验证 + 用例名称:超发配置导入功能验证 + 输出:{"wholeQuantity":"%s"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库超发配置数量 +sql = "SELECT t.wholeQuantity FROM `cmdc-order`.tc_supernova t " \ + "WHERE companyCode = 00102 and productCode = {}".format(productCode) +total = int(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]) +# print(sql) +result = {"wholeQuantity": total} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict10", num) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..99f8b4e294f2a5761b3e8162a1095f121ed69a2a --- /dev/null +++ "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\227\245\345\277\227\350\256\260\345\275\225\351\252\214\350\257\201.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc超发配置导入日志记录验证,32,32-13,sit,be +主数据平台:后台运营系统超发配置导入日志接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发配置导入日志 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13") +# print(request_body) +""" + + 场景: 超发配置导入日志记录验证 + 用例名称:超发配置导入日志记录验证 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取超发配置导入记录数量 +result = json.loads(result.content) +purchase_id = result["data"]["total"] + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库超发配置导入记录数量 +sql = "SELECT count(t.id) FROM `cmdc-order`.tc_excel_log t " \ + "WHERE sheetName = 'supernova-D' and companyCode =00102 ORDER BY createTime desc" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..ac127408f9178cb59580eed356c1192ecf8e8ce7 --- /dev/null +++ "b/air_case/cmdc_32st/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc超发配置导出功能验证,32,32-9,sit,be +主数据平台:后台运营系统超发配置导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取超发配置列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +super_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取超发配置信息 +strsQuery = result["data"]["list"][super_random]["productCode"] + +# 第三步超发配置导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9", strsQuery) + +""" + + 场景: 超发配置导出功能验证 + 用例名称:超发配置导出功能验证 + 输出:{"strsQuery":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/超发配置导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中商品编码 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"strsQuery": excel.read_data()[0].get("商品编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict9", strsQuery) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..346ef42db880879f9633addcb0ab36149a304bc4 --- /dev/null +++ "b/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购协议导出功能验证,32,32-6,sit,be +主数据平台:后台运营系统采购协议导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import os + + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步采购协议导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") + +""" + + 场景: 采购协议导出功能验证 + 用例名称:采购协议导出功能验证 + 输出:{"tcdl01":"202401040918001"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购协议导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中采购协议 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"tcdl01": excel.read_data()[0].get("采购协议")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..85bc0dc6f9cf1a372bce453c403926d0e08d6c45 --- /dev/null +++ "b/air_case/cmdc_32st/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\217\350\256\256\346\211\271\351\207\217\345\257\274\345\205\245\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购协议批量导入功能验证,32,32-2,sit,be +主数据平台:后台运营系统采购协议批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购协议导入模板.xlsx" + +# 第二步进行采购协议的导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 采购协议批量导入功能验证 + 用例名称:采购协议批量导入功能验证 + 输出:{"tcdl01":"202401040918001"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取导入成功后采购协议号 +result = json.loads(result.content) +result = {"tcdl01":result["data"][0]["tcdl01"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict2") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_32st/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" "b/air_case/cmdc_32st/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" new file mode 100644 index 0000000000000000000000000000000000000000..b20bb9830604cd69eaf4e7e1ef51c1567e8c2099 --- /dev/null +++ "b/air_case/cmdc_32st/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.air/\351\207\215\345\244\215\346\225\260\346\215\256\345\257\274\345\205\245\346\240\241\351\252\214\351\252\214\350\257\201_\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245.py" @@ -0,0 +1,83 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc重复数据导入校验验证_超发配置导入,32,32-12,sit,be +主数据平台:后台运营系统超发配置导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json +import os + +module = "cmdc_32st" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1_be") +password = commonFuc().get_business_data(module, "password1_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 第二步获取商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10_1") +request_body = commonFuc().get_business_data(module, "payload10_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +productCode = result["data"]["list"][product_random]["productCode"] +productName = result["data"]["list"][product_random]["productName"] +specifications = result["data"]["list"][product_random]["specifications"] +num = random.randint(1, 5) +# print(productCode) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/超发配置导入模板_数据重复.xlsx" + +# 第三步进行超发配置导入操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") +request_body = commonFuc().get_business_data(module, "payload12") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 重复数据导入校验验证_超发配置导入 + 用例名称:重复数据导入校验验证_超发配置导入 + 输出:{"status":3} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库导入状态 +sql = "SELECT t.status FROM `cmdc-order`.tc_excel_log t " \ + "WHERE sheetName = 'supernova-D' and companyCode =00102 ORDER BY createTime desc" +status = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] +result = {"status": status} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict12") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" index eacd0d0061b6f3edaa224b75fc8683fffa9da480..b228bd90574ddd093994d4622f2fc404c6571009 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" @@ -35,7 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload4") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.py" index d55628e2bed259171ce4fbbd0676bd8ece5e3ccd..8ea36285e6065cc3456680337a305b59a31e29b4 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\225\206\345\223\201\350\266\205\346\225\260\351\207\217\351\252\214\350\257\201.py" @@ -35,7 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload36") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict36") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.py" index 4f29e05aebae81d7d030c83658251c6bfd00d1a3..039d231d183240735f302ad265d1595f0b08b43e 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214.py" @@ -35,7 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload20") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.py" index 7546651e902e28feed296bd8c3e96c6debbe1363..2b3c1ccd317964ed4a23ab461040584a761cb065 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246_\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250\346\210\226\350\200\205\347\253\231\347\202\271\345\267\262\344\270\213\346\236\266.py" @@ -35,7 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload35") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict35") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" index 1390af8a7f5aac4def2c0c2ebd961468c3c38331..208668d14dbdb1387918e27a40771d536ed389ac 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" @@ -55,7 +55,10 @@ request_body = commonFuc().get_business_data(module, "payload5", product_id, pri # 发送请求 result = requests.post(url1, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" index b6ac123e8e471f34f9030444e7c089bbc07d5d50..8b5e08af31c32937e6accce6030152284bdab25f 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" @@ -55,7 +55,10 @@ if result["data"]["list"][0]["isControlSales"] == 1: # 发送请求 result1 = requests.post(url1, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) + result1["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") print(check_dict) diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" index 5239296385183de0ecdec6305a58d25f77a01570..abe91c033fd45b4c67986986106dc2c608ab588b 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" @@ -55,7 +55,10 @@ request_body1 = commonFuc().get_business_data(module, "payload11", product_id, p """ # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) +result1["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" index 2587a05b1ac43db31a32719f80cbfdb868d4c41d..ef3bfa6f4e65680c9bce3b71bc627c57866b1052 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" @@ -52,7 +52,10 @@ request_body1 = commonFuc().get_business_data(module, "payload8", product_id, pr """ # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) +result1["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" index 608047b19169724639e66fd0eea6f1445c3555db..b25a912f5337910b815155831a76ae49b985f83b 100644 --- "a/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" +++ "b/air_case/cmdc_buyercar_list/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.air/\346\226\260\345\242\236\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246.py" @@ -26,7 +26,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") request_body1 = commonFuc().get_business_data(module, "payload300") # 发送请求 result1 = requests.post(url, json=request_body1, headers=headers) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) +result1["api_time"] = api_time # 获取预期结果 check_dict1 = commonFuc().get_business_data(module, "checkDict300") # 断言实际结果中是否包含预期结果的内容 @@ -42,7 +45,9 @@ request_body = commonFuc().get_business_data(module, "payload301") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + result = json.loads(result.content) + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict300") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" "b/air_case/cmdc_buyercar_list/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" index 52f92090ec504890bbc71a86c8cd0cc54c3e027a..acf7116ddff24e78a1d34c6ccc26c4fc4f3ff61e 100644 --- "a/air_case/cmdc_buyercar_list/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_buyercar_list/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\346\267\273\345\212\240JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" @@ -52,7 +52,10 @@ request_body1 = commonFuc().get_business_data(module, "payload10", product_id, p """ # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) +result1["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" "b/air_case/cmdc_buyercar_list/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" index 8659b53d073ad4b6e5225d57b3a465fe5188b05c..ac45c569f75c13706f26129954a314b9aa0c3f86 100644 --- "a/air_case/cmdc_buyercar_list/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_buyercar_list/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload1") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") diff --git "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.air/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.py" "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.air/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.py" index 3214506b42e9c8c42f2fc7628841259e17cca354..ee9c13c14e09dd5ee6b978f8c97d8eba902d47f1 100644 --- "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.air/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.py" +++ "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.air/\350\264\255\347\211\251\350\275\246\345\225\206\345\223\201\347\247\273\351\231\244.py" @@ -2,7 +2,7 @@ __author__ = "liguangyu" """ -case_tag:cmdc_api,cmdc用户购物车商品移除,2252,2252-9,sit,bs +case_tag:cmdc_api,cmdc购物车商品移除,2252,2252-9,sit,bs 主数据平台:多采商城购物车列表商品删除接口 """ @@ -70,8 +70,11 @@ if result_product_id == product_id: """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.content) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 - commonFuc().check_result(check_dict, result) + commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.py" "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.py" index efeb2d0c758c4adf7e5902734e0a408ebf35d338..6684cba1397bb16e011e23ba69f1256549c7b9e6 100644 --- "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\225\260\351\207\217\344\277\256\346\224\271\351\252\214\350\257\201.py" @@ -43,7 +43,10 @@ if invalid_sign == 0: # print(request_body1) # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers) + # 获取接口响应时间 + api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) + result1["api_time"] = api_time # 获取预期结果 check_dict1 = commonFuc().get_business_data(module, "checkDict80") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.air/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.py" "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.air/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.py" index 0d07623ddd9986d42c6a3c6fe8ceeaf1ea1c4353..9c938a1d55671378d50aff9eceba36ee66a4f89f 100644 --- "a/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.air/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_buyercar_list/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.air/\350\264\255\347\211\251\350\275\246\346\226\260\345\242\236\345\225\206\345\223\201.py" @@ -57,8 +57,10 @@ request_body1 = commonFuc().get_business_data(module, "payload2", product_id, pr """ # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) -# print(result1) +result1["api_time"] = api_time if result1["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") diff --git "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.py" "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.py" index 285ec239cafca3e6729d0fe19d1e35fb9ba1e85f..c31f5a909282d86053af3372a2a2634afde780c1 100644 --- "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.py" +++ "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\255\220\347\253\231\347\202\271\344\270\215\345\255\230\345\234\250.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload24", company_id) """ # 发送请求 result = requests.post(url_batch, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict24") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.py" "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.py" index be59703c11f4e265ffe40c98df0b425a548753a7..d6d76ba4acece6d441ed48adf94a252780d2e42e 100644 --- "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.py" +++ "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\345\277\205\345\241\253\345\255\227\346\256\265\347\274\272\345\244\261.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload22") """ # 发送请求 result = requests.post(url_batch, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.py" "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.py" index 87681a8831471f1d2005ca182b05bcd8f9338b12..33da21dcd00a8189cedf8718da1b04f95da93513 100644 --- "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.py" +++ "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\345\244\261\350\264\245.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload21", product_code) """ # 发送请求 result = requests.post(url_batch, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.py" "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.py" index 47173383bd1b18864d3af3ed25bc7cba83adeebb..70bfa51214207a7e4f5513329a3c0d7ca8d414fd 100644 --- "a/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.py" +++ "b/air_case/cmdc_buyercar_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201-\346\267\273\345\212\240\346\210\220\345\212\237.py" @@ -31,7 +31,8 @@ result_body_user_websites = requests.post(url_user_websites, json=request_body_u result_body_user_websites = json.loads(result_body_user_websites.content) # 获取站点对应的id -company_id = result_body_user_websites["data"][3]["companyId"] +company_id = result_body_user_websites["data"][2]["companyId"] +# print(company_id) # 第三步切换至站点 url_switch_website = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_switch_website") @@ -47,10 +48,11 @@ request_body_website_product = commonFuc().get_business_data(module, "payload_we # 发送请求 result_body_website_product = requests.post(url_website_product, json=request_body_website_product, headers=headers) result_body_website_product = json.loads(result_body_website_product.content) - +# print(result_body_website_product) # 获取站点的商品信息 product_code = result_body_website_product["data"]["list"][0]["productcode"] + # 第五步获取通过Excel复制添加商品 # 获取通过Excel复制添加商品接口地址 url_batch = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_batch") @@ -65,8 +67,10 @@ request_body = commonFuc().get_business_data(module, "payload23", product_code, """ # 发送请求 result = requests.post(url_batch, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index 4224f982ec6ddaa0cb8639639f1e570c0d6b13f6..db68e2fab45a196bd52886b1b5620e00ff2caec4 100644 --- "a/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -40,11 +40,13 @@ request_body = commonFuc().get_business_data(module, "payload8") # print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # 获取查询结果中商品id result = {"productId": result["data"]["list"][0]["list"][0]["productId"]} - +result["api_time"] = api_time # # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") # # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.py" "b/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.py" index e3d52f4b4f7f014fa1c4fde7e95d68d08c060c8e..f72a8b70585714406a0b5fb3c3f0ccc9a3af1545 100644 --- "a/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_buyercart_handle/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.air/\350\264\255\347\211\251\350\275\246\346\224\257\346\214\201\350\267\250\347\253\231\345\225\206\345\223\201\344\270\213\345\215\225\351\252\214\350\257\201.py" @@ -31,10 +31,10 @@ result1 = requests.post(url_add, json=request_body1, headers=headers) request_body2 = commonFuc().get_business_data(module, "payload2") result2 = requests.post(url_add, json=request_body2, headers=headers) result2 = json.loads(result2.content) -# 获取预期结果 -check_dict1 = commonFuc().get_business_data(module, "checkDict1") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict1, result2) +# # 获取预期结果 +# check_dict1 = commonFuc().get_business_data(module, "checkDict1") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict1, result2) """ 场景:购物车支持跨站商品下单验证 @@ -79,8 +79,10 @@ request_body = commonFuc().get_business_data(module, "payload30", buyercart_id_1 # print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: if result["data"]: # # 获取预期结果 diff --git "a/air_case/cmdc_commodity_activity/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7cbfa60a26342fe81ce38aa2cc25ed82eba5ea69 --- /dev/null +++ "b/air_case/cmdc_commodity_activity/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\344\277\203\351\224\200\346\264\273\345\212\250\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc促销活动新增功能验证,2262,2262-43,sit,bs +主数据平台:运营后台管理系统促销活动新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_commodity_activity" + +# 第一步登录后台运营平台获取cmdc_access_token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步促销活动新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43") + +""" + 场景:促销活动新增功能验证 + 用例名称:促销活动新增功能验证 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict43") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_commodity_activity/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..c30ee094843519bb8b2d5600c230129a71a8aec6 --- /dev/null +++ "b/air_case/cmdc_commodity_activity/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\344\277\203\351\224\200\346\264\273\345\212\250\347\274\226\350\276\221\346\233\264\346\226\260\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc促销活动编辑更新功能验证,2262,2262-44,sit,bs +主数据平台:运营后台管理系统促销活动编辑更新接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_commodity_activity" + +# 第一步登录后台运营平台获取cmdc_access_token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取活动列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44_1") +request_body = commonFuc().get_business_data(module, "payload44_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取活动信息 +activityBasicId = result["data"]["list"][0]["activityBasicId"] + +# 第三步进行活动编辑更新操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44") +request_body = commonFuc().get_business_data(module, "payload44", activityBasicId) + +""" + 场景:促销活动编辑更新功能验证 + 用例名称:促销活动编辑更新功能验证 + 输出:{"activityBasicId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 获取活动信息 +result = json.loads(result.content) +result = {"activityBasicId": result["data"]["activityBasicId"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict44", activityBasicId) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_commodity_activity/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..d6b5fa493b5c137762c616704a4be78340c21558 --- /dev/null +++ "b/air_case/cmdc_commodity_activity/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\344\277\203\351\224\200\346\264\273\345\212\250\347\273\210\346\255\242\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc促销活动终止功能验证,2262,2262-45,sit,bs +主数据平台:运营后台管理系统促销活动终止接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_commodity_activity" + +# 第一步登录后台运营平台获取cmdc_access_token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取活动列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44_1") +request_body = commonFuc().get_business_data(module, "payload44_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取活动信息 +activityBasicId = result["data"]["list"][0]["activityBasicId"] + +# 第三步促销活动终止 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url45") +request_body = commonFuc().get_business_data(module, "payload45", activityBasicId) + +""" + 场景:促销活动终止功能验证 + 用例名称:促销活动终止功能验证 + 输出:{"activityBasicId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 获取活动信息 +result = json.loads(result.content) +result = {"activityBasicId": result["data"]["activityBasicId"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict45", activityBasicId) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index c0f344319be5f9e4fd1dc290a684f48ff0d5a53c..7ffc1256f597d2a39c35b2643decb797c165e3c2 100644 --- "a/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -9,14 +9,15 @@ case_tag:cmdc_api,cmdc促销活动列表查询条件验证,2262,2262-39,sit,bs from common.common_func import commonFuc from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import random import json module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -28,15 +29,18 @@ request_body = commonFuc().get_business_data(module, "payload1") result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) +# 生成随机数 +activity_random = random.randint(0, len(result["data"]["list"]) - 1) + # 获取促销活动信息activityBasicId、activityName、activityStatus、activityType、startTime、endTime、cStartTime、cEndTime -activity_basic_id = result["data"]["list"][0]["activityBasicId"] -activity_name = result["data"]["list"][0]["activityName"] -activity_status = result["data"]["list"][0]["activityStatus"] -activity_type = result["data"]["list"][0]["activityType"] -start_time = result["data"]["list"][0]["effectiveDate"] -end_time = result["data"]["list"][0]["expirationDate"] -c_start_time = result["data"]["list"][0]["createTime"] -c_end_time = result["data"]["list"][0]["expirationDate"] +activity_basic_id = result["data"]["list"][activity_random]["activityBasicId"] +activity_name = result["data"]["list"][activity_random]["activityName"] +activity_status = result["data"]["list"][activity_random]["activityStatus"] +activity_type = result["data"]["list"][activity_random]["activityType"] +start_time = result["data"]["list"][activity_random]["effectiveDate"] +end_time = result["data"]["list"][activity_random]["expirationDate"] +c_start_time = result["data"]["list"][activity_random]["createTime"] +c_end_time = result["data"]["list"][activity_random]["expirationDate"] # 第三步促销活动管理列表查询条件验证 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") @@ -51,9 +55,12 @@ request_body = commonFuc().get_business_data(module, "payload_list", activity_ba # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) result = {"activityBasicId": result["data"]["list"][0]["activityBasicId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_list", activity_basic_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.py" index 59bdd03785b6259099f5d2df7cf3d4f01bff94bd..0815509700c862b6a320197082e20383e3f6657c 100644 --- "a/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_commodity_activity/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.air/\344\277\203\351\224\200\346\264\273\345\212\250\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -8,6 +8,7 @@ case_tag:cmdc_api,cmdc促销活动列表获取,2262,2262-38,sit,bs from common.common_func import commonFuc from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql import requests import json @@ -17,8 +18,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -29,13 +30,30 @@ request_body = commonFuc().get_business_data(module, "payload1") """ 场景:查询促销活动列表 用例名称:查询促销活动列表 - 输出:{"success":true,"code":"200","message":"OK"} + 输出:{"total":"%s"} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 获取列表中促销活动数量 result = json.loads(result.content) +result = {"total": result["data"]["total"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中促销活动数量 +sql = "SELECT count(t.activityBasicId) FROM `cmdc-order`.tc_activity_basic t WHERE companyCode = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + # 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict1") +check_dict = commonFuc().get_business_data(module, "checkDict1", total) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.py" index 65e1126bfd8579f196476586048f329b319da987..7afa58e867d96f8e46e89813e323cef4d41ec275 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\346\264\273\345\212\250\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -27,7 +27,7 @@ request_body = commonFuc().get_business_data(module, "payload15") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取活动对应的activityBasicId和activityType activity_basic_id = result["data"]["list"][0]["activityBasicId"] activity_type = result["data"]["list"][0]["activityType"] @@ -43,7 +43,7 @@ result = json.loads(result.content) product_id = result["data"][0]["productId"] company_code = result["data"][0]["companyCode"] product_code = result["data"][0]["productCode"] - +# print(product_code) # 第四步获取对应商品详情 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") request_body = commonFuc().get_business_data(module, "payload7", product_id, company_code, product_code) @@ -51,13 +51,17 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com """ 场景:商品参与买赠活动验证 用例名称:商品参与买赠活动验证 - 输出:{"activityBasicId": 10135} + 输出:{"productCode": 10146174} """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -result = {"productId": result["data"]["zero"]["purchaseZeroProductList"][0]["productId"]} +# print(result) +result = {"productCode": result["data"]["zero"]["purchaseZeroProductList"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" index a65ccbb6d66f84fd4680ab50440ccee62db1ba97..1a3bb3b71839c7729f559db9a503968dbe66d029 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" @@ -17,8 +17,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -68,8 +68,11 @@ request_body = [ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"purchaseZeroProductList": result["data"][0]["purchaseZeroProductList"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" index ab22ddc5f0bac5d1794941ec6a3bc15ac98db6f4..606aa97d6409e45b5a6b0d71f799fcb8d44edf51 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.air/\345\225\206\345\223\201_\344\271\260\350\265\240_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\350\265\240\345\223\201\351\252\214\350\257\201.py" @@ -17,8 +17,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -44,7 +44,7 @@ result = json.loads(result.content) # 获取活动商品id、companyCode、productCode company_code = result["data"][0]["companyCode"] product_code = result["data"][0]["productCode"] -purchase_quantity = random.randint(3, 10) +purchase_quantity = random.randint(5, 10) # 获取登录所需账号密码 username = commonFuc().get_business_data(module, "username") @@ -63,13 +63,16 @@ request_body = [ """ 场景:购买满足条件买赠商品验证赠品是否赠送 用例名称:购买满足条件买赠商品验证赠品是否赠送 - 输出:{"productId": 7670} + 输出:{"productCode": 10000841} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -result = {"productId": result["data"][0]["purchaseZeroProductList"][0]["productId"]} +result = {"productCode": result["data"][0]["purchaseZeroProductList"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.py" index 34fc726f91077d0d0fa3b506c1dac08f097ef4d3..fee6cc3f300f50898438b407934bcbd772961c2e 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\346\264\273\345\212\250\351\252\214\350\257\201.py" @@ -56,8 +56,11 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"activityBasicId": result["data"]["activity"]["activityBasicId"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" index 9a5528bfa5edc154e243a0b2b4b64ed7e2c6e5d7..4f4ffba9029da6ceb02f7ec22cfadeac30d87658 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -60,8 +60,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] +result["api_time"] = api_time # print(activity_amount) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" index 642b5a38ee994d7f8e9c6f5218c560dfaa8140d7..d34cd83882dc87f638dc249fc98ce7797b6c646a 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\212\230\346\211\243_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -45,7 +45,7 @@ product_id = result["data"][0]["productId"] company_code = result["data"][0]["companyCode"] product_code = result["data"][0]["productCode"] product_price = result["data"][0]["referencePrice"] -purchase_quantity = random.randint(2, 10) +purchase_quantity = random.randint(3, 10) # 计算减免金额 amount = (product_price - (result["data"][0]["unitDiscount"] * product_price)/100) * purchase_quantity # 保留两位小数(四舍五入) @@ -64,8 +64,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] +result["api_time"] = api_time # print(activity_amount) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", amount) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.air/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.air/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.py" index 6cd5999e0b790202ebed915da3d2a693fe6f3e60..48c5f4c96640b8fc67a29ca1f299ecd74a7ce6ef 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.air/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.air/\345\225\206\345\223\201_\346\234\252\345\217\202\344\270\216\346\264\273\345\212\250.py" @@ -33,9 +33,12 @@ request_body = commonFuc().get_business_data(module, "payload8") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) result = {"activity": result["data"]["activity"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.py" index ded7cc65de21264496686e0445966c89bad88985..f6cea9c6cae3200a6ee50ab0dc8b47efd58ee3e0 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\346\264\273\345\212\250\351\252\214\350\257\201.py" @@ -56,8 +56,11 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"activityBasicId": result["data"]["activity"]["activityBasicId"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" index a0c886635726eb812447787d157c9aabf25bb411..0c19b6c7caefbc414ff2aee656c583c1554d5e9b 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -60,8 +60,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] +result["api_time"] = api_time # print(activity_amount) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" index e02ee3c471312a63754528f05093126468832eb8..92f214972a5bc63492e12ca255d474d43dd7e66a 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\346\273\241\345\207\217_\350\264\255\344\271\260\346\225\260\351\207\217\346\273\241\350\266\263_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -45,7 +45,7 @@ product_id = result["data"][0]["productId"] company_code = result["data"][0]["companyCode"] product_code = result["data"][0]["productCode"] product_price = result["data"][0]["referencePrice"] -purchase_quantity = random.randint(3, 10) +purchase_quantity = random.randint(11, 20) # 计算减免金额 amount = result["data"][0]["reductTotal"] # 保留两位小数(四舍五入) @@ -64,8 +64,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] +result["api_time"] = api_time print(activity_amount) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", amount) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" index 59c54c81c88e0f54d5ce349b2350b325db14a06d..119622dfdb7ad00730a6e5b1d6a786b9b15fd7ae 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\344\270\215\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -24,7 +24,7 @@ headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_toke # 第二步进行促销活动列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload100") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -45,7 +45,7 @@ product_id = result["data"][0]["productId"] company_code = result["data"][0]["companyCode"] product_code = result["data"][0]["productCode"] product_price = result["data"][0]["referencePrice"] -purchase_quantity = random.randint(1, 5) +purchase_quantity = random.randint(1, 4) # print(purchase_quantity) # 第四步验证减免金额正确性 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") @@ -60,9 +60,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] -print(activity_amount) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" index 2c9269270571e99bc78811e96b5c550c455f873b..a4b6720d9657643f85338664d1eea9c67acc7ad9 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\225\260\351\207\217\346\273\241\350\266\263\350\247\204\345\210\231_\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -24,7 +24,7 @@ headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_toke # 第二步进行促销活动列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload100") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -63,9 +63,11 @@ request_body = commonFuc().get_business_data(module, "payload10", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) activity_amount = result["data"]["orderProductList"][0]["activityAmount"] -print(activity_amount) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", amount) print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.py" index 5b836c8b71886c735c37453a587ca84ca5639ae9..6a9c67901591ef306e87fb36224bbe12d29de4cb 100644 --- "a/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.air/\345\225\206\345\223\201_\347\211\271\344\273\267_\346\264\273\345\212\250\351\252\214\350\257\201.py" @@ -23,7 +23,7 @@ headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_toke # 第二步进行促销活动列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload100") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -56,8 +56,11 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"activityBasicId": result["data"]["activity"]["activityBasicId"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", activity_basic_id) diff --git "a/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.air/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.py" "b/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.air/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.py" index 8d27841b0b1d59e20812c3f71953083c3b167e9f..2d0c550026187e161d9ceb1f2ac3fdb3757a409a 100644 --- "a/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.air/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.py" +++ "b/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.air/\346\237\245\350\257\242\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\344\277\203\351\224\200\346\264\273\345\212\250.py" @@ -15,15 +15,15 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 第二步进行促销活动列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload1_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -35,6 +35,7 @@ activity_type = result["data"]["list"][0]["activityType"] # 第三步获取对应活动包含的商品信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") request_body = commonFuc().get_business_data(module, "payload3", activity_basic_id, activity_type) +# print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -56,7 +57,10 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") diff --git "a/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.air/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.py" "b/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.air/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.py" index d29a08ef5e7c65a96ae7d61894164e50ecaec8b1..26004170ca7577f9cc674cfb1b7b4213a1c89282 100644 --- "a/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.air/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.py" +++ "b/air_case/cmdc_commodity_activity/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.air/\346\237\245\350\257\242\345\225\206\345\223\201\350\257\246\346\203\205.py" @@ -15,15 +15,15 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 第二步进行促销活动列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload1_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -54,8 +54,10 @@ request_body = commonFuc().get_business_data(module, "payload6", product_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" index 7b34061f01f3397bb6b89dbf8e81c65185e2bd1e..4a5c95a8c60fcab92d3a61df7f485aea0543c5a8 100644 --- "a/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\235\236\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -27,7 +27,7 @@ request_body = commonFuc().get_business_data(module, "payload22") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取活动对应的activityBasicId和activityType activity_basic_id = result["data"]["list"][0]["activityBasicId"] activity_type = result["data"]["list"][0]["activityType"] @@ -47,20 +47,22 @@ product_code = result["data"][0]["productCode"] # 第四步获取对应商品详情 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") request_body = commonFuc().get_business_data(module, "payload7", product_id, company_code, product_code) -# print(request_body) """ 场景:商品活动非黑名单用户验证 用例名称:商品活动非黑名单用户验证 - 输出:{"activityBasicId": 10127} + 输出:{"activityBasicId": "%s"} """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -result = {"activityBasicId": result["data"]["activity"]["activityBasicId"]} +result = {"activityBasicId": result["data"]["zero"]["purchaseZeroProductList"][0]["activityBasicId"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", activity_basic_id) -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" index 4a733c304a271926274ff963b4855dd21f6652bd..bb60959ddb84f09bca9839e02c3536a8b4c49cb1 100644 --- "a/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.air/\346\264\273\345\212\250\351\273\221\345\220\215\345\215\225\347\224\250\346\210\267\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -64,9 +64,12 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, com # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) print(result) result = {"activity": result["data"]["activity"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22") diff --git "a/air_case/cmdc_commodity_activity/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..bed2f91062e64ed654bcc877f946a0b89d8074c8 --- /dev/null +++ "b/air_case/cmdc_commodity_activity/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\237\346\210\220\346\264\273\345\212\250\350\247\204\345\210\231code\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc生成活动规则code接口验证,2262,2262-41,sit,bs +主数据平台:运营后台管理系统生成活动规则code接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_commodity_activity" + + +# 第一步登录后台运营平台获取cmdc_access_token +# # 获取登录所需账号密码 +# username = commonFuc().get_business_data(module, "username30") +# password = commonFuc().get_business_data(module, "password30") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步生成活动规则code +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url41") +request_body = commonFuc().get_business_data(module, "payload41") + +""" + 场景:生成活动规则code接口验证 + 用例名称:生成活动规则code接口验证 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict41") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.py" "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.py" index 4afff3aa949d1f571dea44e8b408d7a015276aae..836b7b0620cee7f5d3982ec3cb9ce5f643f22c97 100644 --- "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\257\271\345\272\224\347\232\204\350\265\240\345\223\201\344\277\241\346\201\257.py" @@ -10,14 +10,14 @@ from common.common_func import commonFuc from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin import requests import json -import random + module = "cmdc_commodity_activity" # 第一步登录多采商城获取token信息 # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username5") +password = commonFuc().get_business_data(module, "password5") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload16") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 diff --git "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.py" "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.py" index 236f2a2e344edc763ff266843190cd1ecc134abf..b3f43e26f964f79a1b5030ddc6608c92937fbd0c 100644 --- "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\214\205\345\220\253\347\232\204\345\225\206\345\223\201\344\277\241\346\201\257.py" @@ -15,8 +15,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -44,8 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload3", activity_basic_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.py" "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.py" index ab0c38d00ecb8e181a22c0e73edd15982505dd27..668d2162337348a16fede2f94de0da2b213f6c18 100644 --- "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\237\272\346\234\254\344\277\241\346\201\257.py" @@ -15,8 +15,8 @@ module = "cmdc_commodity_activity" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -43,8 +43,10 @@ request_body = commonFuc().get_business_data(module, "payload2", activity_basic_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.py" "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.py" index 3a14a6880fd2f8d3743514d83dd2166c4f1bbb30..e814d06cdc8538b9ca11f74e429842aa306fa724 100644 --- "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.py" +++ "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\346\214\207\345\256\232\345\256\242\346\210\267\345\267\256\345\274\202\344\277\203\351\224\200\350\247\204\345\210\231.py" @@ -45,8 +45,10 @@ request_body = commonFuc().get_business_data(module, "payload5", activity_basic_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.py" "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.py" index 406b41b8d511077ee5fd7f53d4f347736aed77e8..f64c6f626f98c4825c59d6ddb3e1d4ff4117ed05 100644 --- "a/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.py" +++ "b/air_case/cmdc_commodity_activity/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.air/\350\216\267\345\217\226\346\264\273\345\212\250\345\257\271\345\272\224\347\232\204\351\273\221\345\220\215\345\215\225.py" @@ -43,8 +43,10 @@ request_body = commonFuc().get_business_data(module, "payload4", activity_basic_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..06a2331c803dadfae277609a9d3b5f5dd7914746 --- /dev/null +++ "b/air_case/cmdc_commodity_activity/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\200\211\350\265\240\344\277\203\351\224\200\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,77 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc选赠促销导出功能验证,2262,2262-40,sit,bs +主数据平台:运营后台管理系统选赠促销导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_commodity_activity" + + +# 第一步登录后台运营平台获取cmdc_access_token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步进行促销活动列表获取 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40_1") +request_body = commonFuc().get_business_data(module, "payload40_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +activity_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取促销活动信息 +activityBasicId = result["data"]["list"][activity_random]["activityBasicId"] +activityName = result["data"]["list"][activity_random]["activityName"] +print(activityName) +# 第三步进行选赠活动信息导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40") +request_body = commonFuc().get_business_data(module, "payload40", activityBasicId, activityBasicId) + +""" + 场景:选赠促销导出功能验证 + 用例名称:选赠促销导出功能验证 + 输出:{"activityName": "%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/选赠活动列表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中活动名称 +excel = HandleExcel(file_path, "Sheet1") +result = {"activityName": excel.read_data()[0].get("活动名称")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict40", activityName) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_commodity_activity/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.air/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.py" "b/air_case/cmdc_commodity_activity/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.air/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..3c9470b4a115552cf6f7b71a66f9bb078f6c904f --- /dev/null +++ "b/air_case/cmdc_commodity_activity/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.air/\351\200\232\350\277\207code\350\216\267\345\217\226\346\234\215\345\212\241\345\225\206\345\223\201\344\277\241\346\201\257.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc通过code获取服务商品信息,2262,2262-42,sit,bs +主数据平台:运营后台管理系统通过code获取服务商品信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_commodity_activity" + +# 第一步登录后台运营平台获取cmdc_access_token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username30") +password = commonFuc().get_business_data(module, "password30") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步通过code获取服务商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url42") +request_body = commonFuc().get_business_data(module, "payload42") + +""" + 场景:通过code获取服务商品信息 + 用例名称:通过code获取服务商品信息 + 输出:{"companyCode":"00102"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() + +# 获取商品所属站点 +result = json.loads(result.content) +result = {"companyCode": result["data"][0]["filialeCode"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict42") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.py" index 270e410ddb8fb0c5677495fe207225eb49a63463..d60b73ce5b6185f062f606e8fc452157f9be1f19 100644 --- "a/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\345\225\206\345\223\201\351\252\214\350\257\201.py" @@ -66,9 +66,12 @@ request_body = commonFuc().get_business_data(module, "payload21", company_code, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # 获取活动客户对应的活动规则id result = {"activityBasicId": result["data"][0]["activityBasicId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20", activity_basic_id) print(check_dict) diff --git "a/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.py" "b/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.py" index 483ce0a79aef7ecccf49dca0e2aa4698553d6483..d507e29b521047d59e72057529ea81f2c5e0b637 100644 --- "a/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_commodity_activity/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.air/\351\233\205\345\237\271\351\200\211\350\265\240_\346\264\273\345\212\250\347\224\250\346\210\267\351\252\214\350\257\201.py" @@ -65,9 +65,12 @@ request_body = commonFuc().get_business_data(module, "payload20", company_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # 获取活动客户对应的活动规则id result = {"activityBasicId": result["data"][0]["activityBasicId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20", activity_basic_id) print(check_dict) diff --git "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.py" "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.py" index 184c9283e4a1803db2f679e39d6e529355126c78..17116a5fec356626de73f89f4ea507498e61f837 100644 --- "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\244\261\346\225\210\345\225\206\345\223\201.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.py" "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.py" index 1aeb63317fe3fab7a62cc73fd7deb5cfe9aee655..ca0dd0fd48877a9b8fcb0747992ccbbc6fba7aab 100644 --- "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.air/\346\237\245\350\257\242\345\267\262\344\270\212\346\236\266\345\225\206\345\223\201.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.air/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.py" "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.air/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.py" index 58254ca372403b72f05d5d7cc56ba5640b070b2f..0413d1b6eb93fc97876e95028d7778077d1b79ae 100644 --- "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.air/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.air/\346\237\245\350\257\242\346\216\247\351\224\200\345\225\206\345\223\201.py" @@ -32,7 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") print(check_dict) diff --git "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\350\265\240\345\223\201.air/\346\237\245\350\257\242\350\265\240\345\223\201.py" "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\350\265\240\345\223\201.air/\346\237\245\350\257\242\350\265\240\345\223\201.py" index 168233ecaa5249fa8427c15f2533a9ec1fc46afd..93d91ef6b74a84f3c4d0b9faa9668697327e9450 100644 --- "a/air_case/cmdc_commodity_list/\346\237\245\350\257\242\350\265\240\345\223\201.air/\346\237\245\350\257\242\350\265\240\345\223\201.py" +++ "b/air_case/cmdc_commodity_list/\346\237\245\350\257\242\350\265\240\345\223\201.air/\346\237\245\350\257\242\350\265\240\345\223\201.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload4") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") print(check_dict) diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.py" index eb4d28bb3e2dbb79ff891fd4c5b7fc9fa84499a7..f971e9932ac847ba4fce23de6c764c20137100ea 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270_\345\257\274\345\205\245\345\274\217_\347\224\250\346\210\267\345\217\221\346\224\276\351\252\214\350\257\201.py" @@ -32,9 +32,13 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") # 发送请求 result = requests.get(url, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) result = {"couponId": result["data"][0]["couponId"]} +result["api_time"] = api_time # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index 7449cb07682150e0f22d7eef9b3cacfe389b4d41..a1647b8e741249db6d891ac6340aafc37516cf6a 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -49,8 +49,11 @@ request_body = commonFuc().get_business_data(module, "payload2", coupon_id, coup # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"couponId": result["data"]["list"][0]["couponId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", coupon_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.py" index fe6f63b06273a30f81823deeb78cc6eccca3e08e..3ceff515e629d55089ba9243ac099d5a057a3d07 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\225\206\345\223\201\351\252\214\350\257\201.py" @@ -28,9 +28,9 @@ request_body = commonFuc().get_business_data(module, "payload_goods") result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) # 获取商品的productId、productCode、companyCode -product_id = result["data"]["list"][0]["productid"] -product_code = result["data"]["list"][0]["productcode"] -company_code = result["data"]["list"][0]["filialecode"] +product_id = result["data"]["list"][1]["productid"] +product_code = result["data"]["list"][1]["productcode"] +company_code = result["data"]["list"][1]["filialecode"] # 第四步验证商品活动列表中是否包含对应的优惠券 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_discount") @@ -44,13 +44,17 @@ request_body = [{"productId": product_id, "productCode": product_code, "companyC # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) + # print(result) result = {"couponAmount": result["data"][0]["coupon"]["couponAmount"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") -print(check_dict) + # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.air/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.air/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.py" index 4ab343e05fc2b2acaf88831d89e63cb75318d5c2..9e75a133d59afc155b4d8e339644044827dca19b 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.air/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.air/\344\274\230\346\203\240\345\210\270\345\237\272\346\234\254\344\277\241\346\201\257\346\237\245\350\257\242.py" @@ -32,8 +32,11 @@ request_body = commonFuc().get_business_data(module, "payload8") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) result = {"couponId": result["data"]["couponId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" index c7fad5492211e3e568119c6ca7ea3678a0e52f73..7d848b27eb324c9b2867f1f9612dcab4dea04714 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\345\272\223\345\255\230\344\270\215\350\266\263\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" @@ -45,7 +45,10 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon2") diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.py" index 9e75c27adb46a313c87ad8e8d14756a4408f4aaa..0c0703592445ca7222e9c08500180c0dca8a3276 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\234\252\347\224\237\346\225\210\351\252\214\350\257\201.py" @@ -45,7 +45,10 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon4") diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" index 5ac41a829a3540ab609bd71320145e354bc2e4a5..40ff57ba95745041c919367cf855dece8e75ac74 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\350\277\207\346\234\237\346\227\240\346\263\225\351\242\206\345\217\226\351\252\214\350\257\201.py" @@ -45,7 +45,10 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon3") diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.py" index 2dd1d4f549f6fbc83b662d038c042df894bc1cc5..2a1003e30cc368546a1fd6113ec95e5e80013d68 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -46,7 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon") diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.py" index 5511cd1ab2062f14c1ff1a96f45b1e028c73435f..7a7c57d2603f6e205ba254efcf9cdd44a6bc54cc 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\346\254\241\346\225\260\350\266\205\351\231\220\351\252\214\350\257\201.py" @@ -40,12 +40,15 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c """ 场景:优惠券领取次数超限制验证 用例名称:优惠券领取次数超限制验证 - 输出:{"success":false,"code":"500","message":"该券已超过用户最大领取限制,请您关注平台后续其他活动","data":null,"freshToken":null} + 输出:{"success":false,"code":"500","message":"该券已抢完,请您关注平台后续其他活动","data":null,"freshToken":null} """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon1") diff --git "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.py" index ee429dcd1003588428a02a8e1c5a8744101d7406..9c11e67fef2f301ea7172321d7b453b3e72f1ab1 100644 --- "a/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_coupon/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.air/\344\274\230\346\203\240\345\210\270\351\242\206\345\217\226\351\252\214\350\257\201.py" @@ -44,7 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload_collect_coupon", c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time if result["code"] == "200": # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_collect_coupon") diff --git "a/air_case/cmdc_coupon/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.py" "b/air_case/cmdc_coupon/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.py" index 8e5dbd9a58ad34dcd87f6148b3328e6f4c02854b..37044e12172845d222d2458c0310c89b210f73fa 100644 --- "a/air_case/cmdc_coupon/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_coupon/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\346\214\207\345\256\232\345\225\206\345\223\201\344\277\241\346\201\257.py" @@ -43,10 +43,12 @@ request_body = commonFuc().get_business_data(module, "payload10", coupon_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # 获取商品对应的优惠券id result = {"couponId": result["data"][0]["couponId"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", coupon_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_coupon/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.py" "b/air_case/cmdc_coupon/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.py" index 24890a7b23f699b6ca1c439b59d65293a75e67e3..d0549fcc839f7a75321a0dfcea01adffc91a8e7b 100644 --- "a/air_case/cmdc_coupon/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_coupon/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\274\230\346\203\240\345\210\270\345\210\227\350\241\250.py" @@ -32,7 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_coupon/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.air/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.py" "b/air_case/cmdc_coupon/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.air/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.py" index 6ac2374b1f84385c46c08c8a09245cb3f1327a65..f92ab1d1eca3e8c375f2a0c0eed9cfa6d9609008 100644 --- "a/air_case/cmdc_coupon/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.air/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.py" +++ "b/air_case/cmdc_coupon/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.air/\351\252\214\350\257\201\345\225\206\345\223\201\346\230\257\345\220\246\344\270\216\344\274\230\346\203\240\345\210\270\346\264\273\345\212\250\345\214\271\351\205\215\346\210\220\345\212\237.py" @@ -56,12 +56,16 @@ request_body = commonFuc().get_business_data(module, "payload11", product_id, co # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) for i in result["data"]["couponList"]: if i["couponId"] == coupon_id: # 获取商品对应优惠券id result = {"couponId": i["couponId"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", coupon_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_demand/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.air/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.py" "b/air_case/cmdc_demand/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.air/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.py" index db6934b5b033971a28596db3fd770c75e0124957..46f75f2456db8b22e1970c454a92712ca3cc4bfc 100644 --- "a/air_case/cmdc_demand/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.air/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.py" +++ "b/air_case/cmdc_demand/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.air/\345\225\206\345\237\216\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272-\346\237\245\350\257\242-\345\210\240\351\231\244.py" @@ -28,10 +28,10 @@ request_body1 = commonFuc().get_business_data(module, "payload1") # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) result1 = json.loads(result1.content) -# 获取预期结果 -check_dict1 = commonFuc().get_business_data(module, "checkDict1") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict1, result1) +# # 获取预期结果 +# check_dict1 = commonFuc().get_business_data(module, "checkDict1") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict1, result1) # 第三步查询需求单列表中草稿订单列表 url2 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") @@ -39,10 +39,10 @@ request_body2 = commonFuc().get_business_data(module, "payload2") # 发送请求 result2 = requests.post(url2, json=request_body2, headers=headers1) result2 = json.loads(result2.content) -# 获取预期结果 -check_dict2 = commonFuc().get_business_data(module, "checkDict2") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict2, result2) +# # 获取预期结果 +# check_dict2 = commonFuc().get_business_data(module, "checkDict2") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict2, result2) # 第四步获取到新增草稿订单对应的id并进行参数化赋值处理 demand_parent_id = result2["data"]["list"][0]["demandParentId"] @@ -52,7 +52,10 @@ url3 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") request_body3 = commonFuc().get_business_data(module, "payload3", demand_parent_id) # 发送请求 result3 = requests.get(url3, params=request_body3, headers=headers1) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) +result3["api_time"] = api_time # 获取预期结果 check_dict3 = commonFuc().get_business_data(module, "checkDict3") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.py" "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.py" index 5babec269baad43c1311d94b42894176a8f80c0d..d3c4ee6a40dd3a1c325bb3d11fd3b1f04cc32101 100644 --- "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.py" +++ "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\345\256\241\346\240\270\346\213\222\347\273\235.py" @@ -21,7 +21,7 @@ password = commonFuc().get_business_data(module, "password") # 获取登录后Cmdc_access_token并进行参数化赋值 cmdc_access_token1 = CmdcMaiiLogin(username, password).get_token() headers1 = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token1) -print(headers1) + # 第二步进行需求单创建 url1 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") request_body1 = commonFuc().get_business_data(module, "payload4") @@ -38,11 +38,12 @@ order_num = result1["data"]["国药集团北京医疗器械有限公司"]["deman # 登录后台管理系统获取token信息 # 获取登录后台管理系统所需账号密码 -username1 = commonFuc().get_business_data(module, "username1") -password1 = commonFuc().get_business_data(module, "password1") +username1 = commonFuc().get_business_data(module, "username4") +password1 = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token并进行参数化赋值 cmdc_access_token = CmdcDoLogin(username1, password1).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) +# print(username1, password1) # 第三步在需求单列表根据订单编号查询出新创建的需求单 url2 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url80") @@ -50,6 +51,7 @@ request_body2 = commonFuc().get_business_data(module, "payload80") # 发送请求 result2 = requests.post(url2, json=request_body2, headers=headers) result2 = json.loads(result2.content) +# print(result2) # 获取预期结果 check_dict2 = commonFuc().get_business_data(module, "checkDict80") # 断言实际结果中是否包含预期结果的内容 @@ -65,7 +67,10 @@ url3 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url82" request_body3 = commonFuc().get_business_data(module, "payload82", demand_id, demand_code) # 发送请求 result3 = requests.post(url3, json=request_body3, headers=headers) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) +result3["api_time"] = api_time # print(result3) # 获取预期结果 check_dict3 = commonFuc().get_business_data(module, "checkDict82") diff --git "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.py" "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.py" index b5dc476f2984fb3880771514110be3fc2a68f7bc..b80e7e489056b0751f7af07b631b2dd5b55e04e6 100644 --- "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.py" +++ "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.air/\345\277\253\351\200\237\344\270\213\345\215\225-\344\272\214\345\256\241\351\200\232\350\277\207.py" @@ -28,18 +28,18 @@ request_body1 = commonFuc().get_business_data(module, "payload4") # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) result1 = json.loads(result1.content) -# 获取预期结果 -check_dict1 = commonFuc().get_business_data(module, "checkDict4") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict1, result1) +# # 获取预期结果 +# check_dict1 = commonFuc().get_business_data(module, "checkDict4") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict1, result1) # 获取新创建需求单对应的订单编号 order_num = result1["data"]["国药集团北京医疗器械有限公司"]["demandItems"][0]["demandCode"] # print(order_num) # 登录后台管理系统获取token信息 # 获取登录后台管理系统所需账号密码 -username1 = commonFuc().get_business_data(module, "username1") -password1 = commonFuc().get_business_data(module, "password1") +username1 = commonFuc().get_business_data(module, "username4") +password1 = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token并进行参数化赋值 cmdc_access_token = CmdcDoLogin(username1, password1).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -50,10 +50,10 @@ request_body2 = commonFuc().get_business_data(module, "payload80") # 发送请求 result2 = requests.post(url2, json=request_body2, headers=headers) result2 = json.loads(result2.content) -# 获取预期结果 -check_dict2 = commonFuc().get_business_data(module, "checkDict80") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict2, result2) +# # 获取预期结果 +# check_dict2 = commonFuc().get_business_data(module, "checkDict80") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict2, result2) # 第四步获取到新增需求单对应的id并进行参数化赋值处理 demand_id = result2["data"]["list"][0]["demandId"] @@ -65,8 +65,10 @@ url3 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url81" request_body3 = commonFuc().get_business_data(module, "payload81", demand_id, demand_code) # 发送请求 result3 = requests.post(url3, json=request_body3, headers=headers) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) -# print(result3) +result3["api_time"] = api_time # 获取预期结果 check_dict3 = commonFuc().get_business_data(module, "checkDict81") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.py" "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.py" index c6ffdee81ebee8f7472834ed032003f35e53c309..81d908cdbf7883d2c9be3e86e79dc7974b8ea4b3 100644 --- "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.py" +++ "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.air/\345\277\253\351\200\237\344\270\213\345\215\225-\345\256\241\346\240\270\346\213\222\347\273\235.py" @@ -28,18 +28,15 @@ request_body1 = commonFuc().get_business_data(module, "payload4") # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers1) result1 = json.loads(result1.content) -# 获取预期结果 -check_dict1 = commonFuc().get_business_data(module, "checkDict4") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict1, result1) + # 获取新创建需求单对应的订单编号 order_num = result1["data"]["国药集团北京医疗器械有限公司"]["demandItems"][0]["demandCode"] # print(order_num) # 登录后台管理系统获取token信息 # 获取登录后台管理系统所需账号密码 -username1 = commonFuc().get_business_data(module, "username2") -password1 = commonFuc().get_business_data(module, "password2") +username1 = commonFuc().get_business_data(module, "username4") +password1 = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token并进行参数化赋值 cmdc_access_token = CmdcDoLogin(username1, password1).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -50,22 +47,24 @@ request_body2 = commonFuc().get_business_data(module, "payload5", order_num) # 发送请求 result2 = requests.post(url2, json=request_body2, headers=headers) result2 = json.loads(result2.content) -# 获取预期结果 -check_dict2 = commonFuc().get_business_data(module, "checkDict5") -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict2, result2) +# # 获取预期结果 +# check_dict2 = commonFuc().get_business_data(module, "checkDict5") +# # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict2, result2) # 第四步获取到新增需求单对应的id并进行参数化赋值处理 demand_id = result2["data"]["list"][0]["demandId"] # print(demand_id) -# 步骤五对新创建的需求单订单进行删除操作 +# 步骤五对新创建的需求单订单进行审核拒绝操作 url3 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") request_body3 = commonFuc().get_business_data(module, "payload6", demand_id) # 发送请求 result3 = requests.post(url3, json=request_body3, headers=headers) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) -# print(result3) +result3["api_time"] = api_time # 获取预期结果 check_dict3 = commonFuc().get_business_data(module, "checkDict6") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.air/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.py" "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.air/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.py" index 09206e9c7cf48779aae924c46195c09c2fb9697f..f18f5f2ee7a635e89905c1eb8023cc91f17bc691 100644 --- "a/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.air/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.py" +++ "b/air_case/cmdc_demand/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.air/\345\277\253\351\200\237\344\270\213\345\215\225-\347\224\263\350\257\267\345\217\226\346\266\210-\345\256\241\346\240\270.py" @@ -55,8 +55,8 @@ result3 = json.loads(result3.content) """ # 步骤六在后台运营系统查询出用户提交取消申请 # 登录后台运营系统获取token信息 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token并进行参数化赋值 cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -76,8 +76,10 @@ request_body5 = commonFuc().get_business_data(module, "payload84", demand_id) # 发送请求 result5 = requests.post(url5, json=request_body5, headers=headers) +# 获取接口响应时间 +api_time = result5.elapsed.total_seconds() result5 = json.loads(result5.content) -# print(result5) +result5["api_time"] = api_time if result5["code"] == "200": # 获取预期结果 check_dict5 = commonFuc().get_business_data(module, "checkDict84") diff --git "a/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.py" index 00e4eeb477fefa2288f4bc3e3c6cd547f8b2963a..6f028dd8ddb1d0c5218e917668bb06585fb92b73 100644 --- "a/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.py" +++ "b/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -48,15 +48,23 @@ request_body = commonFuc().get_business_data(module, "payload3") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -print(result) +# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 - check_dict = commonFuc().get_business_data(module, "checkDict2") + check_dict = commonFuc().get_business_data(module, "checkDict2_1") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) -else: +elif result["code"] == "401": # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_401") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict2") + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.py" "b/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.py" index fb06e59a7870b13bef2b334850615987a6968ba4..d79265a02c023ce59ce40a51ee6d777f6dcdfbbb 100644 --- "a/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.py" +++ "b/air_case/cmdc_demand_audit/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\351\200\232\350\277\207_\345\277\253\351\200\237\344\270\213\345\215\225.py" @@ -47,7 +47,7 @@ result = json.loads(result.content) # 第五步进行需求单审核处理 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") -request_body = commonFuc().get_business_data(module, "payload3") +request_body = commonFuc().get_business_data(module, "payload40") """ 场景:通过快速下单入口提交创建需求单,并进行审核通过操作 @@ -56,15 +56,23 @@ request_body = commonFuc().get_business_data(module, "payload3") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 - check_dict = commonFuc().get_business_data(module, "checkDict2") + check_dict = commonFuc().get_business_data(module, "checkDict2_1") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) -else: +elif result["code"] == "401": # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_401") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict2") + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" "b/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" index 814da02d1dc9d44b16f81d5210f5b29ae72c1036..1f3d238ef1470ac236daf2a88b25af8bf2f44dfb 100644 --- "a/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" +++ "b/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" @@ -31,8 +31,12 @@ request_body = commonFuc().get_business_data(module, "payload") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) +result["api_time"] = api_time +# print(result) if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict") @@ -42,6 +46,6 @@ if result["success"]: else: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_1") - print(check_dict) + # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.py" "b/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.py" index 30b689d8963659d36d9119adfe4b384fc5e9042f..558ae07fe117fb4d0e74d536e1ec26fe07fd4959 100644 --- "a/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.py" +++ "b/air_case/cmdc_demand_create_pc/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.air/\345\244\232\351\207\207\345\225\206\345\237\216\351\234\200\346\261\202\345\215\225\350\215\211\347\250\277\345\210\233\345\273\272.py" @@ -32,10 +32,12 @@ request_body = commonFuc().get_business_data(module, "payload2") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_creation/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" "b/air_case/cmdc_demand_creation/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" index e06de53a4e11b271a8c1fb6c67372b7b0f3ea84a..ceef5cb07408ac8411d5a9fd8551e9752f12e9ea 100644 --- "a/air_case/cmdc_demand_creation/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" +++ "b/air_case/cmdc_demand_creation/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\345\215\225\345\210\233\345\273\272.py" @@ -16,8 +16,8 @@ module = "cmdc_demand_creation" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -33,10 +33,15 @@ request_body = commonFuc().get_business_data(module, "payload1") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_demand_creation/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.py" "b/air_case/cmdc_demand_creation/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.py" index 02d499e1cf95439c64a94d5de9cdbcdd040274c2..9bb849c999947e9afb1b239a348758a304924405 100644 --- "a/air_case/cmdc_demand_creation/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.py" +++ "b/air_case/cmdc_demand_creation/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.air/\351\234\200\346\261\202\350\215\211\347\250\277\350\256\242\345\215\225\345\210\233\345\273\272.py" @@ -33,10 +33,21 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict2") -print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +result["api_time"] = api_time + +# 判断登录是否成功 +if result["success"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict2") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict_fail") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_delete/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_delete/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" index 26557a76c804e9433df12645e81f3e37d86ebc57..92d67ca50ca0dfc853395a80450c192ce63c2fe8 100644 --- "a/air_case/cmdc_demand_delete/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_delete/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" @@ -37,8 +37,11 @@ request_body = commonFuc().get_business_data(module, "payload2", demand_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") print(check_dict) diff --git "a/air_case/cmdc_demand_delete/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_delete/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.py" index 1c26148645c196d9b701815cffcb7de0197c8359..a4b9948ed3d5a2d57d48a7937526e537153cc282 100644 --- "a/air_case/cmdc_demand_delete/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_delete/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.air/\345\210\240\351\231\244\345\205\266\344\273\226\347\212\266\346\200\201\344\270\213\351\234\200\346\261\202\345\215\225.py" @@ -44,8 +44,11 @@ request_body = commonFuc().get_business_data(module, "payload4", demand_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") print(check_dict) diff --git "a/air_case/cmdc_demand_delete/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.air/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_delete/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.air/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.py" index 98f5e251ab0c5e89355b8fc2cdeb082ccf20a9fa..383e838d8790a9d074e79475386786ec9b7578c7 100644 --- "a/air_case/cmdc_demand_delete/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.air/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_delete/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.air/\351\207\215\345\244\215\345\210\240\351\231\244\351\234\200\346\261\202\345\215\225.py" @@ -73,8 +73,11 @@ request_body3 = commonFuc().get_business_data(module, "payload3", demand_id) # 发送请求 result3 = requests.post(url3, json=request_body3, headers=headers) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) -# print(result) +result3["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") print(check_dict) diff --git "a/air_case/cmdc_demand_delete/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.py" "b/air_case/cmdc_demand_delete/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.py" index 66a91d0c90bb18b8701b832a8e338c2eb24575fa..b7f8cd2671fef0c1ba02264e52080be68d3507b1 100644 --- "a/air_case/cmdc_demand_delete/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.py" +++ "b/air_case/cmdc_demand_delete/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244.py" @@ -27,7 +27,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_dem request_body = commonFuc().get_business_data(module, "payload_demand") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 频繁创建需求单会创建失败,因此添加了判断 if result["code"] == "200": @@ -66,8 +69,10 @@ if result["code"] == "200": # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = result.elapsed.total_seconds() result = json.loads(result.content) - # print(result) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_demand_fail/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_fail/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" index 48924e15016278ec4915c7d96d68f6857fb44bfd..ad2fcd1d2f1b38caa0994ed6effaff5eb30e0a95 100644 --- "a/air_case/cmdc_demand_fail/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_fail/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\344\270\215\345\255\230\345\234\250\347\232\204\351\234\200\346\261\202\345\215\225.py" @@ -37,8 +37,11 @@ request_body = commonFuc().get_business_data(module, "payload3", demand_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") # print(check_dict) diff --git "a/air_case/cmdc_demand_fail/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_fail/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.py" index 974f4d9762a4f64f57405d243ae3a81c3fe62010..95b10e46ea7fb71b63adf32610f064735707b5e6 100644 --- "a/air_case/cmdc_demand_fail/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_fail/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.air/\345\256\241\346\240\270\345\205\266\344\273\226\347\212\266\346\200\201\347\232\204\351\234\200\346\261\202\345\215\225.py" @@ -17,8 +17,8 @@ module = "cmdc_demand_fail" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -44,8 +44,11 @@ request_body1 = commonFuc().get_business_data(module, "payload4", demand_id) # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) -# print(result1) +result1["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") # print(check_dict) diff --git "a/air_case/cmdc_demand_fail/\351\207\215\345\244\215\345\256\241\346\240\270.air/\351\207\215\345\244\215\345\256\241\346\240\270.py" "b/air_case/cmdc_demand_fail/\351\207\215\345\244\215\345\256\241\346\240\270.air/\351\207\215\345\244\215\345\256\241\346\240\270.py" index ada6b6f8150842bd7ab44e4482970974450a3b0a..5ff2c64699f6351f0c8885810f6a82bc5af68400 100644 --- "a/air_case/cmdc_demand_fail/\351\207\215\345\244\215\345\256\241\346\240\270.air/\351\207\215\345\244\215\345\256\241\346\240\270.py" +++ "b/air_case/cmdc_demand_fail/\351\207\215\345\244\215\345\256\241\346\240\270.air/\351\207\215\345\244\215\345\256\241\346\240\270.py" @@ -16,8 +16,8 @@ module = "cmdc_demand_fail" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -49,8 +49,11 @@ request_body3 = commonFuc().get_business_data(module, "payload2", demand_id) """ # 发送请求 result3 = requests.post(url3, json=request_body3, headers=headers) +# 获取接口响应时间 +api_time = result3.elapsed.total_seconds() result3 = json.loads(result3.content) -# print(result3) +result3["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # print(check_dict) diff --git "a/air_case/cmdc_demand_fail/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.py" "b/air_case/cmdc_demand_fail/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.py" index 6261e1292e50339651471c82c7b2f5e221edd846..0cc7a7daec5694264f1ab7beb4381640dd813bd9 100644 --- "a/air_case/cmdc_demand_fail/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.py" +++ "b/air_case/cmdc_demand_fail/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.air/\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\344\270\215\351\200\232\350\277\207.py" @@ -15,8 +15,8 @@ module = "cmdc_demand_fail" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -42,8 +42,11 @@ request_body1 = commonFuc().get_business_data(module, "payload1", demand_id) # 发送请求 result1 = requests.post(url1, json=request_body1, headers=headers) +# 获取接口响应时间 +api_time = result1.elapsed.total_seconds() result1 = json.loads(result1.content) -# print(result1) +result1["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # print(check_dict) diff --git "a/air_case/cmdc_demand_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_demand_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" index 0269fa7e7cb36a10ec6658d31a11ee0dc317c09c..1899d1c1d4fac63c77890e3c85873ecf75527fa2 100644 --- "a/air_case/cmdc_demand_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_demand_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # print(check_dict) diff --git "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.py" "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.py" index a927ed57a1345d35d180ce547b4cc011fc0f2d5a..bf3aaba94f15d23be838c1f5e3218ee454075271 100644 --- "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.py" +++ "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244-\351\200\206\345\220\221.py" @@ -55,8 +55,11 @@ request_body = commonFuc().get_business_data(module, "payload3", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") # print(check_dict) diff --git "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.py" "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.py" index adc1a0449dc80757eb7bf0c34822450c952d3521..4584aed7dbb2297c85dc982cfac208369003432a 100644 --- "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.py" +++ "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.air/\351\234\200\346\261\202\345\215\225-\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244.py" @@ -49,8 +49,11 @@ request_body = commonFuc().get_business_data(module, "payload2", demand_id) """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") # print(check_dict) diff --git "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.air/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.py" "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.air/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.py" index c5c7a6de2e09bc370889b98697f4fed185498ecc..7fae4751a2c92d9a195d8ad75964e9579de4a123 100644 --- "a/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.air/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.py" +++ "b/air_case/cmdc_demand_list/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.air/\351\234\200\346\261\202\345\215\225_\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257\345\244\261\350\264\245.py" @@ -28,8 +28,11 @@ request_body = commonFuc().get_business_data(module, "payload") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # print(check_dict) diff --git "a/air_case/cmdc_demand_list_pc/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.py" "b/air_case/cmdc_demand_list_pc/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.py" index b3c2b2bd7d8e88945a93c6f5556db54b36676e75..d0ef45c99af08e2874e97782ab13c03fc2046ce8 100644 --- "a/air_case/cmdc_demand_list_pc/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.py" +++ "b/air_case/cmdc_demand_list_pc/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250-\345\244\232\351\207\207\345\225\206\345\237\216.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # print(check_dict) diff --git "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.py" "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.py" index 3f57fcab4351350e2e5abccffbe2721f47fdcc61..ac5ce9b89a8737c0a79e3064b983805db33a0d5a 100644 --- "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.py" +++ "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244-\344\270\215\346\216\245\345\217\227.py" @@ -42,8 +42,10 @@ request_body = commonFuc().get_business_data(module, "payload5", demand_parent_i """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") # print(check_dict) diff --git "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.py" "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.py" index 8bf1e4ada14c70967578df5725101ab769d0031d..6663fd9b07527469868449760974c10e2b631781 100644 --- "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.py" +++ "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.air/\351\234\200\346\261\202\345\215\225-\345\256\242\346\210\267\347\241\256\350\256\244.py" @@ -42,8 +42,10 @@ request_body = commonFuc().get_business_data(module, "payload4", demand_parent_i """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") # print(check_dict) diff --git "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.py" "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.py" index a2a7d48f031bb82466b8778d6465f39820c88def..a0fd7670dadfb5b4b7f2cf5fbc72dd021dd00e5e 100644 --- "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.py" +++ "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\210\240\351\231\244\346\223\215\344\275\234.py" @@ -48,7 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload3", demand_parent_i """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") diff --git "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.py" "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.py" index f734e2aa408f1fe4e5642915e296405404994fb4..36e67eefef400871eb2d5923b303bd2b31716865 100644 --- "a/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.py" +++ "b/air_case/cmdc_demand_list_pc/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\346\223\215\344\275\234.py" @@ -41,8 +41,11 @@ request_body = commonFuc().get_business_data(module, "payload2", demand_code) """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.py" index db9dd29691e35b6dfb2fe21a4d59c67228af7513..bc12b52064bcc53ace008a9edc0dd0baebedb1b8 100644 --- "a/air_case/cmdc_demand_mall/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\212\344\274\240\346\224\257\344\273\230\345\207\255\350\257\201\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -42,7 +42,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict34") diff --git "a/air_case/cmdc_demand_mall/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" "b/air_case/cmdc_demand_mall/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" index 4fe79592f42b279f0d78e2551d55dada67d933ba..a304a2689f89f3867306349262d9e04d118551c5 100644 --- "a/air_case/cmdc_demand_mall/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" +++ "b/air_case/cmdc_demand_mall/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" @@ -43,10 +43,13 @@ request_body = commonFuc().get_business_data(module, "payload39") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取message result = {"errMessage": result["data"][0]["errMessage"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict39") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.py" index be30623e21a3aaf0c23af3a68287a973bbf1959e..e61ede205558626a4296e00be0182d7d36be8831 100644 --- "a/air_case/cmdc_demand_mall/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\217\220\344\272\244\350\256\242\345\215\225\346\224\257\344\273\230\350\257\201\346\230\216\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -51,8 +51,11 @@ request_body = commonFuc().get_business_data(module, "payload35", file_aliyun) """ # 发送请求 -result = result = requests.post(url, json=request_body, headers=headers) +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict35") diff --git "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" index 5e0dec503965264341ce21258c4582aa68c5dd33..423ef1f6fd243eb3cb0a1036a4341e27f34fe7d3 100644 --- "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\241\346\240\270\345\217\230\345\212\250\350\256\242\345\215\225_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" @@ -34,10 +34,13 @@ request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取查询结果中是否审核变动标识 result = {"changeSign": result["data"]["list"][0]["changeSign"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") diff --git "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" index db1d4fdcb0d8d87a3ab7b4233a66a0c08abc29d8..c7d61d51b9e28d6d53b8943a12938ee75ab62142 100644 --- "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\212\266\346\200\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" @@ -34,10 +34,13 @@ request_body = commonFuc().get_business_data(module, "payload4") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取查询结果中是否审核变动标识 result = {"orderStatus": result["data"]["list"][0]["orderStatus"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") diff --git "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" index f92bc9f40d854406425d2e33ef768e9d89f9a14a..2bcaef3194236a0361b67dd78507ce905068e4e3 100644 --- "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" @@ -65,10 +65,13 @@ request_body = commonFuc().get_business_data(module, "payload2", seller_company_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取查询结果中订单编号 result = {"orderNum": result["data"]["list"][0]["demandCode"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", order_num) diff --git "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.py" index 7a935bc95bafa6c15892066e93ff68917b760cca..c074dada5702c76b44b670030e3bfec72a348e55 100644 --- "a/air_case/cmdc_demand_mall/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\272\277\344\270\213\346\224\257\344\273\230\350\264\246\345\217\267\344\277\241\346\201\257\351\252\214\350\257\201.py" @@ -34,11 +34,14 @@ request_body = commonFuc().get_business_data(module, "payload33") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取账号数量 result = {"total": result["data"]["total"]} +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_demand_mall/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.py" index 7ef33bae3eb89b632229432f2ea647d10642a31a..ed7685241dda4b26582b96eb4593f2990c955380 100644 --- "a/air_case/cmdc_demand_mall/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.air/\346\240\271\346\215\256\347\224\250\346\210\267\346\237\245\350\257\242\345\205\254\345\217\270\344\277\241\346\201\257\351\252\214\350\257\201.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload30") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict30") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.air/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.air/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.py" index a42b794f6f3a8a9beb2b2ed8d3780f1fefa50a53..c446cc0e8b504c0c295eea306b9978deba3bb8b6 100644 --- "a/air_case/cmdc_demand_mall/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.air/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.air/\346\240\271\346\215\256\351\234\200\346\261\202id\350\216\267\345\217\226\345\205\254\345\217\270id\351\252\214\350\257\201.py" @@ -48,8 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload32", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict32") diff --git "a/air_case/cmdc_demand_mall/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.py" index d3ee20ebabbd80783bcc39221ec4bcdbbe45e7e1..af34d7de979ad7a3a486af374eb1ea180ec0f415 100644 --- "a/air_case/cmdc_demand_mall/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\224\237\344\272\247\345\216\202\345\256\266\345\210\227\350\241\250\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -35,11 +35,14 @@ request_body = commonFuc().get_business_data(module, "payload7", manufacturer) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["data"]: # 获取查询结果中厂家信息 result = {"data": result["data"][0][0]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7", manufacturer) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.py" index 29aee8bb8aa786f34d8d76870420d854fbb88a27..aa160a997a8e4119de7e6af8d8935a293268efbf 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -23,8 +23,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") # 发送请求 result = requests.get(url) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.py" index 7ffe3b98c488214f92b9b14699f808d9546e24ab..ef07e21145a58dffd3a58a7934c799ecc65fa695 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\216\237\345\247\213\351\234\200\346\261\202\350\257\246\346\203\205\351\252\214\350\257\201.py" @@ -34,7 +34,7 @@ random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_code = result["data"]["list"][random_demand]["demandCode"] -# 第三步在需求单列表进行需求单查询操作 +# 第三步查看需求单详情操作 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") request_body = commonFuc().get_business_data(module, "payload10", demand_code) # print(request_body) @@ -46,10 +46,13 @@ request_body = commonFuc().get_business_data(module, "payload10", demand_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取原始需求单中demandCode result = {"demandCode": result["data"]["demandSkuList"]["list"][0]["demandCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", demand_code) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.py" index 8b2c2058dc3faa1416606eaed7ef698da5241970..796ab59d4086b4af654b92097b923486ff57c252 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\256\241\346\240\270\344\272\272\345\221\230\345\210\227\350\241\250\351\252\214\350\257\201.py" @@ -34,7 +34,7 @@ random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_code = result["data"]["list"][random_demand]["demandCode"] -# 第三步在需求单列表进行需求单查询操作 +# 第三步获取审核人员列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") request_body = commonFuc().get_business_data(module, "payload9", demand_code) # print(request_body) @@ -46,8 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload9", demand_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.py" index 722a917f224f6b157b25452459e8b1b19f96cfaf..cf4046f2cb9f9274c01a8728bd29f3d18f6e0f34 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\257\344\273\230\344\277\241\346\201\257\351\252\214\350\257\201_\346\224\257\344\273\230\351\241\265\351\235\242.py" @@ -47,10 +47,13 @@ request_body = commonFuc().get_business_data(module, "payload28", code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) print(result) # 获取需求单对应的客户折扣 result = {"customerCharge": result["data"]["customerCharge"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict28", customer_charge) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.py" index f9fdb5b006ec9b93ddee0bd39f1dcac9e4253dc0..963685359bf4356616fba41c8c303408ed95f4c0 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225.py" @@ -19,14 +19,18 @@ request_body = commonFuc().get_business_data(module, "payload11") """ 场景: 获取站点信息验证_需求单 用例名称:获取站点信息验证_需求单 - 输出:{"companyId":6} + 输出:{"companyId":7} """ # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +# print(result) # 获取站点信息中公司id result = {"companyId": result["data"]["companyId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.py" index c0fad1a2fdf9a1041845c84c6f43f5e16474cea9..4cc3dbb13bc0a4b7232f7856b2c1f589f0a20f0d 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\350\215\211\347\250\277\350\256\242\345\215\225\350\257\246\346\203\205.py" @@ -46,10 +46,13 @@ request_body = commonFuc().get_business_data(module, "payload38", version) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取草稿订单详情中id result = {"id": result["data"]["id"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict38", version) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.py" index 49065721a6802c30ab625a9886e146f94820fe98..14019cf5e5bc40fa0dd770ef32f0322cc8c36023 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\345\210\227\350\241\250\351\252\214\350\257\201.py" @@ -48,11 +48,14 @@ request_body = commonFuc().get_business_data(module, "payload16", demand_code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -print(result) +result["api_time"] = api_time if result["data"]: # 获取订单明细列表中demandCode result = {"demandCode": result["data"][0]["demandCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16", demand_code) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.py" index bd854631a402f8c067fe3248590c27da5bf59937..72137e8c2a152e674f9fcae63e45421df20159a8 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_demand_mall" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -33,7 +33,7 @@ result = json.loads(result.content) random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_code = result["data"]["list"][random_demand]["demandCode"] -demand_code = "17020165859551447" +demand_code = "17023454128426831" # 第三步获取需求单对应的订单变动明细列表 @@ -48,10 +48,13 @@ request_body = commonFuc().get_business_data(module, "payload18", demand_code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) -print(result) +# print(result) # 获取订单明细列表中isChange result = {"isChange": result["data"]["isChange"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict18") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.py" index 34a758d8e5da42fe95f8b76952ce373268dc23e9..354410272324f2b988a84e5d22acc447995cd195 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\345\217\230\345\212\250\346\230\216\347\273\206\351\252\214\350\257\201.py" @@ -59,10 +59,13 @@ request_body = commonFuc().get_business_data(module, "payload17", demand_change_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取明细demandChangeId result = {"demandChangeId": result["data"]["list"][0]["demandChangeId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17", demand_change_id) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.py" index c546b114472fd6b38d31a30f5e579ed599d5e81b..18495a78099f64b84f76c9bb5a607d396cb16e84 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\224\257\344\273\230\351\207\221\351\242\235\351\252\214\350\257\201.py" @@ -47,10 +47,13 @@ request_body = commonFuc().get_business_data(module, "payload28", code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) # print(result) # 获取需求单对应的客户折扣 result = {"customerCharge": result["data"]["customerCharge"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict28", customer_charge) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" index 87daa22ca52da3a4851f5976d94ff39619c62ae1..9f2f2f6850c8339fbc700eacf613c46eddc6a2e4 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\225\260\346\215\256\351\252\214\350\257\201_\350\256\242\345\215\225\344\277\256\346\224\271.py" @@ -48,7 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload20", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = result.elapsed.total_seconds() result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.py" index 0364fa095d6ca1a238b1d81aa26f9b144e89232e..d6805ab9d88df8e6e446e079b666df5f32c77784 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\350\256\242\345\215\225\347\261\273\345\236\213\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -23,8 +23,10 @@ request_body = commonFuc().get_business_data(module, "payload6") # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.py" index a5a8ab862560fcedd09d266af100387fc67f6a1a..87fd295fae42249cfa1c1ce734bfefc7c17084d7 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\224\200\345\224\256\350\256\242\345\215\225\345\220\210\345\220\214\351\205\215\347\275\256\351\252\214\350\257\201.py" @@ -48,8 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload15", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.py" index 6f15740398f8d3fb96a33bbbab3697ce756daebf..607150da9830e942a080ce51a2e947b78bc11c29 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\210\227\350\241\250\346\230\216\347\273\206_\346\224\257\344\273\230\351\241\265\351\235\242.py" @@ -46,10 +46,13 @@ request_body = commonFuc().get_business_data(module, "payload27", demand_parent_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取需求单详情中demandParentCode result = {"demandParentCode": result["data"]["list"][0]["demandParentCode"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict27", demand_parent_code) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.py" index 07becf65055cfcb670c1976a6ed90ed30494920f..aa929004c096400a6fd9b257100e282102438bba 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\345\210\227\350\241\250\351\252\214\350\257\201.py" @@ -49,10 +49,13 @@ request_body = commonFuc().get_business_data(module, "payload13", demand_code, d # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["data"]["list"]: result = {"demandSubCode": result["data"]["list"][0]["demandSubCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13", demand_parent_code) # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" index 716aaa8c50782b324868a6e6670c1b63f60fa55d..2ac46a9e487172bca12d272b886ddda97a827e82 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\255\220\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" @@ -48,18 +48,28 @@ request_body = commonFuc().get_business_data(module, "payload14", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time print(result) if result["data"]: result = {"demandId": result["data"][0]["demandId"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14", demand_id) # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) -else: +elif result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14_1") # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict14_2") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.py" index 1b9c51d40b6d5e42726d9c1b08b3efe896f9e481..5f3eb5b4371b36994eca196f07238fa834183da1 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\346\223\215\344\275\234\350\256\260\345\275\225\344\277\241\346\201\257\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_demand_mall" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -33,9 +33,9 @@ result = json.loads(result.content) random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 # demand_code = result["data"]["list"][random_demand]["demandCode"] -demand_code = "17018438457347575" +demand_code = "17023454128426831" # demand_parent_code = result["data"]["list"][random_demand]["demandParentCode"] -demand_parent_code = "s2312061400015" +demand_parent_code = "s2312120900008" # 第三步获取需求单对应的操作记录 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") @@ -49,8 +49,10 @@ request_body = commonFuc().get_business_data(module, "payload12", demand_code, d # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" index ef0b693a7e0143bb362dde24360ad53811a13444..18ccd662f1e0c0eabf52ac4ccb6fed5e97f4c6d1 100644 --- "a/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\351\252\214\350\257\201.py" @@ -47,13 +47,24 @@ request_body = commonFuc().get_business_data(module, "payload8", demand_parent_c # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) -# 获取需求单详情中订单编号 -result = {"demandCode": result["data"]["demandHead"]["demandCode"]} -# print(result) -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict8", demand_code) -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# 历史数据会出现需求单详情报错的情况 +if result["success"]: + # 获取需求单详情中订单编号 + result = {"demandCode": result["data"]["demandHead"]["demandCode"]} + result["api_time"] = api_time + # print(result) + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict8", demand_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果/打印出有问题的需求单信息 + check_dict = commonFuc().get_business_data(module, "checkDict8", demand_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_mall/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 779b0ff2e4023b2fab109253ba68aa652f914857..a616f8f8ee5fd7d685834164977fbead50473fb4 100644 --- "a/air_case/cmdc_demand_mall/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\247\243\351\231\244\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -24,10 +24,11 @@ headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_tok # 第二步获取需求单列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload1") +request_body = commonFuc().get_business_data(module, "payload_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) +# print(result) # 生成随机数 random_demand = random.randint(0, len(result["data"]["list"]) - 1) @@ -35,7 +36,6 @@ random_demand = random.randint(0, len(result["data"]["list"]) - 1) demand_id = result["data"]["list"][random_demand]["demandId"] # demand_id = "40187" - # 第三步解除订单占用 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") request_body = commonFuc().get_business_data(module, "payload24", demand_id) @@ -48,8 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload24", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict24") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" index c12523de0bb605cc180fa69e26d009f6a9f6f3ae..6a655c0d49bc892e13182fcc226e8dec13cbb7ee 100644 --- "a/air_case/cmdc_demand_mall/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\256\242\345\215\225\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload25") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict25") diff --git "a/air_case/cmdc_demand_mall/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_demand_mall/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" index bffd36d8a91c71890260e9ff83fb93fdfef15387..0d78988e90d1341ae3d4b4361bbf8485f0bf18f7 100644 --- "a/air_case/cmdc_demand_mall/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_demand_mall/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.air/\350\256\242\345\215\225\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250.py" @@ -49,7 +49,9 @@ request_body = commonFuc().get_business_data(module, "payload21", order_num) # 发送请求 result = requests.post(url, json=request_body, headers=headers) -# result = json.loads(result.content) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # print(result) # 获取文件 @@ -63,6 +65,7 @@ with open(file_path, 'wb') as f: # 获取文件中订单编号 excel = HandleExcel(file_path, "Sheet1") result = {"demandCode": excel.read_data()[0].get("订单编号")} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21", order_num) diff --git "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.py" index a9af44b7ec301cb76ece06d4936ff00366cbc03f..409bb1f5cd293a0b54bb180beba28fa6c7fe465f 100644 --- "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # print(check_dict) diff --git "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.py" index a757421a2b5bbeb806dafa01d66a18f4182a5d55..33502f20ce6fc7559d57c38d2ca983b2fc908623 100644 --- "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\217\226\346\266\210\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -39,12 +39,15 @@ request_body = commonFuc().get_business_data(module, "payload23") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time if result["success"]: # 查询需求单状态 sql = "SELECT t.orderStatus FROM `cmdc-order`.tc_demand t WHERE t.demandId = 40213" result = {"orderStatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} + result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23") diff --git "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" index 539b90794783d1d1d6bfdafe09dc69de772711a4..7913ce51cea823168c163a3ae97a519ffb6eeb3c 100644 --- "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\345\225\206\345\223\201\350\277\224\345\210\251\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -47,12 +47,23 @@ request_body = commonFuc().get_business_data(module, "payload26", demand_code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) -# 获取返利明细中demandCode -result = {"demandCode": result["data"][0]["demandCode"]} -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict26", demand_code) -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# 历史数据会出现需求单详情报错的情况 +if result["success"]: + # 获取返利明细中demandCode + result = {"demandCode": result["data"][0]["demandCode"]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict26", demand_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果/打印出有问题的需求单信息 + check_dict = commonFuc().get_business_data(module, "checkDict26", demand_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.py" index 88812b773822c207c9bd28cb89812649897cb9c3..1c5a233164e7d721ed506b6429d5765912ba94b6 100644 --- "a/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_demand_mall/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\234\200\346\261\202\345\215\225\351\224\200\345\224\256\345\220\210\345\220\214\344\270\213\350\275\275\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -36,9 +36,9 @@ result = json.loads(result.content) random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_id = result["data"]["list"][random_demand]["demandId"] -# demand_id = "40187" +# demand_id = "37974" demand_code = result["data"]["list"][random_demand]["demandCode"] - +# 16934694037805759 # 第三步进行需求单销售合同下载 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") @@ -52,8 +52,9 @@ request_body = commonFuc().get_business_data(module, "payload22", demand_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) -# result = json.loads(result.content) -# print(result) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # 获取文件 BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) @@ -67,10 +68,11 @@ with open(file_path, 'wb') as f: excel = HandleExcel(file_path, "Sheet1") result = {"demandCode": excel.read_data()[0].get("医疗器械产品销售合同 ")[-17:]} print(excel.read_data()[0].get("医疗器械产品销售合同 ")) -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22", demand_code) -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.air/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.py" "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.air/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.py" index 7b8aee52539572169ce3abf30b0623323a0e56b7..6d09bf748af87ed7312ea247cd5dfc361d99f3fb 100644 --- "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.air/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.py" +++ "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.air/\351\252\214\350\257\201\350\256\242\345\215\225\345\215\240\347\224\250\345\212\237\350\203\275.py" @@ -34,7 +34,7 @@ random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_id = result["data"]["list"][random_demand]["demandId"] # demand_id = "40187" - +demand_code = result["data"]["list"][random_demand]["demandCode"] # 第三步判断需求单是否被占用 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") @@ -48,12 +48,22 @@ request_body = commonFuc().get_business_data(module, "payload19", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) +result["api_time"] = api_time -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict19") -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# 历史数据会出现需求单详情报错的情况 +if result["success"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict19") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果/打印出有问题的需求单信息 + check_dict = commonFuc().get_business_data(module, "checkDict26", demand_code) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.py" "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.py" index 467fcf36685fd267328bab4d1c59f928820bcff2..e3dcab55f476faa285edee87a96b04d10b0d4fcc 100644 --- "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.py" +++ "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\345\267\262\346\224\257\344\273\230.py" @@ -47,8 +47,11 @@ request_body = commonFuc().get_business_data(module, "payload36", demand_parent_ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) +result["api_time"] = api_time if proof_sign: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict36") diff --git "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" index e9b49d231bcb99c5445791121f0ff0d9a24d37d5..74ea850a5067b895c16357151074c42d8f9bc9b8 100644 --- "a/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" +++ "b/air_case/cmdc_demand_mall/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\350\256\242\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" @@ -34,7 +34,7 @@ random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_id = result["data"]["list"][random_demand]["demandId"] # demand_id = "40187" - +demand_code = result["data"]["list"][random_demand]["demandCode"] # 第三步解除订单占用 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") @@ -48,10 +48,20 @@ request_body = commonFuc().get_business_data(module, "payload37", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict37") -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# 历史数据会出现需求单详情报错的情况 +if result["success"]: + # print(result) + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict37") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果/打印出有问题的需求单信息 + check_dict = commonFuc().get_business_data(module, "checkDict26", demand_code) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_frequent_purchase/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.air/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.py" "b/air_case/cmdc_frequent_purchase/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.air/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.py" index a2cdd8c044131e64f373e6630dd954971c19bed4..466dc70d51bb3c132a5835a8ec8ce0f776a5181f 100644 --- "a/air_case/cmdc_frequent_purchase/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.air/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.py" +++ "b/air_case/cmdc_frequent_purchase/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.air/\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250\345\225\206\345\223\201\347\247\273\351\231\244.py" @@ -73,8 +73,10 @@ if result_product_id == product_id: # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) - # print(result) + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") print(check_dict) diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index 69dbf25ab423ca5dd45250f98961d850ae88cc84..2f39a8470cabccc82f40194e34bf4fc75eaabff5 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236JDE\345\267\262\345\201\234\347\224\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -10,6 +10,7 @@ from common.common_func import commonFuc from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import random import json @@ -29,10 +30,13 @@ request_body = commonFuc().get_business_data(module, "payload80") result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品对应的productId和referencePrice -product_id = result["data"]["list"][0]["productId"] -price = result["data"]["list"][0]["referencePrice"] - +product_id = result["data"]["list"][product_random]["productId"] +price = result["data"]["list"][product_random]["referencePrice"] +productCode = result["data"]["list"][product_random]["productCode"] +# print(productCode) # 第二步登录多采商城添加JDE已停用的商品至常购清单列表 # 获取登录所需账号密码 username = commonFuc().get_business_data(module, "username") @@ -52,10 +56,20 @@ request_body = commonFuc().get_business_data(module, "payload8", product_id, pri # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict8") -print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +if result["code"] == "1078": + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict8_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict8") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index cc71a8c221c413738d38aa58517116d893a90e95..f4129ed8e4f635b3264d8501d6beaa8af663a0f9 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\344\270\215\345\255\230\345\234\250\347\232\204\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -36,8 +36,10 @@ request_body = commonFuc().get_business_data(module, "payload400", product_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict400") # print(check_dict) diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index 9f1456d878514bd6af336eddf6fd052683a3c0a7..7d1080cfb32a89e0daf18f471dcbb941794ca9b2 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -40,7 +40,10 @@ request_body = commonFuc().get_business_data(module, "payload3001") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index addafe12e6dc700fb9ca5347ab0c0d03b9cfccd8..ad31e502e44976440c06acc159b6d3a4fb03b7f3 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -60,7 +60,10 @@ request_body = commonFuc().get_business_data(module, "payload4", product_id, pri # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4") diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index cc2020ab96185a776a095bbc0a6f95f2560c5218..f850de62e87b6d1e18c291fb0cb31fccce18442a 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\346\216\247\351\224\200\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -60,8 +60,10 @@ request_body = commonFuc().get_business_data(module, "payload5", product_id, pri # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") print(check_dict) diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index 67794a243ed992395807f85c84a7425ef66d8927..1d633061a6d0bb920e77a7fd3e570729e36b962e 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201_\346\216\247\351\224\200_\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -10,6 +10,7 @@ from common.common_func import commonFuc from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import random import json @@ -25,13 +26,15 @@ headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_toke # 查询商品列表获取赠品_控销_商品信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") request_body = commonFuc().get_business_data(module, "payload60") - # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品信息并进行参数化处理 -product_id = result["data"]["list"][0]["productId"] -price = result["data"]["list"][0]["referencePrice"] +product_id = result["data"]["list"][product_random]["productId"] +price = result["data"]["list"][product_random]["referencePrice"] # 第二步登录多采商城添加赠品_控销_商品至常购清单列表 # 获取登录所需账号密码 @@ -52,10 +55,19 @@ request_body = commonFuc().get_business_data(module, "payload6", product_id, pri # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict6") -print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +result["api_time"] = api_time +if result["code"] == "1078": + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict8_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict6") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index e8247b199c55e512a728917880ec5540d0f0f588..8825a07741fffdb3d65e5f6672adcb8a4569e5bd 100644 --- "a/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\226\260\345\242\236\350\265\240\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -29,6 +29,7 @@ request_body = commonFuc().get_business_data(module, "payload70") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) + # 获取商品信息并进行参数化处理 product_id = result["data"]["list"][0]["productId"] price = result["data"]["list"][0]["referencePrice"] @@ -59,8 +60,10 @@ request_body = commonFuc().get_business_data(module, "payload7", product_id, pri # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") print(check_dict) diff --git "a/air_case/cmdc_frequent_purchase/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index c0c9f82c67d350f2ed4ecdfc16f3da028fdda3fe..d3f50922c5887c53f27ab2a626b4872e32cf4be7 100644 --- "a/air_case/cmdc_frequent_purchase/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\267\273\345\212\240\350\267\250\347\253\231\347\202\271\345\225\206\345\223\201\350\207\263\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -73,10 +73,10 @@ request_body = commonFuc().get_business_data(module, "payload4", product_id_102, # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) -# # 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict9") -# # 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# # # 获取预期结果 +# check_dict = commonFuc().get_business_data(module, "checkDict9") +# # # 断言实际结果中是否包含预期结果的内容 +# commonFuc().check_result(check_dict, result) # 步骤五切换至子站点国药集团河南省医疗器械有限公司并添加商品至常购清单列表 # 切换至子站点 @@ -91,10 +91,12 @@ request_body = commonFuc().get_business_data(module, "payload4", product_id_103, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9") -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_frequent_purchase/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_frequent_purchase/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" index f214597d2404eb689ebef9773f79cdf4d663ad76..7a33c7930e860d022718861c0a151abefd7b7566 100644 --- "a/air_case/cmdc_frequent_purchase/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_frequent_purchase/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\224\250\346\210\267\345\270\270\350\264\255\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") print(check_dict) diff --git "a/air_case/cmdc_fresenius_group/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.air/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.py" "b/air_case/cmdc_fresenius_group/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.air/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.py" index ce77a6c736ac48f75e660a1bceed2ee449863e00..93d8ae703e097a43b0bc8051b4d3b401272f5d74 100644 --- "a/air_case/cmdc_fresenius_group/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.air/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_fresenius_group/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.air/\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") diff --git "a/air_case/cmdc_fresenius_group/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.air/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.py" "b/air_case/cmdc_fresenius_group/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.air/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.py" index 372202ea3319e12d3febc0ee35961f3ad41d026d..d95bed46c137c23610a6e495d10234feaf32b5c1 100644 --- "a/air_case/cmdc_fresenius_group/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.air/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.py" +++ "b/air_case/cmdc_fresenius_group/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.air/\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225_\346\231\256\351\200\232\345\245\227\345\214\205.py" @@ -16,30 +16,33 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) -# 第二步加入购物车 +# 第二步创建需求单 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") request_body = commonFuc().get_business_data(module, "payload31") """ - 场景:套包清单获取 - 用例名称:套包清单获取 + 场景:创建需求单_普通套包 + 用例名称:创建需求单_普通套包 输出:{"demandCode": "%s"} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -demand_parent_id = result["data"]["国药集团上海医疗器械有限公司"]["demandParentId"] -result = {"demandCode": result["data"]["国药集团上海医疗器械有限公司"]["demandItems"][0]["demandCode"]} +demand_parent_id = result["data"]["国药集团联合医疗器械有限公司"]["demandParentId"] +result = {"demandCode": result["data"]["国药集团联合医疗器械有限公司"]["demandItems"][0]["demandCode"]} +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.py" index c0a46513e9cba21618c2ef9b052cffd5e2139ac1..9a02a6879eea126870581f42ccd8364e2fe20b70 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\347\232\204\351\252\214\350\257\201.py" @@ -51,8 +51,11 @@ request_body = commonFuc().get_business_data(module, "payload7", group_code, gro # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) result = {"productCode": result["data"]["list"][0]["products"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.py" index a70065bb8a80aa683707bf0fb85a74d74cb1d9d4..e8d96c125d357bca508de8415dc5ef527d93de68 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.air/\345\245\227\345\214\205\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\350\267\263\350\275\254.py" @@ -9,33 +9,36 @@ case_tag:cmdc_api,cmdc套包列表查询条件验证_商品详情页跳转,2264, from common.common_func import commonFuc from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import random import json module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 第二步进行套包列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload22") +request_body = commonFuc().get_business_data(module, "payload22_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) +# 生成随机数 +group_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取套包中商品信息和套包信息groupProductCode -product_info = result["data"]["list"][0]["products"][0]["productName"] -product_line_code = result["data"]["list"][0]["productLineCode"] -company_code = result["data"]["list"][0]["products"][0]["companyCode"] -group_product_code = result["data"]["list"][0]["products"][0]["productCode"] -group_name = result["data"]["list"][0]["groupName"] -group_material_code = result["data"]["list"][0]["products"][0]["materialCode"] -group_code = result["data"]["list"][0]["groupCode"] +product_info = result["data"]["list"][group_random]["products"][0]["productName"] +product_line_code = result["data"]["list"][group_random]["productLineCode"] +company_code = result["data"]["list"][group_random]["products"][0]["companyCode"] +group_product_code = result["data"]["list"][group_random]["products"][0]["productCode"] +group_name = result["data"]["list"][group_random]["groupName"] +group_material_code = result["data"]["list"][group_random]["products"][0]["materialCode"] +group_code = result["data"]["list"][group_random]["groupCode"] # 第三步获取商品对应的套包信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") @@ -52,11 +55,23 @@ request_body = commonFuc().get_business_data(module, "payload28", product_info, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) -# 获取商品对应的groupCode -result = {"groupCode": result["data"][0]["groupCode"]} -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict28", group_code) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +if result["data"]: + # 获取商品对应的groupCode + result = {"groupCode": result["data"][0]["groupCode"]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict28", group_code) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取商品对应的groupCode + result = {"groupCode": result["data"]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict28", None) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.py" index 78edd8be1811bbba74125e71c095cdc1155f2266..7b567afd54b2ff88f6f1ec71fec64ff14b7c1749 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\210\227\350\241\250\347\232\204\350\216\267\345\217\226.py" @@ -32,7 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.py" index f469ce3d30b425c3e0a9f6e70e3b06e2ee32f3fe..d1e80db40d3209b807a096cda7f41e674527e934 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\210\240\351\231\244\351\252\214\350\257\201.py" @@ -44,8 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload9", group_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9") # 断言实际结果中是否包含预期结果的内容 @@ -61,6 +63,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = '%s'" % group_id status = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] result = {"status": status} + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict90") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.py" index 0b26e98a8e070d98cd22790bc157105a893453bf..ace9c356c1867bd09b19f186ef81e61c68022adb 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246\351\252\214\350\257\201.py" @@ -35,7 +35,11 @@ request_body = commonFuc().get_business_data(module, "payload29") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict29") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index 2fd8ed1d8ae6e0f23a2d5c8baa4a705634e047cf..9f9331ff77d12449adfa83838b855d8043e4dd2c 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -48,8 +48,14 @@ request_body = commonFuc().get_business_data(module, "payload6", product_code, p # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + result = {"productCode": result["data"]["list"][0]["productCode"]} + +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.py" index 30d34e767effd1862d104b3a58a4bcfe7aeac40d..34cf9bdec5409332418b58211a6ce6ba4cb73dd7 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\245\227\345\214\205\345\225\206\345\223\201\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -33,7 +33,11 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.py" index b7c428cac60424591832233b753c92116c6b3449..8d61633ab9d8b6ea4586ed3577c4740a87e501e8 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244.py" @@ -74,8 +74,11 @@ request_body = {"groupIds": [result["data"]["freseniusGroups"][0]["products"][0] # 发送请求 result = requests.post(url, headers=headers, json=request_body) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.py" index 486e23e3ad09986b9b3d77a08ae7432985a59675..d39d224809e24234b57a0e782ac1a000d1fb101e 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\345\210\240\351\231\244_\345\245\227\345\214\205\344\270\215\345\255\230\345\234\250.py" @@ -53,10 +53,14 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + file.close() result = {"success": result["data"]["errMsg"]["success"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.py" index dbb2ce1b1d4dc4bcaeea8ce97f68abd2f9214f3e..49f09da27fffc1b534e5c2422d9bede08cb7498e 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\346\225\260\351\207\217\345\260\221\344\272\2162.py" @@ -19,8 +19,8 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -77,8 +77,11 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) result = {"success": result["data"]["success"]} +result["api_time"] = api_time file.close() # 获取预期结果 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.py" index 50eeae20728e1c356acd88362471e8370da491b2..f521c1016f3e14a7e91010b727c9f40115e989e5 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\225\206\345\223\201\351\207\215\345\244\215\346\267\273\345\212\240.py" @@ -19,8 +19,8 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -78,8 +78,12 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + result = {"success": result["data"]["success"]} +result["api_time"] = api_time file.close() # 获取预期结果 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" index cd68689f08123cb36de29d79d72a7e25a4835d36..c6914738c4d71b66b170fdcf5c689946d596d298 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" @@ -48,8 +48,8 @@ product_num = random.randint(1, 1000) # 将商品信息写入文件中 excel = HandleExcel(file_path, "Sheet1") -excel.write_data(row=2, column=1, value="套包测试") -excel.write_data(row=3, column=1, value="套包测试") +excel.write_data(row=2, column=1, value="套包000005") +excel.write_data(row=3, column=1, value="套包000005") excel.write_data(row=2, column=2, value=product_code_a) excel.write_data(row=2, column=3, value=product_name_a) excel.write_data(row=2, column=4, value=product_num) @@ -75,8 +75,12 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +# print(result) result = {"success": result["data"]["success"]} +result["api_time"] = api_time file.close() # 获取预期结果 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" index 6ed35803921e4c91a0bd2475f9756dbf9810b39f..d5ac130670939c7b218fa9acb39a2b4f4dd1ec16 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\226\260\345\242\236_\345\255\230\345\234\250\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" @@ -19,8 +19,8 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -89,9 +89,12 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -result = {"success": result["data"]["success"]} +result = {"success": result["data"]["success"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" index 7db96cb2e6d3559d45a0fe7f96902b29abe2808d..8239dc2f51c9194ef14156c510ea8489d6ee04f9 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\211\271\351\207\217\346\233\264\346\226\260_\345\225\206\345\223\201\346\234\252\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" @@ -56,8 +56,8 @@ excel.write_data(row=2, column=2, value=product_code_a) excel.write_data(row=2, column=3, value=product_name_a) excel.write_data(row=2, column=4, value=product_num) -excel.write_data(row=3, column=2, value="10057881") -excel.write_data(row=3, column=3, value="造口护理用品附件") +excel.write_data(row=3, column=2, value="16413312") +excel.write_data(row=3, column=3, value="微导管") excel.write_data(row=3, column=4, value=product_num) # 第二步批量新增套包 @@ -77,8 +77,11 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) result = {"success": result["data"]["success"]} +result["api_time"] = api_time file.close() # 获取预期结果 diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" index 67f076ab57ff6b61e5ac661c3bcd61e1e0319b14..ece548c053cb47e862b1eb42ee4a8e5d61eb1a65 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.air/\345\245\227\345\214\205\346\233\264\346\226\260_\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\234\200\346\273\241\350\266\263\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277.py" @@ -9,6 +9,7 @@ case_tag:cmdc_api,cmdc套包更新_套包内商品需满足同一产品线,2264, from common.common_func import commonFuc from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import uuid import json module = "cmdc_fresenius_group" @@ -28,11 +29,18 @@ request_body = commonFuc().get_business_data(module, "payload1") result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) -# 获取现有套包名称 +# 获取现有套包信息 product_json = result["data"]["list"][0]["products"][0] +# 生成随机字符串用于当做套包名称 +group_name = str(uuid.uuid4())[:10] + # 获取套包信息 group_json = result["data"]["list"][0] + +# 更新套包名称 +group_json["groupName"] = group_name + # 获取其他产品线商品信息 other_product = commonFuc().get_business_data(module, "other_product") # 获取到套包中商品信息并进行更新操作 @@ -50,8 +58,10 @@ request_body = group_json # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16_1") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" index 2c4660077488df59ee0854f392442f104df57fd3..b41c6168159db4ee1ff0076a27215d09df1f8997 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.air/\345\245\227\345\214\205\346\233\264\346\226\260_\346\226\260\345\245\227\345\214\205\345\220\215\347\247\260\345\267\262\345\255\230\345\234\250.py" @@ -48,7 +48,10 @@ request_body = group_json # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" index 16e3ef1766b3a90419459fb292a4cdb53ff2f7e8..9420adea1883c0a94cf1d02046dc5d9b29a334bd 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\345\245\227\345\214\205\346\233\264\346\226\260_\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" @@ -45,7 +45,10 @@ request_body = group_json # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.air/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.air/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.py" index 89bf6a2a0c8c1a9f11a16f1ec9895a6fa66c938b..6fc49c6973d0a152f1321d5ef4cc38b2608f3ae9 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.air/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.air/\345\245\227\345\214\205\346\233\264\346\226\260\351\252\214\350\257\201.py" @@ -40,8 +40,10 @@ request_body = result["data"]["list"][0] # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.air/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.air/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.py" index d7f60c68b9fcb46c2279cf956d1087ccdf4cda17..40bf85774c9d42aefffcdf61554383cb3ebf1bc6 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.air/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.air/\345\245\227\345\214\205\346\270\205\345\215\225\350\216\267\345\217\226.py" @@ -21,7 +21,7 @@ password = commonFuc().get_business_data(module, "password") cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) -# 第二步加入购物车 +# 第二步获取套包信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url30") request_body = commonFuc().get_business_data(module, "payload30") @@ -35,7 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload30") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict30") diff --git "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.air/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.py" "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.air/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.py" index 9c7c2df0b086a649ca41a19c1482993d29d4db0a..b8b1b855c763a4d5dea15b059860b95558cd2154 100644 --- "a/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.air/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.py" +++ "b/air_case/cmdc_fresenius_group/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.air/\345\245\227\345\214\205\347\232\204\345\210\233\345\273\272.py" @@ -37,8 +37,10 @@ request_body = commonFuc().get_business_data(module, "payload8", quantity, quant # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.air/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.py" "b/air_case/cmdc_fresenius_group/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.air/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.py" index dd206d9041285368e3780a92ceb3235ec94dfb5e..46426c778a922d015c4165947401817c62f3fc89 100644 --- "a/air_case/cmdc_fresenius_group/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.air/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_fresenius_group/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.air/\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\350\257\242.py" @@ -32,7 +32,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") # 发送请求 result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict24") diff --git "a/air_case/cmdc_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.air/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.py" "b/air_case/cmdc_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.air/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.py" index 3e89c91f70996b99831c4c3ff61e8212e8a43c79..e56d0940e1895b93932da4be98901cd4f29a496e 100644 --- "a/air_case/cmdc_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.air/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.py" +++ "b/air_case/cmdc_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.air/\346\211\271\351\207\217\346\226\260\345\242\236\345\245\227\345\214\205.py" @@ -31,7 +31,7 @@ file_path = BASE_DIR + "/data/cmdc_files/套包商品批量维护模板.xlsx" # 获取商品列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") -request_body = commonFuc().get_business_data(module, "payload19") +request_body = commonFuc().get_business_data(module, "payload19_1") result = requests.post(url, headers=headers, json=request_body) result = json.loads(result.content) @@ -39,7 +39,7 @@ result = json.loads(result.content) product_id_a = random.randint(1, len(result["data"]["list"]) - 2) product_code_a = result["data"]["list"][product_id_a]["productCode"] product_name_a = result["data"]["list"][product_id_a]["productName"] -product_id_b = random.randint(product_id_a, len(result["data"]["list"])-1) +product_id_b = random.randint(product_id_a + 1, len(result["data"]["list"])-1) product_code_b = result["data"]["list"][product_id_b]["productCode"] product_name_b = result["data"]["list"][product_id_b]["productName"] @@ -77,7 +77,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time file.close() # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_fresenius_group/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.air/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.py" "b/air_case/cmdc_fresenius_group/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.air/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.py" index 73701e8026e43084b9dd67059ebea303373cafbc..9d327f0c5d4af41fe0b75679ce8c9d97c152f85b 100644 --- "a/air_case/cmdc_fresenius_group/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.air/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.py" +++ "b/air_case/cmdc_fresenius_group/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.air/\346\237\245\350\257\242\350\247\204\346\240\274\345\236\213\345\217\267.py" @@ -37,8 +37,10 @@ request_body = commonFuc().get_business_data(module, "payload5", material_code_i # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_fresenius_group/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.air/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.py" "b/air_case/cmdc_fresenius_group/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.air/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.py" index a6dbe5e3b4f4938c8a3743818f7903d6349097a9..8f5ccd34f671b63b30f9a58b36b57241038512af 100644 --- "a/air_case/cmdc_fresenius_group/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.air/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_fresenius_group/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.air/\346\240\271\346\215\256\350\247\204\346\240\274\345\236\213\345\217\267\350\216\267\345\217\226\345\257\271\345\272\224\345\225\206\345\223\201\345\210\227\350\241\250.py" @@ -16,8 +16,8 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -33,7 +33,7 @@ request_body = commonFuc().get_business_data(module, "payload5", material_code_i # 发送请求 result = requests.get(url, params=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取规格型号 specifications = result["data"][1] # 第三步根据规格型号获取对应的商品列表 @@ -48,9 +48,14 @@ request_body = commonFuc().get_business_data(module, "payload4", specifications) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -result = {"optionStr": result["data"]["list"][0]["optionStr"]} +# print(result) +result = {"optionStr": result["data"]["list"][0]["optionStr"][:2]} + +result["api_time"] = api_time # 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict4", specifications) +check_dict = commonFuc().get_business_data(module, "checkDict4", specifications[:2]) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_fresenius_group/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" "b/air_case/cmdc_fresenius_group/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" index 9a86bf66de0aef801867a16ee32ab8da313607c5..6c8827f4e5c3a8697d74ba1fbc8e96479ee7ffba 100644 --- "a/air_case/cmdc_fresenius_group/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" +++ "b/air_case/cmdc_fresenius_group/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\346\250\241\347\263\212\345\214\271\351\205\215\347\211\251\346\226\231\347\274\226\347\240\201_\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" @@ -39,7 +39,10 @@ request_body = commonFuc().get_business_data(module, "payload27", input_value) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict27") diff --git "a/air_case/cmdc_fresenius_group/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" "b/air_case/cmdc_fresenius_group/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" index e88a797a11970ae7af4d70fde414d3b251100883..43e3a0284042076b88708127676d93daf324aeeb 100644 --- "a/air_case/cmdc_fresenius_group/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" +++ "b/air_case/cmdc_fresenius_group/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.air/\350\216\267\345\217\226\345\245\227\345\214\205\345\210\227\350\241\250_\345\225\206\345\223\201\350\257\246\346\203\205\350\267\263\350\275\254.py" @@ -9,34 +9,37 @@ case_tag:cmdc_api,cmdc获取套包列表_商品详情页面跳转,2264,2264-28,s from common.common_func import commonFuc from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin import requests +import random import json module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 第二步进行套包列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload22") +request_body = commonFuc().get_business_data(module, "payload22_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) +# 生成随机数 +group_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取套包中商品信息productLineCode、companyCode和套包信息groupCode -product_line_code = result["data"]["list"][0]["productLineCode"] -company_code = result["data"]["list"][0]["products"][0]["companyCode"] -group_code = result["data"]["list"][0]["groupCode"] - +product_line_code = result["data"]["list"][group_random]["productLineCode"] +company_code = result["data"]["list"][group_random]["products"][0]["companyCode"] +group_code = result["data"]["list"][group_random]["groupCode"] +print(group_code) # 第三步获取商品对应的套包信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") request_body = commonFuc().get_business_data(module, "payload26", product_line_code, company_code) - +print(request_body) """ 场景:验证套包商品详情是否显示套包信息 @@ -47,10 +50,19 @@ request_body = commonFuc().get_business_data(module, "payload26", product_line_c # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# 获取商品对应的groupCode -result = {"groupCode": result["data"][0]["groupCode"]} -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict25", group_code) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +print(result) +for i in result["data"]: + # 商品可能存在于多个套包,循环找到对应的套包验证 + if i["groupCode1"] == group_code: + # 获取商品对应的groupCode + result = {"groupCode": i["subList"]["groupCode"]} + + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict25", group_code) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + break diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.py" index ed3d29ab6f592583bb8becc605438309e91ec904..f01bdccba739b5c7db79b171f901f4fd5322244f 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\206\205\345\225\206\345\223\201\351\235\236\345\220\214\344\270\200\344\272\247\345\223\201\347\272\277\351\231\220\345\210\266.py" @@ -15,8 +15,8 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload12") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12") diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.py" index a07956c2a4ab72ccabdd42c0531ea81a354fdbca..06407003cfbad0d2f3441d4cae8bc45cbd3e58b7 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.air/\351\252\214\350\257\201\345\245\227\345\214\205\345\225\206\345\223\201\350\257\246\346\203\205\346\230\257\345\220\246\346\230\276\347\244\272\345\245\227\345\214\205\344\277\241\346\201\257.py" @@ -15,15 +15,15 @@ module = "cmdc_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 第二步进行套包列表获取 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") -request_body = commonFuc().get_business_data(module, "payload22") +request_body = commonFuc().get_business_data(module, "payload22_1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) @@ -46,10 +46,19 @@ request_body = commonFuc().get_business_data(module, "payload23", product_code, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# 获取商品对应的groupCode -result = {"groupCode": result["data"][0]["groupCode"]} -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict25", group_code) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# print(result) +for i in result["data"]: + # 商品可能存在于多个套包,循环找到对应的套包验证 + if i["groupCode1"] == group_code: + # 获取商品对应的groupCode + result = {"groupCode": i["subList"]["groupCode"]} + + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict25", group_code) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + break \ No newline at end of file diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.air/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.air/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.py" index fd951aaa3ff649fd6bd740749c189c41d18047b9..aa923d427eb596e1e5e3158cd38fc62d2dfa2fbf 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.air/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.air/\351\252\214\350\257\201\345\245\227\345\214\205\347\273\223\346\236\204\350\260\203\346\225\264\345\220\216\345\256\241\346\240\270\346\230\257\345\220\246\346\213\246\346\210\252.py" @@ -33,8 +33,12 @@ request_body = commonFuc().get_business_data(module, "payload32") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) result = {"errType": result["data"][0]["errType"]} + +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict32") diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.air/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.air/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.py" index 62c4b9156e9922918fa32d453c9a83d7afcc10c6..3d88d8cce6c19747c0ef7f0406788a2510086a8c 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.air/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.air/\351\252\214\350\257\201\346\226\260\345\242\236\345\220\215\347\247\260\347\233\270\345\220\214\345\245\227\345\214\205\351\231\220\345\210\266.py" @@ -49,7 +49,10 @@ request_body = commonFuc().get_business_data(module, "payload10", group_name, gr # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10") diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" index 6661987624b3fc5dc0aa836f97156dcc48de15a1..f566a7b7790de56f101d7b5e953feff8247b6164 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\346\226\260\345\242\236\347\273\223\346\236\204\347\233\270\345\220\214\347\232\204\345\245\227\345\214\205.py" @@ -40,7 +40,10 @@ request_body = commonFuc().get_business_data(module, "payload11") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") diff --git "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" index 6352310ac9811a95bbbe9c47c43cbaaa52efa18d..a6470395f7a967cc7812938b530cdc4b9c8573cb 100644 --- "a/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_fresenius_group/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.air/\351\252\214\350\257\201\347\273\204\346\210\220\345\245\227\345\214\205\351\234\2002\344\270\252\346\210\2262\344\270\252\344\273\245\344\270\212\345\225\206\345\223\201.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload13") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13") diff --git "a/air_case/cmdc_hospital/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7470c7fa86e7bded21a5ff8aae72c19c0e2c72e5 --- /dev/null +++ "b/air_case/cmdc_hospital/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,52 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc经销商关联医院新增功能验证,2298,2298-11,sit,bs +主数据平台:后台运营系统经销商关联医院新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步经销商关联医院新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") +request_body = commonFuc().get_business_data(module, "payload12") +# print(request_body) +""" + + 场景: 经销商关联医院新增功能验证 + 用例名称:经销商关联医院新增功能验证 + 输出:{"customerCode": "1228325"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取新增之后医院信息 +result = json.loads(result.content) +result = {"customerCode": result["data"]["customerCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict12") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_hospital/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.air/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.air/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..2a75aaeb645933a6188ff4be6ab2f0411f5274f9 --- /dev/null +++ "b/air_case/cmdc_hospital/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.air/aa_\346\226\260\345\242\236\345\214\273\351\231\242\346\241\243\346\241\210\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc新增医院档案功能验证,2298,2298-14,sit,bs +主数据平台:后台运营系统新增医院档案接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步新增医院档案 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") +request_body = commonFuc().get_business_data(module, "payload18") +# print(request_body) +""" + + 场景: 新增医院档案功能验证 + 用例名称:新增医院档案功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict18") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + + diff --git "a/air_case/cmdc_hospital/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..6a2e572ef1dc961d5a9bf9b82dcd2f9b3602c146 --- /dev/null +++ "b/air_case/cmdc_hospital/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/ab_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc医院档案信息编辑功能验证,2298,2298-15,sit,bs +主数据平台:后台运营系统医院档案信息编辑接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取医院档案列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19_1") +request_body = commonFuc().get_business_data(module, "payload19_1") +# 发送请求 +result = requests.get(url, headers=headers, params=request_body) +result = json.loads(result.content) + +# 获取医院档案信息 +hospital_json = result["data"]["list"][0] + +# 第三步医院档案编辑操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = hospital_json + +""" + + 场景: 医院档案信息编辑功能验证 + 用例名称:医院档案信息编辑功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict19") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_hospital/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7db7fc0f2d7e61b1a3db1341e86927773bcfdce4 --- /dev/null +++ "b/air_case/cmdc_hospital/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc医院档案信息删除功能验证,2298,2298-16,sit,bs +主数据平台:后台运营系统医院档案信息删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取医院档案列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19_1") +request_body = commonFuc().get_business_data(module, "payload19_1") +# 发送请求 +result = requests.get(url, headers=headers, params=request_body) +result = json.loads(result.content) + +# 获取医院档案信息 +id = result["data"]["list"][0]["id"] + +# 第三步医院档案删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") +request_body = commonFuc().get_business_data(module, "payload20", id) + +""" + + 场景: 医院档案信息删除功能验证 + 用例名称:医院档案信息删除功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict20") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_hospital/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..faf4b985e3c4ff6cc451e6a1cc42b40720500cda --- /dev/null +++ "b/air_case/cmdc_hospital/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc经销商关联医院信息编辑功能验证,2298,2298-12,sit,bs +主数据平台:后台运营系统经销商关联医院信息编辑接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商关联医院管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13_1") +# 发送请求 +result = requests.get(url, headers=headers) +result = json.loads(result.content) + +# 获取经销商关联医院信息 +hospital_json = result["data"]["list"][0] + +# 第三步经销商关联医院编辑操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = hospital_json + +""" + + 场景: 经销商关联医院信息编辑功能验证 + 用例名称:经销商关联医院信息编辑功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_hospital/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..12bd32f9d2ed3e3bd7afa9cafc77ccdaa4963861 --- /dev/null +++ "b/air_case/cmdc_hospital/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/c_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\211\271\351\207\217\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc经销商关联医院批量新增功能验证,2298,2298-11,sit,bs +主数据平台:后台运营系统经销商关联医院批量新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/经销商关联医院模板.xlsx" + +# 第二步经销商关联医院批量导入 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + + 场景: 经销商关联医院批量新增功能验证 + 用例名称:经销商关联医院批量新增功能验证 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_hospital/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.air/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.air/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..affdbe52f6006999c910b7da2930d084f212d276 --- /dev/null +++ "b/air_case/cmdc_hospital/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.air/d_\345\257\274\345\205\245\346\227\245\345\277\227\346\237\245\347\234\213\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导入日志查看验证,2298,2298-12,sit,bs +主数据平台:后台运营系统导入日志查看接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取导入日志信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") + +""" + + 场景: 导入日志查看验证 + 用例名称:导入日志查看验证 + 输出:{"status":2} +""" + +# 发送请求 +result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取导入记录状态 +result = json.loads(result.content) +result = {"status": result["data"]["list"][0]["status"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7bd90a25913533f2e30d5d098fd5df5e7c3333a8 --- /dev/null +++ "b/air_case/cmdc_hospital/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc经销商关联医院删除功能验证,2298,2298-26,sit,bs +主数据平台:后台运营系统经销商关联医院删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商关联医院管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16_1") +# 发送请求 +result = requests.get(url, headers=headers) +result = json.loads(result.content) + +# 获取经销商关联医院信息 +for i in result["data"]["list"]: + # 第三步经销商关联医院删除操作 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") + request_body = commonFuc().get_business_data(module, "payload16", i["id"]) + print(request_body) + """ + + 场景: 经销商关联医院删除功能验证 + 用例名称:经销商关联医院删除功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":null,"freshToken":null} + """ + + # 发送请求 + result = requests.get(url, params=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + + # 将接口响应时间添加至result + result = json.loads(result.content) + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict16") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..25ee353cb1d6a3cbaf0a1061fdc4130796b74599 --- /dev/null +++ "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_关联医院列表,2298,2298-9,sit,bs +主数据平台:后台运营系统获取关联医院列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取关联医院列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 获取随机数 +hospital_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取医院信息 +hospitalCode = result["data"]["list"][hospital_random]["hospitalCode"] +hospitalName = result["data"]["list"][hospital_random]["hospitalName"] + +# 第三步进行列表条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") +request_body = commonFuc().get_business_data(module, "payload10", hospitalCode, hospitalName) + +""" + + 场景: 列表查询条件验证_关联医院列表 + 用例名称:列表查询条件验证_关联医院列表 + 输出:{"hospitalCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取医院信息 +result = json.loads(result.content) +result = {"hospitalCode": result["data"]["list"][0]["hospitalCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict10", hospitalCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.py" "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..43a9913d59b7aec06c209ba95e58bc6eb5c40be4 --- /dev/null +++ "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_宽限期管理,2298,2298-20,sit,bs +主数据平台:后台运营系统获取宽限期管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取宽限期管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +grace_random = random.randint(0, len(result["data"]["list"]) -1) +# 获取宽限期信息 +productLineCode = result["data"]["list"][grace_random]["productLineCode"] + +# 第三步进行列表查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22", productLineCode) + +""" + + 场景: 列表查询条件验证_宽限期管理 + 用例名称:列表查询条件验证_宽限期管理 + 输出:{"productLineCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取宽限期信息 +result = json.loads(result.content) +result = {"productLineCode": result["data"]["list"][0]["productLineCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict22", productLineCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..cc49b7fe28ef2b7cd2963434d014ddac0954f80e --- /dev/null +++ "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" @@ -0,0 +1,65 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_经销商关联医院管理列表,2298,2298-4,sit,bs +主数据平台:后台运营系统获取经销商关联医院管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商关联医院管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +hospital_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取经销商关联医院信息 +customerCode = result["data"]["list"][hospital_random]["customerCode"] +customerName = result["data"]["list"][hospital_random]["customerName"] +hospitalCode = result["data"]["list"][hospital_random]["hospitalCode"] +hospitalName = result["data"]["list"][hospital_random]["hospitalName"] + +# 第三步进行列表查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5", customerCode, customerName, hospitalCode, hospitalName) + +""" + + 场景: 列表查询条件验证_经销商关联医院管理列表 + 用例名称:列表查询条件验证_经销商关联医院管理列表 + 输出:{"customerCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取经销商关联医院信息 +result = json.loads(result.content) +result = {"customerCode": result["data"]["list"][0]["customerCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict5", customerCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..aaa011a00ab7c56838c86a5c704a6c1df36c656b --- /dev/null +++ "b/air_case/cmdc_hospital/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_经销商列表,2298,2298-7,sit,bs +主数据平台:后台运营系统获取经销商列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_ramdom = random.randint(0, len(result["data"]["list"]) - 1) +# 获取经销商信息 +telephone = (result["data"]["list"][company_ramdom]["telephone"] if result["data"]["list"][company_ramdom][ + "telephone"] else "") +userName = (result["data"]["list"][company_ramdom]["userName"] if result["data"]["list"][company_ramdom][ + "userName"] else "") +userNo = (result["data"]["list"][company_ramdom]["userNo"] if result["data"]["list"][company_ramdom][ + "userNo"] else "") +customerCompanyName = result["data"]["list"][company_ramdom]["customerCompanyName"] + +# 第三步进行列表条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url8") +request_body = commonFuc().get_business_data(module, "payload8", telephone, userName, userNo, customerCompanyName) + +""" + + 场景: 列表查询条件验证_经销商列表 + 用例名称:列表查询条件验证_经销商列表 + 输出:{"customerCompanyName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取经销商信息 +result = json.loads(result.content) +result = {"customerCompanyName": result["data"]["list"][0]["customerCompanyName"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict8", customerCompanyName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..3d3fe87a187beb354223f7a85e3e9645be9df10d --- /dev/null +++ "b/air_case/cmdc_hospital/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\214\273\351\231\242\346\241\243\346\241\210\344\277\241\346\201\257\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,77 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc医院档案信息批量导出功能验证,2298,2298-13,sit,bs +主数据平台:后台运营系统医院档案信息批量导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取医院档案列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +hospital_random = random.randint(0,len(result["data"]["list"]) - 1) +# 获取植入台账信息 +hospitalCode = result["data"]["list"][hospital_random]["hospitalCode"] + +# 第三步医院档案信息批量导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17", hospitalCode) + +""" + + 场景: 医院档案信息批量导出功能验证 + 用例名称:医院档案信息批量导出功能验证 + 输出:{"hospitalCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/医院管理.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中子医院编号 +excel = HandleExcel(file_path, "Sheet1") +result = {"hospitalCode": excel.read_data()[0].get("医院编号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict17", hospitalCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + + diff --git "a/air_case/cmdc_hospital/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..2a4fce070c048d973ed25a22acf78e8c8283d3c7 --- /dev/null +++ "b/air_case/cmdc_hospital/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\346\211\271\351\207\217\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc宽限期管理批量导出功能验证,2298,2298-21,sit,bs +主数据平台:后台运营系统宽限期管理批量导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取宽限期管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +grace_random = random.randint(0, len(result["data"]["list"]) -1) +# 获取宽限期信息 +productLineCode = result["data"]["list"][grace_random]["productLineCode"] + +# 第三步进行宽限期管理批量导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23", productLineCode) + +""" + + 场景: 宽限期管理批量导出功能验证 + 用例名称:宽限期管理批量导出功能验证 + 输出:{"productLineCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/经销商填报宽限期管理.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中产品线编码 +excel = HandleExcel(file_path, "Sheet1") +result = {"productLineCode": excel.read_data()[0].get("产品线编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict23", productLineCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_hospital/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..9441a0d7359009abda13ca6e76c77239c40a51ed --- /dev/null +++ "b/air_case/cmdc_hospital/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\244\215\345\205\245\345\217\260\350\264\246\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc植入台账导出功能验证,2298,2298-25,sit,bs +主数据平台:后台运营系统植入台账导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取上报植入列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +hospital_random = random.randint(0,len(result["data"]["list"]) - 1) +# 获取植入台账信息 +demandCode = result["data"]["list"][hospital_random]["demandCode"] + +# 第三步进行植入台账导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") +request_body = commonFuc().get_business_data(module, "payload3", demandCode) + +""" + + 场景: 植入台账导出功能验证 + 用例名称:植入台账导出功能验证 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/导出植入台账.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中子需求单编号 +excel = HandleExcel(file_path, "工作表1") +result = {"demandCode": excel.read_data()[0].get("子需求单编号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict3", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_hospital/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_hospital/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..c56eff73d89445ff402078f74401f10da6914473 --- /dev/null +++ "b/air_case/cmdc_hospital/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc经销商关联医院导出功能验证,2298,2298-5,sit,bs +主数据平台:后台运营系统经销商关联医院导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 第二步获取经销商关联医院管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +hospital_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取经销商关联医院信息 +total = result["data"]["total"] + +# 第三步进行经销商关联医院信息导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# print(request_body) +""" + + 场景: 经销商关联医院导出功能验证 + 用例名称:经销商关联医院导出功能验证 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/经销商管理医院.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中数量个数 +excel = HandleExcel(file_path, "Sheet1") +result = {"total": len(excel.read_data())} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..37cd8a65cda1d5067e85fc1a0fb815db5f6c415e --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\212\346\212\245\346\244\215\345\205\245\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取上报植入列表,2298,2298-1,sit,bs +主数据平台:后台运营系统获取上报植入列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取上报植入列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# print(request_body) +""" + + 场景: 获取上报植入列表 + 用例名称:获取上报植入列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict1") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..8c341836bbab221aa6efa1df6d23a712ecfbf048 --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\214\273\351\231\242\345\210\227\350\241\250.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取关联医院列表,2298,2298-8,sit,bs +主数据平台:后台运营系统获取关联医院列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取关联医院列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9") +# print(request_body) +""" + + 场景: 获取关联医院列表 + 用例名称:获取关联医院列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict9") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + + diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..0b89dcf3df3648bf8ea431f137ead5bf730c8acf --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\214\273\351\231\242\350\264\246\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取医院账单详情,2298,2298-2,sit,bs +主数据平台:后台运营系统获取医院账单详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取上报植入列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +hospital_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取上报植入信息 +soCode = result["data"]["list"][hospital_random]["soCode"] + +# 第三步获取医院账单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2", soCode) + +""" + + 场景: 获取医院账单详情 + 用例名称:获取医院账单详情 + 输出:{"soCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取上报植入信息 +result = json.loads(result.content) +result = {"soCode": result["data"]["soCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict2", soCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..9fab68d2435160396d7dad75af47fd29c7ba12bb --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\275\351\231\220\346\234\237\347\256\241\347\220\206\345\210\227\350\241\250.py" @@ -0,0 +1,52 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取宽限期管理列表,2298,2298-19,sit,bs +主数据平台:后台运营系统获取宽限期管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取宽限期管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21") +# print(request_body) +""" + + 场景: 获取宽限期管理列表 + 用例名称:获取宽限期管理列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict21") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + + + diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e7961a0903490a59f4f22a6c56986774f9ebd3b3 --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\347\256\241\347\220\206\345\210\227\350\241\250.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取经销商关联医院管理列表,2298,2298-3,sit,bs +主数据平台:后台运营系统获取经销商关联医院管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商关联医院管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# print(request_body) +""" + + 场景: 获取经销商关联医院管理列表 + 用例名称:获取经销商关联医院管理列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict4") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" "b/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..f26d354723afc1520bf0b580a5fa2a08dac32cc1 --- /dev/null +++ "b/air_case/cmdc_hospital/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\273\217\351\224\200\345\225\206\345\210\227\350\241\250.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取经销商列表,2298,2298-6,sit,bs +主数据平台:后台运营系统获取经销商列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_hospital" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取经销商列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7") +# print(request_body) +""" + + 场景: 获取经销商列表 + 用例名称:获取经销商列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict7") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + + diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" index 2006d788fbcaf5d25f86651c7c5aabdf6aaf5b1a..fa2266b914b0d1cf104d215a68c622435fee3453 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 进行商品jde状态调整为停用操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.jdeStatus = '0' WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.jdeStatus = '0' WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) # 第二步进行提交订单 @@ -43,10 +43,13 @@ request_body = commonFuc().get_business_data(module, "payload19") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取message result = {"message": result["message"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" index d42f06d0f41e86b4047f09d6ac284a19fc97f9ee..d937bf1958b090440d760ab8512353206b5936f5 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201jde\345\201\234\347\224\250\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 查询指定需求单信息 -order_num = "17018438457347575" +order_num = "17071033368805325" # 第二步获取多采商城需求单列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_demand_list") @@ -53,8 +53,10 @@ request_body = commonFuc().get_business_data(module, "payload20", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") # print(check_dict) @@ -62,5 +64,5 @@ check_dict = commonFuc().get_business_data(module, "checkDict20") commonFuc().check_result(check_dict, result) # 把商品对应的jde状态调整为启用状态操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.jdeStatus = 'P' WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.jdeStatus = 'P' WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.py" index a4d30188dee3a8b7f7fdd65ac391660a8ec9b9e3..a494c7e14346b09e8aa2a6cb6bf214b91d4ac171 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_a.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 进行商品下架操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.status = 102 WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.status = 102 WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) # 第二步进行提交订单 @@ -43,10 +43,14 @@ request_body = commonFuc().get_business_data(module, "payload19") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取message result = {"message": result["message"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.py" index 935c69e82028183a53027e4d2dee85396520dd9a..b47b63111c61db6496d8311aa4a50200571a6e5c 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.air/\345\225\206\345\223\201\344\270\213\346\236\266\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_b.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 查询指定需求单信息 -order_num = "17018438457347575" +order_num = "17071033368805325" # 第二步获取多采商城需求单列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_demand_list") @@ -53,7 +53,11 @@ request_body = commonFuc().get_business_data(module, "payload20", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") @@ -62,5 +66,5 @@ check_dict = commonFuc().get_business_data(module, "checkDict20") commonFuc().check_result(check_dict, result) # 进行商品上架架操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.status = 101 WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.status = 101 WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) \ No newline at end of file diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 07b575c1a0e67da12d23225d780d09710f0a92a3..98dbeff5ec976f33be470b75ccdbb9a88170e532 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\345\225\206\345\223\201\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -25,8 +25,11 @@ request_body = commonFuc().get_business_data(module, "payload15") # 发送请求 result = requests.get(url, params=request_body) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" index d3a4699d66b2b4f6d57a4810de5d4d5818a65918..d648a26dde1bce9db06c44ba2d8a545d777a7aba 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\344\270\213\345\215\225_e.py" @@ -17,8 +17,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -32,7 +32,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") amount_product = float(random.randint(100, 1000)) # print(amount_product) # 进行商品金额调整操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.referencePrice = {} WHERE t.productId = 7991".format(amount_product) +sql = "UPDATE `cmdc-product`.ic_product t SET t.referencePrice = {} WHERE t.productId = 9184".format(amount_product) mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) # 第二步进行提交订单 @@ -42,23 +42,34 @@ request_body = commonFuc().get_business_data(module, "payload19") """ 场景: 验证进行订单提交时,修改商品金额,订单是否按修改前商品金额计算 用例名称:商品金额调整验证_下单 - 输出:{"productAmount":"48.25"} + 输出:{"productAmount":"720.38"} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) +result["api_time"] = api_time if result["success"]: # 获取订单中商品金额 - result = {"productAmount": result["data"]["国药集团上海医疗器械有限公司"]["productAmount"]} + result = {"productAmount": result["data"]["国药集团联合医疗器械有限公司"]["productAmount"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22") # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) +elif result["code"] == "30461": + # 获取预期结果//商品证照校验错误 + check_dict = commonFuc().get_business_data(module, "checkDict_30461") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) else: - # 获取预期结果 + # 获取预期结果//商品无效 check_dict = commonFuc().get_business_data(module, "checkDictInvalid") # print(check_dict) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" index 84e40628cae8a232a14385faf4cc64689e81e4bb..48acd2e60274c14ee285534cc44a1f16a698a321 100644 --- "a/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" +++ "b/air_case/cmdc_order_handle/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.air/\345\225\206\345\223\201\351\207\221\351\242\235\350\260\203\346\225\264\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_e.py" @@ -18,8 +18,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -33,11 +33,11 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") amount_product = float(random.randint(100, 1000)) # print(amount_product) # 进行商品金额调整操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.referencePrice = {} WHERE t.productId = 7991".format(amount_product) +sql = "UPDATE `cmdc-product`.ic_product t SET t.referencePrice = {} WHERE t.productId = 9184".format(amount_product) mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) # 查询指定需求单信息 -order_num = "17018438457347575" +order_num = "17071033368805325" # 第二步获取多采商城需求单列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_demand_list") @@ -62,11 +62,15 @@ request_body = commonFuc().get_business_data(module, "payload20", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) if result["success"]: # 获取订单中商品金额 - result = {"productAmount": result["data"]["国药集团上海医疗器械有限公司"]["datas"][0]["productAmount"]} + result = {"productAmount": result["data"]["国药集团联合医疗器械有限公司"]["datas"][0]["productAmount"]} + result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21", amount_product) diff --git "a/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.py" "b/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.py" index c8e9473edc2d5708cac4ab0aa1cb0b3cc5cdcd18..8bcb264fa86db130d646f9347b6c899b6b7bd385 100644 --- "a/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.py" +++ "b/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\344\270\213\345\215\225_c.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 进行商品控销操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.isControlSales = 1 WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.isControlSales = 1 WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) # 第二步进行提交订单 @@ -43,10 +43,12 @@ request_body = commonFuc().get_business_data(module, "payload19") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取message result = {"message": result["message"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.py" "b/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.py" index b1ebb084eb710e4858504fe110c8ce4bb77c7fc1..4f995bb93b62bb467104d40c9157891ba3754125 100644 --- "a/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.py" +++ "b/air_case/cmdc_order_handle/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.air/\346\216\247\351\224\200\345\225\206\345\223\201\346\213\246\346\210\252\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225_d.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -28,7 +28,7 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 查询指定需求单信息 -order_num = "17018438457347575" +order_num = "17071033368805325" # 第二步获取多采商城需求单列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_demand_list") @@ -53,8 +53,10 @@ request_body = commonFuc().get_business_data(module, "payload20", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") # print(check_dict) @@ -62,5 +64,5 @@ check_dict = commonFuc().get_business_data(module, "checkDict20") commonFuc().check_result(check_dict, result) # 进行去除商品控销状态操作 -sql = "UPDATE `cmdc-product`.ic_product t SET t.isControlSales = 0 WHERE t.productId = 7991" +sql = "UPDATE `cmdc-product`.ic_product t SET t.isControlSales = 0 WHERE t.productId = 9184" mysql_handle.executeUpdate(host, port, user, pwd, "cmdc-product", sql) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.py" index cfce58f7c81abdb4e5ab817c97ce08679cce358e..5e0f6e2dd6bdc6abacab7f6892cb3ec0d99b4f71 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242jde\351\205\215\347\275\256\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -46,8 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload_jde_config", compa # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_jde_config") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.py" index 1e8744c2ab8f59508e0309233f39f66a425aa90e..910076e8fe53e0226b9aabae73e8e376f4e9081d 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -52,9 +52,12 @@ request_body = commonFuc().get_business_data(module, "payload1", product_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + result = {"productId": result["data"]["productId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1", product_id) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 2e4b87f1d8521b05b9561809cb82f1d29cc393ea..f639e0de9a1299ccbca2fc9fa8cb948f71cf80f6 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -38,10 +38,12 @@ request_body = commonFuc().get_business_data(module, "payload16", product_code, # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中商品信息 result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16", product_code) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.py" index 360e3d20c471da81bdee74f559513fb2c4abfc3a..fee240416cee7d9b52aa7b04d101e23870d71762 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_a.py" @@ -42,10 +42,13 @@ request_body = commonFuc().get_business_data(module, "payload8", receiver_name) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中收货人姓名 result = {"receiverName": result["data"]["addresses"]["list"][0]["receiverName"][-2:]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8_1", receiver_name) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.py" index d9adf2ef17477a760f52a46f16b776b98895f5cc..0c91d0a06c0034157b36f0765fd96fda6621dc4e 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_b.py" @@ -43,10 +43,12 @@ request_body = commonFuc().get_business_data(module, "payload8", address) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中收货人姓名 result = {"address": result["data"]["addresses"]["list"][0]["address"][-2:]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8_2", address) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.py" index 0eed8dc7c546ee40fb4b630093c55039d8856a10..8f83d92a24d550b142ec3633faa4a87cf2d9399c 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_c.py" @@ -43,10 +43,13 @@ request_body = commonFuc().get_business_data(module, "payload8", mobile) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中收货人姓名 result = {"mobile": result["data"]["addresses"]["list"][0]["mobile"][-2:]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8_3", mobile) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.py" index 76a1f1d7d7a1a497fd6c0853838a2d3c2e1b3834..b5f7ec37ae97ac251aac94cd5e73d8a4e1aea60a 100644 --- "a/air_case/cmdc_order_handle/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_order_handle/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.air/\346\237\245\350\257\242\347\224\250\346\210\267\345\234\260\345\235\200\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload17") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 0005593aa50f081487f7c9f75241c191b0c83e3a..0dc4e0842c2166a7e7534d8f3e30767521ceb134 100644 --- "a/air_case/cmdc_order_handle/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\347\211\251\346\226\231\347\274\226\347\240\201\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -37,10 +37,14 @@ request_body = commonFuc().get_business_data(module, "payload12", random_code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取查询结果中数据 result = {"data": result["data"][0][0]} +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12", random_code) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.air/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.py" "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.air/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.py" index 19a31aa8b5ca087f935e919e6bded27ec0de2b41..67a6b8625e508583573f243a65f60925fb9e27d3 100644 --- "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.air/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.py" +++ "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.air/\350\216\267\345\217\226\345\216\237\350\256\242\345\215\225\344\277\241\346\201\257\346\216\245\345\217\243\351\252\214\350\257\201_\345\206\215\346\235\245\344\270\200\345\215\225.py" @@ -36,6 +36,7 @@ result = json.loads(result.content) random_demand = random.randint(0, len(result["data"]["list"]) - 1) # 获取需求单信息 demand_id = result["data"]["list"][random_demand]["demandId"] +demand_code = result["data"]["list"][random_demand]["demandCode"] # print(demand_id) # 第三步获取原订单信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") @@ -49,19 +50,29 @@ request_body = commonFuc().get_business_data(module, "payload18", demand_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +# 将接口影响时间添加至结果中 +result["api_time"] = api_time + if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict18") # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) -else: - # 获取预期结果 +elif result["code"] == "ERROR": + # 获取预期结果/原需求单中商品无效获取被删除 check_dict = commonFuc().get_business_data(module, "checkDictInvalid") # print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) +else: + # 获取预期结果/原需求单为历史脏数据导致接口异常 + check_dict = commonFuc().get_business_data(module, "checkDict_code", demand_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.py" index 1bae197ee6cfff14a41d288a004902a68de43587..067f6b3938bdd1851ed7a753f00226f24b4c6bf7 100644 --- "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.air/\350\216\267\345\217\226\346\224\266\346\254\276\350\264\246\345\217\267\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -36,10 +36,12 @@ request_body = commonFuc().get_business_data(module, "payload23", company_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取收款账号中公司信息 result = {"companyId": result["data"]["list"][0]["companyId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23", company_id) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 130258cf56c540907bbe0f5a8845ab41537776af..10ecd0874ca7466f18cea4e7f6557d2f009872bb 100644 --- "a/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload7") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 4ef68150f37120f3bda5167d1e16dc737afd204a..036bad0bf390e2b5b30bb18bc57798e8a64afc25 100644 --- "a/air_case/cmdc_order_handle/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\350\247\204\346\240\274\345\236\213\345\217\267\346\250\241\347\263\212\346\237\245\350\257\242\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -23,7 +23,8 @@ cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) # 生成随机数据 -random_code = random.randint(0, 8) +random_code = random.randint(0, 7) + # 第二步进行规格型号模糊匹配查询 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") request_body = commonFuc().get_business_data(module, "payload10", random_code) @@ -36,11 +37,15 @@ request_body = commonFuc().get_business_data(module, "payload10", random_code) # 发送请求 result = requests.get(url, params=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取查询结果中数据 result = {"data": result["data"][0][0]} -# print(result) +result["api_time"] = api_time +print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", random_code) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 33b02c0bc8776955c11baaf02bb4e7d54dbb4009..cf220ec3abb6b80277a844994fc37efca76ae322 100644 --- "a/air_case/cmdc_order_handle/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -16,16 +16,16 @@ module = "cmdc_order_handle" # 第一步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) # 生成随机数据 random_code = random.randint(0, 10) -product_code = "13977315" -material_code = "00-8800-000-10" +product_code = "14384307" +material_code = "TPVL200" # 第二步通过Excel复制添加商品 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") request_body = commonFuc().get_business_data(module, "payload14", product_code, material_code, random_code) @@ -38,10 +38,12 @@ request_body = commonFuc().get_business_data(module, "payload14", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中数据 result = {"productCode": result["data"]["data"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14", product_code) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 65523d4c15271cf55459581fe657044a7091bac7..f1fb38a015bf0e9c7c784ac1c0636fa5f8ed21fb 100644 --- "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\345\225\206\345\223\201\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -25,10 +25,12 @@ request_body = commonFuc().get_business_data(module, "payload9") # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中商品code result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index c4cf70b0ed1116d9f99ed7aa21ee127f634e2ace..1362bd0f286dc1b2db61e4ce53488864b07eedb0 100644 --- "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\347\211\251\346\226\231\347\274\226\347\240\201\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -27,10 +27,12 @@ request_body = commonFuc().get_business_data(module, "payload13", material_code) # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中商品对应的物料编码 result = {"materialCode": result["data"]["list"][0]["materialCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13", material_code) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index b510f866ec96f47ec65b5753fb187e07ed121bdc..c6dc08af97f90c315a927342b5cf77b244e6379e 100644 --- "a/air_case/cmdc_order_handle/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\200\232\350\277\207\350\247\204\346\240\274\345\236\213\345\217\267\346\237\245\350\257\242\345\225\206\345\223\201\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -27,10 +27,12 @@ request_body = commonFuc().get_business_data(module, "payload11", specification) # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取查询结果中商品对应的规格型号 result = {"specifications": result["data"]["list"][0]["specifications"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11", specification) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" "b/air_case/cmdc_order_handle/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" index 9033744614bfa690a722e2d82da63523839f4d66..bd224fb97e67ceb448e347d3f93d3038e9b5c010 100644 --- "a/air_case/cmdc_order_handle/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" +++ "b/air_case/cmdc_order_handle/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.air/\351\231\204\344\273\266\344\270\212\344\274\240\346\216\245\345\217\243\351\252\214\350\257\201_\347\273\223\347\256\227\351\241\265\351\235\242.py" @@ -42,8 +42,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6") # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.air/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.py" "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.air/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.py" index e18cb586efe739d0ca5bf45cf64ca15e95076371..ff17eaf1cee52dcebdd3f2c8f34ad137dcd7a91c 100644 --- "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.air/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.air/\351\252\214\350\257\201\344\270\213\345\215\225\346\227\266\344\270\215\344\274\240\345\234\260\345\235\200\344\277\241\346\201\257.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload5") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["code"] == "3021": # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") diff --git "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" index d15aa050dad674b860f861018c6b39419c2effb4..6d46d6a602808c9774f68c9fdeae28e37925e608 100644 --- "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\344\270\213\346\236\266\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -28,14 +28,14 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取商品信息 -product_id = result["data"]["list"][0]["productId"] +product_id = result["data"]["list"][1]["productId"] # 第三步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -52,9 +52,12 @@ request_body = commonFuc().get_business_data(module, "payload1", product_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + result = {"productId": result["data"]["productId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1", product_id) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" index 5b722b7cf918b0eefbb0eb0c0b5e7bae8fd866f6..d249ad5e55a9e83fb0f4c0f3e41d8245e95695be 100644 --- "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\345\267\262\345\244\261\346\225\210\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" @@ -52,9 +52,12 @@ request_body = commonFuc().get_business_data(module, "payload1", product_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) result = {"productId": result["data"]["productId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1", product_id) # print(check_dict) diff --git "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" index ebddbf7d26a4846004da0e7d78feee0d990d5a94..0bdc645381048fea97329e8d43f83b0434f1e438 100644 --- "a/air_case/cmdc_order_handle/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_order_handle/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.air/\351\252\214\350\257\201\346\216\247\351\224\200\345\225\206\345\223\201\350\257\246\346\203\205\346\237\245\350\257\242.py" @@ -16,8 +16,8 @@ module = "cmdc_order_handle" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -34,8 +34,8 @@ product_id = result["data"]["list"][0]["productId"] # 第三步登录多采商城获取token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -52,9 +52,12 @@ request_body = commonFuc().get_business_data(module, "payload1", product_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) result = {"productId": result["data"]["productId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1", product_id) # print(check_dict) diff --git "a/air_case/cmdc_order_list/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..18076dbafe4fa81efc5df2b1c0ac0364d0422c70 --- /dev/null +++ "b/air_case/cmdc_order_list/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/a_\346\224\266\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc收货地址新增验证_代客下单,2295,2295-37,sit,bs +主数据平台:后台运营系统获收货地址新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][customer_random]["userId"] +company_id = "6" + +# 第三步新增收货地址 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url42") +request_body = commonFuc().get_business_data(module, "payload42", company_id, user_id) +# print(request_body) +""" + 场景: 收货地址新增验证_代客下单 + 用例名称:收货地址新增验证_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":true,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict42") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..e7ea6e43f99a64072bb2565994b36480d4fc83df --- /dev/null +++ "b/air_case/cmdc_order_list/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/b_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,57 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc收货地址删除功能验证_代客下单,2295,2295-42,sit,bs +主数据平台:后台运营系统收货地址删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中收货地址信息 +sql = "SELECT t.addressId FROM `cmdc-user`.cmdc_address t " \ + "WHERE mobile = 18700000000 and receiverName = '收货地址新增测试' and deleteSign = 0" +address_id = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 第三步进行收货地址删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43", address_id) +# print(request_body) +""" + 场景: 收货地址删除功能验证_代客下单 + 用例名称:收货地址删除功能验证_代客下单 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 查询数据库中收货地址删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-user`.cmdc_address t WHERE addressId = {}".format(address_id) +result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict43") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.air/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.air/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..41527ef07670278789075cd00c00abe4e6140837 --- /dev/null +++ "b/air_case/cmdc_order_list/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.air/ca_\351\224\200\345\224\256\344\273\273\345\212\241\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc销售任务新增验证,2295,2295-67,sit,bs +主数据平台:后台运营系统销售任务新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步进行销售任务新增操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url67") +request_body = commonFuc().get_business_data(module, "payload67") + +""" + 场景: 销售任务新增验证 + 用例名称:销售任务新增验证 + 输出:{"success":true,"code":"200","message":"OK","data":"success","freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict67") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..3d5be0c17deb637b7b9430a522ba839eceec6d3f --- /dev/null +++ "b/air_case/cmdc_order_list/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/cb_\351\224\200\345\224\256\344\273\273\345\212\241\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc销售任务编辑功能验证,2295,2295-68,sit,bs +主数据平台:后台运营系统销售任务编辑接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url68_1") +request_body = commonFuc().get_business_data(module, "payload68_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取销售任务信息 +task_json = result["data"]["list"][0] +# 删除多余字段便于对销售任务进行更新操作 +task_json.pop("filialeCode") +task_json.pop("filialeName") +task_json.pop("taskCycle") +task_json.pop("taskDescription") +task_json.pop("useSign") +task_json.pop("deleteSign") +task_json.pop("createTime") +task_json.pop("updateTime") + +# 第三步进行销售任务编辑更新操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url68") +request_body = task_json + +""" + 场景: 销售任务编辑功能验证 + 用例名称:销售任务编辑功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":"success","freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict68") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..885bb78fef624a452433e4625b4bb4105362486a --- /dev/null +++ "b/air_case/cmdc_order_list/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/cc_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc销售任务删除功能验证,2295,2295-71,sit,bs +主数据平台:后台运营系统销售任务删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url68_1") +request_body = commonFuc().get_business_data(module, "payload68_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取销售任务信息 +supplierSaleTaskId = result["data"]["list"][0]["supplierSaleTaskId"] + +# 第三步进行销售任务删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url71") +request_body = commonFuc().get_business_data(module, "payload71", supplierSaleTaskId) + +""" + 场景: 销售任务删除功能验证 + 用例名称:销售任务删除功能验证 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应任务删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-order`.tc_suppliersale_task t WHERE supplierSaleTaskId = {}".format(supplierSaleTaskId) +result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict71") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..90e102f818e9fd520afdc402f6f9be56d341948c --- /dev/null +++ "b/air_case/cmdc_order_list/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/da_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc销售下发任务启用功能验证,2295,2295-69,sit,bs +主数据平台:后台运营系统销售下发任务启用接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表/已启用 +use_sign = 2 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url72") +request_body = commonFuc().get_business_data(module, "payload_use", use_sign) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取任务下发信息 +supplierSaleTaskId = result["data"]["list"][0]["supplierSaleTaskId"] + +# 第三步进行销售下发任务启用操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url69") +request_body = commonFuc().get_business_data(module, "payload69", supplierSaleTaskId) + +""" + + 场景: 销售下发任务启用功能验证 + 用例名称:销售下发任务启用功能验证 + 输出:{"useSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应任务启用状态 +sql = "SELECT t.useSign FROM `cmdc-order`.tc_suppliersale_task t WHERE supplierSaleTaskId = {}".format(supplierSaleTaskId) +result = {"useSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict69") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..b731bc33b97288fcee2a870871dabe058cebc5d3 --- /dev/null +++ "b/air_case/cmdc_order_list/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/db_\351\224\200\345\224\256\344\270\213\345\217\221\344\273\273\345\212\241\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc销售下发任务停用功能验证,2295,2295-70,sit,bs +主数据平台:后台运营系统销售下发任务停用接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表/已停用 +use_sign = 1 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url72") +request_body = commonFuc().get_business_data(module, "payload_use", use_sign) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取任务下发信息 +supplierSaleTaskId = result["data"]["list"][0]["supplierSaleTaskId"] + +# 第三步进行销售下发任务停用操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url70") +request_body = commonFuc().get_business_data(module, "payload70", supplierSaleTaskId) + +""" + + 场景: 销售下发任务停用功能验证 + 用例名称:销售下发任务停用功能验证 + 输出:{"useSign":2} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应任务启用状态 +sql = "SELECT t.useSign FROM `cmdc-order`.tc_suppliersale_task t WHERE supplierSaleTaskId = {}".format(supplierSaleTaskId) +result = {"useSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict70") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..611f6ff0cf81131907d13c84c9f9afa30352af0c --- /dev/null +++ "b/air_case/cmdc_order_list/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/id\344\270\272\347\251\272_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,44 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdcid为空_收货地址删除_代客下单,2295,2295-44,sit,bs +主数据平台:后台运营系统收货地址删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第三步进行收货地址删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44") +request_body = commonFuc().get_business_data(module, "payload44") +# print(request_body) +""" + 场景: id为空_收货地址删除_代客下单 + 用例名称:id为空_收货地址删除_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":false} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict44") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..5d928441dcd59b943fd6cc1108dfc63f4e7fa0ab --- /dev/null +++ "b/air_case/cmdc_order_list/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\270\213\350\275\275\350\265\204\350\264\250\346\226\207\344\273\266\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc下载资质文件功能验证,2295,2295-64,sit,bs +主数据平台:后台运营系统下载资质文件接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1") +# password = commonFuc().get_business_data(module, "password1") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步下载资质文件 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url64") +request_body = commonFuc().get_business_data(module, "payload64") +# print(request_body) +""" + + 场景: 下载资质文件功能验证 + 用例名称:下载资质文件功能验证 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict64") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..5b692a41daacac9f5cf7448199a8ddc292560e8a --- /dev/null +++ "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\220\210\345\271\266\350\257\246\346\203\205.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc传值有效性校验_jde配货合并详情,2295,2295-26,sit,bs +主数据平台:后台运营系统获取jde配货单合并详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成无效distributionJdeDsId +distribution_jde_ds_id = random.randint(0, 100) + +# 第二步获取jde配货单合并详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") +request_body = commonFuc().get_business_data(module, "payload26", distribution_jde_ds_id) + +""" + + 场景: 传值有效性校验_jde配货合并详情 + 用例名称:传值有效性校验_jde配货合并详情 + 输出:{"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict26") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..49c2799158b1376b33f8993a5dbc694a7c8b484b --- /dev/null +++ "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc传值有效性校验_jde配货推送,2295,2295-31,sit,bs +主数据平台:后台运营系统获取jde配货推送接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成无效的配货单信息 +distribution_jde_ds_id = random.randint(0, 100) + +# 第二步jde配货单推送 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") +request_body = commonFuc().get_business_data(module, "payload31", distribution_jde_ds_id) + +""" + + 场景: 传值有效性校验_jde配货推送 + 用例名称:传值有效性校验_jde配货推送 + 输出:{"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict31") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..ef470fd53233497a14f845b6f77eaed20ab11723 --- /dev/null +++ "b/air_case/cmdc_order_list/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\344\274\240\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc传值有效性校验_获取jde配货单信息,2295,2295-23,sit,bs +主数据平台:后台运营系统获取jde配货单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成无效distributionJdeDsId +distribution_jde_ds_id = random.randint(0, 100) +# 第二步获取jde配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23", distribution_jde_ds_id) + +""" + + 场景: 传值有效性校验_获取jde配货单信息 + 用例名称:传值有效性校验_获取jde配货单信息 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":null},"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict23") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..33009390f896245b72fad6060807b8e78b6d3e33 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_商品清单,2295,2295-90,sit,bs +主数据平台:后台运营系统获取客户商品列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import random + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户商品列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url87") +request_body = commonFuc().get_business_data(module, "payload87") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +productInfo = result["data"]["list"][product_random]["productCode"] + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url90") +request_body = commonFuc().get_business_data(module, "payload90", productInfo) + +""" + + 场景: 列表查询条件验证_商品清单 + 用例名称:列表查询条件验证_商品清单 + 输出:{"productInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中商品信息 +result = json.loads(result.content) +result = {"productInfo": result["data"]["list"][0]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict90", productInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..26a1789b1b0dfe549b49d7caf56ba30ee97b6a8b --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_商品预测明细,2295,2295-84,sit,bs +主数据平台:后台运营系统获取商品预测明细接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取商品预测明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url83") +request_body = commonFuc().get_business_data(module, "payload83") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +print(result) +# 生成随机数 +pr_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +startTime = result["data"]["list"][pr_random]["createTime"][:10] + " 00:00:00" +now_time = str(datetime.datetime.now().strftime("%Y-%m-%d")) + " 00:00:00" +productInfo = result["data"]["list"][pr_random]["productCode"] +customerInfo = result["data"]["list"][pr_random]["customerCode"] +procurementDate = result["data"]["list"][pr_random]["procurementDate"] + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url84") +request_body = commonFuc().get_business_data(module, "payload84", startTime, now_time, productInfo, customerInfo, + startTime, now_time, procurementDate) +# print(request_body) +""" + + 场景: 列表查询条件验证_商品预测明细 + 用例名称:列表查询条件验证_商品预测明细 + 输出:{"productInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# print(result) +# 获取查询结果中商品信息 +result = json.loads(result.content) +result = {"productInfo": result["data"]["list"][0]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict84", productInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" new file mode 100644 index 0000000000000000000000000000000000000000..a866aa6db1e6e485334eb23a375fc1f97304893a --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" @@ -0,0 +1,69 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_客户采购计划,2295,2295-80,sit,bs +主数据平台:后台运营系统获取客户采购计划列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json +import datetime + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户采购计划列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url79") +request_body = commonFuc().get_business_data(module, "payload79") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +pro_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户采购计划信息 +startTime = result["data"]["list"][pro_random]["createTime"][:10] + " 00:00:00" +customerInfo = result["data"]["list"][pro_random]["customerCode"] +procurementDate = result["data"]["list"][pro_random]["procurementDate"] +lockSign = result["data"]["list"][pro_random]["lockSign"] +mergeSign = result["data"]["list"][pro_random]["mergeSign"] +now_time = endTime = str(datetime.datetime.now().strftime("%Y-%m-%d")) + " 00:00:00" + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url80") +request_body = commonFuc().get_business_data(module, "payload80", startTime, now_time, customerInfo, startTime, + now_time, procurementDate, lockSign, mergeSign) + +""" + + 场景: 列表查询条件验证_客户采购计划 + 用例名称:列表查询条件验证_客户采购计划 + 输出:{"customerCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中客户采购计划信息 +result = json.loads(result.content) +result = {"customerCode": result["data"]["list"][0]["customerCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict80", customerInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..9572ebf3301eaa9fe87fa5e448984e136d488f09 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" @@ -0,0 +1,72 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_红票明细列表,2295,2295-75,sit,bs +主数据平台:后台运营系统获取红票明细列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取红票明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url74") +request_body = commonFuc().get_business_data(module, "payload74") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +red_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取红票明细信息 +demandParentCode = result["data"]["list"][red_random]["demandParentCode"] +demandCode = result["data"]["list"][red_random]["demandCode"] +customerName = result["data"]["list"][red_random]["customerName"] +orderStatus = result["data"]["list"][red_random]["orderStatus"] +startTime = result["data"]["list"][red_random]["auditTime"][:10] + " 00:00:00" +endTime = str(datetime.datetime.now().strftime("%Y-%m-%d")) + " 23:59:59" +startTime = "" +endTime = "" + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url75") +request_body = commonFuc().get_business_data(module, "payload75", demandParentCode, demandCode, customerName, + orderStatus, + startTime, endTime) +# print(request_body) +""" + 场景: 列表查询条件验证_红票明细列表 + 用例名称:列表查询条件验证_红票明细列表 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中红票明细信息 +result = json.loads(result.content) +# print(result) +result = {"demandCode": result["data"]["list"][0]["demandCode"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict75", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" new file mode 100644 index 0000000000000000000000000000000000000000..e6f4ff2c4bea134681c2aec24078c6adbdd9bc54 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" @@ -0,0 +1,92 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_终端流向,2295,2295-61,sit,bs +主数据平台:后台运营系统获取终端流向列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取终端流向列表信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") +request_body = commonFuc().get_business_data(module, "payload60") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +flow_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取终端流向信息 +delete_sign = result["data"]["list"][flow_random]["deleteSign"] +flow_id = result["data"]["list"][flow_random]["flowId"] +end_customer_name = result["data"]["list"][flow_random]["endCustomerName"] +invoice_no = result["data"]["list"][flow_random]["invoiceNo"] +manufacturer = result["data"]["list"][flow_random]["manufacturer"] +customer_code = result["data"]["list"][flow_random]["customerCode"] +customer_name = result["data"]["list"][flow_random]["customerName"] +demand_code = result["data"]["list"][flow_random]["demandCode"] + +# 第三步获取终端流向详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url65") +request_body = commonFuc().get_business_data(module, "payload65", demand_code, invoice_no, delete_sign, flow_id) +# 发送请求 +result1 = requests.post(url, json=request_body, headers=headers) +result1 = json.loads(result1.content) + +# 获取终端流向详情信息 +product_info = result1["data"][0]["productName"] +material_code = result1["data"][0]["materialCode"] +order_start_time = result1["data"][0]["orderTime"][:10] +upload_start_time = result1["data"][0]["orderTime"][:10] +product_code = result1["data"][0]["productCode"] +product_code = "" +now_date = datetime.datetime.now().strftime("%Y-%m-%d") + +# 第四步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url61") +request_body = commonFuc().get_business_data(module, "payload61", end_customer_name, invoice_no, manufacturer, + product_info, + material_code, order_start_time, customer_code, customer_name, + upload_start_time, + now_date, product_code, demand_code, now_date) +# print(request_body) +# print(material_code) +""" + + 场景: 列表查询条件验证_终端流向 + 用例名称:列表查询条件验证_终端流向 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取终端流向详情中信息 +result = json.loads(result.content) +# print(result) +result = {"demandCode": result["data"]["list"][0]["demandCode"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict61", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..ce2dc0931e041003609c91fac5984a994d7301f0 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\224\200\345\224\256\344\273\273\345\212\241\345\210\227\350\241\250.py" @@ -0,0 +1,72 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_销售任务列表,2295,2295-73,sit,bs +主数据平台:后台运营系统获取销售任务下发列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import random + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url72") +request_body = commonFuc().get_business_data(module, "payload72") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +task_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取任务下发信息 +customerCode = result["data"]["list"][task_random]["customers"][0]["customerCode"] +customerName = result["data"]["list"][task_random]["customers"][0]["customerName"] +materialCode = result["data"]["list"][task_random]["products"][0]["materialCode"] +productCode = result["data"]["list"][task_random]["products"][0]["productCode"] +productLineName = result["data"]["list"][task_random]["products"][0]["productLineName"] +productName = result["data"]["list"][task_random]["products"][0]["productName"] +specifications = result["data"]["list"][task_random]["products"][0]["specifications"] +taskName = result["data"]["list"][task_random]["taskName"] +taskYear = result["data"]["list"][task_random]["taskYear"] +useSign = result["data"]["list"][task_random]["useSign"] + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url73") +request_body = commonFuc().get_business_data(module, "payload73", customerCode, customerName, materialCode, productCode, + productLineName, productName, specifications, taskName, taskYear, useSign) + +""" + + 场景: 列表查询条件验证_销售任务列表 + 用例名称:列表查询条件验证_销售任务列表 + 输出:{"taskName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中任务名称 +result = json.loads(result.content) +result = {"taskName": result["data"]["list"][0]["taskName"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict73", taskName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..802938ddd2e9b82c268173b3603aeb082a0b7e1c --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\210\240\351\231\244\346\227\240\346\225\210\350\215\211\347\250\277\350\256\242\345\215\225\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc删除无效草稿订单验证_代客下单,2295,2295-54,sit,bs +主数据平台:后台运营系统草稿订单删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成无效的订单id +order_id = random.randint(0, 5) + +# 第二步进行草稿订单删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url54") +request_body = commonFuc().get_business_data(module, "payload54", order_id) + +""" + + 场景: 删除无效草稿订单验证_代客下单 + 用例名称:删除无效草稿订单验证_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":false,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict54") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..1ad5bb587a4a744ca43e9cf7e456987d6934d31c --- /dev/null +++ "b/air_case/cmdc_order_list/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\210\267\346\226\260jde\344\276\247\345\272\223\345\255\230\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc刷新jde侧库存接口验证,2295,2295-125,sit,bs +主数据平台:后台运营系刷新jde侧库存接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步同步SO接口 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url125") +request_body = commonFuc().get_business_data(module, "payload125") + +""" + + 场景: 刷新jde侧库存接口验证 + 用例名称:刷新jde侧库存接口验证 + 输出:{"success":true,"code":"200","message":null,"data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict125") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" "b/air_case/cmdc_order_list/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..2228edf771e549ac133858c3c460c5c00412d082 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc勾选合并_jde配货管理,2295,2295-18,sit,bs +主数据平台:后台运营系统合并接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取未推送的配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20_1") +request_body = commonFuc().get_business_data(module, "payload20_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] + +# 第三步进行合并操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") +request_body = commonFuc().get_business_data(module, "payload20", distribution_jde_ds_id) + +""" + 场景: 勾选合并_jde配货管理 + 用例名称:勾选合并_jde配货管理 + 输出:{"distributionJdeDsId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取合并页面中的distributionJdeDsId +result = json.loads(result.content) +result = {"distributionJdeDsId": result["data"]["before"]["distributionJdeDsDetailList"][0]["distributionJdeDsId"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict20", distribution_jde_ds_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" "b/air_case/cmdc_order_list/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..bd4f5b54768e5d51e0c842c7e02b7bc49946f7d8 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\220\210\345\271\266\345\267\262\346\216\250\351\200\201\351\205\215\350\264\247\345\215\225\346\240\241\351\252\214\351\252\214\350\257\201_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc合并已推送配货单校验验证,2295,2295-19,sit,bs +主数据平台:后台运营系统合并接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取已完成推送的配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19_1") +request_body = commonFuc().get_business_data(module, "payload19_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] +distribution_jde_ds_code = result["data"]["list"][dis_random]["distributionJdeDsCode"] + +# 第三步进行合并操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = commonFuc().get_business_data(module, "payload19", distribution_jde_ds_id) + +""" + + 场景: 合并已推送配货单校验验证 + 用例名称:合并已推送配货单校验验证 + 输出:{"success":false,"code":"ERROR","message":"%s配货状态错误","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict19", distribution_jde_ds_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..cf242ad58f28bfc412fead035584800d54dab3ec --- /dev/null +++ "b/air_case/cmdc_order_list/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\220\214\346\255\245SO\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc同步SO接口验证,2295,2295-124,sit,bs +主数据平台:后台运营系同步SO接口接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步同步SO接口 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url124") +request_body = commonFuc().get_business_data(module, "payload124") + +""" + + 场景: 同步SO接口验证 + 用例名称:同步SO接口验证 + 输出:{"success":true,"code":"200","message":null,"data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict124") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.air/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.air/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..4dff1b9b1ce4764d0982a711ec254def578f2b76 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.air/\345\225\206\345\223\201\346\270\205\345\215\225\347\255\233\351\200\211\345\212\237\350\203\275\351\252\214\350\257\201_\346\254\240\350\264\247\350\257\246\346\203\205.py" @@ -0,0 +1,82 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc商品清单筛选功能验证_欠货详情,2295,2295-123,sit,bs +主数据平台:后台运营系统获取欠货详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["queryDemandPageInfo"]["list"]) - 1) +# 获取欠货信息 +customerCode = result["data"]["queryDemandPageInfo"]["list"][debt_random]["customerCode"] +demandId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandId"] +demandSubId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandSubId"] + +# 第三步获取欠货详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url120") +request_body = commonFuc().get_business_data(module, "payload120", demandSubId, demandSubId) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取欠货详情商品信息 +orderMark = result["data"]["list"][0]["orderMark"] +manufacturer = result["data"]["list"][0]["manufacturer"] +productName = result["data"]["list"][0]["productName"] +materialCode = result["data"]["list"][0]["materialCode"] +productCode = result["data"]["list"][0]["productCode"] +optionStr = result["data"]["list"][0]["optionStr"] + +# 第四步进行商品清单筛选查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url123") +request_body = commonFuc().get_business_data(module, "payload123", demandId, demandSubId, orderMark, manufacturer, + productName, + materialCode, productCode, optionStr) + +""" + + 场景: 商品清单筛选功能验证_欠货详情 + 用例名称:商品清单筛选功能验证_欠货详情 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取商品清单信息 +result = json.loads(result.content) +result = {"productCode": result["data"]["list"][0]["productCode"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict123", productCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.air/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.py" "b/air_case/cmdc_order_list/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.air/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..43a22d0221f5f207a7a33eb3d2ae2402ddb256f4 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.air/\345\225\206\345\223\201\350\241\214\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201_\350\256\242\345\215\225\347\273\264\345\272\246_\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc商品行明细导出验证_订单维度_欠货综合管理,2295,2295-119,sit,bs +主数据平台:后台运营系统商品行明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["queryDemandPageInfo"]["list"]) - 1) +# 获取欠货信息 +demandParentCode = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandParentCode"] + +# 第三步进行商品明细导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url119") +request_body = commonFuc().get_business_data(module, "payload119", demandParentCode) + +""" + + 场景: 商品行明细导出验证_订单维度_欠货综合管理 + 用例名称:商品行明细导出验证_订单维度_欠货综合管理 + 输出:{"demandParentCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/欠货商品行明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中需求单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandParentCode": excel.read_data()[0].get("母需求单编号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict119", demandParentCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..35787b5afeb0685b75596df877713fff2d1174bc --- /dev/null +++ "b/air_case/cmdc_order_list/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\255\227\346\256\265\345\200\274\346\234\211\346\225\210\346\200\247\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc字段值有效性校验_查看采购单详情,2295,2295-14,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成purchaseId +id_random = random.randint(11111111, 11111111111) +# 第二步查看采购单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14", id_random) + +""" + + 场景: 字段值有效性校验_查看采购单详情 + 用例名称:字段值有效性校验_查看采购单详情 + 输出:{"success":false,"code":"order-pur-001","message":"采购单单据不存在或已被删除","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..1edaddc0ca60c5e60a538a06f6e6b38c3ef2b25a --- /dev/null +++ "b/air_case/cmdc_order_list/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\256\242\346\210\267\344\277\241\346\201\257\344\270\272\347\251\272_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc客户信息为空_通过Excel添加商品_代客下单,2295,2295-50,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + + +# 第二步通过Excel添加商品 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url47") +request_body = commonFuc().get_business_data(module, "payload47") + +""" + + 场景: 客户信息为空_通过Excel添加商品_代客下单 + 用例名称:客户信息为空_通过Excel添加商品_代客下单 + 输出:{"success":false,"code":"ERROR","message":"用户信息不完整","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict47") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..441552671e871dc60de6b57ff2afb8934764986c --- /dev/null +++ "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\346\270\205\345\215\225.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导出功能验证_商品清单,2295,2295-91,sit,bs +主数据平台:后台运营系统获取客户商品列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import json +import random +import os + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户商品列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url87") +request_body = commonFuc().get_business_data(module, "payload87") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +productInfo = result["data"]["list"][product_random]["productCode"] + +# 第三步进行商品清单导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url91") +request_body = commonFuc().get_business_data(module, "payload91", productInfo) + +""" + + 场景: 导出功能验证_商品清单 + 用例名称:导出功能验证_商品清单 + 输出:{"productInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/商品清单.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中商品编码 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"productInfo": excel.read_data()[0].get("商品编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict91", productInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..509e6d898df24d59478b244da94c9e10928bd079 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导出功能验证_商品预测明细,2295,2295-85,sit,bs +主数据平台:后台运营系统商品预测明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取商品预测明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url83") +request_body = commonFuc().get_business_data(module, "payload83") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +pr_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +customerInfo = result["data"]["list"][pr_random]["customerCode"] + +# 第三步商品预测明细导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url85") +request_body = commonFuc().get_business_data(module, "payload85", customerInfo) + +""" + + 场景: 导出功能验证_商品预测明细 + 用例名称:导出功能验证_商品预测明细 + 输出:{"customerInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/商品预测明细导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中客户编码 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"customerInfo": excel.read_data()[0].get("客户编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict85", customerInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.py" "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..8cf248d069f05be912de802557bba67d495d5096 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导出功能验证_客户清单,2295,2295-89,sit,bs +主数据平台:后台运营系统客户清单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import json +import random +import os + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url86") +request_body = commonFuc().get_business_data(module, "payload86") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +customerInfo = result["data"]["list"][customer_random]["customerCode"] + +# 第三步客户清单导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url89") +request_body = commonFuc().get_business_data(module, "payload89", customerInfo) + +""" + + 场景: 导出功能验证_客户清单 + 用例名称:导出功能验证_客户清单 + 输出:{"customerInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/客户清单.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中客户编码 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"customerInfo": excel.read_data()[0].get("客户编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict89", customerInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" new file mode 100644 index 0000000000000000000000000000000000000000..27d8c5e10f55ee7ad6561a944cdf19db3ae3f4b3 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导出功能验证_客户采购计划,2295,2295-81,sit,bs +主数据平台:后台运营系统客户采购计划导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户采购计划列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url79") +request_body = commonFuc().get_business_data(module, "payload79") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +pro_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户采购计划信息 +customerInfo = result["data"]["list"][pro_random]["customerCode"] + +# 第三步进行客户采购计划导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url81") +request_body = commonFuc().get_business_data(module, "payload81", customerInfo) + +""" + + 场景: 导出功能验证_客户采购计划 + 用例名称:导出功能验证_客户采购计划 + 输出:{"customerCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购计划汇总导出.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中客户编码 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"customerCode": excel.read_data()[0].get("客户编码")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict81", customerInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" new file mode 100644 index 0000000000000000000000000000000000000000..4c95d8bb92c79afb20f195e0a8b8a699d45ce511 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.air/\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201_\347\273\210\347\253\257\346\265\201\345\220\221.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc导出功能验证_终端流向,2295,2295-62,sit,bs +主数据平台:后台运营系统终端流向列表导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取终端流向列表信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") +request_body = commonFuc().get_business_data(module, "payload60") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +flow_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取终端流向信息 +demand_code = result["data"]["list"][flow_random]["demandCode"] + +# 第三步进行导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url62") +request_body = commonFuc().get_business_data(module, "payload62", demand_code) +""" + + 场景: 导出功能验证_终端流向 + 用例名称:导出功能验证_终端流向 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/终端流向管理列表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中订单编号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandCode": excel.read_data()[0].get("订单编号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict62", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..cf7818b31dad1611f788296644e9513645315151 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\207\215\346\226\260\350\216\267\345\217\226\345\210\267\346\226\260\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc库存重新获取刷新接口验证,2295,2295-106,sit,bs +主数据平台:后台运营系统库存重新获取刷新接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["queryDemandPageInfo"]["list"]) - 1) +# 获取欠货信息 +customerCode = result["data"]["queryDemandPageInfo"]["list"][debt_random]["customerCode"] +demandId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandId"] +demandSubId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandSubId"] + +# 第三步获取欠货详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url120") +request_body = commonFuc().get_business_data(module, "payload120", demandSubId, demandSubId) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取欠货详情商品信息 +sellerCompanyCode = result["data"]["list"][0]["sellerCompanyCode"] +productCode = result["data"]["list"][0]["productCode"] + +# 第四步进行库存重新刷新获取 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url106") +request_body = commonFuc().get_business_data(module, "payload106", productCode, sellerCompanyCode) + +""" + + 场景: 库存重新获取刷新接口验证 + 用例名称:库存重新获取刷新接口验证 + 输出:{"status":1,"errorLog":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取库存更新结果 +result = json.loads(result.content) +result = {"status": result["data"]["status"], "errorLog": result["data"]["errorLog"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict106") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..d06cf37cbba6129796677a5adca290dc8f83dde0 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\344\274\240\345\255\227\346\256\265\344\270\272\347\251\272_\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段为空_获取用户默认地址_代客下单,2295,2295-36,sit,bs +主数据平台:后台运营系统获取用户默认地址信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取用户默认地址信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url36") +request_body = commonFuc().get_business_data(module, "payload36") + +""" + + 场景: 必传字段为空_获取用户默认地址_代客下单 + 用例名称:必传字段为空_获取用户默认地址_代客下单 + 输出:{"success":false,"code":"NOUSERID","message":"USERID为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict36") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..b99f7866c3e3ec2552a96f16f747a4189dac443d --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段校验_jde配货单合并详情,2295,2295-25,sit,bs +主数据平台:后台运营系统获取jde配货单合并详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货单合并详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") + +""" + + 场景: 必传字段校验_jde配货单合并详情 + 用例名称:必传字段校验_jde配货单合并详情 + 输出:{"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict25") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..8f12ffcd51feb064b5ad0101b373a96f380ebfcd --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段校验_获取jde配货单信息,2295,2295-24,sit,bs +主数据平台:后台运营系统获取jde配货单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22") + +""" + + 场景: 必传字段校验_获取jde配货单信息 + 用例名称:必传字段校验_获取jde配货单信息 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":null},"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict22") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.py" "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..a5c30c03acbcdc37debbb482500c198a5cced77f --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段校验_通过Excel复制添加商品,2295,2295-17,sit,bs +主数据平台:后台运营系统通过Excel复制添加商品接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步查看采购单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") + +""" + + 场景: 必传字段校验_通过Excel复制添加商品 + 用例名称:必传字段校验_通过Excel复制添加商品 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":null},"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict17") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..b39a7ba31d18df2bf74b2e240f7b078b607cdcf2 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_jde\351\205\215\350\264\247\346\216\250\351\200\201.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_jde配货推送,2295,2295-30,sit,bs +主数据平台:后台运营系统获取jde配货推送接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步jde配货单推送 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url30") +request_body = commonFuc().get_business_data(module, "payload30") + +""" + + 场景: 必填字段校验_jde配货推送 + 用例名称:必填字段校验_jde配货推送 + 输出:{"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict30") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..a8a39bf3f81a324b504e78c47b6c21244a501501 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\213\276\351\200\211\345\220\210\345\271\266_jde\351\205\215\350\264\247\347\256\241\347\220\206.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_勾选合并_jde配货管理,2295,2295-18,sit,bs +主数据平台:后台运营系统合并接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步勾选合并 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") +request_body = commonFuc().get_business_data(module, "payload18") + +""" + + 场景: 必填字段校验_勾选合并_jde配货管理 + 用例名称:必填字段校验_勾选合并_jde配货管理 + 输出:{"success":false,"code":"ERROR","message":"至少两个才能合并","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict18") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..2fda2a70691608025e03e776dbcb61aee47f1330 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\346\237\245\347\234\213\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_查看采购单详情,2295,2295-13,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import datetime +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步查看采购单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13") + +""" + 场景: 必填字段校验_查看采购单详情 + 用例名称:必填字段校验_查看采购单详情 + 输出:{"success":false,"code":"500","message":"采购单id不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..81c0fb1a1e1aedf08d462de6b6aa50116a14ab24 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_草稿订单删除_代客下单,2295,2295-55,sit,bs +主数据平台:后台运营系统草稿订单删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 随机生成无效的订单id +order_id = "" + +# 第二步进行草稿订单删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url55") +request_body = commonFuc().get_business_data(module, "payload55", order_id) + +""" + 场景: 必填字段校验_草稿订单删除_代客下单 + 用例名称:必填字段校验_草稿订单删除_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":false,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict55") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..191f4276678e0698faea47fc3cf8248a6975ab07 --- /dev/null +++ "b/air_case/cmdc_order_list/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_通过Excel添加商品_代客下单,2295,2295-48,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 生成无效的商品code +product_code = random.randint(0, 1000) +# 获取客户信息 +user_no = result["data"]["list"][customer_random]["userNo"] + +# 第三步通过Excel添加商品 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url49") +request_body = commonFuc().get_business_data(module, "payload49", user_no) + +""" + 场景: 必填字段校验_通过Excel添加商品_代客下单 + 用例名称:必填字段校验_通过Excel添加商品_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":[]},"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict49") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..6bc442eaa324fe828ef74ab375f50ea4805836d0 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\211\213\346\234\272\345\217\267\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc手机号查询验证_收货地址列表_代客下单,2295,2295-40,sit,bs +主数据平台:后台运营系统获取收货地址列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][customer_random]["userId"] +company_id = "7" + +# 第三步获取收货地址列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37", company_id, user_id) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 判断地址是否存在 +if result["data"]["addresses"]["list"]: + # 获取收货人手机号 + mobile = result["data"]["addresses"]["list"][0]["mobile"][:7] + # 通过收货人手机号在收货地址列表进行模糊查询 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url39") + request_body = commonFuc().get_business_data(module, "payload39", company_id, user_id, mobile) + + """ + 场景: 手机号查询验证_收货地址列表_代客下单 + 用例名称:手机号查询验证_收货地址列表_代客下单 + 输出:{"mobile":"%s"} + """ + + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + # print(api_time) + # 获取查询结果中收货地址中手机号 + result = json.loads(result.content) + result = {"mobile": result["data"]["addresses"]["list"][0]["mobile"][:7]} + # print(result) + # 将接口响应时间添加至结果中 + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict39", mobile) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_order_list/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.air/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.py" "b/air_case/cmdc_order_list/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.air/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.py" new file mode 100644 index 0000000000000000000000000000000000000000..d41b559213d5afdfcdbcc93e2334771cf8dc4635 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.air/\346\214\211\344\272\247\345\223\201\347\272\277\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\345\216\202\345\256\266\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc按产品线查询商品信息_厂家销售任务下发,2295,2295-66,sit,bs +主数据平台:后台运营系统按产品线查询商品信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步按产品线查询商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url66") +request_body = commonFuc().get_business_data(module, "payload66") + +""" + 场景: 按产品线查询商品信息_厂家销售任务下发 + 用例名称:按产品线查询商品信息_厂家销售任务下发 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict66") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.air/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.py" "b/air_case/cmdc_order_list/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.air/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.py" new file mode 100644 index 0000000000000000000000000000000000000000..b56ca13ce55fb01e48989a5f06d88f2fac72b62e --- /dev/null +++ "b/air_case/cmdc_order_list/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.air/\346\216\250\351\200\201\345\212\237\350\203\275\351\252\214\350\257\201_jde\351\205\215\350\264\247.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc推送功能验证_jde配货,2295,2295-29,sit,bs +主数据平台:后台运营系统jde配货推送接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取未推送的配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20_1") +request_body = commonFuc().get_business_data(module, "payload20_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] + +# 第三步进行合并操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url29") +request_body = commonFuc().get_business_data(module, "payload29", distribution_jde_ds_id) + +""" + 场景: 推送功能验证_jde配货 + 用例名称:推送功能验证_jde配货 + 输出:{"distributionJdeDsId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict29") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.air/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.air/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..0b29e33674354d5e5e847181b247d468dfc85094 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.air/\346\216\250\351\200\201\345\267\262\346\216\250\351\200\201\346\210\220\345\212\237\347\232\204jde\351\205\215\350\264\247\345\215\225\346\213\246\346\210\252\351\252\214\350\257\201.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc推送已推送成功的jde配货单拦截验证,2295,2295-32,sit,bs +主数据平台:后台运营系统jde配货推送接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取已完成推送的配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19_1") +request_body = commonFuc().get_business_data(module, "payload19_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] +distribution_jde_ds_code = result["data"]["list"][dis_random]["distributionJdeDsCode"] + +# 第三步进行jde配货单推送 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32", distribution_jde_ds_id) + +""" + + 场景: 合并已推送配货单校验验证 + 用例名称:合并已推送配货单校验验证 + 输出:{"success":true,"code":"200","message":"OK","data":"fail"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time +# 手动推送和自动推送接口返回提示不同 +if result["success"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict32_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict32_2") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..c4434b998dc5b544a63e44dce1cae8371ea9c1a3 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\344\273\266\344\272\272\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc收件人查询验证_收货地址列表_代客下单,2295,2295-39,sit,bs +主数据平台:后台运营系统获取收货地址列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][customer_random]["userId"] +company_id = "7" + +# 第三步获取收货地址列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37", company_id, user_id) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +if result["data"]["addresses"]["list"]: + # 获取收货人姓名 + receiver_name = result["data"]["addresses"]["list"][0]["receiverName"][:1] + # 通过收货人姓名在收货地址列表进行模糊查询 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") + request_body = commonFuc().get_business_data(module, "payload38", company_id, user_id, receiver_name) + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + # 获取查询结果中收货地址中收件人姓名 + result = json.loads(result.content) + result = {"receiverName": result["data"]["addresses"]["list"][0]["receiverName"][:1]} + # 将接口响应时间添加至结果中 + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict38", receiver_name) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + +""" + 场景: 收件人查询验证_收货地址列表_代客下单 + 用例名称:收件人查询验证_收货地址列表_代客下单 + 输出:{"receiverName":"%s"} +""" + + + diff --git "a/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..969b0dffd7a3122350da3df0eb4f9115706b234d --- /dev/null +++ "b/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc收货地址批量导入_代客下单,2295,2295-45,sit,bs +主数据平台:后台运营系统收货地址批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +from common.db.db import mySql +import requests +import json +import os +import uuid + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/批量导入收货地址模板.xlsx" + +# 生成随机数 +uuid_random = str(uuid.uuid4())[:8] +# 将收货地址写入文件中 +excel = HandleExcel(file_path, "Sheet1") +excel.write_data(row=2, column=1, value=uuid_random) +excel.write_data(row=2, column=2, value="18800000000") +excel.write_data(row=2, column=3, value=uuid_random) + +# 第二步收货地址批量导入 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url46") +request_body = commonFuc().get_business_data(module, "payload46") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + 场景:收货地址批量导入_代客下单 + 用例名称:收货地址批量导入_代客下单 + 输出:{"userId":"32"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +file.close() + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中收货地址信息 +sql = "SELECT t.userId FROM `cmdc-user`.cmdc_address t " \ + "WHERE address = '{}' and receiverName = '{}' and deleteSign = 0".format(uuid_random, uuid_random) +# print(sql) +result = {"userId": mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict46") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..063bff71348c2203f8a7046e2b51490858897e2c --- /dev/null +++ "b/air_case/cmdc_order_list/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\224\266\350\264\247\345\234\260\345\235\200\346\211\271\351\207\217\345\257\274\345\205\245\347\251\272\346\225\260\346\215\256_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc收货地址批量导入空数据_代客下单,2295,2295-46,sit,bs +主数据平台:后台运营系统收货地址批量导入接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import json +import os + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/批量导入收货地址模板.xlsx" + +# 将收货地址写入文件中 +excel = HandleExcel(file_path, "Sheet1") +excel.write_data(row=2, column=1, value=None) +excel.write_data(row=2, column=2, value=None) +excel.write_data(row=2, column=3, value=None) + +# 第二步收货地址批量导入 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url45") +request_body = commonFuc().get_business_data(module, "payload45") + +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + 场景:收货地址批量导入空数据_代客下单 + 用例名称:收货地址批量导入空数据_代客下单 + 输出:{"success":false,"code":"5000070","message":"1,0,1","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time +file.close() + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict45") +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" new file mode 100644 index 0000000000000000000000000000000000000000..8ccd1283710e3f32ad409013d9943a62cfdddc03 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\346\237\245\350\257\242\345\225\206\345\223\201\344\277\241\346\201\257_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询商品信息_采购单新增,2295,2295-15,sit,bs +主数据平台:后台运营系统查询商品信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步查看已发布商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15_1") +request_body = commonFuc().get_business_data(module, "payload15_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +product_code = result["data"]["list"][product_random]["productCode"] + +# 第三步获取商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15", product_code) + +""" + 场景: 查询商品信息_采购单新增 + 用例名称:查询商品信息_采购单新增 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取商品信息 +result = json.loads(result.content) +result = {"productCode": result["data"]["list"][0]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15", product_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.air/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.air/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e2e538d4f0ca91cc8c3b94572cd71f5dffae93be --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.air/\346\237\245\350\257\242\345\276\205\351\205\215\350\264\247\346\230\216\347\273\206\345\210\227\350\241\250.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询待配货明细列表,2295,2295-122,sit,bs +主数据平台:后台运营系统查询待配货明细列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 获取欠货信息 +for i in result["data"]["queryDemandPageInfo"]["list"]: + if i["debtSign"] == 0 and i["pushSign"] == 1: + # 获取欠货信息 + demandSubCode = i["demandSubCode"] + distributionType = i["distributionType"] + # 第三步查询待配货明细列表 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url122") + request_body = commonFuc().get_business_data(module, "payload122", demandSubCode, distributionType) + # print(request_body) + # 发送请求 + result = requests.get(url, params=request_body) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + + # 将接口响应时间添加至结果中 + result = json.loads(result.content) + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict122") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + break +""" + + 场景: 查询待配货明细列表 + 用例名称:查询待配货明细列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" \ No newline at end of file diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..41ac09476a6d2d4805ed2f3ee074b9c89cc3b28e --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" @@ -0,0 +1,90 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_jde配货列表,2295,2295-5,sit,bs +主数据平台:后台运营系统获取jde配货列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distributionJdeDsCode = func(result["data"]["list"][dis_random]["distributionJdeDsCode"]) +pushType = func(result["data"]["list"][dis_random]["pushType"]) +mergeSign = func(result["data"]["list"][dis_random]["mergeSign"]) +customerInfo = func(result["data"]["list"][dis_random]["customerCode"]) +productCode = func(result["data"]["list"][dis_random]["productCode"]) +soCode = func(result["data"]["list"][dis_random]["soCode"]) +optionStr = func(result["data"]["list"][dis_random]["optionStr"]) +materialCode = func(result["data"]["list"][dis_random]["materialCode"]) +mergeCode = func(result["data"]["list"][dis_random]["mergeCode"]) +code = result["data"]["list"][dis_random]["demandCodeStr"] +jdeType = func(result["data"]["list"][dis_random]["jdeType"]) +activityType = func(result["data"]["list"][dis_random]["activityType"]) +isGroup = func(result["data"]["list"][dis_random]["isGroup"]) + +# 第三步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5", distributionJdeDsCode, pushType, mergeSign, + customerInfo, + productCode, soCode, optionStr, materialCode, mergeCode, code, jdeType, + activityType, + isGroup) + +""" + + 场景: 查询条件验证_jde配货列表 + 用例名称:查询条件验证_jde配货列表 + 输出:{"code":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中子需求单 +result = json.loads(result.content) +# print(result) +result = {"code": result["data"]["list"][0]["demandCodeStr"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict5", code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..5a830debb3c9f8e3528b634b25a3e12dbbbfd450 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_客户列表_代客下单,2295,2295-34,sit,bs +主数据平台:后台运营系统获取客户信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +telephone = result["data"]["list"][customer_random]["telephone"] +user_no = result["data"]["list"][customer_random]["userNo"] +user_name = result["data"]["list"][customer_random]["userName"] +customer_company_name = result["data"]["list"][customer_random]["customerCompanyName"] + +# 第三步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url34") +request_body = commonFuc().get_business_data(module, "payload34", telephone, user_no, user_name, customer_company_name) + +""" + 场景: 查询条件验证_客户列表_代客下单 + 用例名称:查询条件验证_客户列表_代客下单 + 输出:{"userNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中客户信息 +result = json.loads(result.content) +result = {"userNo": result["data"]["list"][0]["userNo"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict34", user_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..49fb28a5ac89f14cff0d2ab846dc1704fedb0f37 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_客户清单列表,2295,2295-88,sit,bs +主数据平台:后台运营系统获取客户清单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import random + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url86") +request_body = commonFuc().get_business_data(module, "payload86") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +customerInfo = result["data"]["list"][customer_random]["customerCode"] + +# 第三步进行列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url88") +request_body = commonFuc().get_business_data(module, "payload88", customerInfo) + +""" + + 场景: 查询条件验证_客户清单列表 + 用例名称:查询条件验证_客户清单列表 + 输出:{"customerInfo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中客户信息 +result = json.loads(result.content) +result = {"customerInfo": result["data"]["list"][0]["customerCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict88", customerInfo) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..3d5f58f493abe600ccfe35e25176f3c59ca29660 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,65 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_草稿列表_代客下单,2295,2295-52,sit,bs +主数据平台:后台运营系统获取草稿列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取草稿列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url51") +request_body = commonFuc().get_business_data(module, "payload51") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +user_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取草稿信息 +user_name = result["data"]["list"][user_random]["userName"] +user_no = result["data"]["list"][user_random]["userNo"] +start_time = result["data"]["list"][user_random]["createTime"][:10] +end_time = datetime.datetime.now().strftime("%Y-%m-%d") + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url52") +request_body = commonFuc().get_business_data(module, "payload52", user_name, user_no, start_time, end_time) + +""" + 场景: 查询条件验证_草稿列表_代客下单 + 用例名称:查询条件验证_草稿列表_代客下单 + 输出:{"userNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中客户信息 +result = json.loads(result.content) +result = {"userNo": result["data"]["list"][0]["userNo"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict52", user_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e3333d656a10dca984547f50cd532422cd00a348 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_采购单列表,2295,2295-7,sit,bs +主数据平台:后台运营系统获取采购单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import datetime +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +pur_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取采购单信息 +bill_no = result["data"]["list"][pur_random]["billNo"] +bill_status_list = result["data"]["list"][pur_random]["billStatus"] +creator = result["data"]["list"][pur_random]["creator"] +demand_no = "" +start_time = result["data"]["list"][pur_random]["createTime"][:10] +end_time = datetime.datetime.now().strftime("%Y-%m-%d") + +# 第三步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7", bill_no, bill_status_list, creator, demand_no, + start_time, + end_time, start_time, end_time) +# print(request_body) +""" + 场景: 查询条件验证_采购单列表 + 用例名称:查询条件验证_采购单列表 + 输出:{"billNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购单号 +result = json.loads(result.content) +# print(result) +result = {"billNo": result["data"]["list"][0]["billNo"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict7", bill_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.air/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.air/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.py" new file mode 100644 index 0000000000000000000000000000000000000000..69e8bcb93c6a4e46a382f71752a1e28eca20e9dc --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.air/\346\237\245\350\257\242\347\253\231\347\202\271\346\230\257\345\220\246\345\274\200\345\220\257\347\224\265\345\255\220\345\215\260\347\253\240.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询站点是否开启电子印章,2295,2295-100,sit,bs +主数据平台:后台运营系统查询站点是否开启电子印章接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步查询站点是否开启电子印章 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url100") +request_body = commonFuc().get_business_data(module, "payload100") +# print(request_body) +""" + + 场景: 查询站点是否开启电子印章 + 用例名称:查询站点是否开启电子印章 + 输出:{"sealSiteSign":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点是否开启电子印章 +result = json.loads(result.content) +# 映射,接口返回true:1//开和false:0//关 +seal_sign = 1 if result["data"] else 0 +result = {"sealSiteSign": seal_sign} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应站点是否开启电子章 +sql = "SELECT t.sealSiteSign FROM `cmdc-user`.cmdc_website t WHERE companyId = 7" +sealSiteSign = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict100", sealSiteSign) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..1fb8ee8eae16d47b95fb7fcb3862c186c86be38d --- /dev/null +++ "b/air_case/cmdc_order_list/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\351\207\207\350\264\255\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,65 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询采购单详情信息,2295,2295-9,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import datetime +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +pur_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取采购单信息 +purchase_id = result["data"]["list"][pur_random]["purchaseId"] +bill_no = result["data"]["list"][pur_random]["billNo"] + +# 第三步查询采购单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9", purchase_id, bill_no) + +""" + 场景: 查询采购单详情信息 + 用例名称:查询采购单详情信息 + 输出:{"purchaseId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购单对应id +result = json.loads(result.content) +# print(result) +result = {"purchaseId": result["data"]["purchaseId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict9", purchase_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.air/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.py" "b/air_case/cmdc_order_list/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.air/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.py" new file mode 100644 index 0000000000000000000000000000000000000000..c167b3d819936d9c724fdf11c8a8193b6a5c9431 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.air/\346\240\270\351\252\214\347\253\231\347\202\271\346\230\257\345\220\246\345\205\267\346\234\211\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc核验站点是否具有二次审核权限,2295,2295-101,sit,bs +主数据平台:后台运营系统核验站点是否具有二次审核权限接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步核验站点是否具有二次审核权限 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url101") +request_body = commonFuc().get_business_data(module, "payload101") +# print(request_body) +""" + + 场景: 核验站点是否具有二次审核权限 + 用例名称:核验站点是否具有二次审核权限 + 输出:{"secondAuditSign":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点是否具备二次审核权限 +result = json.loads(result.content) +# print(result) +result = {"secondAuditSign": result["data"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应站点是否具备二次审核权限 +sql = "SELECT t.secondAuditSign FROM `cmdc-cms`.cms_website t WHERE companyId = 7" +second_audit_sign = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict101", second_audit_sign) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.air/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.air/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..828057abd2410dc4274eee113b43d8ad85498e24 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.air/\346\240\271\346\215\256id\346\237\245\350\257\242\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据id查询站点信息,2295,2295-77,sit,bs +主数据平台:后台运营系统根据id查询站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1") +# password = commonFuc().get_business_data(module, "password1") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第一步根据父id获取省市信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url77") +request_body = commonFuc().get_business_data(module, "payload77") +# print(request_body) +""" + + 场景: 根据id查询站点信息 + 用例名称:根据id查询站点信息 + 输出:{"success":true,"code":"200","message":"操作成功"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict77") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..77bc79d8509300bbad3ce56bd4e4b26fd7ecb30b --- /dev/null +++ "b/air_case/cmdc_order_list/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\256\242\346\210\267code\350\216\267\345\217\226\351\207\207\350\264\255\345\215\217\350\256\256\344\277\241\346\201\257.py" @@ -0,0 +1,65 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据客户code获取采购协议信息,2295,2295-107,sit,bs +主数据平台:后台运营系统根据客户code获取采购协议信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +customerCode = result["data"]["list"][demand_random]["customerCode"] +productLineCode = result["data"]["list"][demand_random]["productLineCode"] + +# 第三步根据客户code获取采购协议信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url107") +request_body = commonFuc().get_business_data(module, "payload107", customerCode, productLineCode) + +""" + + 场景: 根据客户code获取采购协议信息 + 用例名称:根据客户code获取采购协议信息 + 输出:{"customerCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购协议对应的客户信息 +result = json.loads(result.content) +result = {"customerCode": result["data"][0]["customerCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict107", customerCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..1aec112d5ba40c0820b1ff8185bf5427b2ca41df --- /dev/null +++ "b/air_case/cmdc_order_list/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\346\240\271\346\215\256\346\216\250\351\200\201\345\215\225\345\217\267\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据推送单号获取配货单信息,2295,2295-28,sit,bs +主数据平台:后台运营系统获取配货单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_code = result["data"]["list"][dis_random]["distributionJdeDsCode"] + +# 第三步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") +request_body = commonFuc().get_business_data(module, "payload28", distribution_jde_ds_code) + +""" + + 场景: 根据推送单号获取配货单信息 + 用例名称:根据推送单号获取配货单信息 + 输出:{"distributionJdeDsCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取查询结果中distributionJdeDsCode +result = json.loads(result.content) +# print(result) +result = {"distributionJdeDsCode": result["data"]["list"][0]["distributionJdeDsCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict28", distribution_jde_ds_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..b6eeb0f35e3cb62a4e484b7f401b790fc0618589 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\210\266id\350\216\267\345\217\226\347\234\201\345\270\202\344\277\241\346\201\257.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据父id获取省市信息,2295,2295-43,sit,bs +主数据平台:后台运营系统根据父id获取省市信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1") +# password = commonFuc().get_business_data(module, "password1") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第一步根据父id获取省市信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url41") +request_body = commonFuc().get_business_data(module, "payload41") +# print(request_body) +""" + + 场景: 根据父id获取省市信息 + 用例名称:根据父id获取省市信息 + 输出:{"success":true,"code":"200","message":"OK","data":[{"areaId":20,"areaCode":"120100","areaName":"天津城区","level":null,"cityCode":null,"center":null,"parentId":null}],"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict41") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.air/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.py" "b/air_case/cmdc_order_list/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.air/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.py" new file mode 100644 index 0000000000000000000000000000000000000000..48e3015d8acfe45526922db607fe9b172a222bd4 --- /dev/null +++ "b/air_case/cmdc_order_list/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.air/\346\254\240\350\264\247\347\273\274\345\220\210\347\256\241\347\220\206\345\210\227\350\241\250_\350\256\242\345\215\225\347\273\264\345\272\246\346\237\245\350\257\242.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc欠货综合管理列表_订单维度查询,2295,2295-118,sit,bs +主数据平台:后台运营系统获取欠货综合管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# print(request_body) +""" + + 场景: 欠货综合管理列表_订单维度查询 + 用例名称:欠货综合管理列表_订单维度查询 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict118") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..2e652eb5feb1e79b8dda6257fde7a2149788911b --- /dev/null +++ "b/air_case/cmdc_order_list/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.air/\347\224\265\345\225\206\351\205\215\350\264\247\344\270\255\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc电商配货中接口验证,2295,2295-126,sit,bs +主数据平台:后台运营系统电商配货中接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取配货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url126_1") +request_body = commonFuc().get_business_data(module, "payload126_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distributionId = result["data"]["list"][dis_random]["distributionId"] + +# 第三步电商配货中接口验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url126") +request_body = commonFuc().get_business_data(module, "payload126", distributionId) + +""" + + 场景: 电商配货中接口验证 + 用例名称:电商配货中接口验证 + 输出:{"distributionId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取配货页面信息 +result = json.loads(result.content) +result = {"distributionId": result["data"]["distributionId"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict126", distributionId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..d33b61f31a427eb65ccaf90418849f19a7375bd9 --- /dev/null +++ "b/air_case/cmdc_order_list/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\272\242\347\245\250\346\230\216\347\273\206\345\257\274\345\207\272\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc红票明细导出功能验证,2295,2295-76,sit,bs +主数据平台:后台运营系统红票明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import os +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取红票明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url74") +request_body = commonFuc().get_business_data(module, "payload74") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +red_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取红票明细信息 +demandParentCode = result["data"]["list"][red_random]["demandParentCode"] + +# 第三步进行红票明细导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url76") +request_body = commonFuc().get_business_data(module, "payload76", demandParentCode) + +""" + 场景: 红票明细导出功能验证 + 用例名称:红票明细导出功能验证 + 输出:{"demandParentCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/红票明细表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中需求单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandParentCode": excel.read_data()[0].get("需求单号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict76", demandParentCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..a7f96d9c90cc6c571bcb2a9d45089935d893658d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc草稿单创建功能验证_代客下单,2295,2295-56,sit,bs +主数据平台:后台运营系统草稿订单创建接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步进行草稿订单创建操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url56") +request_body = commonFuc().get_business_data(module, "payload56") +# print(request_body) +""" + + 场景: 草稿单创建功能验证_代客下单 + 用例名称:草稿单创建功能验证_代客下单 + 输出:{"userNo":"1000086"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取生成草稿订单对应的客户信息 +result = json.loads(result.content) +result = {"userNo": result["data"]["userNo"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict56") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.py" "b/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..0d84b201e37f8646dd2dbe5522d023818668d975 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.air/\350\215\211\347\250\277\345\215\225\345\210\233\345\273\272\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205.py" @@ -0,0 +1,52 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc草稿单创建验证_代客下单_套包,2295,2295-57,sit,bs +主数据平台:后台运营系统草稿订单创建接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步进行草稿订单创建操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url57") +request_body = commonFuc().get_business_data(module, "payload57") +# print(request_body) +""" + + 场景: 草稿单创建验证_代客下单_套包 + 用例名称:草稿单创建验证_代客下单_套包 + 输出:{"userNo":"1000086"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取生成草稿订单对应的客户信息 +result = json.loads(result.content) +result = {"userNo": result["data"]["userNo"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict57") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_order_list/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..b0e65477bdd1c1ba1b92b4f5fadaf4e463f2b20c --- /dev/null +++ "b/air_case/cmdc_order_list/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\215\211\347\250\277\350\256\242\345\215\225\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc草稿订单删除功能验证_代客下单,2295,2295-53,sit,bs +主数据平台:后台运营系统草稿订单删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取草稿列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url51") +request_body = commonFuc().get_business_data(module, "payload51") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +user_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取草稿信息 +order_id = result["data"]["list"][user_random]["id"] + +# 第三步进行草稿订单删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url53") +request_body = commonFuc().get_business_data(module, "payload53", order_id) + +""" + + 场景: 验证代客下单草稿订单删除功能是否可以正常使用 + 用例名称:草稿订单删除功能验证_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":true} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict53") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..534d4d2b25ea3e7a2d3eda0fa6233f1b2e7f2c3b --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\210\227\350\241\250.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取jde配货列表,2295,2295-2,sit,bs +主数据平台:后台运营系统获取jde配货列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") +# print(request_body) +""" + + 场景: 获取jde配货列表 + 用例名称:获取jde配货列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取jde配货数量 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应的jde配货列表数量 +sql = "SELECT count(t.distributionJdeDsId) FROM `cmdc-order`.tc_distribution_jde_ds t " \ + "WHERE companyCode = 00111 and deleteSign = 0 and userId = 69 and pushStatus in(1,2)" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict2", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a8042b9dc2d9fe6c96a032e9c1ce257e153f06be --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226jde\351\205\215\350\264\247\345\215\225\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取jde配货单信息,2295,2295-22,sit,bs +主数据平台:后台运营系统获取jde配货单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] + +# 第三步获取配货对应的订单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") +request_body = commonFuc().get_business_data(module, "payload24", distribution_jde_ds_id) + +""" + + 场景: 获取jde配货单信息 + 用例名称:获取jde配货单信息 + 输出:{"distributionJdeDsId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取详情信息中distributionJdeDsId +result = json.loads(result.content) +result = {"distributionJdeDsId": result["data"]["distributionJdeDsId"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict24", distribution_jde_ds_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..bb2609819e9624b947e104640bb2c6f6cb6d23d5 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.air/\350\216\267\345\217\226jde\351\241\271\347\233\256\345\210\227\350\241\250.py" @@ -0,0 +1,78 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取jde项目列表,2295,2295-114,sit,bs +主数据平台:后台运营系统获取jde项目列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +customerCode = result["data"]["list"][demand_random]["customerCode"] +productLineCode = result["data"]["list"][demand_random]["productLineCode"] + +# 第三步根据客户code获取采购协议信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url107") +request_body = commonFuc().get_business_data(module, "payload107", customerCode, productLineCode) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +vp_random = random.randint(0, len(result["data"]) - 1) +# 获取采购协议信息 +projectCode = result["data"][vp_random]["projectCode"] + +# 第四步获取jde项目列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url114") +request_body = commonFuc().get_business_data(module, "payload114", projectCode) + + +""" + + 场景: 获取jde项目列表 + 用例名称:获取jde项目列表 + 输出:{"projectCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取项目信息 +result = json.loads(result.content) +result = {"projectCode": result["data"]["list"][0]["projectCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict114", projectCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a595fe0f65d9e2f0fb5d3a97e79484f842b7b01b --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\232\345\212\241\344\272\272\345\221\230\344\277\241\346\201\257.py" @@ -0,0 +1,103 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取业务人员信息,2295,2295-113,sit,bs +主数据平台:后台运营系统获取业务人员信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +customerCode = result["data"]["list"][demand_random]["customerCode"] +productLineCode = result["data"]["list"][demand_random]["productLineCode"] + +# 第三步根据客户code获取采购协议信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url107") +request_body = commonFuc().get_business_data(module, "payload107", customerCode, productLineCode) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +vp_random = random.randint(0, len(result["data"]) - 1) +# 获取采购协议信息 +alesDepartmentName = result["data"][vp_random]["alesDepartmentName"] +sourceSign = result["data"][vp_random]["sourceSign"] + +# 第四步获取部门信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url112") +request_body = commonFuc().get_business_data(module, "payload112", alesDepartmentName, sourceSign) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +department_random = random.randint(0, len(result["data"]) - 1) +# 获取部门信息 +alesDepartmentNo = result["data"][0]["alesDepartmentNo"] +alesDepartmentName = result["data"][0]["alesDepartmentName"] + +# 第五步获取业务人员信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url113") +request_body = commonFuc().get_business_data(module, "payload113", alesDepartmentNo) + +""" + 场景: 获取业务人员信息 + 用例名称:获取业务人员信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取业务人员信息 +result = json.loads(result.content) +print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应部门的业务人员数量 +sql = "SELECT count(t.personId) FROM `cmdc-user`.cmdc_person t " \ + "WHERE belong = 00102 and BussinessUnitDesc = '{}' and useFlag = 1".format(alesDepartmentName) +# print(sql) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict112", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a16209bb8ed30c7d7407a77971a9062393b27aa9 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\267\345\244\207\344\272\214\346\254\241\345\256\241\346\240\270\346\235\203\351\231\220\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取具备二次审核权限站点信息,2295,2295-103,sit,bs +主数据平台:后台运营系统获取具备二次审核权限站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取具备二次审核权限站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url103") +request_body = commonFuc().get_business_data(module, "payload103") +# print(request_body) +""" + + 场景: 获取具备二次审核权限站点信息 + 用例名称:获取具备二次审核权限站点信息 + 输出:{"success":true,"code":"200"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict103") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..ea75b2842eda898a79d83a8dd9be881f53b9b17f --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265\345\272\223\345\255\230\344\277\241\346\201\257.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取商品详情页库存信息,2295,2295-115,sit,bs +主数据平台:后台运营系统获取商品详情页库存信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import datetime +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录多采商城获取token +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 获取当前日期 +now_date = datetime.datetime.now().strftime("%Y-%m-%d") +# 将当前日期转化为儒略历 +url = r"https://service-uat.gyqxmall.com/order/public/getDateToRu" +request_body = {"time": now_date} +# 发送请求 +result = requests.get(url, params=request_body) +result = json.loads(result.content) +# 获取转换后的日期 +ru_date = result["data"] + +# 第二步获取商品详情页库存信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url115") +request_body = commonFuc().get_business_data(module, "payload115") +# print(request_body) +""" + + 场景: 获取商品详情页库存信息 + 用例名称:获取商品详情页库存信息 + 输出:{"stockQty":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取商品详情页显示的库存信息 +result = json.loads(result.content) +# print(result) +result = {"stockQty": result["data"][0]["stockQty"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中商品对应的库存数量 +sql = "SELECT sum(t.quantity)/10000 FROM `cmdc-product`.ic_inventory t " \ + "WHERE productCode = 10146174 and markForDelete = 0 " \ + "and type = 1 and isLimited != 'Y' and expireDate > {}".format(ru_date) + +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict115", int(total)) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..859a86147c7ed4f67f9a3b8a68de204dca27c4fc --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\242\204\346\265\213\346\230\216\347\273\206.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取商品预测明细,2295,2295-83,sit,bs +主数据平台:后台运营系统获取商品预测明细接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取商品预测明细 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url83") +request_body = commonFuc().get_business_data(module, "payload83") +# print(request_body) +""" + + 场景: 获取商品预测明细 + 用例名称:获取商品预测明细 + 输出:{"success":true,"code":"200","message":"成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict83") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..73a8f3dbdbef8f6862692e49b287619b6d93ec9c --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取基础配置信息,2295,2295-127,sit,bs +主数据平台:后台运营系统获取基础配置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取基础配置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url127") +request_body = commonFuc().get_business_data(module, "payload127") +# print(request_body) +""" + + 场景: 获取基础配置信息 + 用例名称:获取基础配置信息 + 输出:{"success":true,"code":"200","message":"OK","data":true,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict127") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..e0f0163de51452989d18083c9ddd29496f41bbb4 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\344\277\241\346\201\257.py" @@ -0,0 +1,72 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取审核后商品信息,2295,2295-95,sit,bs +主数据平台:后台运营系统获取审核后商品信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandId = result["data"]["list"][demand_random]["demandId"] + +# 第三步获取需求单审核后商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url95") +request_body = commonFuc().get_business_data(module, "payload95", demandId) + +""" + 场景: 获取审核后商品信息 + 用例名称:获取审核后商品信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取审核后商品信息 +result = json.loads(result.content) +result = {"total": result["data"]["total"]} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中审核后商品数量 +sql = "SELECT count(t.demandSkuId) FROM `cmdc-order`.tc_demand_sku t WHERE demandId = {}".format(demandId) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict95", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..5c985b8d3d2b18a0ad7e8db7d37039e04fc26557 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\345\256\242\346\210\267\344\277\241\346\201\257_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取客户信息_代客下单,2295,2295-33,sit,bs +主数据平台:后台运营系统获取客户信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") + +""" + 场景: 获取客户信息_代客下单 + 用例名称:获取客户信息_代客下单 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict33") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..3935b7f3aa1056bd193bf853138b951924c11e7a --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\225\206\345\223\201\345\210\227\350\241\250.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取客户商品列表,2295,2295-87,sit,bs +主数据平台:后台运营系统获取客户商品列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户商品列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url87") +request_body = commonFuc().get_business_data(module, "payload87") +# print(request_body) +""" + + 场景: 获取客户商品列表 + 用例名称:获取客户商品列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict87") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..6349ed426c7479e7424b66c48ebd93213db9ec6c --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取客户清单列表,2295,2295-86,sit,bs +主数据平台:后台运营系统获取客户清单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url86") +request_body = commonFuc().get_business_data(module, "payload86") +# print(request_body) +""" + + 场景: 获取客户清单列表 + 用例名称:获取客户清单列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict86") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.air/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.air/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.py" new file mode 100644 index 0000000000000000000000000000000000000000..32eabe42f2f99385d72ba1dbdae0a01f2157f874 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.air/\350\216\267\345\217\226\345\256\242\346\210\267\347\224\263\350\257\267\345\217\226\346\266\210\350\256\242\345\215\225\346\225\260\351\207\217.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取客户申请取消订单数量,2295,2295-93,sit,bs +主数据平台:后台运营系统获取客户申请取消订单数量接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户申请取消订单数量 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url93") +request_body = commonFuc().get_business_data(module, "payload93") +# print(request_body) +""" + + 场景: 获取客户申请取消订单数量 + 用例名称:获取客户申请取消订单数量 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict93") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..ba7eb1824c0c7ba7f38dfec84074f064a575bef8 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\351\207\207\350\264\255\350\256\241\345\210\222\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取客户采购计划列表,2295,2295-79,sit,bs +主数据平台:后台运营系统获取客户采购计划列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户采购计划列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url79") +request_body = commonFuc().get_business_data(module, "payload79") +# print(request_body) +""" + + 场景: 获取客户采购计划列表 + 用例名称:获取客户采购计划列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict79") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..1d85d9870746e7592e7f212bed09e42e646de172 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\257\274\345\205\245\346\227\245\345\277\227\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取导入日志信息_jde配货列表,2295,2295-4,sit,bs +主数据平台:后台运营系统获取导入日志信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取导入日志信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# print(request_body) +""" + + 场景: 获取导入日志信息_jde配货列表 + 用例名称:获取导入日志信息_jde配货列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取导入记录数量 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应导入日志数量 +sql = "SELECT count(t.id) FROM `cmdc-order`.tc_excel_log t " \ + "WHERE companyCode = 00111 and sheetName = 'distributiondsJdeDsTemplate'" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict4", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..edb088ccdd2b49bb87250c58686f1dc38c06862e --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\272\223\345\255\230\345\210\227\350\241\250\344\277\241\346\201\257.py" @@ -0,0 +1,77 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取库存列表信息,2295,2295-109,sit,bs +主数据平台:后台运营系统获取库存列表信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import datetime +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取当前日期 +now_date = datetime.datetime.now().strftime("%Y-%m-%d") +# 将当前日期转化为儒略历 +url = r"https://service-uat.gyqxmall.com/order/public/getDateToRu" +request_body = {"time": now_date} +# 发送请求 +result = requests.get(url, params=request_body) +result = json.loads(result.content) +# 获取转换后的日期 +ru_date = result["data"] + +# 第二步获取库存列表信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url109") +request_body = commonFuc().get_business_data(module, "payload109") +# print(request_body) +""" + + 场景: 获取库存列表信息 + 用例名称:获取库存列表信息 + 输出:{"stockQty":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取库存列表中总库存 +result = json.loads(result.content) +# print(result) +result = {"stockQty": result["data"]["stockQty"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中商品对应的库存数量 +sql = "SELECT sum(t.quantity)/10000 FROM `cmdc-product`.ic_inventory t " \ + "WHERE productCode = 10146174 and markForDelete = 0 " \ + "and type = 1 and isLimited != 'Y' and effectiveDate > {}".format(ru_date) +# print(sql) +total = (mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] if + mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] else 0) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict109", int(total)) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..e97a8fa9bfed3d5e67f45a4e96275f1ed06afb3d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\276\205\344\270\212\344\274\240\345\217\221\347\245\250\347\273\237\350\256\241\344\277\241\346\201\257.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取待上传发票统计信息,2295,2295-59,sit,bs +主数据平台:后台运营系统获取待上传发票统计信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取待上传发票统计信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url59") +request_body = commonFuc().get_business_data(module, "payload59") +# print(request_body) +""" + 场景: 获取待上传发票统计信息 + 用例名称:获取待上传发票统计信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict59") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..2a8c90976d0196e4c8d67681941d8ed1764a27ea --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\346\211\271\345\217\267\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取批号清单列表,2295,2295-130,sit,bs +主数据平台:后台运营系统获取批号清单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取批号清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url130") +request_body = commonFuc().get_business_data(module, "payload130") +# print(request_body) +""" + + 场景: 获取批号清单列表 + 用例名称:获取批号清单列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取批次号清单数量 +result = json.loads(result.content) +# print(result) +# result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# # 数据库操作 +# mysql_handle = mySql() +# # 获取conf.ini文件中配置的数据库信息 +# host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") +# +# # 查询数据库中对应批号清单数量 +# sql = "SELECT count(t.id) FROM `cmdc-order`.tc_inventory t " \ +# "WHERE productCode = 10145853 and location = 102302 and markForDelete = 0 and isLimited != 'Y'" +# print(sql) +# total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict130") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..6b592bc86ad41f716f08805f8ccfa8ff76f0c094 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,84 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取收货地址列表_代客下单,2295,2295-37,sit,bs +主数据平台:后台运营系统获取收货地址列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][1]["userId"] +company_id = "7" + +# 第三步获取收货地址列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37", company_id, user_id) +# print(request_body) +""" + 场景: 获取收货地址列表_代客下单 + 用例名称:获取收货地址列表_代客下单 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户默认地址信息 +result = json.loads(result.content) +print(result) +# 判断有些用户没有地址 +if result["data"]: + result = {"total": result["data"]["addresses"]["total"]} + # 将接口响应时间添加至结果中 + result["api_time"] = api_time + + # 数据库操作 + mysql_handle = mySql() + # 获取conf.ini文件中配置的数据库信息 + host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + + # 查询数据库中对应的用户的默认地址 + sql = "SELECT count(t.addressId) FROM `cmdc-user`.cmdc_user_address t " \ + "WHERE userId = {} and companyId = {} and deleteSign = 0".format(user_id, company_id) + print(sql) + total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict37", total) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict35_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..677233f00f7dfa1f9a36427ce09984e55a7c4355 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\346\254\240\350\264\247\350\257\246\346\203\205.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取欠货详情,2295,2295-120,sit,bs +主数据平台:后台运营系统获取欠货详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["queryDemandPageInfo"]["list"]) - 1) +# 获取欠货信息 +customerCode = result["data"]["queryDemandPageInfo"]["list"][debt_random]["customerCode"] +demandId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandId"] +demandSubId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandSubId"] + +# 第三步获取欠货详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url120") +request_body = commonFuc().get_business_data(module, "payload120", demandSubId, demandSubId) + +""" + + 场景: 获取欠货详情 + 用例名称:获取欠货详情 + 输出:{"customerCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取欠货详情中客户信息 +result = json.loads(result.content) +result = {"customerCode": result["data"]["list"][0]["customerCode"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict120", customerCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..307ce235dde5e48976ca9d1cfae9ca0b7da6e9d2 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\264\273\345\212\250\344\277\241\346\201\257.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取活动信息,2295,2295-105,sit,bs +主数据平台:后台运营系统获取活动信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +sellerCompanyCode = result["data"]["list"][demand_random]["sellerCompanyCode"] +customerId = result["data"]["list"][demand_random]["customerId"] + +# 第三步获取活动信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url105") +request_body = commonFuc().get_business_data(module, "payload105", sellerCompanyCode, customerId) + +""" + 场景: 获取活动信息 + 用例名称:获取活动信息 + 输出:{"userId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取活动所属客户信息 +result = json.loads(result.content) +# print(result) +result = {"userId": result["data"][0]["activityProductList"][0]["userId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict105", customerId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.py" new file mode 100644 index 0000000000000000000000000000000000000000..589e062698348a488409af7a150c85fb27605480 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.air/\350\216\267\345\217\226\346\264\273\345\212\250\350\247\204\345\210\231.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取活动规则,2295,2295-104,sit,bs +主数据平台:后台运营系统获取活动规则接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取活动规则 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url104") +request_body = commonFuc().get_business_data(module, "payload104") +# print(request_body) +""" + + 场景: 获取活动规则 + 用例名称:获取活动规则 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict104") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..5567ab353ecafa3b727b922abba940435ac9679d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267JDE\345\234\260\345\235\200\344\277\241\346\201\257.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户JDE地址信息,2295,2295-102,sit,bs +主数据平台:后台运营系统获取用户JDE地址信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +customerId = result["data"]["list"][demand_random]["customerId"] + +# 第三步获取用户JDE地址信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url102") +request_body = commonFuc().get_business_data(module, "payload102", customerId) + +""" + + 场景: 获取用户JDE地址信息 + 用例名称:获取用户JDE地址信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户JDE地址信息 +result = json.loads(result.content) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中用户JDE地址数量 +sql = "SELECT count(t.addressId) FROM `cmdc-user`.cmdc_user_address t " \ + "WHERE userId = {} AND isJde = 0 AND companyId = 7 AND deleteSign = 0 AND isDefault = 0".format(customerId) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict102", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..6f5ad8332d407a577190d2b72bc365bf4f43141e --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\270\213\345\215\225\345\216\237\345\247\213\346\270\205\345\215\225\344\277\241\346\201\257.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户下单原始清单信息,2295,2295-97,sit,bs +主数据平台:后台运营系统获取用户下单原始清单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandCode = result["data"]["list"][demand_random]["demandCode"] + +# 第三步获取用户下单原始清单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url97") +request_body = commonFuc().get_business_data(module, "payload97", demandCode) + +""" + 场景: 获取用户下单原始清单信息 + 用例名称:获取用户下单原始清单信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取下单原始清单信息 +result = json.loads(result.content) +result = {"total": result["data"]["total"]} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中审核后商品数量 +sql = "SELECT count(t.demandSkuId) FROM `cmdc-order`.tc_demand_sku_org t WHERE demandCode = {}".format(demandCode) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict96", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.air/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.air/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.py" new file mode 100644 index 0000000000000000000000000000000000000000..e14fa35285fdc99329627ba80afd3379f5a27abb --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.air/\350\216\267\345\217\226\347\224\250\346\210\267\346\263\250\345\206\214\346\226\271\345\274\217.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户注册方式,2295,2295-58,sit,bs +主数据平台:后台运营系统获取用户注册方式接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取收货地址列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url58") +request_body = commonFuc().get_business_data(module, "payload58") +# print(request_body) +""" + 场景: 获取用户注册方式 + 用例名称:获取用户注册方式 + 输出:{"registerType":"1"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户注册方式 +result = json.loads(result.content) +# print(result) +result = {"registerType": result["data"]["registerType"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict58") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..dd83de5e25295eedca348c484869fe27790f6c48 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\347\224\250\346\210\267\351\273\230\350\256\244\345\234\260\345\235\200_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,87 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户默认地址_代客下单,2295,2295-35,sit,bs +主数据平台:后台运营系统获取用户默认地址接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][customer_random]["userId"] +company_id = "6" + +# 第三步获取用户默认地址 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35", company_id, user_id) +# print(request_body) +""" + 场景: 获取用户默认地址_代客下单 + 用例名称:查获取用户默认地址_代客下单 + 输出:{"addressId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户默认地址信息 +result = json.loads(result.content) +# print(result) +# 判断有些用户没有默认地址 +if result["data"]: + is_default = result["data"][0]["isDefault"] + result = {"addressId": result["data"][0]["addressId"]} + # 将接口响应时间添加至结果中 + result["api_time"] = api_time + + # 数据库操作 + mysql_handle = mySql() + # 获取conf.ini文件中配置的数据库信息 + host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + + # 查询数据库中对应的用户的默认地址 + sql = "SELECT t.addressId FROM `cmdc-user`.cmdc_user_address t " \ + "WHERE userId = {} and companyId = {} and deleteSign = 0 " \ + "and isDefault = {}".format(user_id, company_id, is_default) + # print(sql) + address_id = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + # print(address_id) + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict35", address_id) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict35_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..efd57fdd240096fffc69c00bad4a1829b565e48b --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\272\242\347\245\250\346\230\216\347\273\206\345\210\227\350\241\250.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取红票明细列表,2295,2295-74,sit,bs +主数据平台:后台运营系统获取红票明细列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取红票明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url74") +request_body = commonFuc().get_business_data(module, "payload74") +# print(request_body) +""" + 场景: 获取红票明细列表 + 用例名称:获取红票明细列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict74") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..03709744d535a724ceb5885544484a1c3f58e89a --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\345\210\227\350\241\250\344\277\241\346\201\257.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取终端流向列表信息,2295,2295-60,sit,bs +主数据平台:后台运营系统获取终端流向列表信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取终端流向列表信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") +request_body = commonFuc().get_business_data(module, "payload60") +# print(request_body) +""" + 场景: 获取终端流向列表信息 + 用例名称:获取终端流向列表信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至结果中 +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict60") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..0ddf3789428f7b7c2954e63c09677db2400e756d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\273\210\347\253\257\346\265\201\345\220\221\350\257\246\346\203\205.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取终端流向详情,2295,2295-65,sit,bs +主数据平台:后台运营系统获取终端流向详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取终端流向列表信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") +request_body = commonFuc().get_business_data(module, "payload60") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +flow_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取终端流向信息 +demand_code = result["data"]["list"][flow_random]["demandCode"] +invoice_no = result["data"]["list"][flow_random]["invoiceNo"] +delete_sign = result["data"]["list"][flow_random]["deleteSign"] +flow_id = result["data"]["list"][flow_random]["flowId"] + +# 第三步获取终端流向详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url65") +request_body = commonFuc().get_business_data(module, "payload65", demand_code, invoice_no, delete_sign, flow_id) +""" + + 场景: 获取终端流向详情 + 用例名称:获取终端流向详情 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取终端流向详情中信息 +result = json.loads(result.content) +result = {"demandCode": result["data"][0]["demandCode"]} +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict65", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..238e2eebddfe761684535f06faabc6936415db7d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\216\267\345\217\226\350\215\211\347\250\277\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取草稿列表_代客下单,2295,2295-51,sit,bs +主数据平台:后台运营系统获取草稿列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取草稿列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url51") +request_body = commonFuc().get_business_data(module, "payload51") + +""" + 场景: 获取草稿列表_代客下单 + 用例名称:获取草稿列表_代客下单 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict51") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.air/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.air/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.py" new file mode 100644 index 0000000000000000000000000000000000000000..a7aa7b98215f5faeff91008b71fcef87387f9942 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.air/\350\216\267\345\217\226\350\256\242\345\215\225\344\277\241\346\201\257_jde\351\205\215\350\264\247\345\220\210\345\271\266\351\241\265\351\235\242.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取订单信息_jde配货合并页面,2295,2295-21,sit,bs +主数据平台:后台运营系统获取订单信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +code = result["data"]["list"][dis_random]["demandCodeStr"] + +# 第三步获取配货对应的订单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21", code) +# print(request_body) +""" + + 场景: 获取订单信息_jde配货合并页面 + 用例名称:获取订单信息_jde配货合并页面 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取订单信息中demandCode +result = json.loads(result.content) +# print(result) +result = {"demandCode": result["data"]["list"][0]["demandCode"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict21", code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.air/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.air/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.py" new file mode 100644 index 0000000000000000000000000000000000000000..4a49525deb171b40b1490e408f6e5a998ca01be5 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.air/\350\216\267\345\217\226\350\265\204\344\277\241\351\242\235\345\272\246.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取资信额度,2295,2295-128,sit,bs +主数据平台:后台运营系统获取资信额度接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取配货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url126_1") +request_body = commonFuc().get_business_data(module, "payload126_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distributionId = result["data"]["list"][dis_random]["distributionId"] + +# 第三步获取资信额度 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url128") +request_body = commonFuc().get_business_data(module, "payload128", distributionId) + +""" + + 场景: 获取资信额度 + 用例名称:获取资信额度 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict128") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..09516a7488bb5b4427535727ee4f85b5760b2f10 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\203\250\351\227\250\344\277\241\346\201\257.py" @@ -0,0 +1,86 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取部门信息,2295,2295-112,sit,bs +主数据平台:后台运营系统获取部门信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +customerCode = result["data"]["list"][demand_random]["customerCode"] +productLineCode = result["data"]["list"][demand_random]["productLineCode"] + +# 第三步根据客户code获取采购协议信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url107") +request_body = commonFuc().get_business_data(module, "payload107", customerCode, productLineCode) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +vp_random = random.randint(0, len(result["data"]) - 1) +# 获取采购协议信息 +alesDepartmentName = result["data"][vp_random]["alesDepartmentName"] +sourceSign = result["data"][vp_random]["sourceSign"] + +# 第四步获取部门信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url112") +request_body = commonFuc().get_business_data(module, "payload112", alesDepartmentName, sourceSign) + +""" + 场景: 获取部门信息 + 用例名称:获取部门信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取部门信息 +result = json.loads(result.content) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中部门数量 +sql = "SELECT count(t.MCMCU) FROM `cmdc-user`.cmdc_vapimcu_jde t WHERE MCCO = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict112", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..8fb2f22e2a04cbe16e164d4512af90e3a2d9857d --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\205\215\350\264\247\345\215\225\345\220\210\345\271\266\350\257\246\346\203\205.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取配货单合并详情,2295,2295-27,sit,bs +主数据平台:后台运营系统获取配货单合并详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取未推送的配货单信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20_1") +request_body = commonFuc().get_business_data(module, "payload20_1") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_jde_ds_id = result["data"]["list"][dis_random]["distributionJdeDsId"] + +# 第三步获取配货单合并详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url27") +request_body = commonFuc().get_business_data(module, "payload27", distribution_jde_ds_id) + +""" + 场景: 获取配货单合并详情 + 用例名称:获取配货单合并详情 + 输出:{"distributionJdeDsId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取合并详情页面中的distributionJdeDsId +result = json.loads(result.content) +result = {"distributionJdeDsId": result["data"]["distributionJdeDsId"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict27", distribution_jde_ds_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..8a05f21d4e79b9e35dbfa79551edfcf4c113c26a --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取采购单列表,2295,2295-6,sit,bs +主数据平台:后台运营系统获取采购单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# print(request_body) +""" + + 场景: 获取采购单列表 + 用例名称:获取采购单列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购单列表采购单数量 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中采购单数量 +sql = "SELECT count(t.purchase_id) FROM `cmdc-order`.tc_purchase t WHERE company_code = 00111 and delete_sign = 0" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e58c5bf3de20b6f3f4f2a1977cfb1fbf1dfb00a6 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\227\245\346\234\237\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取采购计划日期列表,2295,2295-78,sit,bs +主数据平台:后台运营系统获取采购计划日期列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url78") +request_body = commonFuc().get_business_data(module, "payload78") +# print(request_body) +""" + + 场景: 获取采购计划日期列表 + 用例名称:获取采购计划日期列表 + 输出:{"success":true,"code":"200"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict78") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..778a6ddb106ce1d3b33c75641a2c110a4f9e3d20 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\346\261\207\346\200\273\344\277\241\346\201\257.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取采购计划汇总信息,2295,2295-82,sit,bs +主数据平台:后台运营系统获取采购计划汇总信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购计划汇总信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url82") +request_body = commonFuc().get_business_data(module, "payload82") +# print(request_body) +""" + + 场景: 获取采购计划汇总信息 + 用例名称:获取采购计划汇总信息 + 输出:{"success":true,"code":"200","message":"成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict82") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..86f0b72c97fea41152e96e8df56f493401e665dd --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\224\200\345\224\256\344\273\273\345\212\241\344\270\213\345\217\221\345\210\227\350\241\250.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取销售任务下发列表,2295,2295-72,sit,bs +主数据平台:后台运营系统获取销售任务下发列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取销售任务下发列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url72") +request_body = commonFuc().get_business_data(module, "payload72") +# print(request_body) +""" + + 场景: 获取销售任务下发列表 + 用例名称:获取销售任务下发列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict72") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..ed6d5aa0083042bfa3c9b90eda2812a442bbd053 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\224\200\345\224\256\345\225\206\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取销售商信息,2295,2295-117,sit,bs +主数据平台:后台运营系统获取销售商信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url117") +request_body = commonFuc().get_business_data(module, "payload117") +# print(request_body) +""" + + 场景: 获取销售商信息 + 用例名称:获取销售商信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取公司数量 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中公司数量 +sql = "SELECT count(t.companyId) FROM `cmdc-user`.cmdc_company t " \ + "WHERE deleteSign = 0 and disableSign = 0 and companyType = 2" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict117", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.air/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.air/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.py" new file mode 100644 index 0000000000000000000000000000000000000000..7c090f05bdc94d45268cf237a1d3befbd64008cd --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.air/\350\216\267\345\217\226\351\231\204\344\273\266\346\223\215\344\275\234\346\265\201\346\260\264.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取附件操作流水,2295,2295-63,sit,bs +主数据平台:后台运营系统获取附件操作流水接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username1") +# password = commonFuc().get_business_data(module, "password1") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取附件操作流水 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url63") +request_body = commonFuc().get_business_data(module, "payload63") +# print(request_body) +""" + + 场景: 获取附件操作流水 + 用例名称:获取附件操作流水 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict63") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.py" new file mode 100644 index 0000000000000000000000000000000000000000..e57a823d1251e35093dc3d24beee5ba4979d44a4 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\210\227\350\241\250_\345\220\216\345\217\260\350\277\220\350\220\245\347\263\273\347\273\237.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取需求单列表_后台运营系统,2295,2295-1,sit,bs +主数据平台:后台运营系统获取需求单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# print(request_body) +""" + + 场景: 获取需求单列表_后台运营系统 + 用例名称:获取需求单列表_后台运营系统 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取需求单数量 +result = json.loads(result.content) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中需求单数量 +sql = "SELECT count(t.demandId) FROM `cmdc-order`.tc_demand t " \ + "WHERE deleteSign = 0 and sellerCompanyCode = 00111 and paymentType is not null" +total = int(mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0]) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict1", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..3345326e1fdd7bccdb2a40c15150192dc6deb242 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取需求单审核详情信息,2295,2295-99,sit,bs +主数据平台:后台运营系统获取需求单审核详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandId = result["data"]["list"][demand_random]["demandId"] + +# 第三步获取需求单审核详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url99") +request_body = commonFuc().get_business_data(module, "payload99", demandId) + +""" + + 场景: 获取需求单审核详情信息 + 用例名称:获取需求单审核详情信息 + 输出:{"auditStatus":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取需求单审核信息 +result = json.loads(result.content) +result = {"auditStatus": result["data"]["auditStatus"]} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应需求单审核状态 +sql = "SELECT t.auditStatus FROM `cmdc-order`.tc_demand t WHERE demandId = {}".format(demandId) +audit_status = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict99", audit_status) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..464cfe508320bed947bc66829bb0ad9d34fed8c5 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205_\347\273\274\345\220\210\346\254\240\350\264\247\347\256\241\347\220\206.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取需求单详情_综合欠货管理,2295,2295-121,sit,bs +主数据平台:后台运营系统获取需求单详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取欠货综合管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url118") +request_body = commonFuc().get_business_data(module, "payload118") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +debt_random = random.randint(0, len(result["data"]["queryDemandPageInfo"]["list"]) - 1) +# 获取欠货信息 +demandId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandId"] +demandSubId = result["data"]["queryDemandPageInfo"]["list"][debt_random]["demandSubId"] + +# 第三步获取需求单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url121") +request_body = commonFuc().get_business_data(module, "payload121", demandId, demandSubId) +# print(request_body) +""" + + 场景: 获取需求单详情_综合欠货管理 + 用例名称:获取需求单详情_综合欠货管理 + 输出:{"demandId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取需求单信息 +result = json.loads(result.content) +# print(result) +result = {"demandId": result["data"]["demandId"]} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict121", demandId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..da065c4d3f73ab3bd2a2e5dccec96a284de97f45 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\234\200\346\261\202\345\215\225\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取需求单详情信息,2295,2295-94,sit,bs +主数据平台:后台运营系统获取需求单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandId = result["data"]["list"][demand_random]["demandId"] + +# 第三步获取需求单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url94") +request_body = commonFuc().get_business_data(module, "payload94", demandId) + +""" + + 场景: 获取需求单详情信息 + 用例名称:获取需求单详情信息 + 输出:{"demandId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取需求单详情信息 +result = json.loads(result.content) +result = {"demandId": result["data"]["demandId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict94", demandId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_order_list/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.air/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.py" "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.air/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.py" new file mode 100644 index 0000000000000000000000000000000000000000..c0dced8bce9d9bb8fe0df0d523821ad25dd7b661 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.air/\350\216\267\345\217\226\351\241\271\347\233\256\345\210\227\350\241\250_\351\234\200\346\261\202\345\215\225\345\256\241\346\240\270.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取项目列表_需求单审核,2295,2295-111,sit,bs +主数据平台:后台运营系统获取项目列表_需求单审核接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取项目列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url111") +request_body = commonFuc().get_business_data(module, "payload111") +# print(request_body) +""" + + 场景: 获取项目列表_需求单审核 + 用例名称:获取项目列表_需求单审核 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取项目数量 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应的jde配货列表数量 +sql = "SELECT count(t.QWPMPN) FROM `cmdc-user`.cmdc_project_jde t WHERE QWCO = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict111", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..6f1e551ec043e8f6108c23fd9c14713ac729ff58 --- /dev/null +++ "b/air_case/cmdc_order_list/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\350\257\246\347\273\206\345\234\260\345\235\200\346\237\245\350\257\242\351\252\214\350\257\201_\346\224\266\350\264\247\345\234\260\345\235\200\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc详细地址查询验证_收货地址列表_代客下单,2295,2295-41,sit,bs +主数据平台:后台运营系统获取收货地址列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_id = result["data"]["list"][customer_random]["userId"] +company_id = "7" + +# 第三步获取收货地址列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37", company_id, user_id) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +if result["data"]["addresses"]["list"]: + # 获取收货人手机号 + address = result["data"]["addresses"]["list"][0]["address"][:7] + print(address) + # 通过收货详细地址在收货地址列表进行模糊查询 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40") + request_body = commonFuc().get_business_data(module, "payload40", company_id, user_id, address) + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + # 获取查询结果中收货地址中详细收货地址 + result = json.loads(result.content) + result = {"address": result["data"]["addresses"]["list"][0]["address"][:7]} + print(result) + # 将接口响应时间添加至结果中 + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict40", address) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + +""" + 场景: 详细地址查询验证_收货地址列表_代客下单 + 用例名称:详细地址查询验证_收货地址列表_代客下单 + 输出:{"address":"%s"} +""" diff --git "a/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" new file mode 100644 index 0000000000000000000000000000000000000000..035cca825ec562c19c6f1d628335f514835e2c69 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\200\232\350\277\207Excel\345\244\215\345\210\266\346\267\273\345\212\240\345\225\206\345\223\201_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc通过Excel复制添加商品_采购单新增,2295,2295-16,sit,bs +主数据平台:后台运营系统通过Excel复制添加商品接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步查看已发布商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15_1") +request_body = commonFuc().get_business_data(module, "payload15_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +product_code = result["data"]["list"][product_random]["productCode"] + +# 第三步获取商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") +request_body = commonFuc().get_business_data(module, "payload16", product_code) + +""" + 场景: 通过Excel复制添加商品_采购单新增 + 用例名称:通过Excel复制添加商品_采购单新增 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,该商品不存在!\n","data":[],"maps":null},"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict16") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..aa4c6ff328d8b1369526109f6600fcc0c8080141 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc通过Excel添加商品_代客下单,2295,2295-47,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取客户信息 +user_no = result["data"]["list"][customer_random]["userNo"] + +# 第三步获取客户对应的商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url50_1") +request_body = commonFuc().get_business_data(module, "payload50_1", user_no) +# 发送请求 +result = requests.get(url, params=request_body) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品信息 +product_code = result["data"]["list"][product_random]["productCode"] + +# 第四步通过Excel添加商品 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url50") +request_body = commonFuc().get_business_data(module, "payload50", product_code, user_no) + +""" + + 场景: 通过Excel添加商品_代客下单 + 用例名称:通过Excel添加商品_代客下单 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取商品信息 +result = json.loads(result.content) +# print(result) +result = {"productCode": result["data"]["data"][0]["productCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict50", product_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..8a3fc84c15f18467db8be08136443151609bd866 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\200\232\350\277\207Excel\346\267\273\345\212\240\346\227\240\346\225\210\345\225\206\345\223\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc通过Excel添加无效商品_代客下单,2295,2295-49,sit,bs +主数据平台:后台运营系统查询采购单详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取客户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +customer_random = random.randint(0, len(result["data"]["list"]) - 1) +# 生成无效的商品code +product_code = random.randint(0, 1000) +# 获取客户信息 +user_no = result["data"]["list"][customer_random]["userNo"] + +# 第三步通过Excel添加商品 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url48") +request_body = commonFuc().get_business_data(module, "payload48", product_code, user_no) + +""" + 场景: 通过Excel添加无效商品_代客下单 + 用例名称:通过Excel添加无效商品_代客下单 + 输出:{"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,该商品不存在!\n","data":[],"maps":[]},"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict48") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.air/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.py" "b/air_case/cmdc_order_list/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.air/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..3816efc6ef2c65527b41902b45fead52e30acba2 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.air/\351\200\232\350\277\207\351\234\200\346\261\202\345\215\225\345\217\267\350\216\267\345\217\226\345\256\241\346\240\270\345\220\216\345\225\206\345\223\201\346\270\205\345\215\225.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc通过需求单号获取审核后商品清单,2295,2295-96,sit,bs +主数据平台:后台运营系统通过需求单号获取审核后商品清单接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandCode = result["data"]["list"][demand_random]["demandCode"] + +# 第三步获取需求单审核后商品信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url96") +request_body = commonFuc().get_business_data(module, "payload96", demandCode) + +""" + 场景: 通过需求单号获取审核后商品清单 + 用例名称:通过需求单号获取审核后商品清单 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取审核后商品信息 +result = json.loads(result.content) +result = {"total": result["data"]["total"]} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中审核后商品数量 +sql = "SELECT count(t.demandSkuId) FROM `cmdc-order`.tc_demand_sku t WHERE demandCode = {}".format(demandCode) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict96", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..5cb045bedf5b99b35df439478bb43e6a62c7a005 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.air/\351\205\215\350\264\247\345\215\225\345\257\274\345\207\272_jde\351\205\215\350\264\247\345\210\227\350\241\250.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc配货单导出_jde配货列表,2295,2295-3,sit,bs +主数据平台:后台运营系统配货单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取jde配货列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url2") +request_body = commonFuc().get_business_data(module, "payload2") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +code = result["data"]["list"][dis_random]["demandCodeStr"] + +# 第三步进行配货单导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") +request_body = commonFuc().get_business_data(module, "payload3", code) + +""" + + 场景: 配货单导出_jde配货列表 + 用例名称:配货单导出_jde配货列表 + 输出:{"code":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/jde配货单当前列表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中子需求单 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"code": excel.read_data()[0].get("子需求单")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict3", code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..480208bf4d6eb9aa04a31e24277179d30b169702 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.air/\351\207\207\350\264\255\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201_\351\207\207\350\264\255\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购单导出验证_采购单列表,2295,2295-8,sit,bs +主数据平台:后台运营系统采购单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取采购单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +print(result) +# 生成随机数 +pur_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取采购单信息 +bill_no = result["data"]["list"][pur_random]["billNo"] + +# 第三步进行采购导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url8") +request_body = commonFuc().get_business_data(module, "payload8", bill_no) +# print(request_body) +""" + 场景: 采购单导出验证_采购单列表 + 用例名称:采购单导出验证_采购单列表 + 输出:{"billNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/采购单导出明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中采购单号 +excel = HandleExcel(file_path, "%E9%87%87%E8%B4%AD%E5%8D%95%E7%") +result = {"billNo": excel.read_data()[0].get("采购单号")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict8", bill_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..0749daae38e2782bda94e513c18d00e76a8d1e85 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.air/\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购单新增验证,2295,2295-10,sit,bs +主数据平台:后台运营系统采购单新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步采购单新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") +request_body = commonFuc().get_business_data(module, "payload10") +# print(request_body) +""" + + 场景: 采购单新增验证 + 用例名称:采购单新增验证 + 输出:{"productCode":"11852135"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购单新增后生成的id +result = json.loads(result.content) +# print(result) +purchase_id = result["data"] + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库新增采购单对应的商品code +sql = "SELECT t.product_code FROM `cmdc-order`.tc_purchase_entry t WHERE purchase_id = {}".format(purchase_id) +product_code = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 实际结果 +result = {"productCode": product_code} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict10") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" "b/air_case/cmdc_order_list/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" new file mode 100644 index 0000000000000000000000000000000000000000..50adf2c560741f548bfd1890b6997c5d185580cb --- /dev/null +++ "b/air_case/cmdc_order_list/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\225\260\351\207\217\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购数量不能为空_采购单新增,2295,2295-11,sit,bs +主数据平台:后台运营系统采购单新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步采购单新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# print(request_body) +""" + + 场景: 采购数量不能为空_采购单新增 + 用例名称:采购数量不能为空_采购单新增 + 输出:{"success":false,"code":"500","message":"采购数量不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict11") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_list/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" "b/air_case/cmdc_order_list/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" new file mode 100644 index 0000000000000000000000000000000000000000..d1ac31baa9a8ead786f56ca078d89303e1ac1364 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.air/\351\207\207\350\264\255\346\230\216\347\273\206\344\270\215\350\203\275\344\270\272\347\251\272_\351\207\207\350\264\255\345\215\225\346\226\260\345\242\236.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc采购明细不能为空_采购单新增,2295,2295-12,sit,bs +主数据平台:后台运营系统采购单新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步采购单新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") +request_body = commonFuc().get_business_data(module, "payload12") +# print(request_body) +""" + + 场景: 采购明细不能为空_采购单新增 + 用例名称:采购明细不能为空_采购单新增 + 输出:{"success":false,"code":"500","message":"采购单明细不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict12") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_list/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_order_list/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..48da334a2aede77ffd7caa64b79ebbc34a2e42fe --- /dev/null +++ "b/air_case/cmdc_order_list/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -0,0 +1,56 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc附件上传功能验证_代客下单,2295,2295-92,sit,be +主数据平台:后台运营系统附件上传功能验证_代客下单接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json +import os + + +module = "cmdc_order_list" + + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file_1", cmdc_access_token) +print(headers) +# 获取文件地址 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/test_file.jpg" + +# 第二步上传附件 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url92") +print(url) +# 获取文件 +file = open(file_path, "rb") +files = {"file": file} + +""" + 场景: 附件上传功能验证_代客下单 + 用例名称:附件上传功能验证_代客下单 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict92") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) +file.close() diff --git "a/air_case/cmdc_order_list/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" "b/air_case/cmdc_order_list/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..bdef4a934011abc88690c8869aa669434ae5c081 --- /dev/null +++ "b/air_case/cmdc_order_list/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.air/\351\252\214\350\257\201\351\234\200\346\261\202\345\215\225\346\230\257\345\220\246\350\242\253\345\215\240\347\224\250.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc验证需求单是否被占用,2295,2295-98,sit,bs +主数据平台:后台运营系统验证需求单是否被占用接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_order_list" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取需求单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +demand_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取需求单信息 +demandId = result["data"]["list"][demand_random]["demandId"] + +# 第三步获取需求单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url98") +request_body = commonFuc().get_business_data(module, "payload98", demandId) + +""" + + 场景: 验证需求单是否被占用 + 用例名称:验证需求单是否被占用 + 输出:{"data":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中对应需求单编辑状态 +sql = "SELECT t.isEdit FROM `cmdc-order`.tc_demand t WHERE demandId = {}".format(demandId) +is_edit = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict98", is_edit) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_merge/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_order_merge/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" new file mode 100644 index 0000000000000000000000000000000000000000..478577df8d2d1c099fb2801616eeddb26d0fd7fc --- /dev/null +++ "b/air_case/cmdc_order_merge/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -0,0 +1,109 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_配货单列表获取,2290,2250-02,sit,bs +主数据平台:运营后台管理系统配货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_merge" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取配货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 生成随机数 +distribution_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货单信息 +distribution_id = func(result["data"]["list"][distribution_random]["distributionId"]) +demand_parent_code = func(result["data"]["list"][distribution_random]["demandParentCode"]) +demand_code = func(result["data"]["list"][distribution_random]["demandCode"]) +distribution_code = func(result["data"]["list"][distribution_random]["distributionCode"]) +customer_code = func(result["data"]["list"][distribution_random]["customerCode"]) +audit_by_name = func(result["data"]["list"][distribution_random]["auditByName"]) +product_line_name = func(result["data"]["list"][distribution_random]["productLineName"]) +distribution_status = func(result["data"]["list"][distribution_random]["distributionStatus"]) +push_type = func(result["data"]["list"][distribution_random]["pushType"]) +is_merge = func(result["data"]["list"][distribution_random]["isMerge"]) +merge_version_code = func(result["data"]["list"][distribution_random]["mergeVersionCode"]) +out_code = func(result["data"]["list"][distribution_random]["soCode"]) +promotion_type = func(result["data"]["list"][distribution_random]["promotionType"]) +jde_type = func(result["data"]["list"][distribution_random]["jdeType"]) +customer_name = func(result["data"]["list"][distribution_random]["customerName"]) + +# 第三步获取配货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5", distribution_id) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) +if result["success"]: + # 获取商品信息 + product_random = random.randint(0, len(result["data"]["distributionDetailList"]) - 1) + productCodeList = func(result["data"]["distributionDetailList"][product_random]["productCode"]) + materialCodeList = func(result["data"]["distributionDetailList"][product_random]["materialCode"]) + optionStr = func(result["data"]["distributionDetailList"][product_random]["optionStr"]) + isGroupSign = "" + # 第四步进行列表查询条件验证 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") + request_body = commonFuc().get_business_data(module, "payload4", demand_parent_code, demand_code, distribution_code, + customer_code, audit_by_name, product_line_name, distribution_status, + push_type, productCodeList, materialCodeList, jde_type, is_merge, + optionStr, customer_name, promotion_type, isGroupSign, + merge_version_code, out_code) + print(request_body) + """ + + 场景: 列表查询条件验证_配货单列表获取 + 用例名称:列表查询条件验证_配货单列表获取 + 输出:{"demandParentCode":"%s"} + """ + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) + print(result) + # 获取结果中demandParentCode + result = {"demandParentCode": result["data"]["list"][0]["demandParentCode"]} + # 将接口响应时间添加至result中 + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict4", demand_parent_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict4", demand_parent_code) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.py" "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.py" index 8bf10590ca5e19a782f083d5b9521267bbd33556..062f0d86c2d564124d5e4057ad7103b0960fc758 100644 --- "a/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\225\206\345\223\201\347\274\226\347\240\201\344\277\241\346\201\257.py" @@ -15,32 +15,34 @@ import json module = "cmdc_order_merge" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 设置需要查询的商品编码 -product_code_random = "16518884" +product_code_random = "14384307" # 模糊查询商品编码信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") request_body = commonFuc().get_business_data(module, "payload3", product_code_random) """ - 场景: 验证模糊查询客户信息接口连通性 - 用例名称:模糊查询客户信息 + 场景: 验证模糊查询商品编码信息接口连通性 + 用例名称:模糊查询商品编码信息 输出:{"productCode":"%s"} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) # 获取查询结果中商品编码信息 result = {"productCode": result["data"][0]["productCode"]} # print(result) - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3", product_code_random) # print(check_dict) diff --git "a/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.py" similarity index 76% rename from "air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" rename to "air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.py" index b67fa5aa853648d257ce058f338f4e7bf47e0a8f..b3fe33b881b9f2c412e6a9c6ad6ad6e98587c4a6 100644 --- "a/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257_\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -2,7 +2,7 @@ __author__ = "liguangyu" """ -case_tag:cmdc_api,cmdc模糊查询客户信息,2290,2250-03,sit,bs +case_tag:cmdc_api,cmdc模糊查询客户信息_配货单列表,2290,2250-03,sit,bs 主数据平台:运营后台管理系统查询客户信息接口 """ @@ -15,8 +15,8 @@ import json module = "cmdc_order_merge" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -30,19 +30,21 @@ request_body = commonFuc().get_business_data(module, "payload2", customer_random """ 场景: 验证模糊查询客户信息接口连通性 - 用例名称:模糊查询客户信息 + 用例名称:模糊查询客户信息_配货单列表 输出:{"cusCompanyName":"%s"} """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取客户信息中cusCompanyName result = {"cusCompanyName": result["data"][0]["cusCompanyName"][:2]} -# print(result) - +result["api_time"] = api_time +print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", customer_random) -# print(check_dict) +print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.py" "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..5b2c9c1758e94da4642be19f36ed50f3f6bf35d9 --- /dev/null +++ "b/air_case/cmdc_order_merge/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.air/\346\250\241\347\263\212\346\237\245\350\257\242\347\211\251\346\226\231\347\274\226\347\240\201.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc模糊查询物料编码,2290,2250-05,sit,bs +主数据平台:运营后台管理系统模糊查询物料编码接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_order_merge" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 设置需要查询的模糊字段 +material_code_random = "TPVL200" + +# 模糊查询物料编码 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6", material_code_random) + +""" + 场景: 验证模糊查询物料编码接口连通性 + 用例名称:模糊查询物料编码 + 输出:{"data":"%s"} +""" +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取查询出的物料编码 +result = {"data": result["data"]} +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6", material_code_random) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_order_merge/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.py" "b/air_case/cmdc_order_merge/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..537c692029e04162a46bfbb34987fe885ca4ed11 --- /dev/null +++ "b/air_case/cmdc_order_merge/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\224\265\345\225\206\351\205\215\350\264\247\350\257\246\346\203\205.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取电商配货详情,2290,2250-01,sit,bs +主数据平台:运营后台管理系统获取电商配货详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_order_merge" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取配货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") +request_body = commonFuc().get_business_data(module, "payload1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取配货信息 +distri_bution_id = result["data"]["list"][dis_random]["distributionId"] + +# 第三步获取配货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5", distri_bution_id) + +""" + 场景: 验证获取电商配货详情接口连通性 + 用例名称:获取电商配货详情 + 输出:{"distributionId":"%s"} +""" +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +if result["success"]: + # 获取详情页中distributionId + result = {"distributionId": result["data"]["distributionId"]} + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict5", distri_bution_id) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict5", distri_bution_id) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_order_merge/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_order_merge/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" index 81708d3e270c9c735f392a6abbfd062374fe8472..8b97de81b2469dd7b26f18b72e3b44c8bb90651c 100644 --- "a/air_case/cmdc_order_merge/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_order_merge/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.air/\351\205\215\350\264\247\345\215\225\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -38,10 +38,13 @@ request_body = commonFuc().get_business_data(module, "payload1") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取列表中配货单数量 result = {"total": result["data"]["total"]} +result["api_time"] = api_time # 查询数据库中对应公司对应的账号信息 sql = "SELECT count(t.distributionId) FROM `cmdc-order`.tc_distributionorder t WHERE companyCode = 00111" diff --git "a/air_case/cmdc_product/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" index 0fcccebd891e35830cc9ce912ef8406e668e27ae..4880f712cd0707768f9a48cdce4164eec89f1ad9 100644 --- "a/air_case/cmdc_product/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\345\225\206\345\223\201\345\261\236\346\200\247\345\215\225\344\270\252\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -55,8 +55,10 @@ request_body = commonFuc().get_business_data(module, "payload6", product_id, reb # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取查询结果中商品code result = {"data": result["data"]} diff --git "a/air_case/cmdc_product/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_product/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" index 950c2d4a47dec89a9f5e6b4c9b29e330028638b3..b39a1b3f37e1c3e73f02e9997239a3fa45a690ca 100644 --- "a/air_case/cmdc_product/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/aa_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -47,8 +47,10 @@ request_body = commonFuc().get_business_data(module, "payload59", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict59") diff --git "a/air_case/cmdc_product/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_product/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" index 0b7ec8059bdbefd25eef0ae5f3e62543f4d47392..495f086a470e2da06366a9b4942e0b6067a2582b 100644 --- "a/air_case/cmdc_product/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/ab_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -18,8 +18,8 @@ import os module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -64,8 +64,10 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict60") diff --git "a/air_case/cmdc_product/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 8e1a708c5120ec3d4e563acd5f5aab6dc7d3ecc2..98b031a5159048de29943717501a549a18c3b7e3 100644 --- "a/air_case/cmdc_product/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ac_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -46,8 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload61", product_packag # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict61") diff --git "a/air_case/cmdc_product/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 8efe30ff1a20acfb7e55e32b3d9843731b6a3df6..e573b21c3a682ee6646b8b403ce92b7ea1cb4666 100644 --- "a/air_case/cmdc_product/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/ad_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -46,8 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload62", product_packag # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict62") diff --git "a/air_case/cmdc_product/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 6eb26e7640fd5a215e10acfb2e4b4dc081fd41d6..5a5bb81c01166bd9e48001a6f8c95668950db77f 100644 --- "a/air_case/cmdc_product/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/ae_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -46,8 +46,10 @@ request_body = commonFuc().get_business_data(module, "payload63", product_packag # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict63") diff --git "a/air_case/cmdc_product/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 1861411e54ff59ebe87ebf57e1bfb1c7b943f949..7cf312acc5bc3b40b188b4778aa030f900c321ce 100644 --- "a/air_case/cmdc_product/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/af_\344\270\213\345\215\225\346\225\260\351\207\217\350\256\276\347\275\256\346\211\271\351\207\217\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -42,13 +42,15 @@ request_body = [product_package] 场景: 下单数量设置批量删除功能验证 用例名称:下单数量设置批量删除功能验证 - 输出:{"success": False,"code":"200","message":"OK","data":1} + 输出:{"success":true,"code":"200","message":"OK","data":1,"freshToken":null} """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict64") diff --git "a/air_case/cmdc_product/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_product/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" index fb0eee3aa7566fbe7bafd679b6d74a244804df34..921681e5a4dccb615a988c1f7beb4bfec32d6ec9 100644 --- "a/air_case/cmdc_product/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/am_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -33,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload68", uuid.uuid4()) """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict68") # print(check_dict) diff --git "a/air_case/cmdc_product/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 963f9c400b034df76beb890986348b81c46d599e..1896f7ed87ce04641cf7a86a8c9824a8fc456e14 100644 --- "a/air_case/cmdc_product/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/an_\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -44,8 +44,11 @@ request_body = commonFuc().get_business_data(module, "payload69", dirt_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict69") diff --git "a/air_case/cmdc_product/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 6cd3e4d482a33d7f408d8bcaa13ed1c96e68acdf..cb6f85c79935a37274a15d2f5913e3cfae74ddae 100644 --- "a/air_case/cmdc_product/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -53,14 +53,17 @@ request_body = {"propertyIds": [property_id]} # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 查询数据库中对应公司对应的商品属性id sql = "SELECT t.deleteSign FROM `cmdc-product`.ic_product_properties t WHERE companyCode = 00111 and propertyId ={}".format( property_id) total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] result = {"deleteSign": total} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") # print(check_dict) diff --git "a/air_case/cmdc_product/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_product/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" index 2e37b8943bd714f7d1baa69d0ecf0c2dc55f3d90..539a019c5dab45c8c27274c273700557279d2f3a 100644 --- "a/air_case/cmdc_product/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/c_\345\272\223\345\255\230\351\205\215\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -38,10 +38,12 @@ request_body = commonFuc().get_business_data(module, "payload23") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) # 获取新增后库存配置id result = {"data": result["data"]} +result["api_time"] = api_time # print(result) # 查询数据库中新增的库存配置对应id sql = "SELECT t.stockRuleId FROM `cmdc-product`.ic_stock_rule t WHERE companyCode = 00111 and deleteSign = 0 and ruleName = '测试数据12321'" diff --git "a/air_case/cmdc_product/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index b0e4634c0e751a35aedfc3a857a10b8530f2000f..1ab7726d02dde7397fb0873e175352745e43aefc 100644 --- "a/air_case/cmdc_product/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -42,11 +42,14 @@ request_body = commonFuc().get_business_data(module, "payload24", rule_id) """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 查询数据库中对应库存配置删除标识 sql = "SELECT t.deleteSign FROM `cmdc-product`.ic_stock_rule t WHERE stockRuleId = {}".format(rule_id) result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict24") # print(check_dict) diff --git "a/air_case/cmdc_product/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 4a9ce0c88813437c859ce090f084c7b90744a3a0..01e616af0c6946dd81808e4075818a1e4b6508a3 100644 --- "a/air_case/cmdc_product/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\345\225\206\345\223\201\351\231\204\344\273\266\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -25,7 +25,10 @@ request_body = commonFuc().get_business_data(module, "payload31") """ # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict31") diff --git "a/air_case/cmdc_product/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 233e6e7088c83aa7dd8d291d420e1f106f340aaa..cc8d07f42f013c7a385d22ab330e636cd7a3e379 100644 --- "a/air_case/cmdc_product/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\345\225\206\345\223\201\351\231\204\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -25,7 +25,10 @@ request_body = commonFuc().get_business_data(module, "payload32") """ # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict32") diff --git "a/air_case/cmdc_product/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" index c9a0b26ae99cff080468871d9794314b7778ae0e..9b0e62aefe0a40bb1537959cf58d01af88bf3056 100644 --- "a/air_case/cmdc_product/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\345\225\206\345\223\201\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -47,7 +47,10 @@ request_body = commonFuc().get_business_data(module, "payload30", product_line_c """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict30") diff --git "a/air_case/cmdc_product/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index bb235580e0544ebd06667ec49884da9a10dd0b44..fb1b6fcf893728a476ae816cce22254fda37b222 100644 --- "a/air_case/cmdc_product/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -43,8 +43,10 @@ request_body = commonFuc().get_business_data(module, "payload33", id) # 发送请求 result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict33") # print(check_dict) diff --git "a/air_case/cmdc_product/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.air/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.py" "b/air_case/cmdc_product/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.air/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.py" index 7600b64aef7e9f7e0a901520b43694f53e3f8688..3dbffc217bda4d3e35f93b8443b73eb2d521e5ce 100644 --- "a/air_case/cmdc_product/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.air/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.py" +++ "b/air_case/cmdc_product/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.air/m_\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245.py" @@ -29,10 +29,10 @@ BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.pa file_path = BASE_DIR + "/data/cmdc_files/商品限购模板.xlsx" # 设定商品信息 -product_code = "12364265" -product_name = "医用检查手套" -cus_code = "1071246" -cus_name = "上海勘泽贸易商行" +product_code = "10145131" +product_name = "掌指骨部支具(腱鞘炎)" +cus_code = "1007035" +cus_name = "北京东信医疗器械有限公司" # 将商品信息写入文件中 excel = HandleExcel(file_path, "Sheet1") @@ -56,8 +56,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict46") # print(check_dict) diff --git "a/air_case/cmdc_product/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 93560a6f1561c905bfb110a4ddcd25623f8a2185..5ffefe9c462abcd77a6556e4f2f2b9feef3a317c 100644 --- "a/air_case/cmdc_product/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -26,7 +26,7 @@ request_body = commonFuc().get_business_data(module, "payload47_1") # 发送请求 result = requests.get(url, params=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取商品限购信息 id = result["data"]["list"][0]["id"] @@ -42,7 +42,10 @@ request_body = commonFuc().get_business_data(module, "payload47", id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict47") diff --git "a/air_case/cmdc_product/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" "b/air_case/cmdc_product/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" index ef58f9aa3e8546edde2bf21a6b28a696107471df..a1c95b88ac00225d81691abcd417ce17852c7250 100644 --- "a/air_case/cmdc_product/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.air/o_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201.py" @@ -17,8 +17,8 @@ module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -42,8 +42,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict54") # print(check_dict) diff --git "a/air_case/cmdc_product/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.air/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.py" "b/air_case/cmdc_product/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.air/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.py" index c65e7971f000a52083d5d0e4392e6eb5195ca737..5d91d697e6b0a96838ae1617356499f3faf9dbd2 100644 --- "a/air_case/cmdc_product/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.air/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.air/p_\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\345\210\240\351\231\244\351\252\214\350\257\201.py" @@ -14,8 +14,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -28,27 +28,30 @@ request_body = commonFuc().get_business_data(module, "payload55") result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) -# 获取折扣规则信息 -id = result["data"]["list"][0]["id"] - -# 对商品折扣规则进行删除操作 -url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url55") -request_body = [id] - -""" - 场景: 雅培商品折扣规则删除验证 - 用例名称:雅培商品折扣规则删除验证 - 输出:{"success":true,"code":"200"} -""" - -# 发送请求 -result = requests.post(url, json=request_body, headers=headers) -result = json.loads(result.content) -# print(result) - -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict55") -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +if result["data"]["list"]: + # 获取折扣规则信息 + id = result["data"]["list"][0]["id"] + + # 对商品折扣规则进行删除操作 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url55") + request_body = [id] + + """ + 场景: 雅培商品折扣规则删除验证 + 用例名称:雅培商品折扣规则删除验证 + 输出:{"success":true,"code":"200"} + """ + + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict55") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.air/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.py" "b/air_case/cmdc_product/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.air/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.py" index d8991f4c7175db405b82f2e161930dc02bf66ccc..b1e2f7a3ed3bcb10921193fce7668bf578fa6ca1 100644 --- "a/air_case/cmdc_product/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.air/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.air/q_\346\214\211\346\235\241\344\273\266\345\210\240\351\231\244\345\215\217\350\256\256\344\273\267\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import os module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -37,25 +37,34 @@ result = requests.post(url, files=files, headers=headers) result = json.loads(result.content) # print(result) # 上传成功后获取对应的id,用于后续确认删除操作 -id = result["data"]["yapeiPrices"][0]["id"] +if result["data"]["yapeiPrices"]: + id = result["data"]["yapeiPrices"][0]["id"] + # 确认删除操作 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url56_1") + request_body = {"ids": [id]} -# 确认删除操作 -url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url56_1") -request_body = {"ids": [id]} + """ + 场景: 按条件删除协议价验证 + 用例名称:按条件删除协议价验证 + 输出:{"success":true,"code":"200","message":"OK","data":true,"freshToken":null} + """ -""" - 场景: 按条件删除协议价验证 - 用例名称:按条件删除协议价验证 - 输出:{"success":true,"code":"200","message":"OK","data":true,"freshToken":null} -""" - -# 发送请求 -result = requests.post(url, json=request_body, headers=headers) -result = json.loads(result.content) + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) + result["api_time"] = api_time -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict56") -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict56") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict56_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) file.close() \ No newline at end of file diff --git "a/air_case/cmdc_product/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.air/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.py" "b/air_case/cmdc_product/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.air/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.py" index deff22c78372ef345a8b50036f190579b2c81f01..47b2f2bf42cf64028c025b8a7918eef6a724154e 100644 --- "a/air_case/cmdc_product/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.air/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_product/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.air/\344\270\212\344\274\240\346\227\245\345\277\227\344\277\241\346\201\257\350\216\267\345\217\226.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload27") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict27") # print(check_dict) diff --git "a/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" index a9a5f38bf6276ae828031419c2d6dc99e95b5ff8..3631514d5c716d0e0253ab8eaadf656c62f0cca8 100644 --- "a/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -25,8 +25,10 @@ request_body = commonFuc().get_business_data(module, "payload29") """ # 发送请求 result = requests.get(url, json=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict29") # print(check_dict) diff --git "a/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7b25ac5c79e65d1b58b83e0ee7ddba4df9ba0167 --- /dev/null +++ "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\206\351\205\215\345\210\266\345\215\225\345\221\230\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc产品线分配制单员功能验证,2293,2293-082,sit,bs +主数据平台:运营后台管理系统产品线分配制单员接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_product" + +# 第一步登录获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步产品线列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url71") +request_body = commonFuc().get_business_data(module, "payload71") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +line_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取产品线信息 +product_line_code = result["data"]["list"][line_random]["productLineCode"] +member_ids_list = result["data"]["list"][line_random]["memberIdsList"] + +# 第三步获取制单员列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url75") +request_body = {"productLineCode": product_line_code, "realName": "", "memberIdsList": member_ids_list, "pageNumber": 1, + "pageSize": 5} +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +marker_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取制单员信息 +marker_list = result["data"]["list"][marker_random] + +# 第四步分配制单员 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url76") +request_body = {"productLineCode": product_line_code, "userList": [marker_list]} + +""" + 场景: 产品线分配制单员功能验证 + 用例名称:产品线分配制单员功能验证 + 输出:{"success":false,"code":"200","message":"操作成功!","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict76") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..c6c914ab654809f42c217e3a99faabb3e0cfde07 --- /dev/null +++ "b/air_case/cmdc_product/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,69 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc产品线制单员删除功能验证,2293,2293-085,sit,bs +主数据平台:运营后台管理系统产品线制单员删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_product" + +# 第一步登录 +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取产品线列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url71") +request_body = commonFuc().get_business_data(module, "payload74_1") + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) + +for i in result["data"]["list"]: + # 只对包含多个制单员的产品线进行制单员删除操作 + if len(i["memberIdsList"]) > 1: + # 获取产品线信息 + product_line_code = i["productLineCode"] + # 生成随机数 + member_random = random.randint(0, len(i["memberIdsList"]) - 1) + # 获取制单员id + member_id = i["memberIdsList"][member_random] + + # 第三步对产品已分配制单员进行删除操作 + url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url79") + request_body = commonFuc().get_business_data(module, "payload79", product_line_code, member_id) + + """ + + 场景: 产品线制单员删除功能验证 + 用例名称:产品线制单员删除功能验证 + 输出:{"success":false,"code":"200","message":"操作成功!","data":null,"freshToken":null} + """ + + # 发送请求 + result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) + result["api_time"] = api_time + + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict79") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + + # 跳出循环 + break diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" index e8879ff002dd77b3190083f26c8598266ff405da..62adbf71c1bfe7f7bab6acb52568a50344318f2f 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" @@ -47,10 +47,14 @@ request_body = commonFuc().get_business_data(module, "payload19", line_code, lin # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取查询结果中产品线 result = {"lineCode": result["data"]["list"][0]["relevanceCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19", line_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.py" index c4c278d96e144e4cd20f6633aded0b56fb7d6be0..a10020f6c7853d548e05ddc2da573d4926993c02 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\346\227\266\351\227\264\345\210\227\350\241\250.py" @@ -28,9 +28,10 @@ request_body = commonFuc().get_business_data(module, "payload34") # 发送请求 result = requests.get(url, params=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 生成一个随机数 delivery_time_random = random.randint(0, len(result["data"]["list"]) - 1) +# delivery_time_random = 0 # 判断商品圈定方式 if result["data"]["list"][delivery_time_random]["productRangeType"]: @@ -39,17 +40,19 @@ if result["data"]["list"][delivery_time_random]["productRangeType"]: # 通过查看发货时间详情获取商品信息 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url36") request_body = commonFuc().get_business_data(module, "payload36", delivery_time_id) - + # print(request_body) # 发送请求 result1 = requests.get(url, params=request_body, headers=headers) result1 = json.loads(result1.content) - + # print(result1) # 获取商品信息 line_codes = "" - name = result1["data"]["list"][delivery_time_random]["name"] - status = result1["data"]["list"][delivery_time_random]["status"] - product_code = result1["data"]["list"][delivery_time_random]["productList"][0]["productCode"] - product_name = result1["data"]["list"][delivery_time_random]["productList"][0]["productName"] + name = result1["data"]["name"] + status = result1["data"]["status"] + product_code = ( + result1["data"]["productList"][0]["productCode"] if result1["data"]["productList"][0]["productCode"] else "") + product_name = ( + result1["data"]["productList"][0]["productName"] if result1["data"]["productList"][0]["productName"] else "") # 进行查询条件验证 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") @@ -58,10 +61,13 @@ if result["data"]["list"][delivery_time_random]["productRangeType"]: # 发送请求 result = requests.get(url, params=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中规则名称 result = {"name": result["data"]["list"][0]["name"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict35", name) # print(check_dict) @@ -88,10 +94,13 @@ else: # 发送请求 result = requests.get(url, params=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中规则名称 result = {"name": result["data"]["list"][0]["name"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict35", name) # print(check_dict) diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.py" index 1946c058c330c0a15c72e41f238dda4acd75547a..4aec8cefe0e4227999c09d3f63e8644e9c200d40 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250.py" @@ -66,10 +66,13 @@ request_body = commonFuc().get_business_data(module, "payload4", product_name, p # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品code result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" index ad16f5ceda237737594e50cfc5df489df97ce188..e5ef47534d86590db3951abf6d2ea1f7fac2218b 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" @@ -16,19 +16,19 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) -# 获取产品线列表 +# 获取商品列表 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") request_body = commonFuc().get_business_data(module, "payload20") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 生成一个随机数字,用于后续随机选择某一条商品属性信息 rebate_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品信息 @@ -47,10 +47,13 @@ request_body = commonFuc().get_business_data(module, "payload21", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品信息 result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21", product_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" index e57b5eee2803c9287cd59bed3845f5df606758bc..b52fe7cc065baa57e11c799be2ac3e60a24ae25f 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" @@ -17,8 +17,8 @@ module = "cmdc_product" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -73,10 +73,13 @@ request_body = commonFuc().get_business_data(module, "payload2", product_code, p # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品code result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.py" index bc846c00bc0da0c1a2d2cef1c0486aa63cfafc5a..a27b1ede4bd132f27d7f15a7c4e4c229d21ab788 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250.py" @@ -52,10 +52,13 @@ request_body = commonFuc().get_business_data(module, "payload12", product_line_c # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取查询结果中商品对应的附件名称 result = {"fileName": result["data"]["list"][0]["fileName"]} +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12", file_name) diff --git "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.py" index 861222476999bfbfd31d9fa3d3e3a75dc8987d06..b4ae3cbdc242ac4f4161694a28227c8915d7e360 100644 --- "a/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -16,8 +16,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -47,10 +47,12 @@ request_body = commonFuc().get_business_data(module, "payload14", rule_name) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取查询结果中库存配置名称 result = {"ruleName": result["data"]["list"][0]["ruleName"]} - +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14", rule_name) diff --git "a/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index de33cccfa0d8ddb32bec411976def2a1991bb34d..a656eccb558b1d9a1c1d42736b4dd956510142c6 100644 --- "a/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -45,7 +45,12 @@ request_body = commonFuc().get_business_data(module, "payload37", delivery_time_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time + # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict37") diff --git "a/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 5e2c8ff1f8067ecd3969a6d48726c9cc5571c457..1a791c06ec6cb07bad8476dbe310e5b96b81a0aa 100644 --- "a/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\217\221\350\264\247\346\227\266\351\227\264\350\247\204\345\210\231\345\220\257\347\224\250\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -45,7 +45,11 @@ request_body = commonFuc().get_business_data(module, "payload38", delivery_time_ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict38") diff --git "a/air_case/cmdc_product/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" index b120bfee9f411b7ed3c1098624d1ec2272c43b7c..601528c158fe15b0ec8f5fa7a01622ebd1beec47 100644 --- "a/air_case/cmdc_product/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\344\273\267\346\240\274\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -51,8 +51,10 @@ request_body = commonFuc().get_business_data(module, "payload53", product_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) -# result = json.loads(result.content) -# print(result) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # 获取文件 BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) @@ -65,6 +67,8 @@ with open(file_path, 'wb') as f: # 获取文件中商品编码 excel = HandleExcel(file_path, "Sheet1") result = {"productCode": excel.read_data()[0].get("商品编码")} + +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict53", product_code) diff --git "a/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" index c61806eb27f597bc5ca8f764b100138b5a0dea2d..4276ef8e3550d1fe30b873ba670de1298ae9cf0a 100644 --- "a/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -63,10 +63,14 @@ request_body = commonFuc().get_business_data(module, "payload5", product_id, pro # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中data信息 result = {"data": result["data"]} + +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5", property_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" index 6df652c43aa7ab69c3fefac7159a741b54f42924..4346057afbd54047b34803a95b5fd387313efa64 100644 --- "a/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\225\206\345\223\201\345\261\236\346\200\247\346\211\271\351\207\217\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -67,7 +67,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time file.close() # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_product/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_product/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.py" index 228983ab384a3162542aad09bfc27b56a0cf55b7..1c87a381706f719e58063c656373be2b5974e64c 100644 --- "a/air_case/cmdc_product/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_product/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\225\206\345\223\201\351\231\204\344\273\266\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload11") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") # print(check_dict) diff --git "a/air_case/cmdc_product/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" index 0abf51aa548a2f1f7b968e4c1cb44f56d3e794a0..3fdc2f9070d123977c40c54dd662dad2423e63a5 100644 --- "a/air_case/cmdc_product/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\351\231\220\350\264\255\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -48,7 +48,9 @@ request_body = commonFuc().get_business_data(module, "payload45", product_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) -# result = json.loads(result.content) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # print(result) # 获取文件 BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) @@ -62,6 +64,7 @@ with open(file_path, 'wb') as f: excel = HandleExcel(file_path, "Sheet1") result = {"productCode": excel.read_data()[0].get("商品编码")} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict45", product_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.air/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.py" "b/air_case/cmdc_product/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.air/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.py" index 059544840ca1b80f3392053a3dd42102636479a6..a983a7a12c5afe4c61edb23017d432d74f1c32ed 100644 --- "a/air_case/cmdc_product/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.air/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_product/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.air/\345\257\274\345\205\245\346\227\245\345\277\227\350\216\267\345\217\226.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload10") # 发送请求 result = requests.get(url, params=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10") # print(check_dict) diff --git "a/air_case/cmdc_product/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.air/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.py" "b/air_case/cmdc_product/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.air/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.py" index 87e730286b9b117fa6b881e92eccd04d2a95d06a..636a7c0d1996a6d86cd7eb6fb76beec02ff2239b 100644 --- "a/air_case/cmdc_product/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.air/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.py" +++ "b/air_case/cmdc_product/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.air/\345\260\206\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257\345\220\214\346\255\245JDE.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload73") # 发送请求 result = requests.get(url, params=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict73") # print(check_dict) diff --git "a/air_case/cmdc_product/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.py" "b/air_case/cmdc_product/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.py" index fdc3363791d2a3d9d349a5e911feb03f3bfc4ae5..dd391ecdbca17dcad5825678a4c4d1ce70970381 100644 --- "a/air_case/cmdc_product/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_product/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.air/\345\272\223\345\255\230\350\247\204\345\210\231\351\205\215\347\275\256\345\210\227\350\241\250\350\216\267\345\217\226.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload13") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13") # print(check_dict) diff --git "a/air_case/cmdc_product/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.py" index 853afa469044331084579874cfc08a0ffaa9709d..6fb2f498cd260fea919f57f2ee93deaf24cf4b6e 100644 --- "a/air_case/cmdc_product/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\351\205\215\347\275\256\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -50,8 +50,9 @@ request_body = commonFuc().get_business_data(module, "payload26", rule_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) -# result = json.loads(result.content) -# print(result) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # 获取文件 BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) @@ -64,6 +65,8 @@ with open(file_path, 'wb') as f: # 获取文件中订单编号 excel = HandleExcel(file_path, "产品线展示库存") result = {"productLineCode": excel.read_data()[0].get("产品线编码")} + +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict26", product_line_code) diff --git "a/air_case/cmdc_product/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.py" "b/air_case/cmdc_product/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.py" new file mode 100644 index 0000000000000000000000000000000000000000..6ea4bbca63c2acc12749e0e8c701841bc658cd81 --- /dev/null +++ "b/air_case/cmdc_product/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\240\351\231\244.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_产品线制单员删除,2293,2293-086,sit,bs +主数据平台:运营后台管理系统产品线制单员删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_product" + + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 验证制单员删除接口必填字段非空校验 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url80") +request_body = commonFuc().get_business_data(module, "payload80") + +""" + + 场景: 必填字段校验_产品线制单员删除 + 用例名称:必填字段校验_产品线制单员删除 + 输出:{"success":false,"code":"ADD MARKERMEMBER ERROR","message":"操作失败:制单员Id为空!","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict80") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_product/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.air/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.py" "b/air_case/cmdc_product/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.air/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.py" index 89015816d442140492a0bacf5995320aacbab586..cefc7694a6ddd74d6e40f06c8fcf0efee8c34c79 100644 --- "a/air_case/cmdc_product/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.air/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.py" +++ "b/air_case/cmdc_product/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.air/\346\211\271\351\207\217\344\270\212\344\274\240\345\225\206\345\223\201\351\231\220\350\264\255\350\247\204\345\210\231\346\227\245\345\277\227\350\216\267\345\217\226.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload44") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict44") # print(check_dict) diff --git "a/air_case/cmdc_product/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" index d96744f6ade13e2cf77847ad747d2b6634f92c1a..d78794e2223befafbbc1597c9bc229624519faf7 100644 --- "a/air_case/cmdc_product/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -50,8 +50,9 @@ request_body = commonFuc().get_business_data(module, "payload9", product_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) -# result = json.loads(result.content) -# print(result) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # 获取文件 BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) @@ -64,6 +65,8 @@ with open(file_path, 'wb') as f: # 获取导出明细文件中商品code excel = HandleExcel(file_path, "商品属性") result = {"productCode": excel.read_data()[0].get("商品编码")} + +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", product_code) diff --git "a/air_case/cmdc_product/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.py" "b/air_case/cmdc_product/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.py" index bd35f270e21fa1504c3304290e45cfa03c7697e9..d280c643a90d58c6d5fa83c22dbbd5a75de049dd 100644 --- "a/air_case/cmdc_product/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.py" +++ "b/air_case/cmdc_product/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.air/\346\237\245\347\234\213\345\217\221\350\264\247\346\227\266\351\227\264\350\257\246\346\203\205.py" @@ -48,10 +48,14 @@ request_body = commonFuc().get_business_data(module, "payload36", delivery_time_ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取发货时间详情中id result = {"id": result["data"]["deliveryTimeId"]} + +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict36", delivery_time_id) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" "b/air_case/cmdc_product/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" index 105db43b6fec58f2051412a6fded21f210210ad0..c4f3fd0ca46d98abc11032940eee2c79e9c70260 100644 --- "a/air_case/cmdc_product/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" +++ "b/air_case/cmdc_product/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.air/\346\237\245\347\234\213\351\233\205\345\237\271\345\225\206\345\223\201\346\212\230\346\211\243\350\247\204\345\210\231\346\211\271\351\207\217\345\257\274\345\205\245\346\227\245\345\277\227.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload52") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict52") # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" index 823f41162f0ced283e26832ea25d55da04ff217b..c25421cb8d6e9f861d70588135460a97d29446c1 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -39,7 +39,7 @@ status = result["data"]["list"][product_random]["status"] # 进行查询条件验证 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url58") request_body = commonFuc().get_business_data(module, "payload58", product_name, product_code, specifications, status) - +# print(request_body) """ 场景: 查询条件验证_下单数量列表 @@ -49,10 +49,14 @@ request_body = commonFuc().get_business_data(module, "payload58", product_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取查询结果中商品信息 result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict58", product_code) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" index 2591367792426751ed5c25253c8dd9d6de6f2265..2b49005b0d01a3932af373ee380c1ce76f5b5eb0 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -47,10 +47,13 @@ if result["data"]["list"][line_random]["memberIdsList"]: # print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中产品线信息 result = {"productLineCode": result["data"]["list"][0]["productLineCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict72", product_line_code) # print(check_dict) @@ -68,10 +71,13 @@ else: # print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中产品线信息 result = {"productLineCode": result["data"]["list"][0]["productLineCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict72", product_line_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..736514c7ac054ffd114c699dea5a474582b05391 --- /dev/null +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_产品线详情,2293,2293-084,sit,bs +主数据平台:运营后台管理系统获取产品线详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_product" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取产品线详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url77") +request_body = commonFuc().get_business_data(module, "payload77") + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +product_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取产品线包含商品信息 +product_code = result["data"]["list"][product_random]["productCode"] +product_name = result["data"]["list"][product_random]["productName"] +specifications = result["data"]["list"][product_random]["specifications"] +material_code = result["data"]["list"][product_random]["materialCode"] +manufacturer = result["data"]["list"][product_random]["manufacturer"] + +# 进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url78") +request_body = commonFuc().get_business_data(module, "payload78", product_code, product_name, specifications, + material_code, manufacturer) + +""" + + 场景: 产品详情页面查询条件验证 + 用例名称:查询条件验证_产品线详情 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取查询结果中商品code +result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict78", product_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..9d4eea134dc9cfa0661a682d5209d719a724a7c0 --- /dev/null +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_制单员列表,2293,2293-081,sit,bs +主数据平台:运营后台管理系统获取制单员或者业务员列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_product" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取制单员或者业务员列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url70") +request_body = commonFuc().get_business_data(module, "payload70") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +marker_random = random.randint(1, len(result["data"]) - 1) +# 获取制单员或者业务员信息 +real_name = result["data"][marker_random]["realName"] + +# 进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url75") +request_body = commonFuc().get_business_data(module, "payload75", real_name) +# print(request_body) +""" + + 场景: 验证制单员或者业务员列表查询条件 + 用例名称:查询条件验证_制单员列表 + 输出:{"realName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +if result["data"]["list"]: + # 获取制单员列表数量 + result = {"realName": result["data"]["list"][0]["realName"]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict75", real_name) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取制单员列表数量 + result = {"realName": result["data"]["list"]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict75_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.py" index f42d78a3b40583933e480febad14c374b98d9f3f..39e2431384dbcaae90dea31a49e471b7ef82de21 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264.py" @@ -50,10 +50,13 @@ request_body = commonFuc().get_business_data(module, "payload40", product_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品信息 result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict40", product_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.py" index 7b947dbd2f6794b927104246131b5f7bcf1bd5d3..ff7b129b6816c4edcae7b55c03c0dce32ee8bfaf 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\231\220\350\264\255\345\210\227\350\241\250.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -27,18 +27,29 @@ request_body = commonFuc().get_business_data(module, "payload41") # 发送请求 result = requests.get(url, params=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 生成随机数 product_random = random.randint(0, len(result["data"]["list"]) - 1) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + # 获取商品限购信息 -product_name = result["data"]["list"][product_random]["productName"] +product_name = func(result["data"]["list"][product_random]["productName"]) product_code = result["data"]["list"][product_random]["productCode"] -customer_code = result["data"]["list"][product_random]["customerCode"] -customer_name = result["data"]["list"][product_random]["customerName"] -specifications = result["data"]["list"][product_random]["specifications"] -product_line_name = result["data"]["list"][product_random]["cpdl01"] -manufacturer = result["data"]["list"][product_random]["manufacturer"] -material_code = result["data"]["list"][product_random]["materialCode"] +customer_code = func(result["data"]["list"][product_random]["customerCode"]) +customer_name = func(result["data"]["list"][product_random]["customerName"]) +specifications = func(result["data"]["list"][product_random]["specifications"]) +product_line_name = func(result["data"]["list"][product_random]["cpdl01"]) +manufacturer = func(result["data"]["list"][product_random]["manufacturer"]) +material_code = func(result["data"]["list"][product_random]["materialCode"]) start_time = result["data"]["list"][product_random]["takeEffectTime"] + " 00:00:00" # 进行查询条件验证操作 @@ -46,7 +57,7 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url42") request_body = commonFuc().get_business_data(module, "payload42", product_name, product_code, customer_code, customer_name, specifications, product_line_name, manufacturer, material_code, start_time) - +# print(request_body) """ 场景: 查询条件验证_商品限购列表 @@ -56,10 +67,13 @@ request_body = commonFuc().get_business_data(module, "payload42", product_name, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品信息 result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict42", product_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" index fcdf5e68e7986769642cdc6368cc362c632b396a..bf7d62ba6df42925300cea4d5a3b1dc713e1bf55 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -48,10 +48,13 @@ request_body = commonFuc().get_business_data(module, "payload67", dirt_code, dir # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中属性配置中对应的属性名称 result = {"dirtCode": result["data"]["list"][0]["dirtCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict67", dirt_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" index a40334a84df8e6a474f06bb9cf92fabb06cc020b..c0d5dd8c869df30bbf2253d5a7a8d0b540b842f9 100644 --- "a/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" @@ -59,10 +59,13 @@ request_body = commonFuc().get_business_data(module, "payload50", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品code result = {"productCode": result["data"]["list"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict50", product_code) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.py" index ef9247696f1d79b040427b1581265fdd9e3f8e0f..3a5c8d66ab7094ade859b5453d9bdc6fae3b3413 100644 --- "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\273\223\345\272\223\344\277\241\346\201\257.py" @@ -36,13 +36,25 @@ request_body = commonFuc().get_business_data(module, "payload22", stash_msg) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) -# 获取查询结果中stashCode -result = {"stashCode": result["data"][0]["stashCode"][:1]} -# 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict22", stash_msg) -# print(check_dict) -# 断言实际结果中是否包含预期结果的内容 -commonFuc().check_result(check_dict, result) +# 增加判断登录失败情况 +if result["success"]: + # 获取查询结果中stashCode + result = {"stashCode": result["data"][0]["stashCode"][:1]} + result["api_time"] = api_time + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict22", stash_msg) + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "payload_401") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.py" index b969b70a8884e8b01d070ead174f1c28caa132df..721a7f4b4846a588bf89c51a85be17cbfbd6c681 100644 --- "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\344\276\233\345\272\224\345\225\206\344\277\241\346\201\257.py" @@ -36,10 +36,13 @@ request_body = commonFuc().get_business_data(module, "payload16", supplier_msg) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中customerName result = {"supplierName": result["data"][0]["supplierName"][:2]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16", supplier_msg) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" index 299d2ec7755dc775be198f4c18a2d931a226cde4..124e56bcf631aee57b924805e0f4492ea41aa48e 100644 --- "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\345\256\242\346\210\267\344\277\241\346\201\257.py" @@ -15,14 +15,14 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) # 模糊查询字段 -customer_msg = "湖南" +customer_msg = "广州" # 进行客户信息模糊查询 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") request_body = commonFuc().get_business_data(module, "payload15", customer_msg) @@ -36,10 +36,13 @@ request_body = commonFuc().get_business_data(module, "payload15", customer_msg) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中customerName result = {"customerName": result["data"][0]["customerName"][:2]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15", customer_msg) # print(check_dict) diff --git "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.py" index f50dfa86bc318f353a9faa6e0997d06687d139d1..31cda16a29348dd6132f77d1f64c7c8e3f1b6996 100644 --- "a/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.air/\346\250\241\347\263\212\346\237\245\350\257\242\351\241\271\347\233\256\344\277\241\346\201\257.py" @@ -36,10 +36,13 @@ request_body = commonFuc().get_business_data(module, "payload17", project_msg) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中customerName result = {"projectName": result["data"][0]["projectName"][:2]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17", project_msg) # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" index 66590e1c6b4fed35e0f626f3c29fb79f0842f04f..fdc5c37dccfe543ebc147474c928a63857fb99cf 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\270\213\345\215\225\346\225\260\351\207\217\345\210\227\350\241\250.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload57") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict57") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" index 05dc576d83ca77332b87c3e8d2fbe3286f83f683..2826e097bd064be2e22d1d9def42d93fee3f52a0 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload18") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict18") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" index 8d7825ab6c636e8e702eee9d1ab3cabadc9905f9..baab24af539ce99f4ae6c6b69a67942d6c705c7f 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\227\350\241\250_\344\272\247\345\223\201\347\272\277\347\256\241\347\220\206.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload71") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict71") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..737166d50df6af5ba174b1c7106233fe019bc7dd --- /dev/null +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\345\210\266\345\215\225\345\221\230\345\210\227\350\241\250.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取产品线制单员列表,2293,2293-080,sit,bs +主数据平台:运营后台管理系统获取产品线制单员列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_product" + +# 第一步登录 +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取产品线列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url71") +request_body = commonFuc().get_business_data(module, "payload74_1") + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) + +# 生成随机数 +marker_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取产品线信息 +product_line_code = result["data"]["list"][marker_random]["productLineCode"] +# print(product_line_code) +# 获取产品线制单员列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url74") +request_body = commonFuc().get_business_data(module, "payload74", product_line_code) + +""" + + 场景: 验证获取产品线制单员列表接口连通性 + 用例名称:获取产品线制单员列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取制单员数量 +result = {"total": result["data"]["total"]} +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中产品线对应制单员数量 +sql = "SELECT count(t.id) FROM `cmdc-product`.ic_marker_member t " \ + "WHERE userId = 114378 and productLineCode = '{}'".format(product_line_code) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict74", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..f175611861cff953ece706ca958436a04981a431 --- /dev/null +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277\350\257\246\346\203\205.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取产品线详情,2293,2293-083,sit,bs +主数据平台:运营后台管理系统获取产品线详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + + +module = "cmdc_product" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取产品线详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url77") +request_body = commonFuc().get_business_data(module, "payload77") + +""" + + 场景: 验证获取产品线详情接口连通性 + 用例名称:获取产品线详情 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +result["api_time"] = api_time +# print(result) +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict77") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.py" index 0a076b12b3668a8b3df3cb92df63572a57cf5954..57becaed460a5f8940a1cce6e00e0a4559cec689 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\210\266\345\215\225\345\221\230\346\210\226\350\200\205\344\270\232\345\212\241\345\221\230\345\210\227\350\241\250.py" @@ -16,8 +16,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -35,10 +35,14 @@ request_body = commonFuc().get_business_data(module, "payload70") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取制单员列表数量 result = {"total": len(result["data"])} +result["api_time"] = api_time # print(result) # 数据库操作 mysql_handle = mySql() @@ -47,7 +51,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 查询数据库中对应制单员数量 sql = "SELECT count(t.userId) FROM `cmdc-user`.cmdc_user t " \ - "WHERE userType = 1 and companyId =6 and deleteSign = 0 in" \ + "WHERE userType = 1 and companyId =7 and deleteSign = 0 in" \ "(SELECT t.userId FROM `cmdc-user`.cmdc_manager_user t)" total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.air/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.air/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.py" index e18444871e5c02aef9344941eaa03868e2a6e565..c728f44a00b0f244eb19ae522eb7f45901547679 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.air/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.air/\350\216\267\345\217\226\345\217\221\350\264\247\346\227\266\351\227\264.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload34") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict34") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.py" index 745b9e911ed449dd24f31210adeedb68eb41b546..35d276e51bc2731e73c1e9bc45a365ead2c1b607 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.py" index 394755e7a1c932e049afb09502e06754f3b81313..fa1980c40408364129b4f37fa2a9e59b533032db 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\217\221\350\264\247\346\227\266\351\227\264\347\256\241\347\220\206.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload39") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict39") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" index 5d604831a77bea7f0c0147fdc5825126bd368f2c..4e3169c79d994f00c5de7eb2b87dde4773b9a4bf 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\210\227\350\241\250_\345\272\223\345\255\230\351\205\215\347\275\256.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload20") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" index 1e367cb0f99170863faf70964ace9668cb2fd864..0f9571cef77ab7ecce60e3858ce8c53456081eb8 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\225\206\345\223\201\345\261\236\346\200\247\345\210\227\350\241\250.py" @@ -16,8 +16,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -38,13 +38,16 @@ request_body = commonFuc().get_business_data(module, "payload1") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取列表中商品属性数量 result = {"total": result["data"]["total"]} +result["api_time"] = api_time # print(result) # 查询数据库中对应公司对应的商品属性数量 -sql = "SELECT count(t.productId) FROM `cmdc-product`.ic_product_properties t WHERE companyCode = 00111 and deleteSign = 0" +sql = "SELECT count(t.productId) FROM `cmdc-product`.ic_product_properties t WHERE companyCode = 00102 and deleteSign = 0" total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-product", sql)[0][0] # 获取预期结果 diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.py" index cbe49ca4a6710ad7d1ab1134db6db9c21d5462f8..421a01554ad02d567b75188a8ab6c50f27d12f80 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\225\206\345\223\201\351\231\220\350\264\255\344\277\241\346\201\257.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload41") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict41") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.py" index f8ca7ddfd320a95752a59061d4547b187ce9f0df..3a5c5139f16d49523ccfd66053584bf70c7a8135 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\345\210\227\350\241\250.py" @@ -35,12 +35,14 @@ request_body = commonFuc().get_business_data(module, "payload65") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取属性值数量 result = {"total": len(result["data"])} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" index cb161d10a61b2e0517c147934493fd1c70a90ac9..140b387a2743835c178c18d8f0fb6eaa2a9c3c65 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\261\236\346\200\247\345\200\274\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -15,8 +15,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload66") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict66") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.py" index 2ff6c435fdbfbe3046a0862a858ae1f2b0de8f22..54be243b4c14bcdb583070ffcbd27254150c35f1 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\272\223\345\255\230\351\205\215\347\275\256\350\257\246\346\203\205.py" @@ -16,8 +16,8 @@ import json module = "cmdc_product" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -47,10 +47,13 @@ request_body = commonFuc().get_business_data(module, "payload25", rule_id) # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # 获取查询结果中库存配置id result = {"stockRuleId": result["data"]["stockRuleId"]} - +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict25", rule_id) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.py" index 6b74f1855fbdcb4e9e628385b0d0542e9cff81fc..d6bc743b5b38bccc4de73139c2179e2f3489bf70 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\237\344\272\247\345\216\202\345\225\206\344\277\241\346\201\257.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload43") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict43") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.py" index 3217c728f7d7bd5bf49e95973b67e578c18c4075..289787e4c93551e9f314688f79819e29dbcc21f2 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\205\345\237\271\344\272\247\345\223\201\347\272\277\344\277\241\346\201\257.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload51") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict51") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.py" index 9a86fa66e4259329ef00e93e97792f146dddc00c..9e1491a095b9ce660b2c7db7bf16fc50a04c431f 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\345\205\254\345\217\270\345\210\227\350\241\250.py" @@ -28,8 +28,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url48") # 发送请求 result = requests.get(url) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict48") # print(check_dict) diff --git "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" index 99feb01a1614ded9173a5530b434176f30702b1a..19b8e1aedc6f6aa7784650720bf93f5dad6b2467 100644 --- "a/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\233\205\345\237\271\346\212\230\346\211\243\344\273\267\346\240\274\344\277\241\346\201\257\345\210\227\350\241\250.py" @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload49") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict49") # print(check_dict) diff --git "a/air_case/cmdc_product/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_product/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" index b8126d65d120dccfa2d55189421f9e5949c4e2f1..398b7dd04dae53a5660ec1fcb4ca5e91032807bf 100644 --- "a/air_case/cmdc_product/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_product/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.air/\351\231\204\344\273\266\344\270\212\344\274\240\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -42,7 +42,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict28") diff --git "a/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" "b/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" index 9a950d3d4adcfbb72322ccb1a8b0c238e9530bc0..bd01cd20e188672ded893a3aefd596e11d9c68d3 100644 --- "a/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" +++ "b/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\344\273\243\345\256\242\344\270\213\345\215\225.py" @@ -42,7 +42,11 @@ request_body = commonFuc().get_business_data(module, "payload1", user_no) # 发送请求 result = requests.get(url, params=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") diff --git "a/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.py" "b/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.py" index 3f9e18a57e51a135834f5c283d5590c2cbd36387..664dc810358f136b312e7fcbecaba0892d7fa892 100644 --- "a/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.py" +++ "b/air_case/cmdc_product_list_query/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.air/\345\225\206\345\223\201\345\210\227\350\241\250_\345\277\253\351\200\237\344\270\213\345\215\225.py" @@ -61,7 +61,11 @@ url13 = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13 """ # 发送请求 result = requests.get(url13, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13") print(check_dict) diff --git "a/air_case/cmdc_product_list_query/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" "b/air_case/cmdc_product_list_query/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" index 063459c7a6e56e42e913beede47b95d3fc55171a..c2ef7a68323ea926f282152203c6bd52fb543858 100644 --- "a/air_case/cmdc_product_list_query/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_product_list_query/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" @@ -32,8 +32,11 @@ request_body = commonFuc().get_business_data(module, "payload2") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") print(check_dict) diff --git "a/air_case/cmdc_purchase_list/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.air/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.py" "b/air_case/cmdc_purchase_list/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.air/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.py" index 4ba8613dadba30523b2bf2c4271491317a905429..9c003a9808c08ac17366ea657ee051f820833bed 100644 --- "a/air_case/cmdc_purchase_list/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.air/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_purchase_list/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.air/\351\207\207\350\264\255\345\215\225\346\237\245\350\257\242.py" @@ -34,8 +34,11 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") print(check_dict) diff --git "a/air_case/cmdc_query_customer/\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\256\242\346\210\267\346\237\245\350\257\242.py" "b/air_case/cmdc_query_customer/\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\256\242\346\210\267\346\237\245\350\257\242.py" index c3a997507ed591270aac54863193ac102d297568..80c23f7c9eaf5f8770d9b2e759ae1cb917be8c22 100644 --- "a/air_case/cmdc_query_customer/\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\256\242\346\210\267\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_query_customer/\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\256\242\346\210\267\346\237\245\350\257\242.py" @@ -34,10 +34,14 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_rebate/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.air/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.air/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.py" index 6847b6c0a0783da3cd7cfc04d81b4e2279df0927..f859dec8e5489a45c94aff776746eeb697b74c31 100644 --- "a/air_case/cmdc_rebate/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.air/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.air/a_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -43,7 +43,7 @@ result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) # 生成随机数 -product_random = random.randint(1, len(result["data"]["list"]) - 1) +product_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品code product_code = result["data"]["list"][product_random]["relevanceCode"] product_name = result["data"]["list"][product_random]["relevanceName"] @@ -63,8 +63,12 @@ request_body = commonFuc().get_business_data(module, "payload21", customer_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) +result["api_time"] = api_time +# print(result) if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21") diff --git "a/air_case/cmdc_rebate/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.air/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.py" "b/air_case/cmdc_rebate/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.air/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.py" index 3387079fb25e62041859b7a90dd28d0cf6375fef..3975e4ae1791ec77570bd26f5fdac95cd59cd3a0 100644 --- "a/air_case/cmdc_rebate/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.air/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.py" +++ "b/air_case/cmdc_rebate/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.air/b_\350\277\224\345\210\251\350\247\204\345\210\231\346\226\260\345\242\236_\344\272\247\345\223\201\347\272\277\345\267\262\350\242\253\347\273\221\345\256\232.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -43,7 +43,7 @@ result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) # 生成随机数 -product_random = random.randint(1, len(result["data"]["list"]) - 1) +product_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品code product_code = result["data"]["list"][product_random]["relevanceCode"] product_name = result["data"]["list"][product_random]["relevanceName"] @@ -63,8 +63,10 @@ request_body = commonFuc().get_business_data(module, "payload21", customer_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.air/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.air/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.py" index 88b5c371938107edda69ea9751ded989212a15e5..ecf0a8bc049f8d2fac9adfd88f0e7aae1e480494 100644 --- "a/air_case/cmdc_rebate/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.air/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.air/c_\350\277\224\345\210\251\350\247\204\345\210\231\350\257\246\346\203\205\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -42,10 +42,14 @@ request_body = commonFuc().get_business_data(module, "payload23", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取结果中返利规则id result = {"rebateid": result["data"]["rebateid"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23", rebate_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" index 6de7e9eecb5f4c1d72eb88bf926586a56fa5a5cf..9b94d59d05000dfc0dd6f3c4f50b56a0a3e1c4fe 100644 --- "a/air_case/cmdc_rebate/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/d_\350\277\224\345\210\251\350\247\204\345\210\231\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -58,7 +58,10 @@ request_body = commonFuc().get_business_data(module, "payload24", customer_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict24") diff --git "a/air_case/cmdc_rebate/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 25b665d4a2ebd258c012adf8a2e08bac8a10b65e..9c6cbc3132534d0441d1cbe193277560f274318c 100644 --- "a/air_case/cmdc_rebate/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\350\277\224\345\210\251\350\247\204\345\210\231\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -28,7 +28,7 @@ request_body = commonFuc().get_business_data(module, "payload23_list") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) - +# print(result) # 获取指定返利规则信息 rebate_id = result["data"]["list"][0]["rebateid"] @@ -44,7 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload26", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict26") diff --git "a/air_case/cmdc_rebate/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index be1871fcd17aa6d27902b0ea88a6ed321df4bccf..d954e492129be42f22f96724ff8ee2f4011d1ed9 100644 --- "a/air_case/cmdc_rebate/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\350\277\224\345\210\251\350\247\204\345\210\231\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -44,7 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload27", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict27") diff --git "a/air_case/cmdc_rebate/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" index 522678551a4d2bacce73d76c0c206e69461ad5c8..154cb931fa73b31907b57664b8e099743ac46aad 100644 --- "a/air_case/cmdc_rebate/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/g_\350\277\224\345\210\251\350\247\204\345\210\231\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -44,7 +44,10 @@ request_body = commonFuc().get_business_data(module, "payload25", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict25") diff --git "a/air_case/cmdc_rebate/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 6d7e1680f1a7e872e533d305f9eec654b4567395..1a2e29b064281d09ed19b4164b77c5c4c3f96cea 100644 --- "a/air_case/cmdc_rebate/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/m_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\220\257\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -48,7 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload39", rebate_trip_id # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict39") diff --git "a/air_case/cmdc_rebate/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 7d3e0fb1f32457bfa4d1eff34d29e7b703c70665..3e20466b0ef91efe460b048423f170ac85be762f 100644 --- "a/air_case/cmdc_rebate/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/n_\345\217\221\346\224\276\350\277\224\345\210\251\350\247\204\345\210\231_\347\224\237\346\225\210\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -48,7 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload39", rebate_trip_id # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict39") diff --git "a/air_case/cmdc_rebate/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" index c6bdb1a0eca7212ee9cabfb028cd4603385e80d9..c0450fca04b57b099b442aa0937e356c2c730f5a 100644 --- "a/air_case/cmdc_rebate/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\270\211\346\226\271\347\224\250\346\210\267\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload31") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict31") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.py" index ba293d70c546787b47082a34d1699addb85fe13b..931c36b7366f3cb4ed7a4a38b763a0739bc99adc 100644 --- "a/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277code\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload17") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.py" index 16fe69ed49521f33d400628d1cb33b1006e297b5..3f8a89771eb5f97f619f74c22efc22efda95da0e 100644 --- "a/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.air/\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload15") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.py" index e4c6ec8c16a8f300f4a80f2e72be148c84609079..c3162575e69f7d0ba73ff3cfe3a1e6eee9ea3f7a 100644 --- "a/air_case/cmdc_rebate/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\277\256\346\224\271\350\277\224\345\210\251\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -36,10 +36,13 @@ request_body = commonFuc().get_business_data(module, "payload01", rebate_amount) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) + # 获取结果中返利金额进行核验 result = {"rebateAmount": result["data"]["rebateAmount"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict01", rebate_amount) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.py" index 438c6601ad55600cb51ec599a38c12c6d1a26924..b0debc749ee76f6a188572c1aba53b11b62097aa 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\270\211\346\226\271\347\224\250\346\210\267\345\210\227\350\241\250.py" @@ -47,11 +47,13 @@ request_body = commonFuc().get_business_data(module, "payload32", customer_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中三方用户信息 result = {"customerCode": result["data"]["list"][0]["customerCode"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict32", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.py" index f327c78e0be626347fbd55263725514c27ad3f8b..00e49ce6385cd45f4784f3d2fb5da10ac935387d 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\344\272\247\345\223\201\347\272\277\345\225\206\345\223\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -48,10 +48,13 @@ request_body = commonFuc().get_business_data(module, "payload16", product_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品对应的商品code result = {"relevanceCode": result["data"]["list"][0]["relevanceCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.py" index bf4bb06661ffdb2b97fe3511a383f3a0a04afd31..7ce034fb4948cda14143f86ea05284028f0d2302 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225.py" @@ -63,11 +63,13 @@ request_body = commonFuc().get_business_data(module, "payload36", product_name, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中可使用商品返利清单信息 result = {"productCode": result["data"]["list"][0]["productCode"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict36", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.py" index 9db2b020c02aff989d93a564bb68abc31039a3b2..42df4f123746491f43ecb3b6009164a31305a71d 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225.py" @@ -60,11 +60,13 @@ print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) # 获取查询结果中可发放客户清单信息 result = {"customerCode": result["data"]["list"][0]["customerCode"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict38", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.py" index aaa2f40ac77efdbce4f091c34acf38e36f2b73db..36a0263a060c8c1c076f2e7619174f19f6987ba9 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225.py" @@ -40,6 +40,8 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") request_body = commonFuc().get_business_data(module, "payload11", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) if result["data"]["list"]: @@ -64,16 +66,20 @@ if result["data"]["list"]: # 发送请求 result = requests.post(url, json=request_body, headers=headers) + # 获取接口响应时间 + api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中商品对应的商品名称 result = {"productname": result["data"]["list"][0]["productname"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12", product_name) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) else: result = {"list": result["data"]["list"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12_1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" index ab120640c326dcab1fdef0b904eecf016e28b025..ecce580c6dc500deefa34e8a3feb4615146f0d24 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" @@ -63,10 +63,13 @@ request_body = commonFuc().get_business_data(module, "payload6", customer_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中返利明细对应的客户编号 result = {"customerCode": result["data"]["list"][0]["customerCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.py" index 4d03a5d4fb335421929144758e7966ad82a45dbb..4d7bc4432929d95d9e78a8d015bfe2ffed69bfad 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\350\214\203\345\233\264.py" @@ -61,10 +61,13 @@ print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) # 获取查询结果对应的客户编号 result = {"customercode": result["data"]["list"][0]["customercode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" index b9d8736f6970a23407dd4e79fca2ebce83d20388..2fa38e5ad17edff4964df2456c01599a48930895 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" @@ -70,11 +70,14 @@ request_body = commonFuc().get_business_data(module, "payload2", customer_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) if result["data"]["list"]: # 获取查询结果中使用明细对应的客户编号 result = {"customerCode": result["data"]["list"][0]["customerCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", customer_code) # 断言实际结果中是否包含预期结果的内容 @@ -82,6 +85,7 @@ if result["data"]["list"]: else: # 获取查询结果中使用明细对应的客户编号 result = {"list": result["data"]["list"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2_1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.py" index 7b6375acb81ed881aff711b8064112eb581cb7e1..e0d7bfadab68bf5cea39030063997226b0cd5068 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\345\210\227\350\241\250.py" @@ -52,10 +52,13 @@ request_body = commonFuc().get_business_data(module, "payload34", status, rebate # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中的返利信息 result = {"rebateTheme": result["data"]["list"][0]["rebateTheme"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict34", rebate_theme) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" index b8c6fa469e9f4d94a660e5fb094f2c3fbb14e3e8..5f731af9f56af4e8495354050f766f9cf7183c27 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -59,10 +59,13 @@ request_body = commonFuc().get_business_data(module, "payload9", create_name, au # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) # 获取查询结果中使用明细对应的客户编号 result = {"rebatename": result["data"]["list"][0]["rebatename"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", rebate_name) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" index 468cef03294957531af1b90ab6cc8af6be62c36b..c0d86ea654643723839b24230a1de6b599ecde8b 100644 --- "a/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" +++ "b/air_case/cmdc_rebate/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" @@ -63,10 +63,13 @@ request_body = commonFuc().get_business_data(module, "payload4", rebate_name, pr # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取查询结果中使用明细对应的客户编号 result = {"rebatename": result["data"]["list"][0]["rebatename"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict4", rebate_name) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" index 44889bf8768009eff58eee2c77453896c9b93cc1..4948f4f5bafea1b40032691c955a130a51885372 100644 --- "a/air_case/cmdc_rebate/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\344\275\277\347\224\250\345\225\206\345\223\201\350\277\224\345\210\251\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -47,8 +47,11 @@ request_body = commonFuc().get_business_data(module, "payload35", rebate_trip_td # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict35") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" index 7ec440fedcbc45b0cd0a7d5b20f8fffd22ff9d5a..aabc87c5cfe5034b8919d1094a93c2cca015734b 100644 --- "a/air_case/cmdc_rebate/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\217\257\345\217\221\346\224\276\345\256\242\346\210\267\346\270\205\345\215\225\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -47,8 +47,10 @@ request_body = commonFuc().get_business_data(module, "payload37", rebate_trip_td # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict37") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.py" "b/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.py" index bb46ef63f685a5e3a5b2d487155f85568d54ef90..ccf6ab4d4d555bab4042ee31dd1f2e5303bf2157 100644 --- "a/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.py" +++ "b/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245_\350\277\224\345\210\251\350\247\204\345\210\231_\345\225\206\345\223\201\344\270\216\344\272\247\345\223\201\347\272\277\344\270\215\345\214\271\351\205\215.py" @@ -18,8 +18,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -58,10 +58,13 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) + file.close() result = {"success": result["data"]["errMsg"]["success"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" "b/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" index 821c0a4ef7ee11b512db125caf501705151cd201..eea3553a03d870376a2cac2df1e354f85f12e10d 100644 --- "a/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" +++ "b/air_case/cmdc_rebate/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" @@ -18,8 +18,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -36,7 +36,7 @@ result = requests.post(url, headers=headers, json=request_body) result = json.loads(result.content) # 生成随机数 -product_random = random.randint(1, len(result["data"]["list"]) - 1) +product_random = random.randint(0, len(result["data"]["list"]) - 1) # 获取商品code product_code = result["data"]["list"][product_random]["relevanceCode"] @@ -58,10 +58,12 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) file.close() result = {"success": result["data"]["errMsg"]["success"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" "b/air_case/cmdc_rebate/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" index 4e7feb606f296ffa78c20465b41b5964fc4d054a..529580b60dd0d380cde5febf7c6a9460c5f2f5af 100644 --- "a/air_case/cmdc_rebate/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" +++ "b/air_case/cmdc_rebate/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\346\213\222\347\273\235\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -49,6 +49,8 @@ request_body = commonFuc().get_business_data(module, "payload10_2", rebate_id, a # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 数据库操作 @@ -59,7 +61,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利规则审核状态 sql = "SELECT t.auditStatus FROM `cmdc-order`.tc_rebate t WHERE rebateId = {}".format(rebate_id) result = {"auditstatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 一级审核通过状态变为审核拒绝 audit_status = 103 # 获取预期结果 diff --git "a/air_case/cmdc_rebate/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.py" index 6c726d1648a28d51f62b3282fd046f1bdd8dc4b4..c44c5f70ff0bc40ae751a5e97b1d43ce55fd30c1 100644 --- "a/air_case/cmdc_rebate/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\241\346\240\270\346\235\203\351\231\220\347\224\250\346\210\267\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -32,8 +32,10 @@ request_body = commonFuc().get_business_data(module, "payload7") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" "b/air_case/cmdc_rebate/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" index 9a1b31490ed3cdc433aa3aa03f679ecb3312d1f2..dde5910284d9a832fd83186825556c311fcdab2e 100644 --- "a/air_case/cmdc_rebate/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" +++ "b/air_case/cmdc_rebate/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.air/\345\256\241\346\240\270\351\200\232\350\277\207\351\252\214\350\257\201_\350\277\224\345\210\251\345\256\241\346\240\270.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -49,8 +49,12 @@ request_body = commonFuc().get_business_data(module, "payload10_1", rebate_id, a # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -59,7 +63,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利规则审核状态 sql = "SELECT t.auditStatus FROM `cmdc-order`.tc_rebate t WHERE rebateId = {}".format(rebate_id) result = {"auditstatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 一级审核通过状态变为二级审核中 audit_status = 104 # 获取预期结果 diff --git "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" index 9774b6972860a4121ba16038175afd488901586b..1f57a617698b6d39ba5342ccd50e4fa66f9f884b 100644 --- "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\344\277\241\346\201\257\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -32,7 +32,11 @@ request_body = commonFuc().get_business_data(module, "payload5") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5") diff --git "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.py" index a4ffd246f8ce0a197a956ce137f2257641d54657..8a78d803861f64c9b0372177d8fe50372e1a2ccc 100644 --- "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -75,8 +75,11 @@ request_body = commonFuc().get_business_data(module, "payload30", rebate_id, amo """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict30") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" index 042a74955e5364791902411f4b5292fac29d3dab..061cea489f13661a738b16c76500efce90ead744 100644 --- "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -46,8 +46,11 @@ request_body = commonFuc().get_business_data(module, "payload30", rebate_id, amo # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict30") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" index 602310ae531246561fb02f9b570c279c02425999..c8d9e2e33758b357f169460f0a6d14818109e427 100644 --- "a/air_case/cmdc_rebate/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" +++ "b/air_case/cmdc_rebate/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.air/\345\256\242\346\210\267\345\220\215\345\215\225\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\350\277\224\345\210\251\350\247\204\345\210\231.py" @@ -60,10 +60,14 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) + file.close() result = {"success": result["data"]["errMsg"]["success"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict18") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" index f16daa62f325ca5d8f93add2fc07e99a39236618..6b5fde09434b5c48ef9bb95fcdc16a3a4c5d8365 100644 --- "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\225\206\345\223\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" @@ -18,8 +18,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) @@ -60,10 +60,13 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) file.close() result = {"productCode": result["data"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict41", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" index ce878c76a205a666191c28c3adc9b75fc82c13a3..0fc165af7049905d2f483573014f45854e39d109 100644 --- "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.air/\346\211\271\351\207\217\345\257\274\345\205\245\345\256\242\346\210\267\351\252\214\350\257\201_\350\277\224\345\210\251\345\217\221\346\224\276\347\256\241\347\220\206.py" @@ -64,12 +64,15 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +# print(result) file.close() if result["success"]: # 导入成功 result = {"customerCode": result["data"][0]["customerCode"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict40", customer_code) # 断言实际结果中是否包含预期结果的内容 @@ -77,6 +80,7 @@ if result["success"]: else: # 客户编码未与此站点首营 result = {"message": result["message"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict40_1") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" index 2f5507a56fb34967dd55b0cc03bd9762dc68520e..5a68ca517725463443ecc563f517ab7598ab0582 100644 --- "a/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" +++ "b/air_case/cmdc_rebate/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.air/\346\211\271\351\207\217\345\257\274\345\205\245\351\252\214\350\257\201_\345\256\242\346\210\267\345\217\221\346\224\276\350\277\224\345\210\251.py" @@ -92,8 +92,9 @@ files = {"file": file} """ # 发送请求 result = requests.post(url, files=files, headers=headers) +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time file.close() # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict29") diff --git "a/air_case/cmdc_rebate/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.py" index 1a78c20302623de728af025d0622feb292ebc51a..10c31c4ac58fae13a739a413455d820534339f8d 100644 --- "a/air_case/cmdc_rebate/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.air/\346\237\245\350\257\242\345\256\242\346\210\267\345\257\271\345\272\224\350\277\224\345\210\251\350\247\204\345\210\231\351\252\214\350\257\201.py" @@ -57,10 +57,13 @@ request_body = commonFuc().get_business_data(module, "payload28", customer_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取结果中返利规则中客户编码 result = {"customercode": result["data"][0]["customercode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict28", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" index 71210cf3b8e9733133d301bcccc77f13d771cd82..244e602d80bfa4056903d76ddf75c4412081b368 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.air/\350\277\224\345\210\251\344\275\277\347\224\250\346\230\216\347\273\206.py" @@ -32,7 +32,11 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.py" index c6f8c8395c3e8df5f261a2b9620ec4c6b90a57f9..a1ff41d05f9732b8e71c0069957f069dc7ab6495 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -40,7 +40,11 @@ request_body = commonFuc().get_business_data(module, "payload43", theme, use_lim # 发送请求 result = requests.post(url, json=request_body, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) if result["success"]: # 获取返利发放明细 @@ -55,6 +59,7 @@ if result["success"]: # 数据库查询返利发放规则主题 sql = "SELECT t.rebateTheme FROM `cmdc-order`.tc_rebatetrip t WHERE rebateTripId = {}".format(rebate_trip_id) result = {"rebateTheme": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} + result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict43", rebate_theme) diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" index 8161ff792697314a26ca5f80cf9ef088ae5410c7..1266b938866ea166c880094d4ef81f2142fd5f52 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\346\230\216\347\273\206\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -25,6 +25,7 @@ headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_toke # 第二步获取返利发放明细 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") request_body = commonFuc().get_business_data(module, "payload33") + """ 场景: 验证返利发放明细查询接口是否可正常使用 用例名称:返利发放明细获取验证 @@ -33,7 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload33") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict33") @@ -42,7 +46,7 @@ commonFuc().check_result(check_dict, result) # 获取返利发放明细 total = result["data"]["total"] -# print(total) + # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -51,8 +55,8 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利发放规则状态 sql = "SELECT t.rebateTripId FROM `cmdc-order`.tc_rebatetrip t" result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))} +result["api_time"] = api_time # print(result) -# 核验数据库返利发放规则对应的删除标识是否正确 # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict33_1", total) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" index 180a7ba24ff8803c8bbeeae93f178878742861ca..5c6b058e1449195238ea6e02d1e5749db60962c2 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\217\221\346\224\276\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -47,10 +47,13 @@ request_body = rebate_json # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取查询结果中的返利信息 result = {"rebateTripId": result["data"]["rebateTripId"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict42", rebate_trip_id) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.py" index b63c052d52707ad60d5b2c6d7a9642e6ed760cd4..e581f46768394ee8b5c97b5a7f4c8b14b8956234 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\345\256\241\346\240\270\345\210\227\350\241\250\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_rebate" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -34,8 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload8") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8") # 断言实际结果中是否包含预期结果的内容 @@ -43,7 +45,7 @@ commonFuc().check_result(check_dict, result) # 获取列表总数量 total = result["data"]["total"] -# print(total) +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() @@ -51,8 +53,10 @@ mysql_handle = mySql() host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询待审核返利规则数量 -sql = "SELECT t.rebateId FROM `cmdc-order`.tc_rebate t WHERE deleteSign = 0 and isAudit = 1 and auditLevel =2" +sql = "SELECT t.rebateId FROM `cmdc-order`.tc_rebate t " \ + "WHERE deleteSign = 0 and isAudit = 1 and auditLevel =2 and filialeCode = 00102" result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))} +result["api_time"] = api_time # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.py" index fa82df00b34e254b6bf4ac1215e12bc3ea2bd3b0..06c23e1b2731c63b1a8f9219a9e0f73ba89ba4ab 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\345\256\242\346\210\267\350\214\203\345\233\264\346\237\245\350\257\242\351\252\214\350\257\201.py" @@ -48,7 +48,10 @@ request_body = commonFuc().get_business_data(module, "payload13", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13") @@ -57,7 +60,7 @@ commonFuc().check_result(check_dict, result) # 获取返利规则对应的客户数量 total = result["data"]["total"] -print(total) +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -66,7 +69,9 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利规则包含的客户数量 sql = "SELECT t.rebateUserId FROM `cmdc-order`.tc_rebate_user t WHERE rebateId = {}".format(rebate_id) result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))} -print(result) + +result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11_1", total) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.py" index 7567ec82cb570ad44b237494009c6d6533a00209..cf051446e3425a1fe1496b3f0613b05eff76c157 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\345\225\206\345\223\201\351\273\221\345\220\215\345\215\225\346\237\245\350\257\242\351\252\214\350\257\201.py" @@ -47,8 +47,10 @@ request_body = commonFuc().get_business_data(module, "payload11", rebate_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict11") # 断言实际结果中是否包含预期结果的内容 @@ -56,7 +58,7 @@ commonFuc().check_result(check_dict, result) # 获取返利规则对应客户数量 total = result["data"]["total"] -print(total) +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -65,7 +67,8 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利规则包含的可使用商品数量 sql = "SELECT t.rebateProductId FROM `cmdc-order`.tc_rebate_product t WHERE rebateId = {}".format(rebate_id) result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))} -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13_1", total) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.py" "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.py" index fd84e0e6be7b3d796c78b3b741e0a8a3f5d05b63..553a10b0f9e7be7a6e06cda4b927ec4eef02c7b8 100644 --- "a/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_rebate/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.air/\350\277\224\345\210\251\350\247\204\345\210\231\350\216\267\345\217\226\351\252\214\350\257\201.py" @@ -33,11 +33,14 @@ request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取列表总数量 total = result["data"]["total"] -print(total) +result["api_time"] = api_time +# print(total) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") # 断言实际结果中是否包含预期结果的内容 @@ -51,7 +54,8 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询返利规则审核状态 sql = "SELECT t.rebateId FROM `cmdc-order`.tc_rebate t WHERE deleteSign = 0 and filialeCode = 00111" result = {"total": len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql))} -print(result) + +# print(result) # 核验数据库返利规则对应的删除标识是否正确 # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3_1", total) diff --git "a/air_case/cmdc_special_fresenius_group/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index 216cbdab013bb5f71abdee6c78b7520ccf18670d..d670dac97fd9e0a6fed93c35df7cc7f1a2e27000 100644 --- "a/air_case/cmdc_special_fresenius_group/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\344\273\243\345\256\242\344\270\213\345\215\225_\345\245\227\345\214\205\346\270\205\345\215\225_\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -28,7 +28,6 @@ request_body = commonFuc().get_business_data(module, "payload50") result = requests.get(url, params=request_body, headers=headers) result = json.loads(result.content) - # 此函数用于当x为none时,进行空字符串替换 def func(x): if x is None: @@ -51,7 +50,7 @@ material_code_split = result["data"][0]["subList"][0]["product"]["materialCode"] url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url50") request_body = commonFuc().get_business_data(module, "payload51", group_name, group_product_code, group_product_name, group_option_str, document_no, product_line_code, material_code_split) - +# print(request_body) """ 场景: 代客下单_套包清单_查询条件验证 用例名称:代客下单_套包清单_查询条件验证 @@ -60,11 +59,13 @@ request_body = commonFuc().get_business_data(module, "payload51", group_name, gr # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) - +# print(result) # 获取结果中ref单号 result = {"productLineCode": result["data"][0]["productLineCode"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict51", product_line_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" "b/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" index 0e6f9c08139e8964e5fb093499becce23c660f08..520f2c40308a96aca4d005153e3aa2e23dfd94c5 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\201\234\347\224\250_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" @@ -44,7 +44,10 @@ request_body = {"freseniusPriceIds": [fresenius_price_id], "groupPriceStatus": 0 # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() @@ -54,7 +57,8 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询特价单品数量 sql = "SELECT t.groupPriceStatus FROM `cmdc-order`.tc_fresenius_agreement_price t WHERE freseniusPriceId = {};".format(fresenius_price_id) result = {"groupPriceStatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" "b/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" index 8904475c94890a6db4f5b33bf7d5bc76865a2ddd..fdbd14598403f324d098d1558e595edc6b801475 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\201\234\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" @@ -76,7 +76,10 @@ request_body = {"freseniusPriceIds": [fresenius_price_id], "groupPriceStatus": 0 # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + file.close() # 数据库操作 @@ -87,7 +90,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询特价单品数量 sql = "SELECT t.groupPriceStatus FROM `cmdc-order`.tc_fresenius_agreement_price t WHERE groupId = {};".format(group_id) result = {"groupPriceStatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict19") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.py" index 8ad331fc6f58c8e27de3e8a1361a1963aecd2111..cbb9ef1379bce18526dd65ad4f704985c419dc03 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\347\256\241\347\220\206.py" @@ -73,10 +73,13 @@ request_body = commonFuc().get_business_data(module, "payload13", group_code, gr # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包协议价信息groupCode result = {"groupCode": result["data"]["list"][0]["groupCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict13", group_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.py" index 2d126cabb42bcb8db93f58e0e1fc7dbdcb5ac6d4..8b3118e6bd30b0e09fa6747e3951489e7f7e0148 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267\347\256\241\347\220\206.py" @@ -71,10 +71,13 @@ request_body = commonFuc().get_business_data(module, "payload31", group_code, gr # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包正价信息groupCode result = {"groupCode": result["data"]["list"][0]["groupCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict31", group_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.py" "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.py" index ed8eaf866dc67b4393348efdefbe5da404c269ab..ffac1bfd3c0e4cca03d1677e3f2a55c60a442e68 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\256\242\346\210\267\345\210\227\350\241\250.py" @@ -44,10 +44,13 @@ request_body = commonFuc().get_business_data(module, "payload16", customer_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取客户信息 result = {"customerCode": result["data"]["list"][0]["customerCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict16", customer_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.py" "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.py" index e5509a983f76da1ba9b94280f8316e12dd58d16b..0e7d09a4f18bb0e2d2b603ae6ea9b6f21f6123df 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201.py" @@ -50,8 +50,11 @@ request_body = commonFuc().get_business_data(module, "payload22", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) result = {"productCode": result["data"]["list"][0]["products"][0]["productCode"]} +result["api_time"] = api_time print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict22", product_code) diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.py" index 2ecdd7ee9636c2c5725bf20ada6d18d437b52839..737f3b1883ea11e64fe77648da8e29e21facb7a0 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\211\271\344\273\267\345\215\225\345\223\201\347\256\241\347\220\206.py" @@ -70,10 +70,13 @@ request_body = commonFuc().get_business_data(module, "payload14", product_code, # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取特价单品code result = {"productCode": result["data"]["list"][0]["freseniusProduct"]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict14", product_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.air/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.py" "b/air_case/cmdc_special_fresenius_group/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.air/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.py" index f5691a884a79e7ee6a7c20a52e6f67065333ca7c..1b24cc66d87158184fcfa1fcb9f9d241b087f523 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.air/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.air/\345\210\240\351\231\244_\346\211\271\351\207\217_\345\245\227\345\214\205\346\255\243\344\273\267.py" @@ -74,8 +74,11 @@ request_body = {"freseniusPriceIds": [fresenius_price_id], "groupPriceStatus": 0 # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) + +# print(result) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -85,7 +88,8 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") sql = "SELECT t.groupPriceStatus FROM `cmdc-order`.tc_fresenius_agreement_price t WHERE freseniusPriceId = {};".format( fresenius_price_id) result = {"groupPriceStatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict23") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" "b/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" index e58995d778a702a19447ba60b02bb9e469885eb6..c3f2e0d43561a4ab3e064b35b9d0d5361ebba827 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267.py" @@ -117,8 +117,10 @@ print(request_body) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") diff --git "a/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.py" "b/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.py" index 251cd9e69c79cda1758ce8ac4bacde0641846501..85d8fab03bd1e299ebbd94aa77b2a587a41b6642 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.air/\345\215\225\344\270\252\346\226\260\345\242\236\351\252\214\350\257\201_\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267.py" @@ -97,7 +97,10 @@ request_body = {"manufacturerGroupName": "", "manufacturerGroupCode": "", "group # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 进行结果判断 diff --git "a/air_case/cmdc_special_fresenius_group/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" "b/air_case/cmdc_special_fresenius_group/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" index e27a8e6986b44014f8771a80173c5d87f33c3375..a4dfa4dd503ffea0fcb7829f00312378e27bbf98 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.air/\345\220\257\347\224\250_\346\211\271\351\207\217_\347\211\271\344\273\267\345\215\225\345\223\201.py" @@ -75,8 +75,10 @@ request_body = {"freseniusPriceIds": [fresenius_price_id], "groupPriceStatus": 1 # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# print(result) result = json.loads(result.content) -print(result) file.close() if result["success"]: # 数据库操作 @@ -89,13 +91,15 @@ if result["success"]: group_id) print(sql) result = {"groupPriceStatus": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - print(result) + result["api_time"] = api_time + # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict18") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) else: result = {"success": False, "code": "fresenius_agreement_price", "message": "客户【1071246】商品【14184540】存在效期冲突"} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict180") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" index a123ac7b03710345eaba61a96bff4d5f80a4e63f..39c1a41eb9703857823c6b71f7877331b3e23efa 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\345\215\217\350\256\256\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -36,8 +36,8 @@ group_price = result["data"]["list"][0]["groupPrice"] # print(product_code) # 第三步登录多采商城获取token信息 # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -60,10 +60,13 @@ request_body = commonFuc().get_business_data(module, "payload47", product_code, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # print(result) # 获取商品详情页中套包正价信息 result = {"groupPrice": result["data"][1]["groupPrice"], "documentNo": result["data"][1]["documentNo"]} +result["api_time"] = api_time # print(result) # # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict48", group_price, document_no) diff --git "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" index 64d9546c981b39826165ed9d63f577bc525a2574..3cc32404ab3e1bd7adbf5e2345784d0b44f6415c 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\345\245\227\345\214\205\346\255\243\344\273\267\346\230\276\347\244\272\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -36,8 +36,8 @@ group_price = result["data"]["list"][0]["groupPrice"] # 第三步登录多采商城获取token信息 # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -60,11 +60,13 @@ request_body = commonFuc().get_business_data(module, "payload47", product_code, # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取商品详情页中套包正价信息 result = {"groupPrice": result["data"][1]["groupPrice"], "groupName": result["data"][1]["groupName"]} - +result["api_time"] = api_time # # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict47", group_price, group_name) # # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.py" index 661051394848145fb3e195d6f0236e9c6569d538..c63d51bd8452e8edc1753403e0a3ed457ffdce6a 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.air/\345\225\206\345\223\201\350\257\246\346\203\205\351\241\265_\347\211\271\344\273\267\345\215\225\345\223\201\346\230\276\347\244\272\351\252\214\350\257\201.py" @@ -15,8 +15,8 @@ import json module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -34,8 +34,8 @@ company_code = result["data"]["list"][0]["companyCode"] print(product_code) # 第三步登录多采商城获取token信息 # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -53,16 +53,18 @@ request_body = commonFuc().get_business_data(module, "payload41", product_code, """ 场景:验证特价单品详情页特价信息展示是否正确 用例名称:验证商品详情页面特价单品的展示 - 输出:{"activityName":"每只特价101元,有效期2023-11-09至2031-12-31"} + 输出:{"activityName":"每支特价11.11元,有效期2024-02-11至2036-03-29"} """ # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取活动信息 result = {"activityName": result["data"][0]["activityName"]} - +result["api_time"] = api_time # # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict41") # # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 0c962c79dafd7ecafce3523fd9816530df38ea5d..fd773428fc2c96ddc6b6d6217c88037a91a71638 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\201\234\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -46,6 +46,8 @@ request_body = {"groupIds": [group_id], "type": 1, "remarks": "验证套包停 # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -54,7 +56,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.py" index 1f7acf9c7e1d68703164ad687c1af54bd3d1140a..9b77faa02a9fd4865cbbcc8cd5285108273ae917 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\345\215\217\350\256\256\347\211\271\344\273\267\346\237\245\350\257\242.py" @@ -33,11 +33,13 @@ request_body = commonFuc().get_business_data(module, "payload03") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包协议特价总数量 result = {"total": result["data"]["total"]} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 86ebf2731c7b25270d8862c3850fab929ee595b6..b26e423bf2e0830b1f46ee50bdcd8a3029e11db0 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\345\245\227\345\214\205\345\220\257\347\224\250_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -16,8 +16,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -47,6 +47,8 @@ request_body = {"groupIds": [group_id], "type": 0, "remarks": ""} # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -55,7 +57,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取 # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6") diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.air/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.air/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.py" index 75c94380b9805c1e54934e8ff1b493ed58865655..6b6b13011221454052649899d622691270e205a1 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.air/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.air/\345\245\227\345\214\205\345\225\206\345\223\201\346\226\260\345\242\236.py" @@ -39,6 +39,8 @@ request_body = commonFuc().get_business_data(module, "payload5", group_name, qua # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -47,7 +49,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包正价数量 sql = "SELECT t.groupName FROM `cmdc-order`.tc_fresenius_group t ORDER BY createTime DESC LIMIT 1" result = {"groupName": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} -# 获取 +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict5", group_name) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" index b5ec7b8e8db5b1a2ca6daf853cf1e4e4d6a37d3f..8367586bff7566ea5f79cef6aba6ec46d2bb6edd 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.air/\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201.py" @@ -69,11 +69,13 @@ request_body = commonFuc().get_business_data(module, "payload9", group_code, gro # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包code result = {"groupCode": result["data"]["list"][0]["groupCode"]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", group_code) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.py" index dce22c61855d934fde9a3fa3dacff1a608a17861..52e36424e3d707c042dcb67355cd9df631ef9b63 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267_\346\214\207\345\256\232\345\256\242\346\210\267\346\237\245\350\257\242.py" @@ -33,11 +33,14 @@ request_body = commonFuc().get_business_data(module, "payload4") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包正价_指定客户总数量 result = {"total": result["data"]["total"]} -print(result) +result["api_time"] = api_time +# print(result) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -47,7 +50,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") sql = "SELECT t.groupId FROM `cmdc-order`.tc_fresenius_agreement_price t " \ "WHERE isRegularPrice = 2 and groupPriceStatus = 1 and companyCode = 00111" total = len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)) -print(total) +# print(total) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2", total) # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.py" "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.py" index 791180e6c16837dab97c3d035b77ac916619b481..7f9b1ff32307b6f4b6f3ae26ef6479305e2d0e1d 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.air/\345\245\227\345\214\205\346\255\243\344\273\267\346\237\245\350\257\242.py" @@ -33,11 +33,13 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 获取套包正价总数量 result = {"total": result["data"]["total"]} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_special_fresenius_group/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.air/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.air/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.py" index c3562a6976c43ef6d2577e0c270edff32182af58..ab91a7aa6d3f91303e503c953a0488238a528039 100644 --- "a/air_case/cmdc_special_fresenius_group/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.air/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.air/\345\256\241\346\240\270\350\212\202\347\202\271_\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\346\213\246\346\210\252\351\252\214\350\257\201.py" @@ -35,8 +35,10 @@ request_body = commonFuc().get_business_data(module, "payload45") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict45") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 144667d7e21216becdc232c89fceeba8b9725c74..b3aa3b1b990554a35ee55044e99e7e73a62c1679 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -19,8 +19,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -76,9 +76,14 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time + file.close() -print(result) +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.py" "b/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.py" index 23b94420003850eb0d51049faa9ceb9111e38bf4..1d5ac86afaa27773d0ec8eae0384336625c71b6b 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.air/\346\211\271\351\207\217\346\226\260\345\242\236_\345\245\227\345\214\205\346\255\243\344\273\267.py" @@ -68,12 +68,17 @@ files = {"file": file} 用例名称:批量新增_套包商品管理 输出:{"success":true,"code":"200","message":"OK","data":{"success":true},"freshToken":null} """ -print(headers) +# print(headers) # 发送请求 result = requests.post(url, files=files, headers=headers) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time + file.close() -print(result) +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict12") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 4c4db666f5d3a08bfe3dd932371dd5f521528316..b34ef1bc741e00f973fb84569d188311746ebade 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\345\201\234\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -63,11 +63,16 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) + +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + file.close() # 截取结果中errList信息 result = {"errList": result["data"]["errMsg"]["errList"]} -print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 err_list = "平台套包编号【{}】 在待停用记录里不存在!".format(group_code) check_dict = commonFuc().get_business_data(module, "checkDict11", err_list) diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 4e74f46b747baa9e3764867e83ac162fe4ad15cf..ffa8ba408216e03a111b5cff31af94a5ad3c3e06 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250_\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -63,11 +63,13 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) file.close() # 截取结果中errList信息 result = {"errList": result["data"]["errMsg"]["errList"]} - +result["api_time"] = api_time # 获取预期结果 err_list = "平台套包编号【{}】 在待停用记录里不存在!".format(group_code) check_dict = commonFuc().get_business_data(module, "checkDict11", err_list) diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" index 8b95aad85ec309c671a9365a0f808bb052a83973..e11df3f590bffe445f3dacd0a4147fd32654e422 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\201\234\347\224\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -72,8 +72,10 @@ request_body = {"groupIds": [group_id], "type": 1, "remarks": "验证套包停 # 发送请求 result = requests.post(url, headers=headers, json=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -82,7 +84,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 22c47770a6b7daf0446a52b43dafea5327b6e336..13727f51e0c23c9452d2acf92add800c924e1a80 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -61,11 +61,14 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) file.close() # 截取结果中errList信息 result = {"errList": result["data"]["errMsg"]["errList"]} - +result["api_time"] = api_time # 获取预期结果 err_list = "平台套包编号【{}】 在待启用记录里不存在!".format(group_code) check_dict = commonFuc().get_business_data(module, "checkDict11", err_list) diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index cf671a016b2249f25ecb5afaad40e63aa075ac7a..5a55de68d98d91673807f87d82118ad36b250750 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250_\345\220\257\347\224\250\345\267\262\345\220\257\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -61,11 +61,14 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers, data=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) file.close() # 截取结果中errList信息 result = {"errList": result["data"]["errMsg"]["errList"]} - +result["api_time"] = api_time # 获取预期结果 err_list = "平台套包编号【{}】 在待启用记录里不存在!".format(group_code) check_dict = commonFuc().get_business_data(module, "checkDict11", err_list) diff --git "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.py" index ccfe6b57774e08250f32210d9e2326a082867797..9cff56ecdcf931cb50736002c85232e8d3f4270f 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.air/\346\214\211\346\235\241\344\273\266\345\220\257\347\224\250\351\252\214\350\257\201.py" @@ -72,6 +72,8 @@ request_body = {"groupIds": [group_id], "type": 0, "remarks": ""} # 发送请求 result = requests.post(url, headers=headers, json=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) # 数据库操作 @@ -82,7 +84,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict6") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.air/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.air/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.py" index a9d7a13484569a839f2ced5d8433a90920f7ba31..8d9ea61b3309de26af39d9c3dbf7efeaae5fe5f4 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.air/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.air/\346\226\260\350\200\201\345\225\206\345\223\201\345\205\263\347\263\273\347\274\226\347\240\201\347\273\264\346\212\244\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -47,8 +47,11 @@ request_body = {"manufacturerGroupName": "", "manufacturerGroupCode": "", "group # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -print(result) +result["api_time"] = api_time +# print(result) if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict20") diff --git "a/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..9caaca7386a2f9a1f6fe7b197550b32e682e0eef --- /dev/null +++ "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\346\226\260\350\200\201\347\274\226\347\240\201\346\233\277\346\215\242\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,77 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc新老编码替换明细导出验证,2264,2264-79,sit,bs +主数据平台:运营后台管理系统新老商品编码替换明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_special_fresenius_group" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步新老编码替换列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_product_code") +request_body = commonFuc().get_business_data(module, "payload_product_code") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +dis_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取商品新老编码替换信息 +group_code = result["data"]["list"][dis_random]["groupCode"] +product_code = result["data"]["list"][dis_random]["products"][0]["productCode"] +productLineName = result["data"]["list"][dis_random]["productLineName"] +# 第三步进行商品新老编码明细导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url60") +request_body = commonFuc().get_business_data(module, "payload60", productLineName) + +""" + 场景: 验证商品新老编码替换列表明细导出接口联通性以及数据的正确性 + 用例名称:新老编码替换明细导出验证 + 输出:{"productLineName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/新老商品编码关系导出明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中子需求单 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"productLineName": excel.read_data()[0].get("产品线")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict60", productLineName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.air/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.py" "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.air/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.py" index c1595cbf8eda536619c692edd69f1cae1c601ceb..6c431bc73a21e71c9a96d9b13a7027ccad8586ee 100644 --- "a/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.air/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.py" +++ "b/air_case/cmdc_special_fresenius_group/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.air/\346\226\260\350\200\201\347\274\226\347\240\201\347\273\204\345\201\234\347\224\250.py" @@ -16,8 +16,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers2", cmdc_access_token) @@ -45,6 +45,9 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, # 发送请求 result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) # 数据库操作 @@ -55,7 +58,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict21") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.py" "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.py" index f471a0b2a473e16144d2f90d555bd41ef6c5de65..d81ac62015abf76ccc04a28711de29016f6f53ef 100644 --- "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.py" +++ "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\210\233\345\273\272\351\234\200\346\261\202\345\215\225.py" @@ -15,8 +15,8 @@ import json module = "cmdc_special_fresenius_group" # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -33,14 +33,18 @@ request_body = commonFuc().get_business_data(module, "payload46") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) +print(result) # 获取创建需求成功后需求单信息 -demand_parent_code = result["data"]["国药集团上海医疗器械有限公司"]["demandParentCode"] -demand_parent_id = result["data"]["国药集团上海医疗器械有限公司"]["demandParentId"] +demand_parent_code = result["data"]["国药集团联合医疗器械有限公司"]["demandParentCode"] +demand_parent_id = result["data"]["国药集团联合医疗器械有限公司"]["demandParentId"] # 实际结果 result = {"demandParentCode": demand_parent_code} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -52,6 +56,6 @@ sql = "SELECT t.demandParentCode FROM `cmdc-order`.tc_demand t WHERE demandParen # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict46", mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]) -print(check_dict) +# print(check_dict) # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.py" "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.py" index 32fa8150051cb888780f1cb4e08383008453bdf7..98fba24bb3ff5c5899f8aa666874326b9ba9a5f6 100644 --- "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.py" +++ "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.air/\347\211\271\344\273\267\345\215\225\345\223\201_\345\212\240\345\205\245\350\264\255\347\211\251\350\275\246_\350\264\255\347\211\251\350\275\246\345\261\225\347\244\272.py" @@ -39,21 +39,26 @@ request_body = commonFuc().get_business_data(module, "payload43") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) -print(result) +# print(result) +result["api_time"] = api_time +# print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict43") # # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) # 查询购物车列表 -# 进行站点切换 url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_buyercart") request_body = commonFuc().get_business_data(module, "payload_buyercart") # 发送请求 result = requests.post(url, json=request_body, headers=headers) result = json.loads(result.content) -print(result) +# print(result) + # 过滤查找添加的单品 for i in result["data"]["list"]: @@ -62,7 +67,8 @@ for i in result["data"]["list"]: if j["buyerCartId"] == 19177: result = {"groupPrice": j["groupPrice"], "timeStr": j["timeStr"], "documentNo": j["documentNo"], "buyCartNum": 5} - print(result) + + # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict_buyercart") # # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.py" index 172cc458dec85c6eee919356de9b7e1e771b3b84..f40784057cf65c75317b4686ee6f51269a1b4b4e 100644 --- "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201_\351\231\220\350\264\255\351\252\214\350\257\201.py" @@ -16,8 +16,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -45,12 +45,18 @@ request_body = commonFuc().get_business_data(module, "payload42", fresenius_pric # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) +result["api_time"] = api_time + # 进行相应判断,当success为true时,说明超限额,否则未超限额 if result["success"]: # 获取结果中限购数量 result = {"purchaseQuantity": result["data"]["purchaseQuantity"]} + result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict42") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.py" index dcfadcc1db1801be3b6f6042dd8f319dbc29ce8b..a5655fe5692a4a5260888476181b7e2d2525b7ee 100644 --- "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -19,8 +19,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录后台运营平台获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username1") -password = commonFuc().get_business_data(module, "password1") +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcDoLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -83,7 +83,12 @@ request_body = {"manufacturerGroupName": "", "manufacturerGroupCode": "", "group # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + +result["api_time"] = api_time + # print(result) if result["success"]: # 数据库操作 @@ -94,10 +99,12 @@ if result["success"]: # 数据库查询新增特价单品 sql = "SELECT t.groupId FROM `cmdc-order`.tc_fresenius_agreement_price t " \ "WHERE customerCode = {} and documentNo = '{}';".format(customer_code, ref_random) - print(sql) + # print(sql) total = len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)) result = {"total": total} + result["api_time"] = api_time + # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict17") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.py" "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.py" index 35de927045d73a6c94d7084d860727f4ad9fad6e..29f7dd7fe92121c9e0737ddbe3bce0883199ed8c 100644 --- "a/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_special_fresenius_group/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.air/\347\211\271\344\273\267\345\215\225\345\223\201\346\237\245\350\257\242.py" @@ -36,6 +36,9 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) # 获取特价单品总数量 @@ -49,6 +52,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询特价单品数量 sql = "SELECT t.groupId FROM `cmdc-order`.tc_fresenius_group t WHERE groupType = 1 and companyCode = 00111;" total = len(mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1", total) diff --git "a/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" "b/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" index 4bf17b81570255a9741eb535229db35de62e23e6..908951f2418f977c772fc19161e5d35277f84876 100644 --- "a/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\256\242\346\210\267\345\210\227\350\241\250.py" @@ -32,8 +32,12 @@ request_body = commonFuc().get_business_data(module, "customer_payload") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict15") # 断言实际结果中是否包含预期结果的内容 diff --git "a/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.py" "b/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.py" index 8d73529133237d3ca474b3b9e522ec223eef1742..c95e6b3c27d3ab68601f0a4295750f4c482c7fb0 100644 --- "a/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.py" +++ "b/air_case/cmdc_special_fresenius_group/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\271\346\256\212\345\245\227\345\214\205\350\257\246\346\203\205.py" @@ -15,8 +15,8 @@ module = "cmdc_special_fresenius_group" # 第一步登录多采商城获取cmdc_access_token # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -39,11 +39,16 @@ request_body = commonFuc().get_business_data(module, "payload38") # 发送请求 result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + result = json.loads(result.content) -print(result) -result = {"productCode": result["data"][0]["productCode"]} +# print(result) +# result = {"productCode": result["data"][0]["productCode"]} + +result["api_time"] = api_time + # 获取预期结果 -check_dict = commonFuc().get_business_data(module, "checkDict38") +check_dict = commonFuc().get_business_data(module, "checkDict38_1") # 断言实际结果中是否包含预期结果的内容 commonFuc().check_result(check_dict, result) - diff --git "a/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.py" "b/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.py" index 1415d6df3c6336f40d187d28ec4670c5ab8dde3b..1a9c2dbcc7cb54c1ec47b5c605e5a8f069cf6f28 100644 --- "a/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.py" +++ "b/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.air/\351\252\214\350\257\201\345\201\234\347\224\250\350\215\211\347\250\277\347\212\266\346\200\201\347\232\204\345\245\227\345\214\205.py" @@ -57,6 +57,8 @@ request_body = {"groupIds": [group_id], "type": 1} # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -65,7 +67,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} - +result["api_time"] = api_time # 获取 # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7") diff --git "a/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" "b/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" index 56d3f4a17568d3d61cde754a074c17bdae6a1724..cd29bc1cdae2c94bba7e4e73334e33213242c175 100644 --- "a/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" +++ "b/air_case/cmdc_special_fresenius_group/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.air/\351\252\214\350\257\201\345\220\257\347\224\250\345\267\262\345\201\234\347\224\250\347\232\204\345\245\227\345\214\205_\345\245\227\345\214\205\345\225\206\345\223\201\347\256\241\347\220\206.py" @@ -46,6 +46,9 @@ request_body = {"groupIds": [group_id], "type": 0, "remarks": ""} # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 @@ -54,6 +57,7 @@ host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 数据库查询套包状态 sql = "SELECT t.status FROM `cmdc-order`.tc_fresenius_group t WHERE groupId = {}".format(group_id) result = {"status": mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0]} +result["api_time"] = api_time # 获取 # 获取预期结果 diff --git "a/air_case/cmdc_trade/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.py" index 1b0f1c1210fba92cc9c540dcb62481a389c4badc..363030ce8a5c10056164ee7a633a2ba51675db4f 100644 --- "a/air_case/cmdc_trade/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_trade/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.air/\344\270\212\344\274\240\345\233\276\347\211\207\351\231\204\344\273\266\346\216\245\345\217\243\351\252\214\350\257\201.py" @@ -42,7 +42,10 @@ files = {"file": file} # 发送请求 result = requests.post(url, files=files, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_trade/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" index f3e13e4ac7093c0424a3fd7bbeafe854b9c72fb1..e66a17c8c01ce604a5d0a9bcc06d1ebeac09cd73 100644 --- "a/air_case/cmdc_trade/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_trade/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\345\215\225\346\215\256\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" @@ -48,6 +48,8 @@ request_body = commonFuc().get_business_data(module, "payload10", demand_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) # result = json.loads(result.content) # print(result) @@ -62,7 +64,7 @@ with open(file_path, 'wb') as f: # 获取文件中订单编号 excel = HandleExcel(file_path, "Sheet1") result = {"demandCode": excel.read_data()[0].get("订单编号")} - +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict10", demand_code) # print(check_dict) diff --git "a/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..51b975216c80c552655e0bb67dba5de9af1af41d --- /dev/null +++ "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc发货单据导出验证,2294,2294-18,sit,bs +主数据平台:多采商城获取发货单据导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_trade" + +# 第一步登录多采商城获取token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +demand_code = result["data"]["list"][jde_random]["demandCode"] + +# 第三步发货单据导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = commonFuc().get_business_data(module, "payload19", demand_code) +# print(request_body) +""" + 场景: 发货单据导出验证 + 用例名称:发货单据导出验证 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/发货单据列表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中需求单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandCode": excel.read_data()[0].get("子需求单编号")} +result["api_time"] = api_time +# print(result) +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict19", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..d96dd5d1b017572367033ad1dcf2d530bf7badbf --- /dev/null +++ "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\215\225\346\215\256\345\257\274\345\207\272\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" @@ -0,0 +1,71 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc发货单据导出验证_发货单管理,2294,2294-30,sit,bs +主数据平台:后台运营平台发货单据导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers_file", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 生成随机数 +out_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +demand_code = result["data"]["list"][out_random]["demandCode"] + +# 第三步发货单据导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url30") +request_body = commonFuc().get_business_data(module, "payload30", demand_code) + +""" + 场景: 发货单据导出验证_发货单管理 + 用例名称:发货单据导出验证_发货单管理 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/导出发货单据列表.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中demandCode +excel = HandleExcel(file_path, "工作表1") +# print(excel.read_data()) +result = {"demandCode": excel.read_data()[0].get("子需求单编号")} +# print(result) +result["api_time"] = api_time +# print(result) +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict30", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..2832bb64bb9696e92d309562c9e3d3be9a69e869 --- /dev/null +++ "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.air/\345\217\221\350\264\247\345\220\214\346\255\245_\345\217\221\350\264\247\345\215\225\347\256\241\347\220\206.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc发货同步_发货单管理,2294,2294-32,sit,bs +主数据平台:后台运营系统发货同步接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步发货同步 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") +request_body = commonFuc().get_business_data(module, "payload31") +# print(request_body) +""" + + 场景: 验证发货同步接口连通性 + 用例名称:发货同步_发货单管理 + 输出:{"success":true,"code":"200","message":null,"data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 将获取到接口响应时间添加至result中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict31") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.air/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.air/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..088e5785f80c554e66d42612cf1a767b9396e0df --- /dev/null +++ "b/air_case/cmdc_trade/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.air/\345\217\221\350\264\247\345\225\206\345\223\201\346\270\205\345\215\225\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\350\257\246\346\203\205.py" @@ -0,0 +1,93 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc发货商品清单查询条件验证_发货详情,2294,2294-29,sit,bs +主数据平台:后台运营系统获取发货单详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 生成随机数 +out_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +SDDOCO = func(result["data"]["list"][out_random]["SDDOCO"]) +demandCode = result["data"]["list"][out_random]["demandCode"] +sddcto = result["data"]["list"][out_random]["sddcto"] + +# 第三步获取发货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") +request_body = commonFuc().get_business_data(module, "payload26", demandCode, SDDOCO, sddcto) +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) +# print(result) +# 获取随机数 +product_random = random.randint(0, len(result["data"]) - 1) +# 获取商品信息 +manufacturer = func(result["data"][product_random]["manufacturer"]) +materialCode = func(result["data"][product_random]["materialCode"]) +productCode = func(result["data"][product_random]["productCode"]) +productName = func(result["data"][product_random]["productName"]) +optionStr = func(result["data"][product_random]["optionStr"]) + +# 第四步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") +request_body = commonFuc().get_business_data(module, "payload28", manufacturer, materialCode, productCode, productName, + optionStr, + demandCode, SDDOCO, sddcto) +# print(request_body) +""" + + 场景: 发货商品清单查询条件验证_发货详情 + 用例名称:发货商品清单查询条件验证_发货详情 + 输出:{"productCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取productCode +result = {"productCode": result["data"][0]["productCode"]} + +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict28", productCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..0272ebc4f7f463f1d5283cc50b70488b1bdece96 --- /dev/null +++ "b/air_case/cmdc_trade/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\270\212\346\212\245\344\277\241\346\201\257\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc库存上报信息导出验证,2294,2294-42,sit,be +主数据平台:多采商城库存上报信息导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取库存上报列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") +request_body = commonFuc().get_business_data(module, "payload38") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +stock_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取库存上报信息 +statistic_year = result["data"]["list"][stock_random]["statisticYear"] + +# 第三步进行库存信息导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url41") +request_body = commonFuc().get_business_data(module, "payload41", statistic_year) +# print(request_body) +""" + + 场景: 库存上报信息导出验证 + 用例名称:库存上报信息导出验证 + 输出:{"statisticYear":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/库存上报明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中库存信息所属年份 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"statisticYear": excel.read_data()[0].get("所属年度")} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict41", statistic_year) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..44e2fd3ee4b4516ed27425c73b30e768c8007684 --- /dev/null +++ "b/air_case/cmdc_trade/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/\345\272\223\345\255\230\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,78 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc库存信息修改功能验证,2294,2294-41,sit,be +主数据平台:多采商城库存信息修改接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import random +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取库存上报列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") +request_body = commonFuc().get_business_data(module, "payload38") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +stock_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取库存上报信息 +source = result["data"]["list"][stock_random]["source"] +statistic_inv_report_id = result["data"]["list"][stock_random]["statisticInvReportId"] +inventory_cost_amount = random.randint(100, 10000) + +# 第三步进行库存信息修改 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40") +request_body = commonFuc().get_business_data(module, "payload40", statistic_inv_report_id, inventory_cost_amount, + source) +# print(request_body) +""" + + 场景: 库存信息修改功能验证 + 用例名称:库存信息修改功能验证 + 输出:{"inventoryCostAmount":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库中库存信息对应的库存数量 +sql = "SELECT t.inventoryCostAmount FROM `cmdc-cms`.cms_statistic_invreport t WHERE statisticInvReportId = {}".format( + statistic_inv_report_id) +amount = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 断言结果 +result = {"inventoryCostAmount": int(amount)} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict40", inventory_cost_amount) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" "b/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" new file mode 100644 index 0000000000000000000000000000000000000000..09ed2ad8db88c862bd21384dc9866283d84bb80d --- /dev/null +++ "b/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段校验_获取发货单号,2294,2294-17,sit,bs +主数据平台:多采商城获取发货单号接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单对应的发货单号 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17") + +""" + + 场景: 验证获取发货单号接口字段必填性校验 + 用例名称:必传字段校验_获取发货单号 + 输出:{"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict17") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..49a778826a53f1e2ff1006a5fab29f10309f402f --- /dev/null +++ "b/air_case/cmdc_trade/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\345\277\205\344\274\240\345\255\227\346\256\265\346\240\241\351\252\214_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必传字段校验_获取物流详情,2294,2294-14,sit,bs +主数据平台:多采商城获取物流详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取物流详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14") + +""" + + 场景: 必传字段校验_获取物流详情 + 用例名称:必传字段校验_获取物流详情 + 输出:{"success":false,"code":"ERROR","message":"单号必传","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..3b6ffeb89efcf4e0003825375f8d64d618645196 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_发票清单列表,2294,2294-37,sit,be +主数据平台:多采商城获取发票清单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import datetime +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发票清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +invoice_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发票信息 +invoice_no = result["data"]["list"][invoice_random]["invoiceNo"] +invoice_time_begin = result["data"]["list"][invoice_random]["invoiceTime"].replace("/", "-") + " 00:00:00" +invoice_time_end = datetime.datetime.now().strftime("%Y-%m-%d 23:59:59") +company_ode = result["data"]["list"][invoice_random]["companyCode"] +demand_parent_code = result["data"]["list"][invoice_random]["demandParentCode"] + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url36") +request_body = commonFuc().get_business_data(module, "payload36", invoice_no, invoice_time_begin, invoice_time_end, + company_ode, demand_parent_code) + +""" + + 场景: 查询条件验证_发票清单列表 + 用例名称:查询条件验证_发票清单列表 + 输出:{"invoiceNo":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取查询结果中invoiceNo +result = json.loads(result.content) +result = {"invoiceNo": result["data"]["list"][0]["invoiceNo"]} + +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict36", invoice_no) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..53f44fd1581b9c8d869436b14d2cd37324b3d2d2 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,85 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_发货单列表,2294,2294-27,sit,bs +主数据平台:后台运营系统获取发货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + + +# 此函数用于当x为none时,进行空字符串替换 +def func(x): + if x is None: + x = "" + return x + else: + return x + + +# 生成随机数 +out_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +SDDOCO = func(result["data"]["list"][out_random]["SDDOCO"]) +customerCode = func(result["data"]["list"][out_random]["customerCode"]) +customerName = func(result["data"]["list"][out_random]["customerName"]) +demandCode = func(result["data"]["list"][out_random]["demandCode"]) +productCode = func(result["data"]["list"][out_random]["productCode"]) +optionStr = func(result["data"]["list"][out_random]["optionStr"]) +materialCode = func(result["data"]["list"][out_random]["materialCode"]) +demandParentCode = func(result["data"]["list"][out_random]["demandParentCode"]) +invoiceNo = func(result["data"]["list"][out_random]["invoiceNo"]) +productLineName = func(result["data"]["list"][out_random]["productLineName"]) +sddcto = func(result["data"]["list"][out_random]["sddcto"]) +distributionType = func(result["data"]["list"][out_random]["distributionType"]) +demandSubCode = func(result["data"]["list"][out_random]["demandSubCode"]) + +# 第三步进行条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url27") +request_body = commonFuc().get_business_data(module, "payload27", demandCode, demandParentCode) +# print(request_body) +""" + + 场景: 查询条件验证_发货单列表 + 用例名称:查询条件验证_发货单列表 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +print(result) +# 获取demandCode +result = {"demandCode": result["data"]["list"][0]["demandCode"]} + +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict27", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..2f32a0ed20d53e534d9daaf3bd58410639b599b9 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" @@ -0,0 +1,82 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_发货单物流信息列表,2294,2294-12,sit,bs +主数据平台:多采商城获取发货单物流信息列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import datetime +import random +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +seller_company_code = result["data"]["list"][jde_random]["sellerCompanyCode"] +demand_parent_code = result["data"]["list"][jde_random]["demandParentCode"] +demand_code = result["data"]["list"][jde_random]["demandCode"] +sd_random = random.randint(0, len(result["data"]["list"][jde_random]["SDDOCOList"]) - 1) +sddoco_1 = result["data"]["list"][jde_random]["SDDOCOList"][sd_random][:8] +start_time = result["data"]["list"][jde_random]["createTime"] +end_time = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S") + +# 第三步获取发货单详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13", demand_parent_code) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 获取商品信息 +product_code = result["data"]["detail"][0]["list"][0]["productCode"] +option_str = result["data"]["detail"][0]["list"][0]["optionStr"] + +# 第四步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") +request_body = commonFuc().get_business_data(module, "payload12", demand_parent_code, product_code, end_time, + start_time, end_time, start_time, + demand_code, sddoco_1, option_str) + +""" + + 场景: 查询条件验证_发货单物流信息列表 + 用例名称:查询条件验证_发货单物流信息列表 + 输出:{"demandParentCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取查询结果中demandParentCode +result = {"demandParentCode": result["data"]["list"][0]["demandParentCode"]} + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict12", demand_parent_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e4303ad0401157f24eab323cc71d9ec037c7cd57 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_库存上报列表,2294,2294-40,sit,be +主数据平台:多采商城获取库存上报列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import datetime +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取库存上报列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") +request_body = commonFuc().get_business_data(module, "payload38") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +stock_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取库存上报信息 +source = result["data"]["list"][stock_random]["source"] +statistic_year = result["data"]["list"][stock_random]["statisticYear"] +statistic_month = result["data"]["list"][stock_random]["statisticMonth"] + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url39") +request_body = commonFuc().get_business_data(module, "payload39", source, statistic_year, statistic_month) + +""" + + 场景: 查询条件验证_库存上报列表 + 用例名称:查询条件验证_库存上报列表 + 输出:{"source":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取查询结果中库存上报信息中source +result = json.loads(result.content) +result = {"source": result["data"]["list"][0]["source"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict39", source) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" index 8800af6b7c5e1a8652c2f2776d221c74e39dc5e1..5ee67fa511de61b40add97ea4fd5134f8f6943e7 100644 --- "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\210\227\350\241\250.py" @@ -65,11 +65,15 @@ request_body = commonFuc().get_business_data(module, "payload7", seller_companyC # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取查询结果中订单编号 result = {"demandCode": result["data"]["list"][0]["demandCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict7", demand_code) # print(check_dict) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" index 52c49409b450d941829cc04d2fe5296d32e1ed34..dea19ee8ef387430507364c2da2d22b5a68b7378 100644 --- "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" @@ -57,11 +57,15 @@ request_body = commonFuc().get_business_data(module, "payload9", demand_code, ma # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取商品行信息中商品信息 result = {"productCode": result["data"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict9", product_code) # print(check_dict) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..fd90c7939c25361176aac036cf3b7519c409e705 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_退货单管理,2294,2294-24,sit,bs +主数据平台:多采商城获取退货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取toen信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取退货单管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +code_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取退货单信息 +jde_refund_code = result["data"]["list"][code_random]["jdeRefundCode"] +customer_name = result["data"]["list"][code_random]["customerName"] +manufacturer = result["data"]["list"][code_random]["manufacturer"] +material_code = result["data"]["list"][code_random]["materialCode"] +demand_parent_code = result["data"]["list"][code_random]["demandParentCode"] +start_time = result["data"]["list"][code_random]["submitTime"] +end_time = datetime.datetime.now().strftime("%Y-%m-%d") + +# 第三步获取退货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23", jde_refund_code, + customer_name, manufacturer, material_code, demand_parent_code, start_time, + end_time) + +""" + + 场景: 查询条件验证_退货单管理 + 用例名称:查询条件验证_退货单管理 + 输出:{"jdeRefundCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取详情页中的jdeRefundCode +result = json.loads(result.content) +result = {"jdeRefundCode": result["data"]["list"][0]["jdeRefundCode"]} + +# 将接口响应时间添加到result +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict23", jde_refund_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..1eaae91618325de4178d44aec3770ac3f4541d43 --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_退货记录列表,2294,2294-34,sit,be +主数据平台:多采商城获取退货记录列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import datetime +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取退货记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +refund_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取退货记录信息 +refund_code = result["data"]["list"][refund_random]["refundCode"] +customer_name = result["data"]["list"][refund_random]["customerName"] +return_type = result["data"]["list"][refund_random]["returnType"] +start_time = result["data"]["list"][refund_random]["refundDate"][:10] + " 00:00:00" +end_time = datetime.datetime.now().strftime('%Y-%m-%d') + " 23:59:59" +seller_company_code = result["data"]["list"][refund_random]["sellerCompanyCode"] + +# 第三步进行查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = commonFuc().get_business_data(module, "payload33", refund_code, customer_name, return_type, start_time, + end_time, seller_company_code) +# print(request_body) +""" + + 场景: 查询条件验证_退货记录列表 + 用例名称:查询条件验证_退货记录列表 + 输出:{"refundCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取退货编号 +result = json.loads(result.content) +# print(result) +result = {"refundCode": result["data"]["list"][0]["refundCode"]} +# 将接口响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict33", refund_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..688fa0c2260cecd0c4d4d8711ca9ab18c9784adf --- /dev/null +++ "b/air_case/cmdc_trade/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\347\211\251\346\265\201\344\277\241\346\201\257_\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询物流信息_发票清单列表,2294,2294-38,sit,be +主数据平台:多采商城获取物流信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import datetime +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发票清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +invoice_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发票信息 +invoice_no = result["data"]["list"][invoice_random]["invoiceNo"] + +# 第三步获取物流信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37", invoice_no) + +""" + + 场景: 验证是否可获取到对应的物流信息 + 用例名称:查询物流信息_发票清单列表 + 输出:{"success":true,"code":"200","message":"未查询到数据","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 将接口响应时间添加至result +result["api_time"] = api_time + +if result["data"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict37_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict37") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" "b/air_case/cmdc_trade/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" index 17328dd87e7e5d9d4ae55207fdd949c5de573084..eee1d6c34348b36b1cfd5d7420403d83a10609f9 100644 --- "a/air_case/cmdc_trade/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_trade/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\347\224\250\346\210\267id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" @@ -34,11 +34,14 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url1") # 发送请求 result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取公司数量 result = {"total": len(result["data"])} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_trade/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.py" index 69e6a2ecca0cea72c0417ed167830114328b992e..2be935f1c1a4fc721a24457a14a987d72b364666 100644 --- "a/air_case/cmdc_trade/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.py" +++ "b/air_case/cmdc_trade/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.air/\346\267\273\345\212\240\347\274\272\350\264\247\345\225\206\345\223\201\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -34,7 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload4") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..becca5f6434eb9ff5dbcfba90dec30a13e456a8d --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\205\263\350\201\224\345\215\225\346\215\256\345\233\276\344\277\241\346\201\257_\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取关联单据图信息_发货单详情,2294,2294-31,sit,bs +主数据平台:后台运营系统获取关联单据图信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +out_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +demandCode = result["data"]["list"][out_random]["demandCode"] + +# 第二步获取关联单据图信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url29") +request_body = commonFuc().get_business_data(module, "payload29", demandCode) + +""" + + 场景: 验证获取关联单据图信息接口连通性和数据正确性 + 用例名称:获取关联单据图信息_发货单详情 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 获取关联单据中demandCode +result = {"demandCode": result["data"]["nodes"][0]["demandCode"]} + +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict29", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..4b4fd79b5606927baa9ea7831df288b05905f857 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\347\245\250\346\270\205\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,45 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取发票清单列表,2294,2294-36,sit,be +主数据平台:多采商城获取发票清单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发票清单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35") + +""" + + 场景: 获取发票清单列表 + 用例名称:获取发票清单列表 + 输出:{"success":true,"code":"200","message":"操作成功"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict35") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..efee57ef517ef64fec3c5e0b79dfd26b7b44e21e --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\210\227\350\241\250.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取发货单列表,2294,2294-26,sit,bs +主数据平台:后台运营系统获取发货单列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") + +""" + + 场景: 验证获取发货单列表接口连通性 + 用例名称:获取发货单列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict25") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..6f3d6fb83562ad4b046ea5f84edbc02d1063f335 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267\351\252\214\350\257\201.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取发货单号验证,2294,2294-15,sit,bs +主数据平台:多采商城获取发货单号接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import json + + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(3, len(result["data"]["list"]) - 1) +# 获取发货单信息 +data = [] +demand_code = result["data"]["list"][jde_random]["demandCode"] +for i in result["data"]["list"][jde_random]["SDDOCOList"]: + data.append(i[:8]) + +# 第三步获取发货单对应的发货单号 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") +request_body = commonFuc().get_business_data(module, "payload16", demand_code) + +""" + + 场景: 获取发货单号验证 + 用例名称:获取发货单号验证 + 输出:{"data":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# 获取发货单号 +result = {"data": result["data"]} + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict16", data) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..d6d9595f3fee02d35b44a4b7d7a86b2fb35f2571 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\347\211\251\346\265\201\344\277\241\346\201\257\345\210\227\350\241\250.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取发货单物流信息列表,2294,2294-11,sit,bs +主数据平台:多采商城获取发货单物流信息列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") + +""" + + 场景: 获取发货单物流信息列表 + 用例名称:获取发货单物流信息列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict11") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..e6ef8dd09a2ff713fcc0e338c0b34c092a7c67a2 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,67 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取发货单详情,2294,2294-28,sit,bs +主数据平台:后台运营系统获取发货单详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取token信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取发货单列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +out_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +SDDOCO = result["data"]["list"][out_random]["SDDOCO"] +demandCode = result["data"]["list"][out_random]["demandCode"] +sddcto = result["data"]["list"][out_random]["sddcto"] + + +# 第三步获取发货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") +request_body = commonFuc().get_business_data(module, "payload26", demandCode, SDDOCO, sddcto) +# print(request_body) +""" + + 场景: 获取发货单详情 + 用例名称:获取发货单详情 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +# print(result) +# 获取demandCode +result = {"demandCode": result["data"][0]["demandCode"]} + +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict26", demandCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.py" index f82195f08a66e474ff2de01e7bb0e3e0aa9af6f3..b756a561da03f70c30b731cf54cb767329a52da8 100644 --- "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\267\262\345\217\221\345\270\203\345\225\206\345\223\201\345\210\206\347\261\273\344\277\241\346\201\257.py" @@ -46,11 +46,15 @@ request_body = commonFuc().get_business_data(module, "payload2", company_id) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# print(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取分类数量 result = {"total": len(result["data"])} - +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..fb5db219bfae75f5b4d58787be3ca588f27b331c --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\272\223\345\255\230\344\270\212\346\212\245\345\210\227\350\241\250.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取库存上报列表,2294,2294-39,sit,be +主数据平台:多采商城获取库存上报列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import datetime +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取库存上报列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") +request_body = commonFuc().get_business_data(module, "payload38") + +""" + + 场景: 获取库存上报列表 + 用例名称:获取库存上报列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) + +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict38") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.air/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.air/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.py" new file mode 100644 index 0000000000000000000000000000000000000000..594f9787bbdb76553fd5a0fb09948a236e461c4e --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.air/\350\216\267\345\217\226\346\211\200\345\261\236\347\253\231\347\202\271\345\210\227\350\241\250_\351\207\207\350\264\255\350\256\241\345\210\222.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取所属站点列表_采购计划,2294,2294-45,sit,be +主数据平台:多采商城获取所属站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取所属站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url42") +# request_body = commonFuc().get_business_data(module, "payload42") +# print(request_body) +""" + + 场景: 获取所属站点列表_采购计划 + 用例名称:获取所属站点列表_采购计划 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点数量 +result = json.loads(result.content) +result = {"total": len(result["data"]["procurements"])} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库中站点数量 +sql = "SELECT count(distinct t.companyName) FROM `cmdc-order`.tc_procurement t" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict42", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" index 193e07c5f4539b7aa08a51b21f03a53545e61135..b822382fca16565d0c2ef11a4bc8fefb31561028 100644 --- "a/air_case/cmdc_trade/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.air/\350\216\267\345\217\226\346\254\240\350\264\247\345\225\206\345\223\201\350\241\214\344\277\241\346\201\257.py" @@ -48,11 +48,15 @@ request_body = commonFuc().get_business_data(module, "payload8", demand_code) # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) + # print(result) # 获取商品行信息中商品信息 result = {"productCode": result["data"][0]["productCode"]} +result["api_time"] = api_time # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict8", product_code) # print(check_dict) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..c6373d5a5c00bb4a79f6a04ac9090a236c0a23b9 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取物流详情,2294,2294-13,sit,bs +主数据平台:多采商城获取物流详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取订单信息 +demand_parent_code = result["data"]["list"][jde_random]["demandParentCode"] +demand_parent_code = "s2401041500004" +demand_code = result["data"]["list"][jde_random]["demandCode"] +demand_code = "17043524219759578" +# 第三步获取物流详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13", demand_parent_code) + +""" + + 场景: 获取物流详情接口验证 + 用例名称:获取物流详情 + 输出:{"demandCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +print(result) +# 获取物流详情页面中demandParentCode +result = {"demandCode": result["data"]["detail"][0]["demandCode"]} +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13", demand_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.py" index 7bae8fa623f8acd1197a0f99b11b2c1216adbb21..7001a6f2e8a57b184f1ae8627c128ede49913c88 100644 --- "a/air_case/cmdc_trade/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\274\272\350\264\247\345\225\206\345\223\201\345\210\227\350\241\250.py" @@ -15,8 +15,8 @@ import json module = "cmdc_trade" # 第一步获取登录多采商城所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) @@ -34,18 +34,20 @@ request_body = commonFuc().get_business_data(module, "payload5") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) -# 获取分类数量 -result = {"total": len(result["data"]["list"])} +# 获取缺货商品数量 +result = {"total": result["data"]["total"]} +result["api_time"] = api_time # 数据库操作 mysql_handle = mySql() # 获取conf.ini文件中配置的数据库信息 host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") # 查询数据库中缺货商品数量 -sql = "SELECT count(t.id) FROM `cmdc-user`.cmdc_stock_out t WHERE userId = 69" +sql = "SELECT count(t.id) FROM `cmdc-user`.cmdc_stock_out t WHERE userId = 124100" total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] # 获取预期结果 diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.py" index 97e360b330f22f18a2b7f777f88a9c14bd85366c..2cf98f2837a75feadadad46250e38948505238f4 100644 --- "a/air_case/cmdc_trade/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.py" +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\256\242\345\215\225\346\254\240\350\264\247\345\210\227\350\241\250.py" @@ -33,7 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload6") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..3185b96f66d6e14096e95fc8818b08e62338035d --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\347\256\241\347\220\206\345\210\227\350\241\250.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取退货单管理列表,2294,2294-23,sit,bs +主数据平台:多采商城获取退货单管理列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取toen信息 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取退货单管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22") + +""" + + 场景: 验证获取退货单管理列表接口连通性 + 用例名称:获取退货单管理列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict22") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..3e26e5e1b0a7834ce2c44243e14265874bbaee12 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\345\215\225\350\257\246\346\203\205.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取退货单详情,2294,2294-25,sit,bs +主数据平台:后台运营系统获取退货单详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_trade" + +# 第一步登录后台运营系统获取toen信息 +username = commonFuc().get_business_data(module, "username4") +password = commonFuc().get_business_data(module, "password4") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取退货单管理列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +code_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取退货单信息 +jde_refund_code = result["data"]["list"][code_random]["jdeRefundCode"] + +# 第三步获取退货单详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") +request_body = commonFuc().get_business_data(module, "payload24", jde_refund_code) + +""" + + 场景: 验证获获取退货单详情 + 用例名称:获取退货单详情 + 输出:{"jdeRefundCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取详情页中的jdeRefundCode +result = json.loads(result.content) +result = {"jdeRefundCode": result["data"]["list"][0]["jdeRefundCode"]} + +# 将接口响应时间添加到result +result["api_time"] = api_time +# print(result) + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict24", jde_refund_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..32546f18289d8452191b3339ad441fdbb8224bf7 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\345\210\227\350\241\250.py" @@ -0,0 +1,45 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取退货记录列表,2294,2294-33,sit,be +主数据平台:多采商城获取退货记录列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取退货记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32") + +""" + + 场景: 获取退货记录列表 + 用例名称:获取退货记录列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict32") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..ed68fb1d42cc9a9f4c84de0c38e248a2fe163822 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\200\200\350\264\247\350\256\260\345\275\225\350\257\246\346\203\205.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取退货记录详情,2294,2294-35,sit,be +主数据平台:多采商城获取退货记录详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取退货记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +refund_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取退货记录信息 +refund_id = result["data"]["list"][refund_random]["refundId"] + +# 第三步获取退货记录详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url34") +request_body = commonFuc().get_business_data(module, "payload34", refund_id) +# print(request_body) +""" + + 场景: 获取退货记录详情 + 用例名称:获取退货记录详情 + 输出:{"refundId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取退货记录id +result = json.loads(result.content) +# print(result) +result = {"refundId": result["data"]["list"][0]["refundId"]} +# 将接口响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict34", refund_id) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.py" new file mode 100644 index 0000000000000000000000000000000000000000..8c417275f96de5529e249870620ecc843d59ce94 --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\344\277\256\346\224\271\350\256\260\345\275\225.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取采购计划修改记录,2294,2294-48,sit,be +主数据平台:多采商城获取采购计划修改记录接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_trade" + +# # 第一步获取登录多采商城所需账号密码 +# username = commonFuc().get_business_data(module, "username_be") +# password = commonFuc().get_business_data(module, "password_be") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取采购计划修改记录 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44") +request_body = commonFuc().get_business_data(module, "payload44") +# print(request_body) +""" + + 场景: 获取采购计划修改记录 + 用例名称:获取采购计划修改记录 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取采购计划修改记录数量 +result = json.loads(result.content) +result = {"total": len(result["data"])} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库中对应采购计划修改记录数量 +sql = "SELECT count(t.id) FROM `cmdc-order`.tc_procurement_record t WHERE procurementId = 92" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict44", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..d971e820b777928382783f74b011a8a3a2b48c2a --- /dev/null +++ "b/air_case/cmdc_trade/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.air/\350\216\267\345\217\226\351\207\207\350\264\255\350\256\241\345\210\222\350\257\246\346\203\205.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取采购计划详情,2294,2294-46,sit,be +主数据平台:多采商城获取采购计划详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username_be") +password = commonFuc().get_business_data(module, "password_be") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取采购计划详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43") +# print(request_body) +""" + + 场景: 获取采购计划详情 + 用例名称:获取采购计划详情 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +result = json.loads(result.content) +# 获取采购计划id +procurement_id = result["data"]["procurementId"] +# 获取采购计划中商品数量 +result = {"total": len(result["data"]["procurementDetailList"])} + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db_be") + +# 查询数据库中对应采购计划中包含的商品数量 +sql = "SELECT count(t.id) FROM `cmdc-order`.tc_procurement_detail t WHERE procurementId = {}".format(procurement_id) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict43", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" "b/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" new file mode 100644 index 0000000000000000000000000000000000000000..989622c39a20297f7715c6f8af7d6fdc6722c2df --- /dev/null +++ "b/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\345\217\221\350\264\247\345\215\225\345\217\267.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc订单不存在验证_获取发货单号,2294,2294-18,sit,bs +主数据平台:多采商城获取发货单号接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import random +import requests +import json + + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 随机生成不存在的订单信息 +demand_code = random.randint(1, 1000000000000) + +# 第二步获取发货单对应的发货单号 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") +request_body = commonFuc().get_business_data(module, "payload18", demand_code) + +""" + + 场景: 验证获取发货单号接口,当订单不存在时接口是否进行拦截 + 用例名称:订单不存在验证_获取发货单号 + 输出:{"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict18") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" "b/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..2541444f23a1950b06b16458afc964981055db7f --- /dev/null +++ "b/air_case/cmdc_trade/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.air/\350\256\242\345\215\225\344\270\215\345\255\230\345\234\250\351\252\214\350\257\201_\350\216\267\345\217\226\347\211\251\346\265\201\350\257\246\346\203\205.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc订单不存在验证_获取物流详情,2294,2294-15,sit,bs +主数据平台:多采商城获取物流详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取物流详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15") + +""" + + 场景: 订单不存在验证_获取物流详情 + 用例名称:订单不存在验证_获取物流详情 + 输出:{"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 将获取到的响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..ed9a8b451a80cd591116d509baeb2d1aec2d3ac8 --- /dev/null +++ "b/air_case/cmdc_trade/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.air/\350\256\242\345\215\225\345\217\221\350\264\247\346\230\216\347\273\206\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc订单发货明细导出验证,2294,2294-17,sit,bs +主数据平台:多采商城订单发货明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_trade" + +# 第一步登录多采商城获取token +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +demand_parent_code = result["data"]["list"][jde_random]["demandParentCode"] + +# 第三步订单发货明细导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") +request_body = commonFuc().get_business_data(module, "payload20", demand_parent_code) +# print(request_body) +""" + 场景: 订单发货明细导出验证 + 用例名称:订单发货明细导出验证 + 输出:{"demandParentCode":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/订单发货明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中需求单号 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"demandParentCode": excel.read_data()[0].get("母需求单编号\n(商城订单号)")} +# print(result) +result["api_time"] = api_time +# print(result) +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict20", demand_parent_code) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_trade/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" "b/air_case/cmdc_trade/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..6981baa6973f80c24a10a384622ad4ad25d7d0b9 --- /dev/null +++ "b/air_case/cmdc_trade/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.air/\351\232\217\350\264\247\345\220\214\350\241\214\345\215\225\345\257\274\345\207\272\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc随货同行单导出验证,2294,2294-16,sit,bs +主数据平台:多采商城随货同行单导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +from common.handle_excel import HandleExcel +import random +import requests +import json +import os + + +module = "cmdc_trade" + +# 第一步获取登录多采商城所需账号密码 +username = commonFuc().get_business_data(module, "username3") +password = commonFuc().get_business_data(module, "password3") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取发货单物流信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = commonFuc().get_business_data(module, "payload11") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +jde_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取发货单信息 +demand_code = result["data"]["list"][jde_random]["demandCode"] +sd_random = random.randint(0, len(result["data"]["list"][jde_random]["SDDOCOList"]) - 1) +sddoco_1 = result["data"]["list"][jde_random]["SDDOCOList"][sd_random][:8] + + +# 第四步随货同行单导出 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21", demand_code, sddoco_1) + +""" + + 场景: 随货同行单导出验证 + 用例名称:随货同行单导出验证 + 输出:{"so":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/发货单号{}随货同行单导出.xlsx".format(sddoco_1) + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取文件中需求单号 +excel = HandleExcel(file_path, "工作表1") +# print(excel.read_data()) +result = {"so": excel.read_data()[0].get("出库单号:")} +# print(result) +result["api_time"] = api_time +# print(result) +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict21") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_userinfo_query/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.air/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.py" "b/air_case/cmdc_userinfo_query/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.air/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.py" index 568b4f51bbabe9d4323864dcba1aa52eef70a6dd..80338c3cee8d605eb7a45db930581022f57f2bab 100644 --- "a/air_case/cmdc_userinfo_query/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.air/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.py" +++ "b/air_case/cmdc_userinfo_query/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.air/\347\224\250\346\210\267\344\277\241\346\201\257\346\237\245\350\257\242.py" @@ -34,7 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload1") # 发送请求 result = requests.get(url, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict1") diff --git "a/air_case/cmdc_website/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..6bbb0ca970de5e7021f6b379f219af405cea0e9e --- /dev/null +++ "b/air_case/cmdc_website/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.air/a_\347\253\231\347\202\271\346\226\260\345\242\236\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点新增功能验证,2256,2256-8,sit,bs +主数据平台:后台运营系统站点新增功能验证接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步进行站点新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url8") +request_body = commonFuc().get_business_data(module, "payload8") +# print(request_body) +""" + + 场景: 站点新增功能验证 + 用例名称:站点新增功能验证 + 输出:{"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict8") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..cd771b109013160011778a105e7afa3fcef27455 --- /dev/null +++ "b/air_case/cmdc_website/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.air/b_\347\253\231\347\202\271\344\277\241\346\201\257\347\274\226\350\276\221\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,58 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点信息编辑功能验证,2256,2256-9,sit,bs +主数据平台:后台运营系统站点信息编辑接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库新增站点id信息 +sql = "SELECT t.websiteId FROM `cmdc-cms`.cms_website t " \ + "WHERE deleteSign = 0 and supplierSign = 0 and websiteName = '站点新增测试'" +website_id = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 第二步进行站点信息更新操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url9") +request_body = commonFuc().get_business_data(module, "payload9", website_id) + +""" + + 场景: 站点信息编辑功能验证 + 用例名称:站点信息编辑功能验证 + 输出:{"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict9") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" "b/air_case/cmdc_website/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..4dd03b3233df7e6b1af77ecb41ae2cbc7acb4188 --- /dev/null +++ "b/air_case/cmdc_website/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/c_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\274\200\345\220\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点直通车开启_站点管理,2256,2256-10,sit,bs +主数据平台:后台运营系统站点直通车开启接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取站点信息 +website_json = result["data"]["list"][0] + +# 站点开通直通车标识 +pass_sign = 2 + +# 进行站点信息更新操作 +website_json["passSign"] = pass_sign + +# 第三步进行站点开通直通车操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url10") +request_body = website_json +# print(request_body) +""" + + 场景: 站点直通车开启_站点管理 + 用例名称:站点直通车开启_站点管理 + 输出:{"passSign":2} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库对应站点是否开通直通车标识 +sql = "SELECT t.passSign FROM `cmdc-cms`.cms_website t " \ + "WHERE deleteSign = 0 and supplierSign = 0 and websiteName = '站点新增测试'" +result = {"passSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict10") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.air/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.py" "b/air_case/cmdc_website/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.air/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..f3fa5c05afd38b087fdacf50d38a0818ef5f4563 --- /dev/null +++ "b/air_case/cmdc_website/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.air/d_\347\253\231\347\202\271\347\233\264\351\200\232\350\275\246\345\205\263\351\227\255_\347\253\231\347\202\271\347\256\241\347\220\206.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点直通车关闭_站点管理,2256,2256-11,sit,bs +主数据平台:后台运营系统站点直通车关闭接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取站点信息 +website_json = result["data"]["list"][0] + +# 站点关闭直通车标识 +pass_sign = 1 + +# 进行站点信息更新操作 +website_json["passSign"] = pass_sign + +# 第三步进行站点关闭直通车操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url11") +request_body = website_json +# print(request_body) +""" + + 场景: 站点直通车关闭_站点管理 + 用例名称:站点直通车关闭_站点管理 + 输出:{"passSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库对应站点是否开通直通车标识 +sql = "SELECT t.passSign FROM `cmdc-cms`.cms_website t " \ + "WHERE deleteSign = 0 and supplierSign = 0 and websiteName = '站点新增测试'" +result = {"passSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict11") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_website/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..470706030ccb5db22c731dd6b3d96e337592901d --- /dev/null +++ "b/air_case/cmdc_website/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/e_\347\253\231\347\202\271\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,67 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点删除功能验证,2256,2256-12,sit,bs +主数据平台:后台运营系统站点删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_list") +request_body = commonFuc().get_business_data(module, "payload_list") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取站点信息 +website_id = result["data"]["list"][0]["websiteId"] + +# 第三步进行站点关闭直通车操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url12") +request_body = commonFuc().get_business_data(module, "payload12", website_id) +# print(request_body) +""" + + 场景: 站点删除功能验证 + 用例名称:站点删除功能验证 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库对应站点删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-cms`.cms_website t WHERE websiteId = {}".format(website_id) +result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict12") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..4750e04dbb1b614ec480b6af739895020de87b35 --- /dev/null +++ "b/air_case/cmdc_website/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.air/f_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc新增产品线备注功能验证,2256,2256-18,sit,bs +主数据平台:后台运营系统新增产品线备注接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取产品线信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_line") +# 发送请求 +result = requests.get(url) +result = json.loads(result.content) + +# 生成随机数 +line_random = random.randint(0, len(result["data"]) - 1) +# 获取产品信息 +productLineCode = result["data"][line_random]["productLineCode"] + +# 第三步新增产品线备注 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url18") +request_body = commonFuc().get_business_data(module, "payload18", productLineCode) +""" + + 场景: 新增产品线备注功能验证 + 用例名称:新增产品线备注功能验证 + 输出:{"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +if result["success"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict18") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict18_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.air/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.py" "b/air_case/cmdc_website/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.air/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..cadabd6bd5a2667ee4dfcb5d606a7d3277fc7ec8 --- /dev/null +++ "b/air_case/cmdc_website/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.air/g_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244\351\252\214\350\257\201.py" @@ -0,0 +1,68 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点产品线备注设置删除验证,2256,2256-22,sit,bs +主数据平台:后台运营系统站点产品线备注设置删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中新增的产品线备注设置 +sql = "SELECT t.id FROM `cmdc-cms`.cms_line_remark t WHERE remark = '测试勿动'" + +# 判断id是否为空 +id = (mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] if mysql_handle.selectSql(host, port, user, + pwd, "cmdc-cms", + sql) else "") + +# 第二步删除产品线备注设置 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url22") +request_body = commonFuc().get_business_data(module, "payload22", id) +# print(request_body) +""" + + 场景: 站点产品线备注设置删除验证 + 用例名称:站点产品线备注设置删除验证 + 输出:{"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +if result["success"]: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict22") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) +else: + # 获取预期结果 + check_dict = commonFuc().get_business_data(module, "checkDict22_1") + # print(check_dict) + # 断言实际结果中是否包含预期结果的内容 + commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..4c19bc1df9665420ac349c73ae7e87b47e28515d --- /dev/null +++ "b/air_case/cmdc_website/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.air/h_\347\253\231\347\202\271\346\226\260\345\242\236\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点新增客户联系人信息功能验证,2256,2256-27,sit,bs +主数据平台:后台运营系统站点新增客户联系人信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第三步进行客户信息新增操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url27") +request_body = commonFuc().get_business_data(module, "payload27") + +""" + + 场景: 站点新增客户联系人信息功能验证 + 用例名称:站点新增客户联系人信息功能验证 + 输出:{"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict27") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.air/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.py" "b/air_case/cmdc_website/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.air/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..2a9e1f89b18730b5a517fda30d45f0bd0c8f0e46 --- /dev/null +++ "b/air_case/cmdc_website/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.air/i_\350\216\267\345\217\226\347\253\231\347\202\271\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\345\210\227\350\241\250.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点客户联系人列表,2256,2256-28,sit,bs +主数据平台:后台运营系统获取站点客户联系人列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第三步获取站点客户联系人列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") +request_body = commonFuc().get_business_data(module, "payload28") +""" + + 场景: 获取站点客户联系人列表 + 用例名称:获取站点客户联系人列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取客户联系人信息 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点对应的客户联系人信息 +sql = "SELECT count(t.contactId) FROM `cmdc-cms`.cms_contact t WHERE deleteSign = 0 and companyId = 7" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict28", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..7a867b44d91252fbe7eb7e293e0fb7b4d1f4df0a --- /dev/null +++ "b/air_case/cmdc_website/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.air/j_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\344\277\256\346\224\271\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc客户联系人信息修改功能验证,2256,2256-29,sit,bs +主数据平台:后台运营系统客户联系人信息修改接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点客户联系人列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url28") +request_body = commonFuc().get_business_data(module, "payload28") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取客户联系人信息 +name = result["data"]["list"][0]["name"] +telephone = result["data"]["list"][0]["telephone"] +contactId = result["data"]["list"][0]["contactId"] + +# 第三步进行客户联系人信息修改操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url29") +request_body = commonFuc().get_business_data(module, "payload29", name, telephone, contactId) + +""" + + 场景: 客户联系人信息修改功能验证 + 用例名称:客户联系人信息修改功能验证 + 输出:{"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict29") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..96556e73d3acbe65fbecb178c7d7ab1b278d0308 --- /dev/null +++ "b/air_case/cmdc_website/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/k_\345\256\242\346\210\267\350\201\224\347\263\273\344\272\272\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc客户联系人信息删除功能验证,2256,2256-30,sit,bs +主数据平台:后台运营系统客户联系人信息删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests + + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点对应的客户联系人信息 +sql = "SELECT t.contactId FROM `cmdc-cms`.cms_contact t WHERE deleteSign = 0 and companyId = 7 and name = '测试勿动'" +contactId = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 第二步进行客户联系人信息删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url30") +request_body = commonFuc().get_business_data(module, "payload30", contactId) +""" + + 场景: 客户联系人信息删除功能验证 + 用例名称:客户联系人信息删除功能验证 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 查询数据库中站点对应的客户联系人信息删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-cms`.cms_contact t WHERE contactId = {}".format(contactId) +result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict30") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.air/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_website/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.air/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..bc29af45cc95d25b87a33c653ca8aa54def5183c --- /dev/null +++ "b/air_case/cmdc_website/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.air/m_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点退货地址新增验证,2256,2256-31,sit,bs +主数据平台:后台运营系统站点退货地址新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步站点退货地址新增 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url31") +request_body = commonFuc().get_business_data(module, "payload31") +# print(request_body) +""" + + 场景: 站点退货地址新增验证 + 用例名称:站点退货地址新增验证 + 输出:{"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict31") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.air/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.py" "b/air_case/cmdc_website/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.air/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..822e69ceed05496165f26aa26139ab45e01df666 --- /dev/null +++ "b/air_case/cmdc_website/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.air/n_\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\345\210\240\351\231\244\351\252\214\350\257\201.py" @@ -0,0 +1,58 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点退货地址删除验证,2256,2256-32,sit,bs +主数据平台:后台运营系统站点退货地址删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点退货地址信息 +sql = "SELECT t.returnAddressId FROM `cmdc-user`.cmdc_return_address t " \ + "WHERE receiverName = '测试勿动' and companyCode = 00102" +id = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 第二步进行站点退货地址删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url32") +request_body = commonFuc().get_business_data(module, "payload32", id) +""" + + 场景: 站点退货地址删除验证 + 用例名称:站点退货地址删除验证 + 输出:{"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict32") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.air/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_website/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.air/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..ff1b97924b3ea4b11f0bb2b6f93ed41ba715700d --- /dev/null +++ "b/air_case/cmdc_website/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.air/o_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc公司基础配置信息新增验证,2256,2256-36,sit,bs +主数据平台:后台运营系统公司基础配置信息新增验证接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步公司基础配置信息新增验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url38") +request_body = commonFuc().get_business_data(module, "payload38") +# print(request_body) +""" + + 场景: 公司基础配置信息新增验证 + 用例名称:公司基础配置信息新增验证 + 输出:{"success":true,"code":"200","message":"OK","data":"success","freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict38") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..1af6fa3c4d90ea6777a7d6cd2a8ac5a1a14dae78 --- /dev/null +++ "b/air_case/cmdc_website/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.air/p_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,66 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc公司基础信息删除功能验证,2256,2256-40,sit,bs +主数据平台:后台运营系统公司基础信息删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取公司基础配置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40_1") +request_body = commonFuc().get_business_data(module, "payload40_1") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 获取公司配置信息 +configId = result["data"]["list"][0]["configId"] + +# 第三步公司基础信息删除操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url40") +request_body = commonFuc().get_business_data(module, "payload40", configId) + +""" + 场景: 公司基础信息删除功能验证 + 用例名称:公司基础信息删除功能验证 + 输出:{"deleteSign":1} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) +result = json.loads(result.content) + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中公司对应的删除标识 +sql = "SELECT t.deleteSign FROM `cmdc-user`.cmdc_jde_config t WHERE configId = {}".format(configId) +result = {"deleteSign": mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict40") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" "b/air_case/cmdc_website/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" new file mode 100644 index 0000000000000000000000000000000000000000..b4ac2e37f2b27cf34a91842010477017526a0822 --- /dev/null +++ "b/air_case/cmdc_website/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\344\274\240\345\217\202\346\227\240\346\225\210\346\200\247\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" @@ -0,0 +1,51 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc传参无效性校验_公司基础信息删除,2256,2256-42,sit,bs +主数据平台:后台运营系统公司基础信息删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 随机生成configId +config_id = random.randint(100000000000000, 1000000000000000000) +# 第二步进行公司基础信息删除 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url42") +request_body = commonFuc().get_business_data(module, "payload42", config_id) +# print(request_body) +""" + + 场景: 传参无效性校验_公司基础信息删除 + 用例名称:传参无效性校验_公司基础信息删除 + 输出:{"success":true,"code":"200","message":"OK","data":"fail","freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict42") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..26cb071261561e7e71a6d2605547605e64c3b382 --- /dev/null +++ "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\345\210\227\350\241\250.py" @@ -0,0 +1,69 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_公司基础配置列表,2256,2256-35,sit,be +主数据平台:后台运营系统获取公司基础配置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username_beta") +password = commonFuc().get_business_data(module, "password_beta") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取公司基础配置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url34") +request_body = commonFuc().get_business_data(module, "payload34") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取公司配置信息 +companyCode = result["data"]["list"][company_random]["companyCode"] +companyName = result["data"]["list"][company_random]["companyName"] +settlementType = result["data"]["list"][company_random]["settlementType"] +payMerchantNo = result["data"]["list"][company_random]["payMerchantNo"] +siteType = result["data"]["list"][company_random]["siteType"] +affiliationCode = (result["data"]["list"][company_random]["affiliationCode"] if siteType == 2 else "") + +# 第三步进行列表查询条件核验 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url35") +request_body = commonFuc().get_business_data(module, "payload35", companyCode, companyName, settlementType, + payMerchantNo, + siteType, affiliationCode) + +""" + 场景: 列表查询条件验证_公司基础配置列表 + 用例名称:列表查询条件验证_公司基础配置列表 + 输出:{"companyCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取公司配置信息 +result = json.loads(result.content) +result = {"companyCode": result["data"]["list"][0]["companyCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict35", companyCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..5c17beff295834dfbf4df9a91e5426da1ccfa566 --- /dev/null +++ "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\255\220\347\253\231\347\202\271\345\210\227\350\241\250.py" @@ -0,0 +1,65 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_子站点列表,2256,2256-7,sit,bs +主数据平台:后台运营系统获取子站信息列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import random +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取子站信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取子站点信息 +companyName = result["data"]["list"][company_random]["companyName"] +companyCode = result["data"]["list"][company_random]["companyCode"] + +# 第三步进行列表条件查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url7") +request_body = commonFuc().get_business_data(module, "payload7", companyName, companyCode) + +""" + + 场景: 列表查询条件验证_子站点列表 + 用例名称:列表查询条件验证_子站点列表 + 输出:{"companyCode":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取子站站点信息 +result = json.loads(result.content) +# print(result) +result = {"companyCode": result["data"]["list"][0]["companyCode"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict7", companyCode) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..9d57e667b5e5ae902638b279e8226ae31b8afa16 --- /dev/null +++ "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\345\210\227\350\241\250.py" @@ -0,0 +1,67 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_站点列表,2256,2256-2,sit,bs +主数据平台:后台运营系统获取站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +websiteName = result["data"]["list"][website_random]["websiteName"] +orderApportionPrinciple = result["data"]["list"][website_random]["orderApportionPrinciple"] +companyName = result["data"]["list"][website_random]["companyName"] +companyType = result["data"]["list"][website_random]["companyType"] + +# 第三步进行列表查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url5") +request_body = commonFuc().get_business_data(module, "payload5", websiteName, orderApportionPrinciple, companyName, + companyType) +""" + + 场景: 列表查询条件验证_站点列表 + 用例名称:列表查询条件验证_站点列表 + 输出:{"websiteName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点简称 +result = json.loads(result.content) +# print(result) +result = {"websiteName": result["data"]["list"][0]["websiteName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict5", websiteName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..0ab06a97204fe1fbb955485e8f86563263536c17 --- /dev/null +++ "b/air_case/cmdc_website/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\345\210\227\350\241\250\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" @@ -0,0 +1,74 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc列表查询条件验证_站点资质明细列表,2256,2256-44,sit,bs +主数据平台:后台运营系统获取站点资质明细列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import datetime +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点资质明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点资质信息 +companyName = result["data"]["list"][company_random]["companyName"] +companyType = result["data"]["list"][company_random]["companyType"] +companyProperty = result["data"]["list"][company_random]["companyProperty"] +licenceTypes = result["data"]["list"][company_random]["licenceType"] +isOverdue = ( + result["data"]["list"][company_random]["isOverdue"] if result["data"]["list"][company_random]["isOverdue"] else "") +startTime = result["data"]["list"][company_random]["registerTime"][:10] +endTime = datetime.datetime.now().strftime("%Y-%m-%d") +typeList = (1 if result["data"]["list"][company_random]["appsNum"] else "") + +# 第三步进行列表查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url44") +request_body = commonFuc().get_business_data(module, "payload44", companyName, companyType, companyProperty, + licenceTypes, + isOverdue, startTime, endTime, typeList) +# print(request_body) +""" + + 场景: 列表查询条件验证_站点资质明细列表 + 用例名称:列表查询条件验证_站点资质明细列表 + 输出:{"companyName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点资质明细 +result = json.loads(result.content) +# print(result) +result = {"companyName": result["data"]["list"][0]["companyName"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict44", companyName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.air/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.py" "b/air_case/cmdc_website/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.air/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.py" new file mode 100644 index 0000000000000000000000000000000000000000..63ad830133e9b447d08e42b13d215a4f26bb9b11 --- /dev/null +++ "b/air_case/cmdc_website/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.air/\345\217\202\346\225\260\345\277\205\345\241\253\346\200\247\346\240\241\351\252\214_\347\253\231\347\202\271\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250\350\256\276\347\275\256\345\210\240\351\231\244.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc参数必填性校验_站点产品线备注设置删除,2256,2256-24,sit,bs +主数据平台:后台运营系统站点产品线备注设置删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步删除产品线备注设置 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url24") +request_body = commonFuc().get_business_data(module, "payload24") +# print(request_body) +""" + + 场景: 参数必填性校验_站点产品线备注设置删除 + 用例名称:参数必填性校验_站点产品线备注设置删除 + 输出:{"success":false,"code":"ERROR","message":"找不到配置","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict24") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.air/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.py" "b/air_case/cmdc_website/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.air/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..e2763ffa7d2e87475d781aa9b584c577a96fe943 --- /dev/null +++ "b/air_case/cmdc_website/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.air/\345\244\207\346\263\250\344\270\272\347\251\272\346\240\241\351\252\214_\346\226\260\345\242\236\344\272\247\345\223\201\347\272\277\345\244\207\346\263\250.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc备注为空校验_新增产品线备注,2256,2256-20,sit,bs +主数据平台:后台运营系统新增产品线备注接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取产品线信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url_line") +# 发送请求 +result = requests.get(url) +result = json.loads(result.content) + +# 生成随机数 +line_random = random.randint(0, len(result["data"]) - 1) +# 获取产品信息 +productLineCode = result["data"][line_random]["productLineCode"] + +# 第三步新增产品线备注 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url20") +request_body = commonFuc().get_business_data(module, "payload20", productLineCode) +""" + + 场景: 备注为空校验_新增产品线备注 + 用例名称:备注为空校验_新增产品线备注 + 输出:{"success":false,"code":"ERROR","message":"备注不能为空","data":null,"freshToken":null} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict20") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_website/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" "b/air_case/cmdc_website/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" new file mode 100644 index 0000000000000000000000000000000000000000..6e002b55ca40ddb9f155bd9b6b6e4ac7f3ab6333 --- /dev/null +++ "b/air_case/cmdc_website/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.air/\345\277\205\345\241\253\345\255\227\346\256\265\346\240\241\351\252\214_\345\205\254\345\217\270\345\237\272\347\241\200\344\277\241\346\201\257\345\210\240\351\231\244.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc必填字段校验_公司基础信息删除,2256,2256-41,sit,bs +主数据平台:后台运营系统公司基础信息删除接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步进行公司基础信息删除 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url41") +request_body = commonFuc().get_business_data(module, "payload41") +# print(request_body) +""" + + 场景: 必填字段校验_公司基础信息删除 + 用例名称:必填字段校验_公司基础信息删除 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict41") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..07c9075449dafcc5464c7d6c1db0e01643b0d107 --- /dev/null +++ "b/air_case/cmdc_website/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\346\237\245\350\257\242\344\270\211\346\226\271\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询三方站点详情信息,2256,2256-23,sit,bs +主数据平台:后台运营系统查询三方站点详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取三方站点详细信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23") +# print(request_body) +""" + + 场景: 查询三方站点详情信息 + 用例名称:查询三方站点详情信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict23") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..dc228f4c1796cd8515a06edcaff7451c7473ebeb --- /dev/null +++ "b/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_合作站点列表,2256,2256-50,sit,bs +主数据平台:多采商城站点获取已合作站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取已合作站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url49") +request_body = commonFuc().get_business_data(module, "payload49") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]) - 1) +# 获取站点信息 +companyName = result["data"][company_random]["companyName"] + +# 第三步进行列表查询 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url50") +request_body = commonFuc().get_business_data(module, "payload50", companyName) + +""" + 场景:查询条件验证_合作站点列表 + 用例名称:查询条件验证_合作站点列表 + 输出:{"companyName":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点信息 +result = json.loads(result.content) +result = {"companyName": result["data"][0]["companyName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict50", companyName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..0003c2380498291e6729bf611480b5f7bb5f9f4d --- /dev/null +++ "b/air_case/cmdc_website/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\346\237\245\350\257\242\346\235\241\344\273\266\351\252\214\350\257\201_\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" @@ -0,0 +1,62 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询条件验证_资料申请变更记录列表,2256,2256-53,sit,bs +主数据平台:多采商城站点获取资料申请变更记录列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取资料申请变更记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url52") +request_body = commonFuc().get_business_data(module, "payload52") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取资料申请变更记录 +applycompany = result["data"]["list"][company_random]["applycompany"] + +# 第三步列表查询条件验证 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url53") +request_body = commonFuc().get_business_data(module, "payload53", applycompany) + +""" + 场景:查询条件验证_资料申请变更记录列表 + 用例名称:查询条件验证_资料申请变更记录列表 + 输出:{"applycompany":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取资料申请变更记录 +result = json.loads(result.content) +result = {"applycompany": result["data"]["list"][0]["applycompany"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict53", applycompany) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.air/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.py" "b/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.air/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.py" new file mode 100644 index 0000000000000000000000000000000000000000..3ed1f4bbf6d8db2366616ebb76c9289a695e1af8 --- /dev/null +++ "b/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.air/\346\237\245\350\257\242\347\253\231\347\202\271\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询站点变更记录详情,2256,2256-26,sit,bs +主数据平台:后台运营系统查询站点变更记录详情接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取三方站点详细信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url23") +request_body = commonFuc().get_business_data(module, "payload23") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 获取站点信息 +tripartiteId = result["data"]["tripartiteId"] + +# 第三步查询站点变更记录详情 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url26") +request_body = commonFuc().get_business_data(module, "payload26", tripartiteId) + +""" + + 场景: 查询站点变更记录详情 + 用例名称:查询站点变更记录详情 + 输出:{"tripartiteId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点信息 +result = json.loads(result.content) +result = {"tripartiteId": result["data"]["tripartiteId"]} +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict26", tripartiteId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.air/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.py" "b/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.air/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.py" new file mode 100644 index 0000000000000000000000000000000000000000..168f940ced412581f689313553ec18e7cfd94609 --- /dev/null +++ "b/air_case/cmdc_website/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.air/\346\237\245\350\257\242\347\253\231\347\202\271\350\257\246\346\203\205JDE.py" @@ -0,0 +1,49 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc查询站点详情JDE,2256,2256-25,sit,bs +主数据平台:后台运营系统查询站点详情JDE接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步查询站点详情JDE +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url25") +request_body = commonFuc().get_business_data(module, "payload25") +# print(request_body) +""" + + 场景: 查询站点详情JDE + 用例名称:查询站点详情JDE + 输出:{"companyId":"7"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict25") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..61b24e7f579d9dc54ffff294b285d499c6803bb4 --- /dev/null +++ "b/air_case/cmdc_website/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.air/\346\240\271\346\215\256\345\205\254\345\217\270id\350\216\267\345\217\226\345\205\254\345\217\270\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc根据公司id获取公司信息,2256,2256-13,sit,bs +主数据平台:后台运营系统根据公司id获取公司信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = result["data"]["list"][website_random]["companyId"] + +# 第三步根据站点信息获取站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url13") +request_body = commonFuc().get_business_data(module, "payload13", companyId) +""" + + 场景: 根据公司id获取公司信息 + 用例名称:根据公司id获取公司信息 + 输出:{"companyId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点信息 +result = json.loads(result.content) +# print(result) +result = {"companyId": result["data"]["companyId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict13", companyId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" "b/air_case/cmdc_website/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..5c6b02ce37dc9e43b9df146b8d159c2a7bc945e9 --- /dev/null +++ "b/air_case/cmdc_website/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.air/\347\253\231\347\202\271JDE\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\346\226\260\345\242\236\351\252\214\350\257\201.py" @@ -0,0 +1,70 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点JDE配货手动推送设置新增验证,2256,2256-33,sit,bs +主数据平台:后台运营系统站点JDE配货手动推送设置新增接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = 7 + +# 第三步获取站点jde配货手动推送设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21", companyId) +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 获取站点jde配货手动推送设置信息 +data_json = result["data"] + +# 第三步站点jde配货手动推送信息更新操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url33") +request_body = data_json + +""" + 场景: 站点JDE配货手动推送设置新增验证 + 用例名称:站点JDE配货手动推送设置新增验证 + 输出:{"success":true,"code":"200","message":"OK","data":"success"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +# print(result) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict33") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\347\253\231\347\202\271\345\210\207\346\215\242.air/\347\253\231\347\202\271\345\210\207\346\215\242.py" "b/air_case/cmdc_website/\347\253\231\347\202\271\345\210\207\346\215\242.air/\347\253\231\347\202\271\345\210\207\346\215\242.py" index 552f8926085f74b1854ce5982b8746cb11e219a4..004e247892beb8e2774542fe59ee0ce8836bf881 100644 --- "a/air_case/cmdc_website/\347\253\231\347\202\271\345\210\207\346\215\242.air/\347\253\231\347\202\271\345\210\207\346\215\242.py" +++ "b/air_case/cmdc_website/\347\253\231\347\202\271\345\210\207\346\215\242.air/\347\253\231\347\202\271\345\210\207\346\215\242.py" @@ -2,7 +2,7 @@ __author__ = "liguangyu" """ -case_tag:cmdc_api,cmdc站点切换,2252345,2252-45,sit,bs +case_tag:cmdc_api,cmdc站点切换,2252,2252-45,sit,bs 主数据平台:多采商城站点切换接口 """ @@ -11,10 +11,8 @@ from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLo import requests import json - module = "cmdc_website" - # print(url) # 获取登录所需账号密码 username = commonFuc().get_business_data(module, "username1") @@ -35,8 +33,10 @@ request_body = commonFuc().get_business_data(module, "payload2") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) -# print(result) +result["api_time"] = api_time if result["success"]: # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict2") diff --git "a/air_case/cmdc_website/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.py" "b/air_case/cmdc_website/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..a9ef3d6288799ef75c683d67d91ba4412839ae2f --- /dev/null +++ "b/air_case/cmdc_website/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.air/\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\257\274\345\212\237\350\203\275\351\252\214\350\257\201.py" @@ -0,0 +1,76 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc站点资质明细导出功能验证,2256,2256-45,sit,bs +主数据平台:后台运营系统站点资质明细导出接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.handle_excel import HandleExcel +import requests +import random +import json +import os + + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点资质明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点资质信息 +companyName = result["data"]["list"][company_random]["companyName"] +websiteId = result["data"]["list"][company_random]["websiteId"] + +# 第三步进行站点资质明细导出操作 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url45") +request_body = {"websiteIdList": [websiteId]} +# print(request_body) +""" + + 场景: 站点资质明细导出功能验证 + 用例名称:站点资质明细导出功能验证 + 输出:{"companyName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取文件 +BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))) +file_path = BASE_DIR + "/data/cmdc_files/站点证照明细.xlsx" + +# 获取到导出文件存入cmdc_files文件中 +with open(file_path, 'wb') as f: + f.write(result.content) + +# 获取导出文件中站点全称 +excel = HandleExcel(file_path, "Sheet1") +# print(excel.read_data()) +result = {"companyName": excel.read_data()[0].get("站点全称")} + +# 将接口响应时间添加至结果中 +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict45", companyName) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..859efc952ad17a895c64a79ecc15b862ce47f30e --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\270\211\346\226\271\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取三方站点信息,2256,2256-36,sit,bs +主数据平台:后台运营系统获取三方站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取三方站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url36") +request_body = commonFuc().get_business_data(module, "payload36") +# print(request_body) +""" + + 场景: 获取三方站点信息 + 用例名称:获取三方站点信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取子站站点数量 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中子站点数量 +sql = "SELECT count(t.companyId) FROM `cmdc-user`.cmdc_company t WHERE companyType = 3 and deleteSign = 0" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict36", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..078461925961c365b206a831651b945df8023273 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.air/\350\216\267\345\217\226\344\272\247\345\223\201\345\244\207\346\263\250\345\210\227\350\241\250.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取产品备注列表,2256,2256-19,sit,bs +主数据平台:后台运营系统获取产品备注列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第三步获取产品备注列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url19") +request_body = commonFuc().get_business_data(module, "payload19") +""" + + 场景: 获取产品备注列表 + 用例名称:获取产品备注列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取产品线备注信息 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中产品线备注信息 +sql = "SELECT count(t.id) FROM `cmdc-cms`.cms_line_remark t WHERE companyCode = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-cms", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict19", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..6a13c3b5aec466b8f205ba1ba0a842de4b1d4ccc --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.air/\350\216\267\345\217\226\344\272\247\345\223\201\347\272\277code\344\277\241\346\201\257.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取产品线code信息,2256,2256-16,sit,bs +主数据平台:后台运营系统获取产品线code信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取产品线code信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url16") +request_body = commonFuc().get_business_data(module, "payload16") + +""" + 场景: 获取产品线code信息 + 用例名称:获取产品线code信息 + 输出:{"success":true,"code":"200","message":"OK","data":["DS-电商专用"]} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict16") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..403ed74f5ce134fedc872c870a740d2bd3cd8ebb --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\345\237\272\347\241\200\351\205\215\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取公司基础配置信息,2256,2256-34,sit,bs +主数据平台:后台运营系统获取公司基础配置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取公司基础配置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url34") +request_body = commonFuc().get_business_data(module, "payload34") + +""" + 场景: 获取公司基础配置信息 + 用例名称:获取公司基础配置信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict34") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a6f39fc2fed54a56e2bb8b0cd79768d5ed422005 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取公司站点信息,2256,2256-15,sit,bs +主数据平台:后台运营系统获取公司站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = result["data"]["list"][website_random]["companyId"] + +# 第三步获取公司站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url15") +request_body = commonFuc().get_business_data(module, "payload15", companyId) +""" + + 场景: 获取公司站点信息 + 用例名称:获取公司站点信息 + 输出:{"companyId":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点信息 +result = json.loads(result.content) +# print(result) +result = {"companyId": result["data"][0]["companyId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict15", companyId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..ef1e2f517c39a6d76932c72b3b61d4155f770fe6 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\205\254\345\217\270\351\205\215\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,47 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取公司配置信息,2256,2256-39,sit,bs +主数据平台:后台运营系统获取公司配置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取公司配置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url39") +request_body = commonFuc().get_business_data(module, "payload39") +# print(request_body) +""" + + 场景: 获取公司配置信息 + 用例名称:获取公司配置信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict39") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..d021c0448ddb1894b8f8453de8437f3dc3fd02d8 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取合作站点信息,2256,2256-55,sit,bs +主数据平台:多采商城站点获取合作站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取合作站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url55") +request_body = commonFuc().get_business_data(module, "payload55") + +""" + 场景:获取合作站点信息 + 用例名称:获取合作站点信息 + 输出:{"success":true,"code":"200"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict55") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) \ No newline at end of file diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..cbe87c80099fa3225577f202498a067e59f454e6 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\345\220\210\344\275\234\347\253\231\347\202\271\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,64 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取合作站点详情信息,2256,2256-51,sit,bs +主数据平台:多采商城站点获取合作站点详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取已合作站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url49") +request_body = commonFuc().get_business_data(module, "payload49") +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +company_random = random.randint(0, len(result["data"]) - 1) +# 获取站点信息 +userId = result["data"][company_random]["userId"] +companyId = result["data"][company_random]["companyId"] + +# 第三步获取合作站点详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url51") +request_body = commonFuc().get_business_data(module, "payload51", userId, companyId) +# print(request_body) +""" + 场景:获取合作站点详情信息 + 用例名称:获取合作站点详情信息 + 输出:{"userId":"%s"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点信息 +result = json.loads(result.content) +# print(result) +result = {"userId": result["data"]["userId"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict51", userId) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..f7d85a72ee9b948725bb48984c73358fe2a5389f --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\255\220\347\253\231\344\277\241\346\201\257\345\210\227\350\241\250.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取子站信息列表,2256,2256-6,sit,bs +主数据平台:后台运营系统获取子站信息列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取子站信息列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url6") +request_body = commonFuc().get_business_data(module, "payload6") +# print(request_body) +""" + + 场景: 获取子站信息列表 + 用例名称:获取子站信息列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取子站站点数量 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中子站点数量 +sql = "SELECT count(t.companyId) FROM `cmdc-user`.cmdc_company t WHERE companyType != 1 and deleteSign = 0" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict6", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..a4f8ba635d2991e6c60e6ebd2e99e6f7be549cff --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.air/\350\216\267\345\217\226\345\267\262\345\220\210\344\275\234\347\253\231\347\202\271\345\210\227\350\241\250.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取已合作站点列表,2256,2256-49,sit,bs +主数据平台:多采商城站点获取已合作站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取已合作站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url49") +request_body = commonFuc().get_business_data(module, "payload49") + +""" + 场景:获取已合作站点列表 + 用例名称:获取已合作站点列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict49") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a07a3bedeb63a0b6e489bc8d911b186a18ada051 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\344\277\241\346\201\257.py" @@ -0,0 +1,50 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户信息,2256,2256-47,sit,bs +主数据平台:多采商城站点获取用户信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取用户信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url47") +request_body = commonFuc().get_business_data(module, "payload47") + +""" + 场景:获取用户信息 + 用例名称:获取用户信息 + 输出:{"userName":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取用户信息 +result = json.loads(result.content) +result = {"userName": result["data"]["userName"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict47", username) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + + diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..6ff13ae95d677df4a9492877b9cb638b9949b1c3 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\224\250\346\210\267\350\257\201\347\205\247\344\277\241\346\201\257.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取用户证照信息,2256,2256-48,sit,bs +主数据平台:多采商城站点获取用户证照信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 获取用户证照信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url48") +request_body = commonFuc().get_business_data(module, "payload48") + +""" + 场景:获取用户证照信息 + 用例名称:获取用户证照信息 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict48") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..0dc79a13ff3dc413994994842b464abddf9da3e2 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271jde\351\205\215\350\264\247\346\211\213\345\212\250\346\216\250\351\200\201\350\256\276\347\275\256\344\277\241\346\201\257.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点jde配货手动推送设置信息,2256,2256-21,sit,bs +主数据平台:后台运营系统获取站点jde配货手动推送设置信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = result["data"]["list"][website_random]["companyId"] + +# 第三步获取站点jde配货手动推送设置信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url21") +request_body = commonFuc().get_business_data(module, "payload21", companyId) +""" + + 场景: 获取站点jde配货手动推送设置信息 + 用例名称:获取站点jde配货手动推送设置信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点JDE配货手动推送设置信息 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"]) if result["data"] else 0} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点JDE配货手动推送设置 +sql = "SELECT count(t.id) FROM `cmdc-order`.tc_jde_push_config t " \ + "WHERE companyCode in (SELECT t.companyCode FROM `cmdc-user`.cmdc_company t WHERE companyId = {})".format( + companyId) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict21", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.py" index 7394909fb8f1ee14df96e5ae3dccf983bad46868..9c35c115f91b868aa1ba63cd2f43762e58caa445 100644 --- "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.py" +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -17,8 +17,8 @@ module = "cmdc_website" # print(url) # 获取登录所需账号密码 -username = commonFuc().get_business_data(module, "username") -password = commonFuc().get_business_data(module, "password") +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") # 获取登录后Cmdc_access_token cmdc_access_token = CmdcMaiiLogin(username, password).get_token() headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) @@ -34,7 +34,10 @@ request_body = commonFuc().get_business_data(module, "payload1") """ # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # 判断是否获取到站点信息 if result["data"]: # 获取预期结果 diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" new file mode 100644 index 0000000000000000000000000000000000000000..3cb3a4c7f9891b61e920aa270e276deb8be090de --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.air/\350\216\267\345\217\226\347\253\231\347\202\271\344\277\241\346\201\257_\347\253\231\347\202\271\347\256\241\347\220\206.py" @@ -0,0 +1,61 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点列表,2256,2256-1,sit,bs +主数据平台:后台运营系统获取站点列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# print(request_body) +""" + + 场景: 获取站点列表 + 用例名称:获取站点列表 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点列表站点数量 +result = json.loads(result.content) +# print(result) +result = {"total": result["data"]["total"]} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中站点数量 +sql = "SELECT count(t.websiteId) FROM `cmdc-cms`.cms_website t WHERE deleteSign = 0 and supplierSign = 0" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-order", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict4", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.py" index 40b6ccd3edc6ff8fe2018f28bfa751f38751c49f..809506976ebac9e14819145461b6e2807cb22777 100644 --- "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.py" +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\225\206\345\223\201.py" @@ -39,7 +39,10 @@ url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url3") request_body = commonFuc().get_business_data(module, "payload3") # 发送请求 result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) result = json.loads(result.content) +result["api_time"] = api_time # print(result) # 获取预期结果 check_dict = commonFuc().get_business_data(module, "checkDict3") diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.py" new file mode 100644 index 0000000000000000000000000000000000000000..488ea1dde0e400b218452f46f2b1704460ef8d95 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.air/\350\216\267\345\217\226\347\253\231\347\202\271\345\244\207\346\263\250\351\205\215\347\275\256.py" @@ -0,0 +1,75 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点备注配置,2256,2256-17,sit,bs +主数据平台:后台运营系统获取站点备注配置接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = result["data"]["list"][website_random]["companyId"] + +# 第三步获取站点备注配置 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url17") +request_body = commonFuc().get_business_data(module, "payload17", companyId) +""" + + 场景: 获取站点备注配置 + 用例名称:获取站点备注配置 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点备注配置信息 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"]["resultList"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中备注信息 +sql = "SELECT count(t.remarksConfigManageId) FROM `cmdc-user`.cmdc_remarks_config_manage t " \ + "WHERE deleteSign = 0 and companyId = {}".format(companyId) +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict17", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..526fc5709f1622000a052516f7e534494bd7122d --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\257\201\347\205\247\345\210\227\350\241\250.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点证照列表,2256,2256-46,sit,bs +主数据平台:后台运营系统获取站点证照列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点证照列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url46") +request_body = commonFuc().get_business_data(module, "payload46") + +""" + + 场景: 获取站点证照列表 + 用例名称:获取站点证照列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict46") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..1e4c638f41c5d4280319d92db161f5a9e79f7a2e --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.air/\350\216\267\345\217\226\347\253\231\347\202\271\350\265\204\350\264\250\346\230\216\347\273\206\345\210\227\350\241\250.py" @@ -0,0 +1,48 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点资质明细列表,2256,2256-43,sit,bs +主数据平台:后台运营系统获取站点资质明细列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +import requests +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username2") +password = commonFuc().get_business_data(module, "password2") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点资质明细列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url43") +request_body = commonFuc().get_business_data(module, "payload43") +# print(request_body) +""" + + 场景: 获取站点资质明细列表 + 用例名称:获取站点资质明细列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict43") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..c55aeeb2096daefc745348cecc791f0fa16f7dcd --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.air/\350\216\267\345\217\226\347\253\231\347\202\271\351\200\200\350\264\247\345\234\260\345\235\200\344\277\241\346\201\257.py" @@ -0,0 +1,73 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取站点退货地址信息,2256,2256-14,sit,bs +主数据平台:后台运营系统获取站点退货地址信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import random +import json + +module = "cmdc_website" + +# 第一步登录后台运营系统获取token +username = commonFuc().get_business_data(module, "username") +password = commonFuc().get_business_data(module, "password") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcDoLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取站点列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url4") +request_body = commonFuc().get_business_data(module, "payload4") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +website_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取站点信息 +companyId = result["data"]["list"][website_random]["companyId"] + +# 第三步获取站点退货地址信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url14") +request_body = commonFuc().get_business_data(module, "payload14", companyId) +""" + + 场景: 获取站点退货地址信息 + 用例名称:获取站点退货地址信息 + 输出:{"data":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取站点退货信息 +result = json.loads(result.content) +# print(result) +result = {"data": len(result["data"])} +# print(result) +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中退货地址信息 +sql = "SELECT count(t.returnAddressId) FROM `cmdc-user`.cmdc_return_address t WHERE companyCode = 00102" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict14", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..4ed9354f43fd1c614fca9475aa8085fc1a11066d --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\345\217\230\346\233\264\345\216\237\350\256\260\345\275\225\344\277\241\346\201\257.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取资料变更原记录信息,2256,2256-56,sit,bs +主数据平台:多采商城站点获取资料变更原记录信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取资料变更原记录信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url56") +request_body = commonFuc().get_business_data(module, "payload56") + +""" + 场景:获取资料变更原记录信息 + 用例名称:获取资料变更原记录信息 + 输出:{"success":true,"code":"200"} +""" + +# 发送请求 +result = requests.get(url, params=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict56") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" new file mode 100644 index 0000000000000000000000000000000000000000..2b702b0987907c476afcba017e69127dc75517f6 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\345\210\227\350\241\250.py" @@ -0,0 +1,46 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取资料申请变更记录列表,2256,2256-52,sit,bs +主数据平台:多采商城站点获取资料申请变更记录列表接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取资料申请变更记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url52") +request_body = commonFuc().get_business_data(module, "payload52") + +""" + 场景:获取资料申请变更记录列表 + 用例名称:获取资料申请变更记录列表 + 输出:{"success":true,"code":"200","message":"OK"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict52") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..a79c6289ac914685c083589ee49d2e9f12bee2a3 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.air/\350\216\267\345\217\226\350\265\204\346\226\231\347\224\263\350\257\267\345\217\230\346\233\264\350\256\260\345\275\225\350\257\246\346\203\205\344\277\241\346\201\257.py" @@ -0,0 +1,59 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取资料申请变更记录详情信息,2256,2256-54,sit,bs +主数据平台:多采商城站点获取资料申请变更记录详情信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.多采商城登录.多采商城登录 import CmdcMaiiLogin +import requests +import random +import json + +module = "cmdc_website" + +# 第一步获取登录所需账号密码 +username = commonFuc().get_business_data(module, "username1") +password = commonFuc().get_business_data(module, "password1") +# 获取登录后Cmdc_access_token +cmdc_access_token = CmdcMaiiLogin(username, password).get_token() +headers = commonFuc().get_business_data(module, "json_headers", cmdc_access_token) + +# 第二步获取资料申请变更记录列表 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url52") +request_body = commonFuc().get_business_data(module, "payload52") +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +result = json.loads(result.content) + +# 生成随机数 +first_random = random.randint(0, len(result["data"]["list"]) - 1) +# 获取资料申请变更记录信息 +firstid = result["data"]["list"][first_random]["firstid"] + +# 第三步获取资料申请变更记录详情信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url54") +request_body = commonFuc().get_business_data(module, "payload54", firstid) + +""" + 场景:获取资料申请变更记录详情信息 + 用例名称:获取资料申请变更记录详情信息 + 输出:{"firstid":"%s"} +""" + +# 发送请求 +result = requests.post(url, json=request_body, headers=headers) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 将接口响应时间添加至result +result = json.loads(result.content) +result["api_time"] = api_time + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict54") +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) diff --git "a/air_case/cmdc_website/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.py" "b/air_case/cmdc_website/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..28f09b9c944b01805093cfb985a2e39aaa5a6e68 --- /dev/null +++ "b/air_case/cmdc_website/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.air/\350\216\267\345\217\226\351\233\206\351\205\215\347\253\231\347\202\271\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +__author__ = "liguangyu" + +""" +case_tag:cmdc_api,cmdc获取集配站点信息,2256,2256-37,sit,bs +主数据平台:后台运营系统获取集配站点信息接口 +""" + +from common.common_func import commonFuc +from air_case.cmdc_login.后台管理系统登录.后台管理系统登录 import CmdcDoLogin +from common.db.db import mySql +import requests +import json + +module = "cmdc_website" + +# # 第一步登录后台运营系统获取token +# username = commonFuc().get_business_data(module, "username2") +# password = commonFuc().get_business_data(module, "password2") +# # 获取登录后Cmdc_access_token +# cmdc_access_token = CmdcDoLogin(username, password).get_token() +# headers = commonFuc().get_business_data(module, "json_headers1", cmdc_access_token) + +# 第二步获取集配站点信息 +url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "url37") +request_body = commonFuc().get_business_data(module, "payload37") +# print(request_body) +""" + + 场景: 获取集配站点信息 + 用例名称:获取集配站点信息 + 输出:{"total":"%s"} +""" + +# 发送请求 +result = requests.get(url, json=request_body) +# 获取接口响应时间 +api_time = float(result.elapsed.total_seconds()) + +# 获取集配站点信息 +result = json.loads(result.content) +# print(result) +result = {"total": len(result["data"])} + +# 将接口响应时间添加至result +result["api_time"] = api_time + +# 数据库操作 +mysql_handle = mySql() +# 获取conf.ini文件中配置的数据库信息 +host, port, user, pwd = mysql_handle.getConf(db="cmdc_db") + +# 查询数据库中获取集配站点信息 +sql = "SELECT count(distinct t.affiliationCode) FROM `cmdc-user`.cmdc_jde_config t " \ + "WHERE deleteSign = 0 and affiliationCode is not null" +total = mysql_handle.selectSql(host, port, user, pwd, "cmdc-user", sql)[0][0] + +# 获取预期结果 +check_dict = commonFuc().get_business_data(module, "checkDict37", total) +# print(check_dict) +# 断言实际结果中是否包含预期结果的内容 +commonFuc().check_result(check_dict, result) + diff --git a/common/common_func.py b/common/common_func.py index 060daba858fbabfa1663384758b65ef23a5a0fdc..28531421bdd15e94eb00874af2d30f6d093077cb 100644 --- a/common/common_func.py +++ b/common/common_func.py @@ -68,9 +68,12 @@ class commonFuc(object): url = "" elif env == "od": # 骨科 url = "" - elif env == "bs": # 电商 + elif env == "bs": # 电商uat环境 url = "https://service-uat.gyqxmall.com" # url = "https://service-slb.cmic.com.cn" + elif env == "be": # beta环境 + # url = "https://service-uat.gyqxmall.com" + url = "https://service-slb.cmic.com.cn" else: url = 'http://spddev.cmic.com.cn' diff --git a/common/db/conf.ini b/common/db/conf.ini index 78f8475c83c1bd5097fea86834e9749870b3a704..b1e4c14f03cdf33d70e08a22e156b02fc2e6bda2 100644 --- a/common/db/conf.ini +++ b/common/db/conf.ini @@ -32,4 +32,8 @@ port = 3306 user = root password = @^2DMfIYt1%%6OVT8 - +[cmdc_db_be] +host = 39.106.228.69 +port = 3306 +user = cmdc +password = GHEyi.414 diff --git a/common/run_case_conditions.py b/common/run_case_conditions.py index 548c7a170c032eb98ae3922874572d82804b8713..2e81e9b4a1e598eb9d286d75be841f260c8b0ae2 100644 --- a/common/run_case_conditions.py +++ b/common/run_case_conditions.py @@ -180,17 +180,20 @@ class CustomAirTestCase(AirtestCase): txt_log = os.path.join(log, 'log.txt') f = open(txt_log, 'r', encoding='utf-8') lines = f.readlines() - f.close() - start_time = float(re.findall('.*"start_time": (.*), "ret".*', lines[0])[0]) - start_time = int(start_time * 1000) + try: + start_time = float(re.findall('.*"start_time": (.*), "ret".*', lines[0])[0]) end_time = float(re.findall('.*"end_time": (.*)}}.*', lines[-1])[0]) + # 用于获取接口响应时间,供电商项目使用 + api_time = re.findall('"api_time":(.*)}, "second"', lines[0])[0] except: # case执行失败的话没打end_time - end_time = float(re.findall('.*"time": (.*), "data".*', lines[-2])[0]) + start_time = end_time = api_time = 0 + # end_time = float(re.findall('.*"time": (.*), "data".*', lines[-2])[0]) + start_time = int(start_time * 1000) end_time = int(end_time * 1000) - return start_time, end_time + return start_time, end_time, api_time def assign_tasks(self, task_list, num): """ @@ -436,6 +439,8 @@ class CustomAirTestCase(AirtestCase): result["result"] = flag result["author"] = author result["time"] = (end - start) / 1000 if end > start else 0 + start_time, end_time, api_time = self.get_case_runtime(log) + result["api_time"] = api_time case_results.append(result) if flag == False: msg = confOP().getYamlValue("msg") diff --git a/data/cmdc_31st/data b/data/cmdc_31st/data new file mode 100644 index 0000000000000000000000000000000000000000..cdaf365b5ed5cbbd0c8863693a499fbe21d82ad8 --- /dev/null +++ b/data/cmdc_31st/data @@ -0,0 +1,312 @@ +# 多采商城登录信息 +"username": "BJ0621" +"password": "Aa123456" + +"username3": "GL1000086" +"password3": "Aa123456" + +"username_be": "testtest" +"password_be": "Aa123456" + +#后台运营管理系统登录信息(子站点上海医疗器械有限公司) +"username1": "admin00111" +"password1": "Aa123456" + +"username2": "admin" +"password2": "Aa123456" + +"username4": "Admin00102" +"password4": "Aa123456" + +"username1_be": "admin2" +"password1_be": "@Aa123456" + +"username1_be1": "admin1" +"password1_be1": "Aa123456" + +#后台管理系统headers +json_headers: { + "Content-Type": "application/json", + "Cmdc_access_token": "%s" +} + +#文件上传headers +json_headers_file: { + "Cmdc_access_token": "%s" +} + +#多采商城headers +json_headers1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#需求:站点优化 + +#测试场景一:站点资料变更列表获取 +"url1": "/user/back/tripartiteChangeList" +"payload1": {"applyNo":"","applyTimes":[],"pageStart":1,"pageSize":10} +#预期结果 +checkDict1: {"total":"%s"} + +#测试场景二:查询条件验证_站点资料变更列表 +"url2": "/user/back/tripartiteChangeList" +"payload2": {"applyNo":"%s","applyTimes":["%s","%s"],"pageStart":1,"pageSize":10} +#预期结果 +checkDict2: {"applyNo":"%s"} + +#测试场景三:发起站点资料变更申请 +"url3": "/user/tripartiteChange/getChangeDetail" +"payload3": {} +#预期结果 +checkDict3: {"userName":"%s"} + + +#测试场景四:查询站点资料变更详情 +"url4": "/user/tripartiteChange/queryTripartiteChangeDetail" +"payload4": {"tripartiteId":"%s"} +#预期结果 +checkDict4: {"tripartiteId":"%s"} + +#测试场景五:站点资料变更审核列表获取 +"url5": "/user/back/tripartiteChangeList" +"payload5": {"applyNo":"","companyName":"","applyTimes":[],"applyStatus":"","pageStart":1,"pageSize":10,"siteType":""} +#预期结果 +checkDict5: {"success":true,"code":"200","message":"OK"} + +#测试场景六:查询条件验证_变更审核列表 +"url6": "/user/back/tripartiteChangeList" +"payload6": {"applyNo":"%s","companyName":"%s","applyTimes":["%s","%s"],"applyStatus":"%s","pageStart":1,"pageSize":10,"siteType":"%s"} +#预期结果 +checkDict6: {"applyNo":"%s"} + +#测试场景七:获取站点列表_站点管理 +"url7": "/cms/website/queryListPage" +"payload7": {"websiteName":"","orderApportionPrinciple":"","companyName":"","companyType":"","allocationSite":"","pageStart":1,"pageSize":10,"total":10,"pageNumber":1,"pageTotal":24} +#预期结果 +checkDict7: {"success":true,"code":"200","message":"操作成功"} + + +#测试场景八:查询条件验证_站点管理 +"url8": "/cms/website/queryListPage" +"payload8": {"websiteName":"%s","orderApportionPrinciple":"%s","companyName":"%s","companyType":"%s","allocationSite":"","pageStart":1,"pageSize":10,"total":null,"pageNumber":1,"pageTotal":null} +#预期结果 +checkDict8: {"websiteName":"%s"} + +#测试场景九:获取站点证照信息 +"url9": "/user/public/getLicenseByCompanyId" +"payload9": {"companyId":2} +#预期结果 +checkDict9: {"success":true,"code":"200","message":"OK"} + +#测试场景十:资料上传接口验证_申请变更 +"url10": "/product/public/fileUpload" +"payload10": {} +#预期结果 +checkDict10: {"success":true,"code":"200","message":"OK"} + + +#测试场景十一:站点资料申请变更功能验证 +"url11": "/user/tripartiteChange/toChange" +"payload11": {"changeSubject":"站点资料变更申请测试","companyName":"国药集团联合医疗器械有限公司","companyProperty":"101","licenceList":[{"validityStartTime":"2024-01-22","validityEndTime":"2032-04-30","validityTime":["2024-01-22","2032-04-30"],"licenceTypeExplain":"营业执照","licenceType":"008","licenceUrl":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/91e5bc63-3883-4f69-9c46-a698c7682ced.jpg","fileList":[{"status":"success","name":"WechatIMG252.jpg","size":456498,"percentage":100,"uid":1705907694509,"raw":{"uid":1705907694509},"url":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/91e5bc63-3883-4f69-9c46-a698c7682ced.jpg","response":{"success":true,"code":"200","message":"OK","data":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/91e5bc63-3883-4f69-9c46-a698c7682ced.jpg","freshToken":"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VySWQiOjIsInVzZXJOYW1lIjoiYWRtaW4yIiwidGltZSI6MTcwNTkwNzY5NDY2N30.1ePCWHUgUa1j4gK3gKrOpAiC0nAvbcz2pFTKZX_1QN4"},"filetype":"","title":"WechatIMG252.jpg","validId":""}],"newOneScope":"","oldOneScope":"","newTwoScope":"","oldTwoScope":"","newThreeScope":"","oldThreeScope":"","licenceCode":"213421414"}],"suppleList":[{"validityStartTime":"2024-01-22","validityEndTime":"2035-02-28","validityTime":["2024-01-22","2035-02-28"],"licenceTypeExplain":"续签协议","licenceType":"0012","licenceUrl":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/14e2940e-5415-4b30-8822-1e3dffbae79e.jpg","fileList":[{"status":"success","name":"WechatIMG252.jpg","size":456498,"percentage":100,"uid":1705907730774,"raw":{"uid":1705907730774},"url":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/14e2940e-5415-4b30-8822-1e3dffbae79e.jpg","response":{"success":true,"code":"200","message":"OK","data":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/14e2940e-5415-4b30-8822-1e3dffbae79e.jpg","freshToken":"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VySWQiOjIsInVzZXJOYW1lIjoiYWRtaW4yIiwidGltZSI6MTcwNTkwNzczMDkwNn0.abX7CpflkGMmQrdsOSOHycL_g2ObHsyHPDt1DxW2Vu0"},"filetype":"","title":"WechatIMG252.jpg","validId":""}],"licenceCode":"3245315251515"}],"companyCode":"00102","area":3,"businessUnit":"12325556677","registrations":[],"city":2,"telephone":"18008613536","userName":"admin2","userId":2,"businessPlace":"北京市顺义区金航中路3号天竺万科中心1号楼3单元2层201(北京天竺综合保税区))","legalName":"张洁2","principal":"张洁2","province":1,"merchantsDepositoryList":[{"depositoryId":964,"abbreviation":null,"addressDetail":"北京市顺义区顺义港物流园区机场北街10号A2-2","merchantsId":null,"userId":null,"depotProvince":1,"depotCity":2,"depotArea":3,"createTime":"2024-01-11T03:09:40.000+0000","updateTime":"2024-01-11T03:09:40.000+0000","tripartiteId":255},{"depositoryId":965,"abbreviation":null,"addressDetail":"仓库地址","merchantsId":null,"userId":null,"depotProvince":217,"depotCity":218,"depotArea":221,"createTime":"2024-01-11T03:09:40.000+0000","updateTime":"2024-01-11T03:09:40.000+0000","tripartiteId":255}],"registerLicenceList":[{"validityStartTime":"","validityEndTime":"","validityTime":["2024-01-22","2032-04-30"],"licenceTypeExplain":"营业执照","licenceType":"008","licenceUrl":"","fileList":[{"status":"success","name":"WechatIMG252.jpg","size":456498,"percentage":100,"uid":1705907694509,"raw":{"uid":1705907694509},"url":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/91e5bc63-3883-4f69-9c46-a698c7682ced.jpg","response":{"success":true,"code":"200","message":"OK","data":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/91e5bc63-3883-4f69-9c46-a698c7682ced.jpg","freshToken":"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VySWQiOjIsInVzZXJOYW1lIjoiYWRtaW4yIiwidGltZSI6MTcwNTkwNzY5NDY2N30.1ePCWHUgUa1j4gK3gKrOpAiC0nAvbcz2pFTKZX_1QN4"},"filetype":"","title":"WechatIMG252.jpg","validId":""}],"newOneScope":"","oldOneScope":"","newTwoScope":[],"oldTwoScope":[],"newThreeScope":[],"oldThreeScope":[],"licenceCode":"213421414"}],"detailAddress":"北京市朝阳区太阳宫中路19号院1号楼2层\n","merchantsCategoryList":[{"id":1193,"categoryId":1,"typeId":2,"merchantsId":null,"categoryTypeTxt":"测试测试","tripartiteId":255},{"id":1194,"categoryId":2,"typeId":3,"merchantsId":null,"categoryTypeTxt":"测试","tripartiteId":255}],"supplementLicences":[{"validityStartTime":"","validityEndTime":"","validityTime":["2024-01-22","2035-02-28"],"licenceTypeExplain":"续签协议","licenceType":"0012","licenceUrl":"","fileList":[{"status":"success","name":"WechatIMG252.jpg","size":456498,"percentage":100,"uid":1705907730774,"raw":{"uid":1705907730774},"url":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/14e2940e-5415-4b30-8822-1e3dffbae79e.jpg","response":{"success":true,"code":"200","message":"OK","data":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/01/22/14e2940e-5415-4b30-8822-1e3dffbae79e.jpg","freshToken":"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VySWQiOjIsInVzZXJOYW1lIjoiYWRtaW4yIiwidGltZSI6MTcwNTkwNzczMDkwNn0.abX7CpflkGMmQrdsOSOHycL_g2ObHsyHPDt1DxW2Vu0"},"filetype":"","title":"WechatIMG252.jpg","validId":""}],"licenceCode":"3245315251515"}],"siteType":0,"remarks":"","tripartiteCategoryChangeList":[{"id":1193,"categoryId":1,"typeId":2,"merchantsId":null,"categoryTypeTxt":"测试测试","tripartiteId":255},{"id":1194,"categoryId":2,"typeId":3,"merchantsId":null,"categoryTypeTxt":"测试","tripartiteId":255}],"tripartiteDepositoryChangeList":[{"depositoryId":964,"abbreviation":null,"addressDetail":"北京市顺义区顺义港物流园区机场北街10号A2-2","merchantsId":null,"userId":null,"depotProvince":1,"depotCity":2,"depotArea":3,"createTime":"2024-01-11T03:09:40.000+0000","updateTime":"2024-01-11T03:09:40.000+0000","tripartiteId":255},{"depositoryId":965,"abbreviation":null,"addressDetail":"仓库地址","merchantsId":null,"userId":null,"depotProvince":217,"depotCity":218,"depotArea":221,"createTime":"2024-01-11T03:09:40.000+0000","updateTime":"2024-01-11T03:09:40.000+0000","tripartiteId":255}]} +#预期结果 +checkDict11: {"success":true,"code":"200","message":"OK","data":"success"} + + +#测试场景十二:审核驳回_站点申请资料变更 +"url12": "/user/tripartiteChange/auditTripartiteChange" +"payload12": {} +#预期结果 +checkDict12: {"success":true,"code":"200","message":"OK"} + +#测试场景十三:获取登录用户信息 +"url13": "/user/mall/queryUserInfoNow" +"payload13": {} +#预期结果 +checkDict13: {"userName":"%s"} + + +#测试场景十四:获取用户已合作站点信息 +"url14": "/user/mall/listUserCompany?userId=7&companyName=" +"payload14": {} +#预期结果 +checkDict14: {"total":"%s"} + +#测试场景十五:获取补货单设置信息 +"url15": "/order/public/replenishmentSetting/querySettingPage" +"payload15": {"currentPage":null,"pageSize":10,"total":null,"pageStart":1} +#预期结果 +checkDict15: {"success":true,"code":"200","message":"OK"} + +#测试场景十六:查询条件验证_补货设置 +"url16": "/order/public/replenishmentSetting/querySettingPage" +"payload16": {"currentPage":null,"pageSize":10,"total":null,"productName":"%s","productLineCode":"%s","supplierName":"%s","pacNo":"%s","specifications":"%s","manufacturer":"%s","customerName":"%s","projectName":"%s","materialCode":"%s","creatorName":"%s","pageStart":1} +#预期结果 +checkDict16: {"productName":"%s"} + +#测试场景十七:获取补货单列表 +"url17": "/order/public/replenishmentOrders/queryReplenishmentManageByPage" +"payload17": {"pageSize":10,"pageStart":1,"type":"0"} +#预期结果 +checkDict17: {"success":true,"code":"200","message":"OK"} + +#测试场景十八:查询条件验证_获取补货单列表 +"url18": "/order/public/replenishmentOrders/queryReplenishmentManageByPage" +"payload18": {"pageSize":10,"pageStart":1,"productLineCode":"%s","pacNo":"%s","specifications":"%s","manufacturer":"%s","materialCode":"%s","syncSign":"%s","supplierReplenishmentCode":"%s","replenishmentCode":"%s","orCode":"%s","productInfo":"%s","supplierInfo":"%s","customerInfo":"%s","projectInfo":"%s","creatorName":"%s","startTime":"%s","endTime":"%s","type":"0"} +#预期结果 +checkDict18: {"replenishmentCode":"%s"} + +#测试场景十九:获取子需求单列表_补货单列表 +"url19": "/order/public/replenishmentOrderDetail/queryReplenishmentDetailManageByPage" +"payload19": {"pageSize":10,"type":"1"} +#预期结果 +checkDict19: {"success":true,"code":"200","message":"OK"} + +#测试场景二十:获取补货单详情信息 +"url20": "/order/public/replenishmentOrders/getReplenishmentOrderDetail" +"payload20": {"replenishmentCode":"%s"} +#预期结果 +checkDict20: {"replenishmentCode":"%s"} + +#测试场景二十一:补货单导出验证 +"url21": "/order/public/replenishmentOrders/exportExcel" +"payload21": {"pageSize":10,"pageStart":1,"replenishmentCode":"%s","type":"0"} +#预期结果 +checkDict21: {"replenishmentCode":"%s"} + +#测试场景二十二:子需求单导出_补货单列表 +"url22": "/order/public/replenishmentOrders/exportExcel" +"payload22": {"pageSize":10,"pageStart":1,"type":"1"} +#预期结果 +checkDict22: {"total":"%s"} + +#测试场景二十三:补货设置信息导出验证 +"url23": "/order/public/replenishmentSetting/exportExcel" +"payload23": {"currentPage":null,"pageSize":10,"total":null,"productName":"%s","pageStart":1,"type":"1"} +#预期结果 +checkDict23: {"productName":"%s"} + +#测试场景二十四:获取供应商信息_补货单 +"url24": "/user/public/vptisupluerJde/getVptisupluerJdeListByCondition" +"payload24": {} +#预期结果 +checkDict24: {"total":"%s"} + +#测试场景二十五:获取协议合同号信息_补货单 +"url25": "/user/public/vptihtxyJde/getVptihtxyByPacNo" +"payload25": {} +#预期结果 +checkDict25: {"total":"%s"} + + +#测试场景二十六:补货设置批量导入验证 +"url26": "/order/public/replenishmentSetting/importExcel" +"payload26": {"type":1} +#预期结果 +checkDict26: {"pacNo":"2016017"} + + +#测试场景二十七:补货设置更新功能验证 +"url27": "/order/public/replenishmentSetting/updateById" +"payload27": {"id":"%s","pacNo":"%s","supplierCode":"%s","supplierName":"%s","projectName":"%s","projectCode":"%s","salesmanName":"%s","businessDepartmentName":"%s"} +#预期结果 +checkDict27: {"pacNo":"%s"} +#查找指定的补货设置 +"payload27_1": {"currentPage":1,"pageSize":10,"total":2,"productName":"10154719","pageStart":1} + + +#测试场景二十八:补货设置删除功能验证 +"url28": "/order/public/replenishmentSetting/deleteById" + +#预期结果 +checkDict28: {"deleteSign":1} + + +#测试场景二十九:获取补货设置批量导入日志 +"url29": "/order/public/excelLog/list" +"payload29": {"sheetName":"replenishmentSetting","pageStart":1,"pageSize":2,"total":null} +#预期结果 +checkDict29: {"success":true,"code":"200","message":"OK"} + +#测试场景三十:根据code查询补货设置信息 +"url30": "/order/public/replenishmentSetting/querySettingByCode" +"payload30": {"customerCode":"%s","productCode":"%s","supplierCode":"%s","companyCode":"%s"} +#预期结果 +checkDict30: {"productCode":"%s"} + +#测试场景三十一:获取补货单商品详情 +"url31": "/order/public/replenishmentProductDetails" +"payload31": {"debtMergeVos":[{"customerCode":"%s","distributionType":"%s","productCode":"%s","sellerCompanyCode":"%s","shipmentType":"%s"}]} +#预期结果 +checkDict31: {"productCode":"%s"} +#客户查询维度_欠货综合管理 +"url31_1": "/order/debtStatementList" +"payload31_1": {"demandCode":"","customerName":"","customerCode":"","demandParentCode":"","lackStatusList":[],"orderMark":"","afterPayStatus":"","sellerCompanyName":"","productLineName":"","materialCode":"","optionStr":"","projectName":"","projectCode":"","paidSearch":[],"auditSearch":[],"createSearch":[],"distributionType":null,"shipmentType":null,"demandSubCode":"","auditByName":"","productCode":"","sortSign":2,"afterPay":0,"debtTabSign":"2","productInfoValue":"","mergeSige":null,"pageStart":1,"pageSize":10} + + +#测试场景三十二:获取补货单欠货明细 +"url32": "/order/public/replenishmentDebtList" +"payload32": {"uuid":"%s","replenishmentId":null} +#预期结果 +checkDict32: {"uuid":"%s"} + + +#测试场景三十三:必填字段校验_获取补货单欠货明细 +"url33": "/order/public/replenishmentDebtList" +"payload33": {"uuid":"%s","replenishmentId":null} +#预期结果 +checkDict33: {"success":false,"code":"ERROR","message":"欠货唯一标识至少有一个不为空","data":null,"freshToken":null} + + +#测试场景三十四:分公司编码必填校验_核验供应商证照 +"url34": "/order/public/supplierLicenseCheck" +"payload34": {"companyCode":"","supplierMap":{"1000478":["10145854","10145854"]}} +#预期结果 +checkDict34: {"success":false,"code":"check","message":"分公司编码不能为空","data":null,"freshToken":null} + +#测试场景三十五:供应商字段必填校验_核验供应商证照 +"url35": "/order/public/supplierLicenseCheck" +"payload35": {"companyCode":"00102"} +#预期结果 +checkDict35: {"success":false,"code":"check","message":"供应商数据不能为空","data":null,"freshToken":null} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/data/cmdc_32st/data b/data/cmdc_32st/data new file mode 100644 index 0000000000000000000000000000000000000000..6c0d532ac780642a88eb6b4884c0fff0fa367664 --- /dev/null +++ b/data/cmdc_32st/data @@ -0,0 +1,162 @@ +# 多采商城图形验证码url +"getVerifyCode_url": "/sso/getVerifyCode" +# 多采商城登录地址 +"maii_login_url": "/sso/mallLogin" +# 多采商城登录信息 +"do_username": "BJ0621" +"do_password": "Aa123456" +# 国药运营后台管理系统登录地址 +"do_login_url": "/sso/doLogin" + +# 多采商城登录信息 +"username": "BJ0621" +"password": "Aa123456" + +"username3": "GL1000086" +"password3": "Aa123456" + +"username_be": "testtest" +"password_be": "Aa123456" + +#后台运营管理系统登录信息(子站点上海医疗器械有限公司) +"username1": "admin00111" +"password1": "Aa123456" + +"username2": "admin" +"password2": "Aa123456" + +"username1_be": "admin2" +"password1_be": "@Aa123456" + +"username1_be1": "admin1" +"password1_be1": "Aa123456" + +#后台管理系统headers +json_headers: { + "Content-Type": "application/json", + "Cmdc_access_token": "%s" +} + +#文件上传headers +json_headers_file: { + "Cmdc_access_token": "%s" +} + +#多采商城headers +json_headers1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#需求:站点优化 + +#测试场景1:登录接口新增雅培配置字段验证 +"url1": "/user/back/tripartiteChangeList" +"payload1": {"applyNo":"","applyTimes":[],"pageStart":1,"pageSize":10} +#预期结果 +checkDict1: {"total":"%s"} + +#测试场景14:获取超发记录 +"url14": "/order/public/getStayOverflowList" +"payload14": {"pageNum":1,"pageSize":10,"pageStart":1} +#预期结果 +checkDict14: {"total":"%s"} + +#测试场景15:列表查询条件验证_超发记录 +"url15": "/order/public/getStayOverflowList" +"payload15": {"custData":"%s","productData":"%s","demandCode":"%s","distributionCode":"%s","startTime":"%s","endTime":"%s","pageNum":1,"pageSize":10,"pageStart":1} +#预期结果 +checkDict15: {"productData":"%s"} + +#测试场景16:超发记录导出功能验证 +"url16": "/order/public/exportStayOverflowExcel" +"payload16": {"demandCode":"%s"} +#预期结果 +checkDict16: {"demandCode":"%s"} + +#测试场景7:获取超发配置列表 +"url7": "/order/public/supernovaList" +"payload7": {"strsQuery":"","materialCode":"","productLineCode":"","pageNum":1,"pageSize":10,"pageStart":1} +#预期结果 +checkDict7: {"total":"%s"} + +#测试场景8:列表查询条件验证_超发配置列表 +"url8": "/order/public/supernovaList" +"payload8": {"strsQuery":"%s","materialCode":"%s","productLineCode":"%s","pageNum":1,"pageSize":10,"pageStart":1} +#预期结果 +checkDict8: {"strsQuery":"%s"} + +#测试场景9:超发配置导出功能验证 +"url9": "/order/public/exportstockPurchaseExcel" +"payload9": {"strsQuery":"%s","materialCode":"","productLineCode":""} +#预期结果 +checkDict9: {"strsQuery":"%s"} + +#测试场景13:超发配置导入日志记录验证 +"url13": "/order/public/excelLog/list?sheetName=supernova-D&pageStart=1&pageSize=10&total=" +"payload13": {} +#预期结果 +checkDict13: {"total":"%s"} + +#测试场景10:超发配置导入功能验证 +"url10": "/order/public/supernovaExcel" +"payload10": {"type":"supernova-D"} +#预期结果 +checkDict10: {"wholeQuantity":"%s"} +#获取商品信息 +"url10_1": "/product/mall/queryProductInfoByPage" +"payload10_1": {"isFbList":0,"filialeCode":null,"productName":null,"productCode":null,"specifications":null,"materialCode":null,"manufacturer":null,"lineName":null,"riskRank":null,"isRelease":"1","isExistImage":null,"jdeStatus":"P","isGift":"0","description":null,"tbsj":[],"pageNum":1,"pageSize":8,"total":619,"firstQuery":true,"flag":true,"preInvalidStatus":null,"isControlSales":"0","startTime":null,"endTime":null,"status":101} + +#测试场景11:空数据导入校验验证_超发配置导入 +"url11": "/order/public/supernovaExcel" +"payload11": {"type":"supernova-D"} +#预期结果 +checkDict11: {"success":false,"code":"EXCEL","message":"excel数据内容不能为空","data":null,"freshToken":null} + +#测试场景12:重复数据导入校验验证_超发配置导入 +"url12": "/order/public/supernovaExcel" +"payload12": {"type":"supernova-D"} +#预期结果 +checkDict12: {"status":3} + +#测试场景2:采购协议批量导入功能验证 +"url2": "/product/public/stockPurchaseAgreeExcel" +"payload2": {} +#预期结果 +checkDict2: {"tcdl01":"202401040918001"} + +#测试场景3:导入不能为空校验_采购协议批量导入 +"url3": "/product/public/stockPurchaseAgreeExcel" +"payload3": {} +#预期结果 +checkDict3: {"success":false,"code":"stock","message":"导入数据不能为空","data":null,"freshToken":null} + +#测试场景4:客户编码或采购协议为空_采购协议批量导入 +"url4": "/product/public/stockPurchaseAgreeExcel" +"payload4": {} +#预期结果 +checkDict4: {"success":false,"code":"stock","message":"第2行客户编码或采购协议为空","data":null,"freshToken":null} + +#测试场景5:数据重复校验拦截_采购协议批量导入 +"url5": "/product/public/stockPurchaseAgreeExcel" +"payload5": {} +#预期结果 +checkDict5: {"success":false,"code":"stock","message":"客户编码:1000086对应采购协议重复","data":null,"freshToken":null} + +#测试场景6:采购协议导出功能验证 +"url6": "/product/public/exportPurchaseAgreeExcel" +"payload6": {"stockRuleId":51} +#预期结果 +checkDict6: {"tcdl01":"202401040918001"} + + + + + + + + + + + + diff --git a/data/cmdc_buyercar_list/data b/data/cmdc_buyercar_list/data index 359ab19577ee2a7f6ee560da157c99560e7c031c..b916da78bf1581d38e6a1fd55f959a87128744ab 100644 --- a/data/cmdc_buyercar_list/data +++ b/data/cmdc_buyercar_list/data @@ -185,8 +185,8 @@ checkDict3: {"success":true,"code":"200","message":"OK","data":"ok"} #新增跨站点商品至购物车 -"payload300": {"currentCompanyId":6,"productId":7892,"quantity":1,"agreementPriceId":0,"price":1879,"filialeCode":"00111"} -"payload301": {"currentCompanyId":3,"productId":25769,"quantity":1,"agreementPriceId":0,"price":69,"filialeCode":"00103"} +"payload300": {"currentCompanyId":3,"productId":23380,"quantity":1,"agreementPriceId":0,"price":3980,"filialeCode":"00103"} +"payload301": {"currentCompanyId":7,"productId":9144,"quantity":1,"agreementPriceId":0,"price":1707.71,"filialeCode":"00102"} #预期结果 checkDict300: {"success":true,"code":"200","message":"OK","data":"ok"} diff --git a/data/cmdc_commodity_activity/data b/data/cmdc_commodity_activity/data index 8e6f324ab2bebc60d21e511e483525e63ccdbfaa..3a0e3dd5063fca2906379dfc7f7e9d713f39edde 100644 --- a/data/cmdc_commodity_activity/data +++ b/data/cmdc_commodity_activity/data @@ -2,6 +2,9 @@ "username": "BJ0621" "password": "Aa123456" +"username4": "GL1000086" +"password4": "Aa123456" + #后台运营管理系统登录信息(子公司) "username1": "Admin00111" "password1": "Aa123456" @@ -10,6 +13,10 @@ "username2": "admin" "password2": "Aa123456" +#后台运营管理系统登录信息(国联公司) +"username30": "Admin00102" +"password30": "Aa123456" + #后台管理系统headers json_headers: { "Content-Type": "application/json", @@ -24,9 +31,10 @@ json_headers1: { #测试场景一:促销活动列表获取 "url1": "/order/back/activityBasic/listBackActivity" -"payload1": {"activityBasic":{"activityBasicId":"10127","activityName":"特价验证","activityStatus":102,"activityType":1},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +"payload1": {"activityBasic":{"activityBasicId":"","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +"payload1_1": {"activityBasic":{"activityBasicId":"10143","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #预期结果 -checkDict1: {"success":true,"code":"200","message":"OK"} +checkDict1: {"total":"%s"} #测试场景二:获取活动基本信息 @@ -85,7 +93,7 @@ checkDict9: {"activityBasicId": "%s"} "payload10": {"companyCode":"%s","orderProductList":[{"agreementPriceId":null,"activityUseSgin":1,"buyerCartId":null,"productId":"%s","productCode":"%s","productPrice":"%s","purchaseQuantity":"%s"}],"couponUseSgin":1} #预期结果 checkDict10: {"activityAmount":"%s"} - +"payload100": {"activityBasic":{"activityBasicId":"10146","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #测试场景十一:购买不满足条件特价商品金额验证 #预期结果 @@ -100,29 +108,29 @@ checkDict12: {"success":false,"code":"2001","message":"有时间重叠的商品, #折扣活动验证 -#进行促销活动列表获取 -"payload13": {"activityBasic":{"activityBasicId":"10134","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +#进行折扣活动列表获取 +"payload13": {"activityBasic":{"activityBasicId":"10144","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #预期结果 -checkDict13: {"activityBasicId": 10134} +checkDict13: {"activityBasicId": 10144} #满减活动验证 -#进行促销活动列表获取 -"payload14": {"activityBasic":{"activityBasicId":"10135","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +#进行满减活动列表获取 +"payload14": {"activityBasic":{"activityBasicId":"10145","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #预期结果 -checkDict14: {"activityBasicId": 10135} +checkDict14: {"activityBasicId": 10145} #买赠活动验证 -#进行促销活动列表获取 -"payload15": {"activityBasic":{"activityBasicId":"10136","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +#进行买赠活动列表获取 +"payload15": {"activityBasic":{"activityBasicId":"10143","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #预期结果 -checkDict15: {"productId": 7670} +checkDict15: {"productCode": 10000840} #获取商品对应的赠品信息 #购买买赠商品时为满足条件,进行赠品的赠送 "url16": "/order/public/getCartPurchaseZero" -"payload16": [{"buyerCartId":0,"purchaseQuantity":9,"productCode":"13018749","companyCode":"00111"}] +"payload16": [{"buyerCartId":0,"purchaseQuantity":9,"productCode":"10000841","companyCode":"00102"}] #预期结果 checkDict16: {"success":True,"code":"200","message":"OK"} @@ -163,9 +171,9 @@ checkDict21: {"activityBasicId": "%s"} #商品活动黑名单验证 #获取活动规则 -"payload22": {"activityBasic":{"activityBasicId":"10138","activityName":"","activityStatus":"","activityType":1},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +"payload22": {"activityBasic":{"activityBasicId":"10143","activityName":"","activityStatus":""},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} #黑名单用户信息 -"username5": "BJ0500" +"username5": "GL1000005" "password5": "Tss12345" #预期结果 checkDict22: {"activity": null} @@ -188,20 +196,47 @@ checkDict23: {"productId":111477} +#测试场景40:选赠促销导出功能验证 +"url40": "/order/public/exportXZExcel" +"payload40": {"ids":["%s"],"activityBasic":{"activityBasicId":"%s","activityName":"","activityStatus":"","activityType":5},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +#预期结果 +checkDict40: {"activityName": "%s"} +# 获取选赠活动列表 +"url40_1": "/order/back/activityBasic/listBackActivity" +"payload40_1": {"activityBasic":{"activityBasicId":"","activityName":"","activityStatus":"","activityType":5},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"pageSize":10,"allowanceFlag":null,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} +#测试场景41:生成活动规则code接口验证 +"url41": "/order/public/activityRule/generateActivityRuleCode" +"payload41": {} +#预期结果 +checkDict41: {"success":true,"code":"200","message":"OK"} +#测试场景42:通过code获取服务商品信息 +"url42": "/product/public/queryServiceProductListByCompanyCode" +"payload42": {"companyCode":"00102"} +#预期结果 +checkDict42: {"companyCode":"00102"} +#测试场景43:促销活动新增功能验证 +"url43": "/order/back/activityBasic/save" +"payload43": {"companyCode":"00102","companyAbbreName":null,"activityName":"活动终止功能核验","activityTitle":null,"giftSettlementMethod":null,"serveGiftProductCode":null,"noticeSign":0,"activityStatus":"101","activityType":3,"effectiveDate":"2024-03-06 00:00:00","expirationDate":"2024-03-31 00:00:00","activityDesc":"活动终止功能核验","effectiveDates":["2024-03-06 00:00:00","2024-03-31 00:00:00"]} +#预期结果 +checkDict43: {"success":true,"code":"200"} +#测试场景44:促销活动编辑更新功能验证 +"url44": "/order/back/activityBasic/update" +"payload44": {"companyCode":"00102","companyAbbreName":"国药集团联合医疗器械有限公司","activityName":"活动终止功能核验","activityTitle":null,"serveGiftProductCode":null,"giftSettlementMethod":null,"activityStatus":101,"activityType":3,"effectiveDate":"2024-03-06 00:00:00","expirationDate":"2024-03-31 00:00:00","activityDesc":"活动终止功能核验","noticeSign":0,"effectiveDates":["2024-03-06 00:00:00","2024-03-31 00:00:00"],"activityBasicId":"%s"} +#预期结果 +checkDict44: {"activityBasicId":"%s"} +#查找指定活动 +"url44_1": "/order/back/activityBasic/listBackActivity" +"payload44_1": {"activityBasic":{"activityBasicId":"","activityName":"活动终止功能核验","activityStatus":"101"},"activityDifferenceUser":{"customerCode":"","customerCompanyName":""},"activityProduct":{"productCode":"","materialCode":"","productLineCode":null,"specifications":""},"allowanceFlag":null,"pageSize":10,"pageStart":1,"startTime":null,"cStartTime":null,"endTime":null,"cEndTime":null,"pageNum":1} - - - - - - - - - +#测试场景45:促销活动终止功能验证 +"url45": "/order/back/activityBasic/toggle" +"payload45": {"activityStatus":104,"activityBasicId":"%s"} +#预期结果 +checkDict45: {"activityBasicId":"%s"} diff --git a/data/cmdc_coupon/data b/data/cmdc_coupon/data index 14ecc931425a4f72ca669ed7af7046e2a9078700..036692055661c303a31f85e3c8987ac17db5c66f 100644 --- a/data/cmdc_coupon/data +++ b/data/cmdc_coupon/data @@ -62,7 +62,7 @@ checkDict_collect_coupon: {"success":true,"code":"200","message":"OK","data":tru "payload4": {"pageSize":10,"pageNum":1,"couponId":"10027","couponName":null,"couponStatus":null,"productRangeType":null,"provideType":null,"effectiveDate":null,"expirationDate":null,"total":1} #预期结果 -checkDict_collect_coupon1: {"success":false,"code":"500","message":"该券已超过用户最大领取限制,请您关注平台后续其他活动","data":null,"freshToken":null} +checkDict_collect_coupon1: {"success":false,"code":"500","message":"该券已抢完,请您关注平台后续其他活动","data":null,"freshToken":null} #测试场景六:优惠券库存不足无法领取验证 #获取指定优惠券活动报文 diff --git a/data/cmdc_demand/data b/data/cmdc_demand/data index 1cd75bd0456fe6e4632af7c2c2e49215f08e40af..1131bbb80e8b70561812a5c5c8d968a06384e972 100644 --- a/data/cmdc_demand/data +++ b/data/cmdc_demand/data @@ -10,6 +10,10 @@ "username2": "admin" "password2": "Aa123456" +#后台运营管理系统登录信息(北京) +"username4": "admin2" +"password4": "Aa123456" + #后台管理系统headers json_headers: { "Content-Type": "application/json", @@ -65,7 +69,7 @@ checkDict30: {"success":true,"code":"200","message":"OK","data":1} #测试场景三:快速下单-审核拒绝 #创建需求单 "url4": "/order/public/saveAllDemandOrder" -"payload4": {"国药集团北京医疗器械有限公司":{"datas":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"45.0000","productAmount":45,"payableAmount":45,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":null,"brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":160,"productName":"一次性使用手术衣","productCode":"10980792","productNature":null,"brandName":null,"optionStr":"普通型 M120cm×140cm","imageUrl":null,"lineNumber":null,"price":25,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":25,"measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"稳健医疗用品股份有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"普通型 M120cm×140cm","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"","productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0,"rebateType":0,"paymentAmountWholeLine":45,"discountAmountWholeLine":0,"payableAmountWholeLine":45,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"普通型 M120cm×140cm","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"preDisSign":0,"shareType":null,"singleRebateSign":null,"cf":false,"notice":null,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"productAmountWholeLine":45,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"settementQuantity":2,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false}],"addressConfig":2,"openPreTaxAmount":0,"promotionOrRebate":1,"promotionType":1,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":2,"totalPrice":45,"discountAmount":0,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":null,"brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":160,"productName":"一次性使用手术衣","productCode":"10980792","productNature":null,"brandName":null,"optionStr":"普通型 M120cm×140cm","imageUrl":null,"lineNumber":null,"price":25,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":25,"measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"稳健医疗用品股份有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"普通型 M120cm×140cm","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"45.0000","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[],"defaultBankInfo":{"accountId":52,"companyId":3,"companyName":"国药集团联合医疗器械有限公司","registeredAddress":"北京市东城区","bank":"建设银行19","accountName":"建设银行北京支行19","accountNumber":"62231478523685414","disableSign":0,"deleteSign":0,"createTime":"2021-01-25 11:17:26","updateTime":"2021-01-25 11:17:26","createBy":2,"realName":"子公司1admin"},"addressList":[{"addressId":5243,"addressNo":0,"addressName":null,"provinceCode":null,"userId":null,"companyId":3,"receiverName":"叶二娘","address":"嵩山少林室","isDefault":1,"type":5,"postcode":null,"mobile":"13223233434","updateDate":null,"updateTime":0,"flag":null,"deleteSign":null,"province":1681,"city":1797,"area":null,"dateTime":null,"provinceStr":"湖北省","cityStr":"仙桃市","areaStr":null,"isJde":0,"cityList":[{"areaId":1682,"areaCode":"420100","areaName":"武汉市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1696,"areaCode":"420200","areaName":"黄石市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1703,"areaCode":"420300","areaName":"十堰市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1712,"areaCode":"420500","areaName":"宜昌市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1726,"areaCode":"420600","areaName":"襄阳市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1736,"areaCode":"420700","areaName":"鄂州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1740,"areaCode":"420800","areaName":"荆门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1746,"areaCode":"420900","areaName":"孝感市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1754,"areaCode":"421000","areaName":"荆州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1763,"areaCode":"421100","areaName":"黄冈市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1774,"areaCode":"421200","areaName":"咸宁市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1781,"areaCode":"421300","areaName":"随州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1785,"areaCode":"422800","areaName":"恩施土家族苗族自治州","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1794,"areaCode":"429005","areaName":"潜江市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1795,"areaCode":"429021","areaName":"神农架林区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1796,"areaCode":"429006","areaName":"天门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1797,"areaCode":"429004","areaName":"仙桃市","level":null,"cityCode":null,"center":null,"parentId":null}],"areaList":[]}],"selecteAddresId":5243,"receiverNote":"叶二娘","receiverPhoneNote":"13223233434","receiverAddressNote":"湖北省仙桃市嵩山少林室","addressNoNote":0,"province":1681,"city":1797,"cityList":[{"areaId":1682,"areaCode":"420100","areaName":"武汉市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1696,"areaCode":"420200","areaName":"黄石市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1703,"areaCode":"420300","areaName":"十堰市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1712,"areaCode":"420500","areaName":"宜昌市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1726,"areaCode":"420600","areaName":"襄阳市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1736,"areaCode":"420700","areaName":"鄂州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1740,"areaCode":"420800","areaName":"荆门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1746,"areaCode":"420900","areaName":"孝感市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1754,"areaCode":"421000","areaName":"荆州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1763,"areaCode":"421100","areaName":"黄冈市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1774,"areaCode":"421200","areaName":"咸宁市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1781,"areaCode":"421300","areaName":"随州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1785,"areaCode":"422800","areaName":"恩施土家族苗族自治州","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1794,"areaCode":"429005","areaName":"潜江市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1795,"areaCode":"429021","areaName":"神农架林区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1796,"areaCode":"429006","areaName":"天门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1797,"areaCode":"429004","areaName":"仙桃市","level":null,"cityCode":null,"center":null,"parentId":null}],"area":null,"areaList":[],"paymentAmount":"45.0000","taxRate":0.17,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"45.0000","productAmount":45,"payableAmount":45,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":null,"brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":160,"productName":"一次性使用手术衣","productCode":"10980792","productNature":null,"brandName":null,"optionStr":"普通型 M120cm×140cm","imageUrl":null,"lineNumber":null,"price":25,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":25,"measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"稳健医疗用品股份有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"普通型 M120cm×140cm","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"purchaseEntryId":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"sort":0,"circleArea":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"","productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0,"rebateType":0,"paymentAmountWholeLine":45,"discountAmountWholeLine":0,"payableAmountWholeLine":45,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"普通型 M120cm×140cm","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"preDisSign":0,"shareType":null,"singleRebateSign":null,"cf":false,"notice":null,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"productAmountWholeLine":45,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"settementQuantity":2,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"pSign":0}],"orderStatus":102,"userReceiveId":"","userReceiveId2":"","productAmount":45,"paymentType":0,"accountId":52,"receiveBankName":"建设银行北京支行19","receiveBankAccount":"62231478523685414","buyerCartIds":[null,null],"sellerCompanyCode":"00103","companyId":3}} +"payload4": {"国药集团北京医疗器械有限公司":{"datas":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"20.0000","productAmount":20,"payableAmount":20,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":20,"discountAmountWholeLine":0,"payableAmountWholeLine":20,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"密合型拱形(13.5cm×12cm)","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":20,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false}],"addressConfig":2,"openPreTaxAmount":0,"remark":null,"receiverPhoneNote":"15887223281","promotionOrRebate":1,"promotionType":1,"productLineCodes":[""],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":20,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"20.0000","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":3278,"addressNo":93465,"addressName":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","provinceCode":null,"userId":null,"companyId":null,"receiverName":"郭红声","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"15887223281","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":1,"companyId":3,"companyName":"国药集团北京医疗器械有限公司","registeredAddress":"北京市朝阳区安定路39号长新大厦16层","bank":"招商银行股份有限公司北京东直门支行 ","accountName":"国药集团北京医疗器械有限公司","accountNumber":"110927396010401 ","disableSign":0,"deleteSign":0,"createTime":"2020-12-30 17:18:49","updateTime":"2021-05-28 09:54:12","createBy":2,"updateBy":2,"realName":"北京医疗器械公司1admin"},"addressList":[{"addressId":3278,"addressNo":93465,"addressName":null,"provinceCode":null,"userId":null,"companyId":3,"receiverName":"郭红声","address":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","isDefault":0,"type":3,"postcode":null,"mobile":"15887223281","updateDate":120211,"updateTime":100440,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":3278,"receiverNote":"郭红声","receiverAddressNote":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","addressNoNote":93465,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"20.0000","taxRate":null,"draftDemandId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"20.0000","productAmount":20,"payableAmount":20,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":20,"discountAmountWholeLine":0,"payableAmountWholeLine":20,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"密合型拱形(13.5cm×12cm)","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":20,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":20,"paymentType":0,"accountId":1,"version":null,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401 ","addressNumber":93465,"receiverName":"郭红声","receiverContact":"15887223281","receiverAddress":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","buyerCartIds":[""],"sellerCompanyCode":"00103","companyId":3}} #预期结果 checkDict4: {"success":true,"code":"200"} diff --git a/data/cmdc_demand_audit/data b/data/cmdc_demand_audit/data index b3eeb9924fa67586a3bab6d852d0a23f4bf0d191..bbf823e2321007a36ca9b2fda61fa0b190be6631 100644 --- a/data/cmdc_demand_audit/data +++ b/data/cmdc_demand_audit/data @@ -25,11 +25,13 @@ json_headers: { #步骤四对已创建的需求单进行审核处理 #需求单审核接口地址 "url3": "/order/back/auditDemand" -#审核通过 -"payload3": {"demandId":38596,"demandParentId":36577,"demandParentCode":"s2310090900018","demandCode":"16968152283263140","customerId":18,"customerName":"上海勘泽贸易商行","customerCode":1071246,"loginName":"BJ0500","realName":"赵林","addressNumber":76216,"mobile":"15640336952","productName":null,"productCode":null,"sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","paymentAmount":1879,"productAmount":1879,"payableAmount":1879,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":"2023-10-09 09:33:48","updateTime":"2023-10-09 09:33:48","submitTime":"2023-10-09 09:33:48","pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":[{"demandSkuId":198228,"productName":"测瓣器及其组件","productId":7892,"productCode":"11852135","productLineCode":"4011","productLineName":"HV","sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","optionStr":"VH-100","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","price":1879,"quantity":1,"subtotal":1879,"materialCode":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","produceRegisterNum":"国械备20152082号","riskRank":null,"productClassify":null,"storageType":"999","measuringUnit":"盒","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"productNature":null,"productInventory":[],"totalInventory":0,"promotionPrice":0,"promotionTotalPrice":0,"discountRate":0,"realPay":1879,"customerCode":"1071246","isRebate":"0","rebateId":"82","rebateDetail":{"rebateoperaskuid":null,"filialecode":"00111","rebateid":82,"customercode":null,"transactionamount":null,"transactiontype":null,"rebateStartTime":null,"rebateValidity":null,"balance":null,"deletesign":null,"note":null,"createtime":null,"updatetime":null,"demandId":null,"demandCode":null,"relevanceName":null,"rebateName":null,"customerCompanyName":null,"lineCodeDelete":null,"rebateTripId":null,"monNum":null,"relevanceCode":"4011","pageSize":null,"pageNum":null,"startTime":null,"endTime":null,"userId":null,"customerCodeList":null,"filialeCodeList":null,"companyName":null,"reSign":null,"demandParentCode":null,"distributionCode":null,"frontNote":null,"backNote":null,"cancelId":null,"effectivetype":null,"validityperiodSign":null,"rebatename":"HV返利","useLimitStart":0,"useLimitEnd":1,"istax":1,"taxround":0,"isdisposable":0,"productCode":null,"isOperated":null,"userPrice":null,"rebateFalg":null},"useMaxLimit":"1.0000","useBalance":0,"taxRate":0.13,"rebateType":0,"singleRebateAmount":null,"multipleCodeProductList":null,"stockNumber":0,"prescription":"2099-12-31","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"simpleMultipleCodeProductList":[{"groupId":71,"optionStr":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","materialCode":"VH-100","produceRegisterNum":"国械备20152082号","prescription":"2019-02-03","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","measuringUnit":"盒","price":1879,"productName":"测瓣器及其组件","productCode":"11852135","quantity":0,"productId":7892,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"areaName":null,"offerPrice":null,"referencePrice":1879,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"takeEffectRange":null,"showlimitNum":null,"showproductLimitBuyId":null,"showalreadyBuyNum":null,"showtakeEffectRange":null,"limitBuySign":0},{"groupId":71,"optionStr":"VH-100","manufacturer":"恪心意大利有限公司 Corcym S.r.l.","materialCode":"VH-100","produceRegisterNum":"国械备20152082号","prescription":"2021-11-23","imageUrl":null,"measuringUnit":"盒","price":1111,"productName":"测瓣器及其组件","productCode":"16911089","quantity":0,"productId":39610,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"areaName":null,"offerPrice":null,"referencePrice":1111,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"takeEffectRange":null,"showlimitNum":null,"showproductLimitBuyId":null,"showalreadyBuyNum":null,"showtakeEffectRange":null,"limitBuySign":0}],"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"useLimitStart":"0.0000","lineNumberOrg":1,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"takeEffectRange":null,"limitBuySign":0,"overdueSign":0,"sxPrice":null,"invalidStr":null,"submitTime":"2023-10-09T01:33:48.000+0000","manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"groupId":71,"groupNumber":1,"groupProductType":null,"groupCode":null,"giftSign":0,"giftProductCode":"11852135","description":"","demandCode":"16968152283263140","lineNum":1,"threeRebateBalance":null,"threeRebateMaxScale":null,"rebateTripId":null,"companyType":null,"busProductCode":null,"rebateControlSign":0,"rebateRule":null,"hospitalHopeDate":null,"uniqueKey":null,"activityRuleId":null,"differenceActivityUserId":null,"replaceSgin":0,"skuGroup":{},"fsGroupId":null,"demandSkuVOList":null,"companyCode":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupSpitSign":0,"plusMinuKey":null,"purchaseEntryId":null,"installedDate":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"sdOutStorage":0,"lineCodeDelete":0,"showState":true,"purchaseZeroProductList":[],"giftList":[],"selectGiftArr":[]}],"demandSubItems":[{"demandId":38596,"demandParentId":36577,"demandParentCode":"s2310090900018","demandCode":"16968152283263140","customerId":18,"customerName":"上海勘泽贸易商行","customerCode":1071246,"loginName":"BJ0500","realName":"赵林","addressNumber":76216,"mobile":"15640336952","productName":null,"productCode":null,"sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","paymentAmount":1879,"productAmount":1879,"payableAmount":1879,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":null,"demandSubItems":[{"demandSkuId":198228,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"16968152283263140","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","customerCode":1071246,"productLineCode":"4011","productLineName":"HV","propertyStr":null,"storageType":"999","suppDist":null,"productId":7892,"productName":"测瓣器及其组件","productCode":"11852135","productNature":null,"brandName":null,"optionStr":"VH-100","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","lineNumber":null,"price":1879,"rebateId":82,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":1879,"measuringUnit":"盒","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","produceRegisterNum":"国械备20152082号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":1879,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2099-12-31","specifications":null,"lineCodeDelete":0,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"11852135","activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":71,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null},"subList":null,"dataJson":null,"skuMergeSign":"11852135-1879-0-0-0-1879","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":"0","rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false}],"rebateDetail":null,"rebateAmountList":null,"productLineCode":"4011","productLineName":"HV","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":"BM-1071246","alesDepartmentNo":"111002","alesDepartmentName":"法律事务部","salesPersonNo":"80054216","salesPersonName":"苏荷艳","customerNote":"","otherNote":"","contractAgreementCode":"77411","projectName":"捷迈","projectCode":"17001218","regionId":null,"regionName":null,"productLineBindSign":2,"shipVia":"2","orderSource":2,"userBalance":null,"liquidCode":"04","shipmentTypeStr":"","specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2023-10-09 09:33:48","updateTimeStr":"2023-10-09 09:33:48","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":[{"demandSubId":190399,"demandId":38596,"demandParentId":36577,"demandCode":"16968152283263140","demandSubCode":"16968152283263140","customerId":18,"customerName":"上海勘泽贸易商行","customerCode":1071246,"loginName":"BJ0500","realName":"赵林","addressNumber":76216,"mobile":"15640336952","productLineCode":"4011","productLineName":"HV","sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","productAmount":1879,"cancelAmount":0,"payableAmount":0,"discountAmount":0,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","remark":null,"pushJdeStatus":null,"submitTime":"2023-10-09T01:33:48.000+0000","pushJdeTime":null,"successTime":null,"deleteSign":null,"taxRate":0.13,"singleRebateAmount":null,"rebateType":0,"isRebateEdit":0,"discountRate":0,"changeType":null,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"isEdit":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":"","otherNote":null,"jdeType":0,"shipVia":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"orderSource":2,"regionId":null,"regionName":null,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"addressNoNote":76216,"rebateValidity":null,"liquidCode":null,"promotionType":1,"activityTotalAmount":null,"couponTotalAmount":null,"userReceiveId":null,"editSgin":0,"snSgin":0,"totalAllPaAmount":null,"jdeOutAmount":null,"diffShowSgin":0,"changeSgin":0,"yapei":2,"acrossMainCode":null,"sdCancelTime":null,"sdTipSign":0,"customerCharge":0,"isElectronicSeal":null,"userReceiveId2":null,"inventoryNode":null,"customCode":null,"terminalSource":1,"confirmReceiptSign":null,"confirmReceiptTime":null,"deliveryCompletedTime":null,"taxSign":0,"delay":null,"rebateControlSign":0,"erpRejectTime":null,"erpHandingTime":null,"allShippingTime":null,"partShippingTime":null,"confirmTime":null,"noTaxRebateAmount":0,"newIsTax":null,"countFormula":null,"countNumber":null,"siteCompanyCode":null,"hospitalOrderType":null,"shipmentType":null,"distributionType":null,"isShowReate":null,"spitSgin":null,"detailIsSpit":false,"createTime":"2023-10-09T01:33:48.000+0000","updateTime":"2023-10-09T01:33:48.000+0000","paymentAmount":null,"demandSubItems":null,"sdlnty":null}],"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":"76216","detailIsSpit":false,"spitSgin":null,"distributionType":"2","rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":0,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"serialNumber":1,"lockHover":false,"shipmentType":0,"activityAmount":0,"couponAmount":0}],"rebateDetail":null,"rebateAmountList":null,"productLineCode":"4011","productLineName":"HV","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":"","otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":2,"shipVia":1,"orderSource":2,"userBalance":null,"liquidCode":null,"shipmentTypeStr":"","specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":"","secondAuditByName":"","secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2023-10-09 09:33:48","updateTimeStr":"2023-10-09 09:33:48","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":[{"demandSubId":190399,"demandId":38596,"demandParentId":36577,"demandCode":"16968152283263140","demandSubCode":"16968152283263140","customerId":18,"customerName":"上海勘泽贸易商行","customerCode":1071246,"loginName":"BJ0500","realName":"赵林","addressNumber":76216,"mobile":"15640336952","productLineCode":"4011","productLineName":"HV","sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","productAmount":1879,"cancelAmount":0,"payableAmount":0,"discountAmount":0,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","remark":null,"pushJdeStatus":null,"submitTime":"2023-10-09T01:33:48.000+0000","pushJdeTime":null,"successTime":null,"deleteSign":null,"taxRate":0.13,"singleRebateAmount":null,"rebateType":0,"isRebateEdit":0,"discountRate":0,"changeType":null,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"isEdit":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":"","otherNote":null,"jdeType":0,"shipVia":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"orderSource":2,"regionId":null,"regionName":null,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"addressNoNote":76216,"rebateValidity":null,"liquidCode":null,"promotionType":1,"activityTotalAmount":null,"couponTotalAmount":null,"userReceiveId":null,"editSgin":0,"snSgin":0,"totalAllPaAmount":null,"jdeOutAmount":null,"diffShowSgin":0,"changeSgin":0,"yapei":2,"acrossMainCode":null,"sdCancelTime":null,"sdTipSign":0,"customerCharge":0,"isElectronicSeal":null,"userReceiveId2":null,"inventoryNode":null,"customCode":null,"terminalSource":1,"confirmReceiptSign":null,"confirmReceiptTime":null,"deliveryCompletedTime":null,"taxSign":0,"delay":null,"rebateControlSign":0,"erpRejectTime":null,"erpHandingTime":null,"allShippingTime":null,"partShippingTime":null,"confirmTime":null,"noTaxRebateAmount":0,"newIsTax":null,"countFormula":null,"countNumber":null,"siteCompanyCode":null,"hospitalOrderType":null,"shipmentType":null,"distributionType":null,"isShowReate":null,"spitSgin":null,"detailIsSpit":false,"createTime":"2023-10-09T01:33:48.000+0000","updateTime":"2023-10-09T01:33:48.000+0000","paymentAmount":null,"demandSubItems":null,"sdlnty":null}],"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":76216,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":null,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":0,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":[{"demandSkuId":198228,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"16968152283263140","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团上海医疗器械有限公司","sellerCompanyCode":"00111","customerCode":1071246,"productLineCode":"4011","productLineName":"HV","propertyStr":null,"storageType":"999","suppDist":null,"productId":7892,"productName":"测瓣器及其组件","productCode":"11852135","productNature":null,"brandName":null,"optionStr":"VH-100","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","lineNumber":null,"price":1879,"rebateId":82,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":1879,"measuringUnit":"盒","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","produceRegisterNum":"国械备20152082号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":1879,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2099-12-31","specifications":null,"lineCodeDelete":0,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"11852135","activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":71,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null},"subList":null,"dataJson":null,"skuMergeSign":"11852135-1879-0-0-0-1879","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":"0","rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false}],"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"serialNumber":1,"lockHover":false} +#代客下单审核通过 +"payload3": {"otherNote":null,"sellerCompanyCode":"00103","productLineCode":"","demandId":41414,"demandParentId":39389,"demandParentCode":"s2402051000007","demandCode":"17070989273346247","customerId":15,"customerName":"中国医药对外贸易公司","customerCode":1000598,"loginName":"BJ0001","realName":"王春晖","addressNumber":1564,"mobile":"15811121168","productName":null,"productCode":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","paymentType":1,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401","paymentAmount":18,"productAmount":18,"payableAmount":18,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"王春晖","receiverContact":"15811121168","receiverAddress":"北京市朝阳区惠新东街4号","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":"2024-02-05 10:08:47","updateTime":"2024-02-05 10:08:47","submitTime":"2024-02-05 10:08:47","pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":[{"demandSkuId":203526,"productName":"一次性使用手术衣","productId":159,"productCode":"10951104","productLineCode":"","productLineName":"","sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","optionStr":"中号","imageUrl":null,"price":18,"quantity":1,"subtotal":18,"materialCode":"","manufacturer":"河南亚都实业有限公司","produceRegisterNum":"豫械注准20162640174","riskRank":"002","productClassify":null,"storageType":"999","measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"productNature":null,"productInventory":null,"totalInventory":0,"promotionPrice":0,"promotionTotalPrice":0,"discountRate":0,"realPay":18,"customerCode":"1000598","isRebate":"0","rebateId":null,"circleArea":null,"rebateDetail":null,"useMaxLimit":null,"useBalance":null,"taxRate":0.13,"rebateType":0,"singleRebateAmount":null,"storageCondition":"999","otherStorageCondition":"详见说明书或标签","countryOfOrigin":"CN","newProductClassify":"14","newClassifyLevel":"002","newProductClassify2":"","multipleCodeProductList":null,"stockNumber":null,"prescription":"2030-03-31","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"simpleMultipleCodeProductList":[],"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"useLimitStart":null,"lineNumberOrg":1,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"areaName":"1","agreementPriceId":531616,"offerPrice":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"takeEffectRange":null,"limitBuySign":0,"overdueSign":0,"sxPrice":null,"invalidStr":null,"submitTime":"2024-02-05T02:08:47.000+0000","manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"groupId":null,"groupNumber":1,"groupProductType":null,"groupCode":null,"giftSign":0,"giftProductCode":"10951104","description":"","demandCode":"17070989273346247","lineNum":1,"threeRebateBalance":null,"threeRebateMaxScale":null,"rebateTripId":null,"companyType":null,"busProductCode":null,"rebateControlSign":0,"rebateRule":null,"hospitalHopeDate":null,"uniqueKey":null,"activityRuleId":null,"differenceActivityUserId":null,"replaceSgin":0,"skuGroup":{},"fsGroupId":null,"demandSkuVOList":null,"companyCode":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupSpitSign":0,"plusMinuKey":null,"purchaseEntryId":null,"installedDate":null,"giftGroupQuantity":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"sdOutStorage":0,"installedDateMust":0,"lineCodeDelete":1,"showState":true,"purchaseZeroProductList":[],"giftList":[],"selectGiftArr":[],"propertyStr":""}],"expireDemandSkus":null,"demandSubItems":[{"otherNote":"","sellerCompanyCode":"00103","productLineCode":"","demandId":41414,"demandParentId":39389,"demandParentCode":"s2402051000007","demandCode":"17070989273346247","customerId":15,"customerName":"中国医药对外贸易公司","customerCode":1000598,"loginName":"BJ0001","realName":"王春晖","addressNumber":1564,"mobile":"15811121168","productName":null,"productCode":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","paymentType":1,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401","paymentAmount":18,"productAmount":18,"payableAmount":18,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"王春晖","receiverContact":"15811121168","receiverAddress":"北京市朝阳区惠新东街4号","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":null,"expireDemandSkus":null,"demandSubItems":[{"demandSkuId":203526,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"17070989273346247","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","customerCode":1000598,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":159,"productName":"一次性使用手术衣","productCode":"10951104","productNature":null,"brandName":null,"optionStr":"中号","imageUrl":null,"lineNumber":null,"price":18,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":18,"measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"河南亚都实业有限公司","produceRegisterNum":"豫械注准20162640174","riskRank":"002","productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":18,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2030-03-31","specifications":null,"lineCodeDelete":1,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":"1","agreementPriceId":531616,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"10951104","activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":0,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null},"subList":null,"dataJson":null,"skuMergeSign":"10951104-18-0-0-0-181","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false,"pushQuantity":0,"residualQuantity":1}],"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":"2016241","alesDepartmentNo":"103001","alesDepartmentName":"北京公司经理室","salesPersonNo":"10300101","salesPersonName":"刘吉亮","customerNote":"","contractAgreementCode":"248","projectName":"益阳市妇幼保健院采购项目","projectCode":"16000350","regionId":null,"regionName":null,"productLineBindSign":0,"shipVia":"2","orderSource":2,"userBalance":null,"liquidCode":"08","shipmentTypeStr":"","distributionTypeStr":null,"soStr":null,"soList":[],"specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2024-02-05 10:08:47","updateTimeStr":"2024-02-05 10:08:47","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":"0","refuseType":0,"groupChangeSign":0,"custModify":0,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":"1564","detailIsSpit":false,"spitSgin":null,"distributionType":"2","rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":8,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"iconArr":[],"serialNumber":1,"lockHover":false,"shipmentType":0,"activityAmount":0,"couponAmount":0}],"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":"","contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":0,"shipVia":1,"orderSource":2,"userBalance":null,"liquidCode":null,"shipmentTypeStr":"","distributionTypeStr":null,"soStr":null,"soList":[],"specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":"","secondAuditByName":"","secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2024-02-05 10:08:47","updateTimeStr":"2024-02-05 10:08:47","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":"0","refuseType":0,"groupChangeSign":0,"custModify":0,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":1564,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":null,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":8,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":[{"demandSkuId":203526,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"17070989273346247","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","customerCode":1000598,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":159,"productName":"一次性使用手术衣","productCode":"10951104","productNature":null,"brandName":null,"optionStr":"中号","imageUrl":null,"lineNumber":null,"price":18,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":18,"measuringUnit":"件","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"河南亚都实业有限公司","produceRegisterNum":"豫械注准20162640174","riskRank":"002","productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":18,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2030-03-31","specifications":null,"lineCodeDelete":1,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":"1","agreementPriceId":531616,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"10951104","activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":0,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null},"subList":null,"dataJson":null,"skuMergeSign":"10951104-18-0-0-0-181","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false,"pushQuantity":0,"residualQuantity":1}],"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"iconArr":[],"serialNumber":1,"lockHover":false} #预期结果 checkDict1: {"success":true,"code":"200","message":null,"data":[],"freshToken":null} +#快速下单审核通过 +"payload40": {"otherNote":null,"sellerCompanyCode":"00103","productLineCode":"","demandId":41411,"demandParentId":39386,"demandParentCode":"s2402050900213","demandCode":"17070982942689568","customerId":69,"customerName":"国药集团云南医疗器械有限公司","customerCode":1127254,"loginName":"BJ0621","realName":"郭红声","addressNumber":93465,"mobile":"15887223281","productName":null,"productCode":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","paymentType":0,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401","paymentAmount":20,"productAmount":20,"payableAmount":20,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"郭红声","receiverContact":"15887223281","receiverAddress":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":"2024-02-05 09:58:14","updateTime":"2024-02-05 09:58:14","submitTime":"2024-02-05 09:58:14","pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":[{"demandSkuId":203523,"productName":"医用防护口罩","productId":822,"productCode":"13295500","productLineCode":"","productLineName":"","sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"price":20,"quantity":1,"subtotal":20,"materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":"京械注准20172640749","riskRank":"002","productClassify":"6864","storageType":"999","measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","productNature":"01","productInventory":null,"totalInventory":0,"promotionPrice":0,"promotionTotalPrice":0,"discountRate":0,"realPay":20,"customerCode":"1127254","isRebate":"0","rebateId":null,"circleArea":null,"rebateDetail":null,"useMaxLimit":null,"useBalance":null,"taxRate":0.13,"rebateType":0,"singleRebateAmount":null,"storageCondition":"999","otherStorageCondition":"详见说明书或标签","countryOfOrigin":"CN","newProductClassify":"","newClassifyLevel":"","newProductClassify2":"","multipleCodeProductList":null,"stockNumber":3100000,"prescription":"2030-03-31","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"simpleMultipleCodeProductList":[],"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"useLimitStart":null,"lineNumberOrg":1,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"takeEffectRange":null,"limitBuySign":0,"overdueSign":0,"sxPrice":null,"invalidStr":null,"submitTime":"2024-02-05T01:58:14.000+0000","manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"groupId":null,"groupNumber":null,"groupProductType":null,"groupCode":null,"giftSign":0,"giftProductCode":"13295500","description":"","demandCode":"17070982942689568","lineNum":1,"threeRebateBalance":null,"threeRebateMaxScale":null,"rebateTripId":null,"companyType":null,"busProductCode":null,"rebateControlSign":0,"rebateRule":null,"hospitalHopeDate":null,"uniqueKey":null,"activityRuleId":null,"differenceActivityUserId":null,"replaceSgin":0,"skuGroup":{},"fsGroupId":null,"demandSkuVOList":null,"companyCode":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupSpitSign":0,"plusMinuKey":null,"purchaseEntryId":null,"installedDate":null,"giftGroupQuantity":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"sdOutStorage":0,"installedDateMust":0,"lineCodeDelete":1,"showState":true,"purchaseZeroProductList":[],"giftList":[],"selectGiftArr":[],"propertyStr":""}],"expireDemandSkus":null,"demandSubItems":[{"otherNote":"","sellerCompanyCode":"00103","productLineCode":"","demandId":41411,"demandParentId":39386,"demandParentCode":"s2402050900213","demandCode":"17070982942689568","customerId":69,"customerName":"国药集团云南医疗器械有限公司","customerCode":1127254,"loginName":"BJ0621","realName":"郭红声","addressNumber":93465,"mobile":"15887223281","productName":null,"productCode":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","paymentType":0,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401","paymentAmount":20,"productAmount":20,"payableAmount":20,"refundAmount":0,"cancelAmount":0,"discountAmount":0,"orderStatus":102,"refundStatus":null,"receiverName":"郭红声","receiverContact":"15887223281","receiverAddress":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":0,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":1,"deleteSign":0,"firstOrderFlag":0,"demandItems":null,"expireDemandSkus":null,"demandSubItems":[{"demandSkuId":203523,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"17070982942689568","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","customerCode":1127254,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":"京械注准20172640749","riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":20,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2030-03-31","specifications":null,"lineCodeDelete":1,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"13295500","activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":0,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null},"subList":null,"dataJson":null,"skuMergeSign":"13295500-20-0-0-0-20","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":"3100000","priceChange":false,"jdeStockNumber":null,"rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false,"pushQuantity":0,"residualQuantity":1}],"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":"YJWZGRKH-2020-051","alesDepartmentNo":"103001","alesDepartmentName":"北京公司经理室","salesPersonNo":"10300101","salesPersonName":"刘吉亮","customerNote":"","contractAgreementCode":"192932","projectName":"新型冠状病毒感染肺炎疫情应急物资供应项目","projectCode":"20022312","regionId":null,"regionName":null,"productLineBindSign":0,"shipVia":"2","orderSource":1,"userBalance":null,"liquidCode":"05","shipmentTypeStr":"","distributionTypeStr":null,"soStr":null,"soList":[],"specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2024-02-05 09:58:14","updateTimeStr":"2024-02-05 09:58:14","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":"0","refuseType":0,"groupChangeSign":0,"custModify":0,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":"93465","detailIsSpit":false,"spitSgin":null,"distributionType":"2","rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":"ac17070982939363139","forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":8,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"iconArr":[],"serialNumber":2,"lockHover":false,"shipmentType":0,"activityAmount":0,"couponAmount":0}],"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":1,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":null,"discountAmountWholeLine":null,"payableAmountWholeLine":null,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":0,"payCertUrl":null,"rebateAmount":0,"demandCance":0,"soAdd":0,"soCance":0,"orderReturn":0,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":0,"editIngStr":null,"jdeType":0,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":0,"shipVia":1,"orderSource":1,"userBalance":null,"liquidCode":null,"shipmentTypeStr":"","distributionTypeStr":null,"soStr":null,"soList":[],"specifications":null,"pageStart":null,"pageSize":null,"changeSgin":0,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":1,"secondAuditSign":0,"secondAuditById":"","secondAuditByName":"","secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":null,"rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":"2024-02-05 09:58:14","updateTimeStr":"2024-02-05 09:58:14","auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":0,"cancelRecords":[],"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":0,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":"0","refuseType":0,"groupChangeSign":0,"custModify":0,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":0,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":93465,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":0,"snSgin":0,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":0,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":"2","afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":"ac17070982939363139","forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":8,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":[{"demandSkuId":203523,"demandId":null,"distributionId":null,"companyCode":null,"demandCode":"17070982942689568","demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":"国药集团北京医疗器械有限公司","sellerCompanyCode":"00103","customerCode":1127254,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":"京械注准20172640749","riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":20,"promotionPrice":0,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":"2030-03-31","specifications":null,"lineCodeDelete":1,"sdOutStorage":0,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":"13295500","activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":0,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":1,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":null,"taxRate":0.13,"demandSplitSign":null,"hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":{"id":null,"groupId":null,"companyCode":null,"groupProductType":null,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":null,"lineNumber":null,"freseniusPriceId":null,"groupNumber":null,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null},"subList":null,"dataJson":null,"skuMergeSign":"13295500-20-0-0-0-20","freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":"","demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":"3100000","priceChange":false,"jdeStockNumber":null,"rebate":false,"shipmentType":0,"isRebate":"0","hideInTable":false,"pushQuantity":0,"residualQuantity":1}],"inventoryNode":null,"customCode":null,"terminalSource":1,"potentialClientsId":null,"settlementStatus":"000","firstOrderAuditStatus":null,"confirmReceiptSign":"0","confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":0,"spitOrderSign":1,"productAmountWholeLine":null,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"iconArr":[],"serialNumber":2,"lockHover":false} #多采商场快速下单 #步骤一登录多采商城 @@ -46,9 +48,10 @@ json_headers1: { #需求单创建接口地址 "url4": "/order/public/saveAllDemandOrder" #需求单创建 -"payload4": {"国药集团北京医疗器械有限公司":{"datas":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"230.0000","productAmount":230,"payableAmount":230,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":314,"productName":"红外测温仪","productCode":"12043728","productNature":null,"brandName":null,"optionStr":"YHW-3","imageUrl":null,"lineNumber":null,"price":230,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":230,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"江苏鱼跃医用仪器有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":230,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"YHW-3","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"","productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":230,"discountAmountWholeLine":0,"payableAmountWholeLine":230,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"YHW-3","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":230,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false}],"addressConfig":2,"openPreTaxAmount":0,"promotionOrRebate":1,"promotionType":1,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":230,"discountAmount":0,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":314,"productName":"红外测温仪","productCode":"12043728","productNature":null,"brandName":null,"optionStr":"YHW-3","imageUrl":null,"lineNumber":null,"price":230,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":230,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"江苏鱼跃医用仪器有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":230,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"YHW-3","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"230.0000","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"defaultBankInfo":{"accountId":1,"companyId":3,"companyName":"国药集团北京医疗器械有限公司","registeredAddress":"北京市朝阳区安定路39号长新大厦16层","bank":"招商银行股份有限公司北京东直门支行 ","accountName":"国药集团北京医疗器械有限公司","accountNumber":"110927396010401 ","disableSign":0,"deleteSign":0,"createTime":"2020-12-30 17:18:49","updateTime":"2021-05-28 09:54:12","createBy":2,"updateBy":2,"realName":"北京医疗器械公司1admin"},"addressList":[{"addressId":3278,"addressNo":93465,"addressName":null,"provinceCode":null,"userId":null,"companyId":3,"receiverName":"郭红声","address":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","isDefault":0,"type":3,"postcode":null,"mobile":"15887223281","updateDate":120211,"updateTime":100440,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":3278,"receiverNote":"郭红声","receiverPhoneNote":"15887223281","receiverAddressNote":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","addressNoNote":93465,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"receiveInfo":[{"addressId":3278,"addressNo":93465,"addressName":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","provinceCode":null,"userId":null,"companyId":null,"receiverName":"郭红声","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"15887223281","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"paymentAmount":"230.0000","taxRate":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"230.0000","productAmount":230,"payableAmount":230,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":"","storageType":"999","suppDist":null,"productId":314,"productName":"红外测温仪","productCode":"12043728","productNature":null,"brandName":null,"optionStr":"YHW-3","imageUrl":null,"lineNumber":null,"price":230,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":230,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"江苏鱼跃医用仪器有限公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":230,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"YHW-3","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":"","userReceiveIdx2":"","limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"","productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":230,"discountAmountWholeLine":0,"payableAmountWholeLine":230,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"YHW-3","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":230,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"pSign":0}],"orderStatus":102,"userReceiveId":"","userReceiveId2":"","productAmount":230,"paymentType":0,"accountId":1,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401 ","addressNumber":93465,"receiverName":"郭红声","receiverContact":"15887223281","receiverAddress":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","buyerCartIds":[null],"sellerCompanyCode":"00103","companyId":3}} +"payload4": {"国药集团北京医疗器械有限公司":{"datas":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"20.0000","productAmount":20,"payableAmount":20,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":20,"discountAmountWholeLine":0,"payableAmountWholeLine":20,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"密合型拱形(13.5cm×12cm)","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":20,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"showInfo":false,"addressConfig":2}],"addressConfig":2,"openPreTaxAmount":0,"remark":null,"receiverPhoneNote":"15887223281","promotionOrRebate":1,"promotionType":1,"productLineCodes":[""],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":20,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"20.0000","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"defaultBankInfo":{"accountId":1,"companyId":3,"companyName":"国药集团北京医疗器械有限公司","registeredAddress":"北京市朝阳区安定路39号长新大厦16层","bank":"招商银行股份有限公司北京东直门支行 ","accountName":"国药集团北京医疗器械有限公司","accountNumber":"110927396010401 ","disableSign":0,"deleteSign":0,"createTime":"2020-12-30 17:18:49","updateTime":"2021-05-28 09:54:12","createBy":2,"updateBy":2,"realName":"北京医疗器械公司1admin"},"receiveInfo":[{"addressId":3278,"addressNo":93465,"addressName":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","provinceCode":null,"userId":null,"companyId":null,"receiverName":"郭红声","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"15887223281","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"addressList":[{"addressId":3278,"addressNo":93465,"addressName":null,"provinceCode":null,"userId":null,"companyId":3,"receiverName":"郭红声","address":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","isDefault":0,"type":3,"postcode":null,"mobile":"15887223281","updateDate":120211,"updateTime":100440,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":3278,"receiverNote":"郭红声","receiverAddressNote":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","addressNoNote":93465,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"20.0000","taxRate":null,"draftDemandId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1127254,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"20.0000","productAmount":20,"payableAmount":20,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00103","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":822,"productName":"医用防护口罩","productCode":"13295500","productNature":"01","brandName":null,"optionStr":"密合型拱形(13.5cm×12cm)","imageUrl":null,"lineNumber":null,"price":20,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":20,"measuringUnit":"支","auxiliaryMeasuringUnit":"BN","procurementMeasuringUnit":"BN","pricingMeasuringUnit":"BN","materialCode":"YYPS20210031","manufacturer":"北京中北博健科贸有限公司","produceRegisterNum":null,"riskRank":"002","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":20,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"密合型拱形(13.5cm×12cm)","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":3,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":20,"discountAmountWholeLine":0,"payableAmountWholeLine":20,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"密合型拱形(13.5cm×12cm)","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":3,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":20,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"showInfo":false,"addressConfig":2,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":20,"paymentType":0,"accountId":1,"version":null,"receiveBankName":"国药集团北京医疗器械有限公司","receiveBankAccount":"110927396010401 ","addressNumber":93465,"receiverName":"郭红声","receiverContact":"15887223281","receiverAddress":"云南省昆明市高新技术开发区产业基地B1-02-01地块物流园二期项目1号库M1-2-1,M1-2-2号","buyerCartIds":[""],"sellerCompanyCode":"00103","companyId":3}} checkDict2: {"success":false,"code":"demand","message":"订单已拒绝,无法审核","data":null,"freshToken":null} +checkDict2_1: {"success":true,"code":"200","message":null,"data":[],"freshToken":null} # 登录失败断言 diff --git a/data/cmdc_demand_creation/data b/data/cmdc_demand_creation/data index 5df13bd388e19bf0268a2a6441c2b40d28f646ed..9a2761131eece6c6bfba84f2a4846d9693ff355b 100644 --- a/data/cmdc_demand_creation/data +++ b/data/cmdc_demand_creation/data @@ -8,6 +8,10 @@ "username": "Admin00111" "password": "Aa123456" + +"username2": "Admin00102" +"password2": "Aa123456" + json_headers1: { "Content-Type": "application/json", "Cmdc_access_token": "%s" @@ -16,7 +20,7 @@ json_headers1: { #测试场景一:需求单创建 -"payload1": {"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productId":7892,"productCode":"11852135","materialCode":"VH-100","productName":"测瓣器及其组件","specifications":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","productLineName":"HV","productLineCode":"4011","zonePriceVOList":null,"price":1879,"storageType":"999","optionStr":"VH-100","measuringUnit":"BX","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"盒","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","companyCode":"00111","areaName":null,"areaPrice":1879,"agreementPriceId":null,"hidden":null,"description":"","taxRate":"0.13","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"mustInstallDate":false,"showDemandAuditLineLabel":false,"editProductCode":false,"quantityErr":false,"fresenuis":false,"singleFresenuis":null,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1,"giftSign":0,"customerCode":"1071246","realPay":"1879.00"}],"paymentAmount":1879,"productAmount":1879,"userId":18,"userNo":"1071246","customerCode":"1071246","userName":"上海勘泽贸易商行","companyId":"6","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","accountId":3,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNumber":76216,"remark":"","receiverNote":"刘海涛","receiverPhoneNote":"18940124666","receiverAddressNote":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNoNote":76216,"fileList":[],"sellerCompanyCode":"00111","sellerCompanyName":"国药集团上海医疗器械有限公司","orderSource":2,"replaceCustomerOrder":{"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productId":7892,"productCode":"11852135","materialCode":"VH-100","productName":"测瓣器及其组件","specifications":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","productLineName":"HV","productLineCode":"4011","zonePriceVOList":null,"price":1879,"storageType":"999","optionStr":"VH-100","measuringUnit":"BX","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"盒","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","companyCode":"00111","areaName":null,"areaPrice":1879,"agreementPriceId":null,"hidden":null,"description":"","taxRate":"0.13","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"mustInstallDate":false,"showDemandAuditLineLabel":false,"editProductCode":false,"quantityErr":false,"fresenuis":false,"singleFresenuis":null,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1}],"paymentAmount":1879,"productAmount":1879,"userId":18,"userNo":"1071246","customerCode":"1071246","userName":"上海勘泽贸易商行","companyId":"6","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","accountId":3,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNumber":76216,"remark":"","receiverNote":"刘海涛","receiverPhoneNote":"18940124666","receiverAddressNote":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNoNote":76216,"fileList":[],"sellerCompanyCode":"00111","sellerCompanyName":"国药集团上海医疗器械有限公司","orderSource":2,"customerInfo":{"userId":18,"userName":"BJ0500","rejectUserName":null,"password":null,"realName":"赵林","userNo":"1071246","telephone":"15640336952","rejectTelephone":null,"registerAddress":"[{\\\"province\\\":810,\\\"city\\\":849,\\\"area\\\":850}]","detailAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","businessScope":"[{\\\"province\\\":\\\"\\\",\\\"city\\\":2237,\\\"area\\\":\\\"\\\"}]","companyProperty":101,"companyId":null,"companyCode":null,"companyName":"国药集团上海医疗器械有限公司","companyNameList":null,"customerCompanyName":"上海勘泽贸易商行","lienceNo":"91310116MA1JAFLT2B","userType":2,"companyType":null,"status":3,"disableSign":0,"deleteSign":null,"createBy":null,"updateBy":null,"createTime":null,"updateTime":null,"licenceSketchUrl":null,"licenceUrl":null,"openId":null,"referrer":null,"gift":null,"identity":null,"department":null,"platformStatus":1,"rejectionReason":null,"registerType":null,"siteType":null,"departmentCode":null,"personName":null,"registration":null,"realPassword":null,"recommend":null,"taxRate":0.13,"roleNames":null,"subCompanyName":"国药集团上海医疗器械有限公司","roleIds":null,"addressList":null,"licenseList":null,"labelList":null,"managerList":null,"createTimeStr":null,"categoriesList":null,"merchantsAddress":null,"merchantStatus":null,"refuseReason":null,"merchantsId":null,"userTransactionAmount":"0","gray":null,"bindingTime":null,"bindSign":1,"jdeStatus":0,"jdePhone":"","recommender":null,"coopeSgin":null,"bindflowList":null,"userJDEInfo":null}},"draftId":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1071246,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"1879.00","productAmount":1879,"payableAmount":1879,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":1071246,"productLineCode":"4011","productLineName":"HV","propertyStr":null,"storageType":"999","suppDist":null,"productId":7892,"productName":"测瓣器及其组件","productCode":"11852135","productNature":null,"brandName":null,"optionStr":"VH-100","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/09/29/3721d7b9-0cd6-4d45-a5f2-f41595cd231b.jpg","lineNumber":null,"price":1879,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":1879,"measuringUnit":"盒","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"VH-100","manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":1879,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":null,"couponAmount":null,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"VH-100","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":0,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"userBalance":null,"purchaseQuantity":1,"purchaseZeroProductList":[]}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"4011","productLineName":"HV","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":1879,"discountAmountWholeLine":0,"payableAmountWholeLine":1879,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"VH-100","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":null,"activityTotalAmount":null,"couponTotalAmount":null,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":1879,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"showMoreAttribute":false,"ratio":null,"ratioFlag":false,"rebateFlags":false,"userBalancePrice":0,"allQuantity":1,"totalPriceNum":0,"maxTotalLimitPrice":0,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0}]} +"payload1": {"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productCode":"10146314","productId":117,"materialCode":"","productName":"温温热","specifications":"温热温热我人","manufacturer":"北京康思润业生物技术有限公司-黄翼","productLineName":null,"productLineCode":null,"zonePriceVOList":null,"price":1000.888,"storageType":"999","optionStr":"温热温热我人","measuringUnit":"EA","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"个","imageUrl":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2020/12/16/a613b1d7-d4be-4140-9be3-2266746f35b7.png","companyCode":"00102","areaName":"","areaPrice":1000.888,"agreementPriceId":538663,"hidden":null,"description":"","taxRate":"0.17","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":"商品属性名","propertyVal":"10146314","propertyNote":"10146314","mustInstallDate":false,"showDemandAuditLineLabel":false,"yaPei":false,"installedDateMust":0,"yapeiPrice":null,"editProductCode":false,"quantityErr":false,"fresenuis":false,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1,"propertyStr":"商品属性名:10146314&10146314","giftSign":0,"customerCode":"1000012","realPay":1000.89,"priceChange":0,"purchaseId":5,"purchaseCode":"P2307051500001","purchaseEntryId":null}],"paymentAmount":1000.89,"productAmount":1000.89,"userId":124035,"userNo":"1000012","customerCode":"1000012","userName":"石家庄康雅医疗器械有限公司","companyId":"7","paymentType":1,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","accountId":5,"receiverName":"王璐","receiverContact":"18510958965","receiverAddress":"北京市丰台区马家堡东路71号立业大厦7003室","addressNumber":6281,"remark":"","receiverNote":"王璐","receiverPhoneNote":"18510958965","receiverAddressNote":"北京市丰台区马家堡东路71号立业大厦7003室","addressNoNote":6281,"fileList":[],"sellerCompanyCode":"00102","sellerCompanyName":"国药集团联合医疗器械有限公司","orderSource":2,"replaceCustomerOrder":{"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productCode":"10146314","productId":117,"materialCode":"","productName":"温温热","specifications":"温热温热我人","manufacturer":"北京康思润业生物技术有限公司-黄翼","productLineName":null,"productLineCode":null,"zonePriceVOList":null,"price":1000.888,"storageType":"999","optionStr":"温热温热我人","measuringUnit":"EA","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"个","imageUrl":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2020/12/16/a613b1d7-d4be-4140-9be3-2266746f35b7.png","companyCode":"00102","areaName":"","areaPrice":1000.888,"agreementPriceId":538663,"hidden":null,"description":"","taxRate":"0.17","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":"商品属性名","propertyVal":"10146314","propertyNote":"10146314","mustInstallDate":false,"showDemandAuditLineLabel":false,"yaPei":false,"installedDateMust":0,"yapeiPrice":null,"editProductCode":false,"quantityErr":false,"fresenuis":false,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1,"propertyStr":"商品属性名:10146314&10146314"}],"paymentAmount":1000.89,"productAmount":1000.89,"userId":124035,"userNo":"1000012","customerCode":"1000012","userName":"石家庄康雅医疗器械有限公司","companyId":"7","paymentType":1,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","accountId":5,"receiverName":"王璐","receiverContact":"18510958965","receiverAddress":"北京市丰台区马家堡东路71号立业大厦7003室","addressNumber":6281,"remark":"","receiverNote":"王璐","receiverPhoneNote":"18510958965","receiverAddressNote":"北京市丰台区马家堡东路71号立业大厦7003室","addressNoNote":6281,"fileList":[],"sellerCompanyCode":"00102","sellerCompanyName":"国药集团联合医疗器械有限公司","orderSource":2,"customerInfo":{"userId":124035,"userName":"GL1000012","rejectUserName":null,"password":null,"realName":"客户1000012","userNo":"1000012","telephone":"87817554000","rejectTelephone":null,"registerAddress":null,"detailAddress":"国联客户地址","businessScope":null,"companyProperty":101,"companyId":null,"companyCode":null,"companyName":"国药集团联合医疗器械有限公司","companyNameList":null,"customerCompanyName":"石家庄康雅医疗器械有限公司","lienceNo":"9113010006339588XU","userType":2,"companyType":null,"status":3,"disableSign":0,"deleteSign":null,"createBy":null,"updateBy":null,"createTime":null,"updateTime":null,"licenceSketchUrl":null,"licenceUrl":null,"openId":null,"referrer":null,"gift":null,"identity":null,"department":null,"platformStatus":1,"rejectionReason":null,"registerType":null,"siteType":null,"departmentCode":null,"personName":null,"registration":null,"realPassword":null,"recommend":null,"merchantsStatus":null,"backAuditing":false,"taxRate":0.17,"roleNames":null,"subCompanyName":"国药集团联合医疗器械有限公司","roleIds":null,"addressList":null,"licenseList":null,"labelList":null,"managerList":null,"createTimeStr":null,"categoriesList":null,"merchantsAddress":null,"merchantStatus":null,"refuseReason":null,"merchantsId":null,"userTransactionAmount":"0","gray":null,"bindingTime":null,"bindSign":1,"jdeStatus":0,"jdePhone":"","recommender":null,"coopeSgin":null,"cusCompanyName":null,"registerLicenceList":null,"bindflowList":null,"userJDEInfo":null}},"purchaseId":5,"purchaseCode":"P2307051500001","draftId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000012,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"1000.89","productAmount":1000.89,"payableAmount":1000.888,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":1000012,"productLineCode":"","productLineName":"","propertyStr":"商品属性名:10146314&10146314","storageType":"999","suppDist":null,"productId":117,"productName":"温温热","productCode":"10146314","productNature":null,"brandName":null,"optionStr":"温热温热我人","imageUrl":"https://uat-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2020/12/16/a613b1d7-d4be-4140-9be3-2266746f35b7.png","lineNumber":null,"price":1000.888,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":1000.89,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"北京康思润业生物技术有限公司-黄翼","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":1000.89,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":null,"couponAmount":null,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"温热温热我人","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":"","agreementPriceId":538663,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":1000.888,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":0,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":"商品属性名","propertyVal":"10146314","propertyNote":"10146314","sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"userBalance":null,"purchaseQuantity":1,"purchaseZeroProductList":[]}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":0,"paymentAmountWholeLine":1000.888,"discountAmountWholeLine":0,"payableAmountWholeLine":1000.888,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"温热温热我人","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":5,"purchaseCode":"P2307051500001","sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":null,"activityTotalAmount":null,"couponTotalAmount":null,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":1000.888,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"showMoreAttribute":true,"installedDateMust":true,"ratio":null,"ratioFlag":false,"rebateFlags":false,"userBalancePrice":0,"allQuantity":1,"totalPriceNum":0,"maxTotalLimitPrice":0,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0}]} #预期结果 checkDict1: {"success":true,"code":"200","message":"ok","data":null,"freshToken":null} @@ -24,4 +28,7 @@ checkDict1: {"success":true,"code":"200","message":"ok","data":null,"freshToken" "payload2": {"productMap":{"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productId":8192,"productCode":"10086272","materialCode":"C1048042","productName":"可吸收外科带针缝线","specifications":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","manufacturer":"B.Braun Surgical SA","productLineName":"蛇牌","productLineCode":"3046","zonePriceVOList":null,"price":915,"storageType":"999","optionStr":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","measuringUnit":"BX","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"盒","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/14/1e3727ab-49cc-46b9-afa1-2606b283553b.jpg","companyCode":"00111","areaName":null,"areaPrice":915,"agreementPriceId":null,"hidden":null,"description":"","taxRate":"0.13","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"mustInstallDate":false,"showDemandAuditLineLabel":false,"editProductCode":false,"quantityErr":false,"fresenuis":false,"singleFresenuis":null,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1,"giftSign":0,"customerCode":"1071246","realPay":"915.00"}],"paymentAmount":915,"productAmount":915,"userId":18,"userNo":"1071246","customerCode":"1071246","userName":"上海勘泽贸易商行","companyId":"6","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","accountId":3,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNumber":76216,"remark":"","receiverNote":"刘海涛","receiverPhoneNote":"18940124666","receiverAddressNote":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNoNote":76216,"fileList":[],"sellerCompanyCode":"00111","sellerCompanyName":"国药集团上海医疗器械有限公司","orderSource":2,"replaceCustomerOrder":{"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productId":8192,"productCode":"10086272","materialCode":"C1048042","productName":"可吸收外科带针缝线","specifications":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","manufacturer":"B.Braun Surgical SA","productLineName":"蛇牌","productLineCode":"3046","zonePriceVOList":null,"price":915,"storageType":"999","optionStr":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","measuringUnit":"BX","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"盒","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/14/1e3727ab-49cc-46b9-afa1-2606b283553b.jpg","companyCode":"00111","areaName":null,"areaPrice":915,"agreementPriceId":null,"hidden":null,"description":"","taxRate":"0.13","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"mustInstallDate":false,"showDemandAuditLineLabel":false,"editProductCode":false,"quantityErr":false,"fresenuis":false,"singleFresenuis":null,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1}],"paymentAmount":915,"productAmount":915,"userId":18,"userNo":"1071246","customerCode":"1071246","userName":"上海勘泽贸易商行","companyId":"6","paymentType":1,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","accountId":3,"receiverName":"刘海涛","receiverContact":"18940124666","receiverAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNumber":76216,"remark":"","receiverNote":"刘海涛","receiverPhoneNote":"18940124666","receiverAddressNote":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","addressNoNote":76216,"fileList":[],"sellerCompanyCode":"00111","sellerCompanyName":"国药集团上海医疗器械有限公司","orderSource":2,"customerInfo":{"userId":18,"userName":"BJ0500","rejectUserName":null,"password":null,"realName":"赵林","userNo":"1071246","telephone":"15640336952","rejectTelephone":null,"registerAddress":"[{\\\"province\\\":810,\\\"city\\\":849,\\\"area\\\":850}]","detailAddress":"金山区朱泾镇鸿安路599号2幢北2楼210、211室","businessScope":"[{\\\"province\\\":\\\"\\\",\\\"city\\\":2237,\\\"area\\\":\\\"\\\"}]","companyProperty":101,"companyId":null,"companyCode":null,"companyName":"国药集团上海医疗器械有限公司","companyNameList":null,"customerCompanyName":"上海勘泽贸易商行","lienceNo":"91310116MA1JAFLT2B","userType":2,"companyType":null,"status":3,"disableSign":0,"deleteSign":null,"createBy":null,"updateBy":null,"createTime":null,"updateTime":null,"licenceSketchUrl":null,"licenceUrl":null,"openId":null,"referrer":null,"gift":null,"identity":null,"department":null,"platformStatus":1,"rejectionReason":null,"registerType":null,"siteType":null,"departmentCode":null,"personName":null,"registration":null,"realPassword":null,"recommend":null,"taxRate":0.13,"roleNames":null,"subCompanyName":"国药集团上海医疗器械有限公司","roleIds":null,"addressList":null,"licenseList":null,"labelList":null,"managerList":null,"createTimeStr":null,"categoriesList":null,"merchantsAddress":null,"merchantStatus":null,"refuseReason":null,"merchantsId":null,"userTransactionAmount":"0","gray":null,"bindingTime":null,"bindSign":1,"jdeStatus":0,"jdePhone":"","recommender":null,"coopeSgin":null,"bindflowList":null,"userJDEInfo":null}},"draftId":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1071246,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"915.00","productAmount":915,"payableAmount":915,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":1071246,"productLineCode":"3046","productLineName":"蛇牌","propertyStr":null,"storageType":"999","suppDist":null,"productId":8192,"productName":"可吸收外科带针缝线","productCode":"10086272","productNature":null,"brandName":null,"optionStr":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/14/1e3727ab-49cc-46b9-afa1-2606b283553b.jpg","lineNumber":null,"price":915,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":915,"measuringUnit":"盒","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"C1048042","manufacturer":"B.Braun Surgical SA","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":0,"realPay":915,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":null,"couponAmount":null,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"lockType":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":0,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":1,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"rebate":false,"userBalance":null,"purchaseQuantity":1,"purchaseZeroProductList":[]}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"3046","productLineName":"蛇牌","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":915,"discountAmountWholeLine":0,"payableAmountWholeLine":915,"discountRate":0,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":"C1048042,紫色结福 2/0线 (3) 70厘米 1/2弧 圆针 26","pageStart":null,"pageSize":null,"changeSgin":null,"yapei":2,"companyId":null,"userReceiveId2":null,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":null,"activityTotalAmount":null,"couponTotalAmount":null,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":915,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"showMoreAttribute":false,"ratio":null,"ratioFlag":false,"rebateFlags":false,"userBalancePrice":0,"allQuantity":1,"totalPriceNum":0,"maxTotalLimitPrice":0,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0}]},"id":null,"type":2,"userNo":"1071246","userName":"上海勘泽贸易商行"} #预期结果 -checkDict2: {"success":true,"code":"200","message":"OK"} \ No newline at end of file +checkDict2: {"success":true,"code":"200","message":"OK"} + +#登录失败 +checkDict_fail: {"success":false,"code":"login_empty","message":"获取登录信息失败","data":null,"freshToken":null,"api_time":0.143888} \ No newline at end of file diff --git a/data/cmdc_demand_fail/data b/data/cmdc_demand_fail/data index c3de1051e02ee269802672a28de917dd4419e979..2b946d263b48e4d6151be721d32244fa5212c091 100644 --- a/data/cmdc_demand_fail/data +++ b/data/cmdc_demand_fail/data @@ -7,6 +7,9 @@ "username": "Admin00111" "password": "Aa123456" +"username1": "Admin00102" +"password1": "Aa123456" + json_headers1: { "Content-Type": "application/json", "Cmdc_access_token": "%s" diff --git a/data/cmdc_demand_mall/data b/data/cmdc_demand_mall/data index 05539cb0a3e23fd1e9a0ce4b6c880717c8e5539a..8e81f0ccccdd402be23780478e7d1b4c00173899 100644 --- a/data/cmdc_demand_mall/data +++ b/data/cmdc_demand_mall/data @@ -2,6 +2,9 @@ "username": "BJ0621" "password": "Aa123456" +"username3": "GL1000086" +"password3": "Aa123456" + #后台运营管理系统登录信息(子站点上海医疗器械有限公司) "username1": "Admin00111" "password1": "Aa123456" @@ -27,6 +30,7 @@ json_headers1: { #测试场景一:需求单列表获取接口验证 "url1": "/order/public/ownListDemand" "payload1": {"sellerCompanyCodes":[],"materialCode":"","productCode":"","productInfoValue":"","manufacturerList":null,"orderNum":"","paymentType":null,"preferenceType":null,"changeSign":null,"mainOrderStatus":null,"shipmentType":null,"pageStart":5,"pageSize":10} +"payload_1": {"sellerCompanyCodes":[],"materialCode":"","productCode":"","productInfoValue":"","manufacturerList":null,"orderNum":"","paymentType":null,"preferenceType":null,"changeSign":null,"mainOrderStatus":2,"shipmentType":null,"pageStart":1,"pageSize":10} #预期结果 checkDict1: {"success":true,"code":"200","message":"OK"} @@ -92,9 +96,9 @@ checkDict10: {"demandCode":"%s"} #测试场景十一:获取站点信息验证_需求单 "url11": "/cms/public/website/queryWebsiteByCompanyIdNoCode" -"payload11": {"companyId":6} +"payload11": {"companyId":7} #预期结果 -checkDict11: {"companyId":6} +checkDict11: {"companyId":7} @@ -119,7 +123,7 @@ checkDict13_1: {"success":True,"code":"200"} #预期结果 checkDict14: {"demandId":"%s"} checkDict14_1: {"success":True,"code":"200"} - +checkDict14_2: {"success":false,"code":"500","message":"内部系统错误","data":null} #测试场景十五:获取销售订单合同配置验证 "url15": "/order/public/contract/config" diff --git "a/data/cmdc_files/\346\211\271\351\207\217\345\257\274\345\205\245\346\224\266\350\264\247\345\234\260\345\235\200\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\346\211\271\351\207\217\345\257\274\345\205\245\346\224\266\350\264\247\345\234\260\345\235\200\346\250\241\346\235\277.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..bfc01492aba581ed55b54bd7ea6394500a8e915b Binary files /dev/null and "b/data/cmdc_files/\346\211\271\351\207\217\345\257\274\345\205\245\346\224\266\350\264\247\345\234\260\345\235\200\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\250\241\346\235\277.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..ffe7cc4b8260bf27f2410afc3e6680e61c783af3 Binary files /dev/null and "b/data/cmdc_files/\347\273\217\351\224\200\345\225\206\345\205\263\350\201\224\345\214\273\351\231\242\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\350\241\245\350\264\247\350\256\276\347\275\256\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\350\241\245\350\264\247\350\256\276\347\275\256\346\250\241\346\235\277.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..3709f5538b734a7a97b76eedb4f9bca195eb18f7 Binary files /dev/null and "b/data/cmdc_files/\350\241\245\350\264\247\350\256\276\347\275\256\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..0cdcecf62c17a198d82a861dc0d9864c44de0fa6 Binary files /dev/null and "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\346\225\260\346\215\256\351\207\215\345\244\215.xlsx" "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\346\225\260\346\215\256\351\207\215\345\244\215.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..0ebd53a9c092d55106d4ad6964a9a43d8cbf8d39 Binary files /dev/null and "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\346\225\260\346\215\256\351\207\215\345\244\215.xlsx" differ diff --git "a/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..c9ef9d6a594961d740a39e26fbc8b27c083754d6 Binary files /dev/null and "b/data/cmdc_files/\350\266\205\345\217\221\351\205\215\347\275\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" differ diff --git "a/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..b374addb568aeae9d7b8f6645a4e8d81debea002 Binary files /dev/null and "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\345\277\205\345\241\253\345\255\227\346\256\265\347\251\272.xlsx" "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\345\277\205\345\241\253\345\255\227\346\256\265\347\251\272.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..418a325ea5f19ccfbac18fe35d752e65308d7bb2 Binary files /dev/null and "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\345\277\205\345\241\253\345\255\227\346\256\265\347\251\272.xlsx" differ diff --git "a/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..26c145f80e89d9eaa3488f3a454145e96a83c4f7 Binary files /dev/null and "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\347\251\272.xlsx" differ diff --git "a/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\351\207\215\345\244\215.xlsx" "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\351\207\215\345\244\215.xlsx" new file mode 100644 index 0000000000000000000000000000000000000000..c622aaf1d390967d544185678fdf83f61a1fc038 Binary files /dev/null and "b/data/cmdc_files/\351\207\207\350\264\255\345\215\217\350\256\256\345\257\274\345\205\245\346\250\241\346\235\277_\351\207\215\345\244\215.xlsx" differ diff --git "a/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\210\240\351\231\244\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\210\240\351\231\244\346\250\241\346\235\277.xlsx" index b13a812ed4a926a61d0f15e9d7e3d73a91a49a1c..d5154d4896377a6d136b4b288da1d73b2b06c08a 100644 Binary files "a/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\210\240\351\231\244\346\250\241\346\235\277.xlsx" and "b/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\210\240\351\231\244\346\250\241\346\235\277.xlsx" differ diff --git "a/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" "b/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" index 9527ac46685c2856b7238234655f94a946976fce..7c627870f37e2987096849bc53a77ac21b47db04 100644 Binary files "a/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" and "b/data/cmdc_files/\351\233\205\345\237\271\347\273\264\346\212\244\344\273\267\346\240\274\346\211\271\351\207\217\345\257\274\345\205\245\346\250\241\346\235\277.xlsx" differ diff --git a/data/cmdc_frequent_purchase/data b/data/cmdc_frequent_purchase/data index b307cca8c3eaaeb1250d3e9b554dca7efba7a74a..b7cafd27eb33f23811c1e13f2c4f7ced03555974 100644 --- a/data/cmdc_frequent_purchase/data +++ b/data/cmdc_frequent_purchase/data @@ -5,6 +5,9 @@ "username1": "admin" "password1": "Aa123456" +"username2": "Admin00111" +"password2": "Aa123456" + json_headers: { "Content-Type": "application/json", "Cmdc_access_token": "%s" @@ -127,7 +130,7 @@ checkDict7: {"success":true,"code":"200","message":"OK","data":"ok"} "payload8": {"currentCompanyId":null,"productId":"%d","quantity":1,"agreementPriceId":0,"price":"%d"} #预期结果 checkDict8: {'success': False, 'code': 'addFrequentPurchaseFail', 'message': '商品为失效状态,不可加入常购清单', 'data': None, 'freshToken': None} - +checkDict8_1: {"success":false,"code":"1078","message":"该商品不存在,加入购物车失败","data":null,"freshToken":null} #新增跨站点商品至常购清单列表 diff --git a/data/cmdc_fresenius_group/data b/data/cmdc_fresenius_group/data index cb533543441f36a72659d9c431b67c2adf0304c3..b278f4981cdd26cea5fd62cfe0e6ea6baea06c7f 100644 --- a/data/cmdc_fresenius_group/data +++ b/data/cmdc_fresenius_group/data @@ -2,10 +2,18 @@ "username": "BJ0621" "password": "Aa123456" +"username2": "GL1000086" +"password2": "Aa123456" + #后台运营管理系统登录信息(子站点上海医疗器械有限公司) "username1": "Admin00111" "password1": "Aa123456" +#后台运营管理系统登录信息(子站点国联医疗器械有限公司) +"username4": "Admin00102" +"password4": "Aa123456" + + #后台管理系统headers json_headers: { @@ -102,7 +110,7 @@ checkDict11: {"success":false,"code":"FRESENIUS_GROUP_ERROR","message":"已存 #测试场景十二:验证套包内商品非同一产品线限制 "url12": "/order/public/saveFreseniusGroup" -"payload12": {"manufacturerGroupName":"","manufacturerGroupCode":"","groupName":"","products":[{"productCode":"11792427","productName":"可吸收外科缝线","manufacturer":"贝朗医疗西班牙股份公司B.Braun Surgical SA","manufacturerCode":"7039686","optionStr":"C0023412","storageCondition":"999","activityUnitAmount":null,"price":1518,"measuringUnit":"盒","materialCode":"C0023412","description":"","quantity":"999999","manufacturerProductNo":null,"manufacturerProductDesc":null,"produceRegisterNum":"国械注进20193021757","productLineName":"蛇牌","productLineCode":"3046"},{"productCode":"13422435","productName":"造口护理用品附件","manufacturer":"康乐保公司 Coloplast A/S","manufacturerCode":"7038267","optionStr":"12050","storageCondition":"999","activityUnitAmount":null,"price":144.1,"measuringUnit":"支","materialCode":"","description":"","quantity":"999999","manufacturerProductNo":null,"manufacturerProductDesc":null,"produceRegisterNum":"国械备20191252号","productLineName":"康乐保","productLineCode":"3111"}],"productLineName":"蛇牌","status":0,"groupType":3} +"payload12": {"manufacturerGroupName":"","manufacturerGroupCode":"","groupName":"套包验证","products":[{"productCode":"10113417","productName":"植入类商品-演示用-时兴哲","manufacturer":"198测试-MF-时兴哲1","manufacturerCode":"7014009","optionStr":"A0001","storageCondition":"999","activityUnitAmount":null,"price":12.3,"measuringUnit":"个","materialCode":"A0001","description":"4","quantity":"1","manufacturerProductNo":null,"manufacturerProductDesc":null,"produceRegisterNum":null,"productLineName":"HHH测试产品线","productLineCode":"1006"},{"productCode":"10145928","productName":"威尔特","manufacturer":"北京康思润业生物技术有限公司-黄翼","manufacturerCode":"7014587","optionStr":"犬瘟热","storageCondition":"999","activityUnitAmount":null,"price":68.88,"measuringUnit":"个","materialCode":"","description":"","quantity":"1","manufacturerProductNo":null,"manufacturerProductDesc":null,"produceRegisterNum":"2134234","productLineName":"电商产品线","productLineCode":"DS-002"}],"productLineName":"HHH测试产品线","status":0,"groupType":3} #预期结果 checkDict12: {"success":false,"code":"FRESENIUS_GROUP_ERROR","message":"组成一个套包内商品需满足套包在同一产品线下","data":null,"freshToken":null} @@ -136,7 +144,7 @@ checkDict16_1: {"success":true,"code":"200","message":"OK","data":true} #预期结果 checkDict17: {"success":true,"code":"200","message":"OK","data":true,"freshToken":null} -checkDict17_1: {"success":true,"code":"200","message":"OK","data":true,"freshToken":null} +checkDict17_1: {"success":false,"code":"FRESENIUS_GROUP_ERROR","message":"该行套包名称系统已存在,无需重复添加!","data":null,"freshToken":null} #测试场景十八:套包批量新增 @@ -145,10 +153,10 @@ checkDict17_1: {"success":true,"code":"200","message":"OK","data":true,"freshTok #预期结果 checkDict18: {"success":true,"code":"200","message":"OK","data":{"success":true},"freshToken":null} -# 获取商品信息-产品线为麦迪康 +# 获取商品信息- "url19": "/product/public/productGroupList" -"payload19": {"productCode":"","productName":"","materialCode":"","specifications":"","productLineName":"麦迪康","userNo":"","companyCode":"00111","pageSize":10,"pageNum":1} - +"payload19": {"productCode":"","productName":"","materialCode":"","specifications":"","productLineName":"","userNo":"","companyCode":"","pageSize":10,"pageNum":1} +"payload19_1": {"productCode":"","productName":"","materialCode":"","specifications":"","productLineName":"史塞克关节","userNo":"","companyCode":"00111","pageSize":10,"pageNum":1} #测试场景二十:套包批量新增-套包名称已存在、结构与已有相同、商品数少于2、组成一个套包内商品需满足套包在同一产品线下、商品重复添加 #预期结果 @@ -184,6 +192,7 @@ checkDict24: {"success":true,"code":"200","message":"OK"} #测试场景二十四:验证套包中商品详情页面是否显示套包信息 #获取指定套包信息 "payload22": {"groupCode":"cpg00659551","groupName":"","productCode":"","productName":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","companyCode":"","productInfo":"","status":null,"pageStart":1,"pageSize":10,"groupType":3} +"payload22_1": {"groupCode":"","groupName":"","productCode":"","productName":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","companyCode":"","productInfo":"","status":null,"pageStart":1,"pageSize":10,"groupType":3} #获取套包信息接口和报文 "url25": "/order/public/getFreseniusGroup" "payload23": {"productCode":"%s","companyCode":"%s","detail":true,"buyCart":true,"num":1} @@ -209,7 +218,7 @@ checkDict27: {"success":true,"code":"200","message":"OK"} "url28": "/order/public/getFreseniusGroup" "payload28": {"productInfo":"%s","documentNo":null,"groupCode":null,"materialCode":null,"type":0,"productLineCode":"%s","companyCode":"%s","buyCart":true,"num":1,"groupProductCode":"%s","groupName":"%s","groupMaterialCode":"%s"} #预期结果 -checkDict28: {"groupCode":"%s"} +checkDict28: {"groupName":"%s"} #测试场景二十八:套包加入购物车验证 @@ -231,7 +240,7 @@ checkDict30: {"success":true,"code":"200","message":"OK"} #测试场景三十:创建需求单_普通套包 #需求单创建接口地址和报文 "url31": "/order/public/saveAllDemandOrder" -"payload31": {"国药集团上海医疗器械有限公司":{"datas":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":101,"productAmount":201,"payableAmount":101,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":100,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":100,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":100,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":49.75,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":true,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"rebateType":0},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7439,"productName":"一次性使用灭菌橡胶外科手套","productCode":"14479934","productNature":null,"brandName":null,"optionStr":"SFTCS1145E 7.5 无粉麻面","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/bb721764-a0ca-4ff7-9d63-778803bc0c68.jpg","lineNumber":null,"price":101,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":101,"measuringUnit":"副","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCS1145E-0040050","manufacturer":"TG MEDICAL SDN. BHD.","produceRegisterNum":"国械注进20172661704","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":101,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":50.25,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"rebateType":0}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"2012","productLineName":"麦迪康","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":201,"discountAmountWholeLine":0,"payableAmountWholeLine":201,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":2,"activityTotalAmount":0,"couponTotalAmount":100,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"edit":false,"productAmountWholeLine":201,"auditCompanyName":null,"auditCompanyNameCode":null,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"settementQuantity":2,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"totalPriceNum":0}],"addressConfig":2,"openPreTaxAmount":0,"promotionOrRebate":2,"promotionType":2,"productLineCodes":["2012"],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":100,"activityTotalAmount":0,"totalQuantity":2,"totalPrice":201,"discountAmount":0,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":100,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":100,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":100,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":49.75,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":true,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7439,"productName":"一次性使用灭菌橡胶外科手套","productCode":"14479934","productNature":null,"brandName":null,"optionStr":"SFTCS1145E 7.5 无粉麻面","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/bb721764-a0ca-4ff7-9d63-778803bc0c68.jpg","lineNumber":null,"price":101,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":101,"measuringUnit":"副","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCS1145E-0040050","manufacturer":"TG MEDICAL SDN. BHD.","produceRegisterNum":"国械注进20172661704","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":101,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":50.25,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":101,"fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":27568,"addressNo":82429,"addressName":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","provinceCode":null,"userId":null,"companyId":null,"receiverName":"/","address":"","isDefault":1,"type":null,"postcode":null,"mobile":"/","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":3,"companyId":6,"companyName":"国药集团上海医疗器械有限公司","registeredAddress":"上海市宝山区江杨南路880号厂房7幢V008","bank":"中国光大银行上海彭浦支行","accountName":"国药集团上海医疗器械有限公司","accountNumber":"36830188000041806","disableSign":0,"deleteSign":0,"createTime":"2021-05-06 10:46:15","updateTime":"2021-05-06 10:46:15","createBy":2795,"realName":"国药集团上海医疗器械有限公司admin"},"addressList":[{"addressId":27568,"addressNo":82429,"addressName":null,"provinceCode":null,"userId":null,"companyId":6,"receiverName":"/","address":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","isDefault":1,"type":3,"postcode":null,"mobile":"/","updateDate":120035,"updateTime":93623,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":27568,"receiverNote":"/","receiverPhoneNote":"/","receiverAddressNote":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","addressNoNote":82429,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"101.0000","taxRate":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":101,"productAmount":201,"payableAmount":101,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":100,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":100,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":100,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":49.75,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":true,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null,"rebateType":0},{"demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7439,"productName":"一次性使用灭菌橡胶外科手套","productCode":"14479934","productNature":null,"brandName":null,"optionStr":"SFTCS1145E 7.5 无粉麻面","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/bb721764-a0ca-4ff7-9d63-778803bc0c68.jpg","lineNumber":null,"price":101,"rebateId":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":101,"measuringUnit":"副","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCS1145E-0040050","manufacturer":"TG MEDICAL SDN. BHD.","produceRegisterNum":"国械注进20172661704","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":100,"realPay":101,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":50.25,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":[],"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":355,"fsGroupId":355,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"套包测试","skuGroup":{"id":null,"groupId":355,"companyCode":"00111","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00659551\\\",\\\"groupName\\\":\\\"套包测试\\\",\\\"groupCode1\\\":\\\"cpg00659551\\\",\\\"groupPrice\\\":201,\\\"groupProductType\\\":4,\\\"realPay\\\":201,\\\"subtotal\\\":201,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"100.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"},{\\\"activityUnitAmount\\\":\\\"101.0\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14479934\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupCode":"cpg00659551","groupName":"套包测试","groupCode1":"cpg00659551","groupPrice":201,"realPay":201,"subtotal":201,"quantity":1,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只+一次性使用灭菌橡胶外科手套(SFTCS1145E 7.5 无粉麻面)*1副","subList":[{"activityUnitAmount":"100.0","quantity":1,"productCode":"14037826"},{"activityUnitAmount":"101.0","quantity":1,"productCode":"14479934"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":1,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"cpg00659551","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"bol":false,"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null,"rebateType":0}],"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"2012","productLineName":"麦迪康","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":201,"discountAmountWholeLine":0,"payableAmountWholeLine":201,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":2,"activityTotalAmount":0,"couponTotalAmount":100,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"edit":false,"productAmountWholeLine":201,"auditCompanyName":null,"auditCompanyNameCode":null,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"settementQuantity":2,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"totalPriceNum":0,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":201,"paymentType":0,"accountId":3,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","addressNumber":82429,"receiverName":"/","receiverContact":"/","receiverAddress":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","buyerCartIds":[null],"sellerCompanyCode":"00111","companyId":6,"rebateType":0}} +"payload31": {"国药集团联合医疗器械有限公司":{"datas":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"DS-电商专用","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"224.1600","productAmount":224.16,"payableAmount":224.16,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":"包装规格:3&阿萨大","storageType":"002","suppDist":null,"productId":111470,"productName":"起搏电极导线-电商专用","productCode":"10145853","productNature":null,"brandName":null,"optionStr":"5078","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/09/28/c87288eb-9e09-4e65-951f-3ca2cda71568.jpg","lineNumber":null,"price":35.58,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":71.16,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5078","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20231213","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":71.16,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":2,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":"包装规格","propertyVal":"3","propertyNote":"阿萨大","sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"阿三大苏打","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":56.92},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":null,"storageType":"999","suppDist":null,"productId":111468,"productName":"起搏电极导线-电商专用","productCode":"10145851","productNature":null,"brandName":null,"optionStr":"5076","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/11/08/86af41cd-b623-4a98-8921-90cc77f01b67.jpg","lineNumber":null,"price":51,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":3,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":153,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5076","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20210202","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":153,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":1,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":3,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":"2024-02-29","installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":false,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":122.4}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":[{"rebateoperaskuid":null,"filialecode":"00102","rebateid":105,"customercode":null,"transactionamount":null,"transactiontype":null,"rebateStartTime":null,"rebateValidity":null,"balance":null,"deletesign":null,"note":null,"createtime":null,"updatetime":null,"demandId":null,"demandCode":null,"relevanceName":null,"rebateName":null,"customerCompanyName":null,"lineCodeDelete":null,"rebateTripId":null,"monNum":null,"relevanceCode":"DS-电商专用","pageSize":null,"pageNum":null,"startTime":null,"endTime":null,"userId":null,"customerCodeList":null,"filialeCodeList":null,"companyName":null,"reSign":null,"demandParentCode":null,"distributionCode":null,"frontNote":null,"backNote":null,"cancelId":null,"effectivetype":null,"validityperiodSign":null,"soCode":null,"rebatename":"起搏电极导线","useLimitStart":0.5,"useLimitEnd":0.8,"istax":1,"taxround":0,"isdisposable":0,"productCode":null,"isOperated":null,"userPrice":null,"rebateFalg":null}],"rebateAmountList":null,"productLineName":"DS-电商产品线","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":1,"paymentAmountWholeLine":224.16,"discountAmountWholeLine":0,"payableAmountWholeLine":224.16,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"1;2;3;4","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":1,"countFormula":1,"countNumber":0,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":"产品线级提示","shareType":2,"singleRebateSign":0,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":224.16,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":true,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":5,"userBalancePrice":0,"isEdit":true,"discountRateOne":100}],"addressConfig":2,"openPreTaxAmount":1,"notice":"站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示","remark":null,"receiverPhoneNote":"13810613577","promotionOrRebate":1,"promotionType":1,"productLineCodes":["DS-电商专用"],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":5,"totalPrice":224.16,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":"包装规格:3&阿萨大","storageType":"002","suppDist":null,"productId":111470,"productName":"起搏电极导线-电商专用","productCode":"10145853","productNature":null,"brandName":null,"optionStr":"5078","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/09/28/c87288eb-9e09-4e65-951f-3ca2cda71568.jpg","lineNumber":null,"price":35.58,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":71.16,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5078","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20231213","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":71.16,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":2,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":"包装规格","propertyVal":"3","propertyNote":"阿萨大","sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"阿三大苏打","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":56.92},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":null,"storageType":"999","suppDist":null,"productId":111468,"productName":"起搏电极导线-电商专用","productCode":"10145851","productNature":null,"brandName":null,"optionStr":"5076","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/11/08/86af41cd-b623-4a98-8921-90cc77f01b67.jpg","lineNumber":null,"price":51,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":3,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":153,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5076","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20210202","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":153,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":1,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":3,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":"2024-02-29","installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":false,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":122.4}],"productPrice":"224.1600","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":37354,"addressNo":17823,"addressName":"上海市浦东新区浦电路3号1","provinceCode":null,"userId":null,"companyId":null,"receiverName":"张梦怡","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"13810613577","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":5,"companyId":7,"companyName":"国药集团联合医疗器械有限公司","registeredAddress":"北京市顺义区金航中路3号院天竺万科中心1号楼3单元2层201(北京天竺综合保税区)","bank":"中国工商银行股份有限公司北京新街口支行","accountName":"国药集团联合医疗器械有限公司","accountNumber":"0200002919200155850","disableSign":0,"deleteSign":0,"createTime":"2021-06-03 09:46:49","updateTime":"2021-06-03 09:46:49","createBy":114378,"realName":"国药集团联合医疗器械有限公司admin"},"addressList":[{"addressId":37354,"addressNo":17823,"addressName":null,"provinceCode":null,"userId":null,"companyId":7,"receiverName":"张梦怡","address":"上海市浦东新区浦电路3号1","isDefault":0,"type":3,"postcode":null,"mobile":"13810613577","updateDate":123354,"updateTime":95133,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":37354,"receiverNote":"张梦怡","receiverAddressNote":"上海市浦东新区浦电路3号1","addressNoNote":17823,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"224.1600","taxRate":null,"draftDemandId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"DS-电商专用","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"224.1600","productAmount":224.16,"payableAmount":224.16,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":"包装规格:3&阿萨大","storageType":"002","suppDist":null,"productId":111470,"productName":"起搏电极导线-电商专用","productCode":"10145853","productNature":null,"brandName":null,"optionStr":"5078","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/09/28/c87288eb-9e09-4e65-951f-3ca2cda71568.jpg","lineNumber":null,"price":35.58,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":71.16,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5078","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20231213","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":71.16,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":2,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":"包装规格","propertyVal":"3","propertyNote":"阿萨大","sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"阿三大苏打","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":56.92,"orderType":null},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"DS-电商专用","productLineName":"DS-电商产品线","propertyStr":null,"storageType":"999","suppDist":null,"productId":111468,"productName":"起搏电极导线-电商专用","productCode":"10145851","productNature":null,"brandName":null,"optionStr":"5076","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2022/11/08/86af41cd-b623-4a98-8921-90cc77f01b67.jpg","lineNumber":null,"price":51,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0.5,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":3,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":153,"measuringUnit":"个","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"5076","manufacturer":"山东育达医疗设备有限公司-电商专用","produceRegisterNum":"国械注准20210202","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":153,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":1,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":825,"fsGroupId":825,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":"DS-电商产品线套包000001","skuGroup":{"id":null,"groupId":825,"companyCode":"00102","groupProductType":4,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"groupCode\\\":\\\"cpg00343339\\\",\\\"groupName\\\":\\\"DS-电商产品线套包000001\\\",\\\"groupCode1\\\":\\\"cpg00343339\\\",\\\"groupPrice\\\":224.16,\\\"groupProductType\\\":4,\\\"realPay\\\":224.16,\\\"subtotal\\\":224.16,\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"35.58\\\",\\\"quantity\\\":2,\\\"productCode\\\":\\\"10145853\\\"},{\\\"activityUnitAmount\\\":\\\"51.0\\\",\\\"quantity\\\":3,\\\"productCode\\\":\\\"10145851\\\"}]}","lineNumber":null,"freseniusPriceId":null,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"groupCode":"cpg00343339","groupName":"DS-电商产品线套包000001","groupCode1":"cpg00343339","groupPrice":224.16,"realPay":224.16,"subtotal":224.16,"quantity":1,"calSubFreName":"起搏电极导线-电商专用(5078)*2个+起搏电极导线-电商专用(5076)*3个","subList":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"oldObjArr":[{"activityUnitAmount":"35.58","quantity":2,"productCode":"10145853"},{"activityUnitAmount":"51.0","quantity":3,"productCode":"10145851"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":3,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":"2024-02-29","installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"cpg00343339","groupProductType":4,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":true,"giftList":[],"bol":false,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"useLimitEnd":0.8,"maxuseLimit":122.4,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":[{"rebateoperaskuid":null,"filialecode":"00102","rebateid":105,"customercode":null,"transactionamount":null,"transactiontype":null,"rebateStartTime":null,"rebateValidity":null,"balance":null,"deletesign":null,"note":null,"createtime":null,"updatetime":null,"demandId":null,"demandCode":null,"relevanceName":null,"rebateName":null,"customerCompanyName":null,"lineCodeDelete":null,"rebateTripId":null,"monNum":null,"relevanceCode":"DS-电商专用","pageSize":null,"pageNum":null,"startTime":null,"endTime":null,"userId":null,"customerCodeList":null,"filialeCodeList":null,"companyName":null,"reSign":null,"demandParentCode":null,"distributionCode":null,"frontNote":null,"backNote":null,"cancelId":null,"effectivetype":null,"validityperiodSign":null,"soCode":null,"rebatename":"起搏电极导线","useLimitStart":0.5,"useLimitEnd":0.8,"istax":1,"taxround":0,"isdisposable":0,"productCode":null,"isOperated":null,"userPrice":null,"rebateFalg":null}],"rebateAmountList":null,"productLineName":"DS-电商产品线","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":1,"paymentAmountWholeLine":224.16,"discountAmountWholeLine":0,"payableAmountWholeLine":224.16,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"1;2;3;4","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":1,"countFormula":1,"countNumber":0,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":"产品线级提示","shareType":2,"singleRebateSign":0,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":224.16,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":true,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":5,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":224.16,"paymentType":0,"accountId":5,"version":null,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","addressNumber":17823,"receiverName":"张梦怡","receiverContact":"13810613577","receiverAddress":"上海市浦东新区浦电路3号1","buyerCartIds":[null],"sellerCompanyCode":"00102","companyId":7}} #预期结果 checkDict31: {"demandCode": "%s"} diff --git a/data/cmdc_hospital/data b/data/cmdc_hospital/data new file mode 100644 index 0000000000000000000000000000000000000000..cb03ff67368110cd78c74dc50fbdb20591e8c3f8 --- /dev/null +++ b/data/cmdc_hospital/data @@ -0,0 +1,208 @@ +# 多采商城登录信息 +"username": "BJ0621" +"password": "Aa123456" + +"username3": "GL1000086" +"password3": "Aa123456" + +#后台运营管理系统登录信息(子站点上海医疗器械有限公司) +"username1": "Admin00111" +"password1": "Aa123456" + +#后台运营管理系统登录信息(子站点国联) +"username2": "Admin00102" +"password2": "Aa123456" + +"username_be": "admin2" +"password_be": "@Aa123456" + +#后台管理系统headers +json_headers: { + "Content-Type": "application/json", + "Cmdc_access_token": "%s" +} + +#文件上传headers +json_headers_file: { + "Cmdc_access_token": "%s" +} + +json_headers_file_1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#多采商城headers +json_headers1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#测试场景一:获取上报植入列表 +"url1": "/order/public/queryHospitalBillPage" +"payload1": {"companyCode":null,"customerCode":null,"customerName":null,"soCode":null,"demandCode":null,"demandParentCode":null,"productLineCode":null,"productCode":null,"productName":null,"optionStr":null,"manufacturer":null,"materialCode":null,"reportedSign":null,"isReportedEnd":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict1: {"success":true,"code":"200","message":"OK"} + +#测试场景二:获取医院账单详情 +"url2": "/order/back/getHospitalBillDetail" +"payload2": {"soCode":"%s"} +#预期结果 +checkDict2: {"soCode":"%s"} + +#测试场景三:植入台账导出功能验证 +"url3": "/order/back/exportHospitalBillDetail" +"payload3": {"companyCode":null,"customerCode":null,"customerName":null,"soCode":null,"demandCode":"%s","demandParentCode":null,"productLineCode":null,"productCode":null,"productName":null,"optionStr":null,"manufacturer":null,"materialCode":null,"reportedSign":null,"isReportedEnd":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict3: {"demandCode":"%s"} + +#测试场景四:获取经销商关联医院管理列表 +"url4": "/order/public/hospitalCustomer/list" +"payload4": {"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict4: {"success":true,"code":"200","message":"OK"} + +#测试场景五:列表查询条件验证_经销商关联医院管理列表 +"url5": "/order/public/hospitalCustomer/list" +"payload5": {"customerCode":"%s","customerName":"%s","hospitalCode":"%s","hospitalName":"%s","pageStart":null,"pageSize":null,"total":null} +#预期结果 +checkDict5: {"customerCode":"%s"} + + +#测试场景六:经销商关联医院导出功能验证 +"url6": "/order/public/hospitalCustomer/export" +"payload6": {} +#预期结果 +checkDict6: {"total":"%s"} + +#测试场景七:获取经销商列表 +"url7": "/user/querySubCustomerPage" +"payload7": {"pageStart":1,"pageSize":10,"total":null,"companyId":"7"} +#预期结果 +checkDict7: {"success":true,"code":"200","message":"OK"} + + +#测试场景八:列表查询条件验证_经销商列表 +"url8": "/user/querySubCustomerPage" +"payload8": {"pageStart":1,"pageSize":10,"total":null,"companyId":"7","telephone":"%s","userName":"%s","userNo":"%s","customerCompanyName":"%s"} +#预期结果 +checkDict8: {"customerCompanyName":"%s"} + + +#测试场景九:获取关联医院列表 +"url9": "/order/public/hospitalArchive/list" +"payload9": {"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict9: {"success":true,"code":"200","message":"OK"} + + +#测试场景十:列表查询条件验证_关联医院列表 +"url10": "/order/public/hospitalArchive/list" +"payload10": {"pageStart":1,"pageSize":10,"total":null,"hospitalCode":"%s","hospitalName":"%s"} +#预期结果 +checkDict10: {"hospitalCode":"%s"} + + + +#测试场景十一:列表查询条件验证_关联医院列表 +"url11": "/order/public/hospitalArchive/list" +"payload11": {"pageStart":1,"pageSize":10,"total":null,"hospitalCode":"%s","hospitalName":"%s"} +#预期结果 +checkDict11: {"hospitalCode":"%s"} + +#测试场景十二:经销商关联医院新增功能验证 +"url12": "/order/public/hospitalCustomer/add" +"payload12": {"customerName":"中国船舶集团物资有限公司","customerCode":"1228325","hospitalName":"安贞医院","hospitalCode":"0010227","companyCode":"00102"} +#预期结果 +checkDict12: {"customerCode": "1228325"} + +#测试场景十三:经销商关联医院信息编辑功能验证 +"url13": "/order/public/hospitalCustomer/edit" +#预期结果 +checkDict13: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +# 获取指定医院 +"url13_1": "/order/public/hospitalCustomer/list?pageNum=1&customerCode=1228325&hospitalCode=0010227&pageStart=1&pageSize=10&total=" + +#测试场景十四:经销商关联医院批量新增功能验证 +"url14": "/order/public/hospitalCustomer/importExcel" +#预期结果 +checkDict14: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} + +#测试场景十五:导入日志查看验证 +"url15": "/order/public/excelLog/list?sheetName=hospitalCustomer&pageStart=1&pageSize=10&total=" +#预期结果 +checkDict15: {"status":2} + +#测试场景十六:经销商关联医院删除功能验证 +"url16": "/order/public/hospitalCustomer/delete" +"payload16": {"ids":"%s"} +#预期结果 +checkDict16: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +# 获取医院信息 +"url16_1": "/order/public/hospitalCustomer/list?customerCode=1228325&pageStart=1&pageSize=10&total=" + + +#测试场景十七:医院档案信息批量导出功能验证 +"url17": "/order/public/hospitalArchive/export" +"payload17": {"hospitalCode":"%s"} +#预期结果 +checkDict17: {"hospitalCode":"%s"} + +#测试场景十八:新增医院档案功能验证 +"url18": "/order/public/hospitalArchive/add" +"payload18": {"hospitalName":"测试添加医院档案功能","provinceId":464,"province":"辽宁省","cityId":479,"city":"大连市","companyCode":"00102"} +#预期结果 +checkDict18: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} + + +#测试场景十九:医院档案信息编辑功能验证 +"url19": "/order/public/hospitalArchive/edit" +#预期结果 +checkDict19: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} +#获取指定的医院档案 +"url19_1": "/order/public/hospitalArchive/list" +"payload19_1": {"pageStart":1,"pageSize":10,"total":null,"hospitalName":"测试添加医院档案功能"} + + +#测试场景二十:医院档案信息删除功能验证 +"url20": "/order/public/hospitalArchive/delete" +"payload20": {"ids":"%s"} +#预期结果 +checkDict20: {"success":true,"code":"200","message":"OK","data":null,"freshToken":null} + + +#测试场景二十一:获取宽限期管理列表 +"url21": "/order/public/queryHospitalGracePage" +"payload21": {"companyCode":null,"productLineCode":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict21: {"success":true,"code":"200","message":"OK"} + +#测试场景二十二:列表查询条件验证_宽限期管理 +"url22": "/order/public/queryHospitalGracePage" +"payload22": {"companyCode":null,"productLineCode":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict22: {"productLineCode":"%s"} + + +#测试场景二十三:宽限期管理批量导出功能验证 +"url23": "/order/public/exportHospitalGraceList" +"payload23": {"companyCode":null,"productLineCode":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict23: {"productLineCode":"%s"} + + + + + + + + + + + + + + + + + diff --git a/data/cmdc_order_handle/data b/data/cmdc_order_handle/data index b9a8c027aadfee9897c1b320a7e27b92b3990200..f943a1b34ce3e760a35dd3aa71dce67cb2982355 100644 --- a/data/cmdc_order_handle/data +++ b/data/cmdc_order_handle/data @@ -2,10 +2,16 @@ "username": "BJ0621" "password": "Aa123456" +"username2": "GL1000086" +"password2": "Aa123456" + #后台运营管理系统登录信息(子站点上海医疗器械有限公司) "username1": "Admin00111" "password1": "Aa123456" +#后台运营管理系统登录信息(子站点北京医疗器械有限公司) +"username4": "Admin00102" +"password4": "Aa123456" #后台管理系统headers json_headers: { @@ -174,7 +180,7 @@ checkDict18: {"success":true,"code":"200","message":"ok"} #测试场景十九:商品下架拦截验证_下单 #接口信息 "url19": "/order/public/saveAllDemandOrder" -"payload19": {"国药集团上海医疗器械有限公司":{"datas":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"48.2500","productAmount":48.25,"payableAmount":48.25,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"3111","productLineName":"康乐保","propertyStr":null,"storageType":"999","suppDist":null,"productId":7991,"productName":"水胶体油纱","productCode":"10056338","productNature":"01","brandName":null,"optionStr":"3915","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/be146b0a-4998-4e03-b250-17ed8d846f8b.jpg","lineNumber":null,"price":48.25,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":48.25,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"","manufacturer":"Coloplast A/S","produceRegisterNum":null,"riskRank":"003","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":48.25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"3915","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":true,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":1852.1,"useLimitEnd":1,"maxuseLimit":48.25}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":[{"rebateoperaskuid":null,"filialecode":"00111","rebateid":111,"customercode":null,"transactionamount":null,"transactiontype":null,"rebateStartTime":null,"rebateValidity":null,"balance":null,"deletesign":null,"note":null,"createtime":null,"updatetime":null,"demandId":null,"demandCode":null,"relevanceName":null,"rebateName":null,"customerCompanyName":null,"lineCodeDelete":null,"rebateTripId":null,"monNum":null,"relevanceCode":"3111","pageSize":null,"pageNum":null,"startTime":null,"endTime":null,"userId":null,"customerCodeList":null,"filialeCodeList":null,"companyName":null,"reSign":null,"demandParentCode":null,"distributionCode":null,"frontNote":null,"backNote":null,"cancelId":null,"effectivetype":null,"validityperiodSign":null,"soCode":null,"rebatename":"康乐保20230619","useLimitStart":0,"useLimitEnd":1,"istax":1,"taxround":0,"isdisposable":0,"productCode":null,"isOperated":null,"userPrice":null,"rebateFalg":null}],"rebateAmountList":null,"productLineCode":"3111","productLineName":"康乐保","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":1,"paymentAmountWholeLine":48.25,"discountAmountWholeLine":0,"payableAmountWholeLine":48.25,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":1852.1,"liquidCode":null,"shipmentTypeStr":null,"specifications":"3915","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"1","rebateControlSign":1,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":1,"countFormula":1,"countNumber":0,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":1,"singleRebateSign":0,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":48.25,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":1852.1,"isEdit":true,"discountRateOne":100,"_rebateType":true}],"addressConfig":2,"openPreTaxAmount":0,"remark":null,"receiverPhoneNote":"/","promotionOrRebate":1,"promotionType":1,"productLineCodes":["3111"],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":48.25,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"3111","productLineName":"康乐保","propertyStr":null,"storageType":"999","suppDist":null,"productId":7991,"productName":"水胶体油纱","productCode":"10056338","productNature":"01","brandName":null,"optionStr":"3915","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/be146b0a-4998-4e03-b250-17ed8d846f8b.jpg","lineNumber":null,"price":48.25,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":48.25,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"","manufacturer":"Coloplast A/S","produceRegisterNum":null,"riskRank":"003","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":48.25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"3915","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":true,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":1852.1,"useLimitEnd":1,"maxuseLimit":48.25}],"productPrice":"48.2500","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"defaultBankInfo":{"accountId":3,"companyId":6,"companyName":"国药集团上海医疗器械有限公司","registeredAddress":"上海市宝山区江杨南路880号厂房7幢V008","bank":"中国光大银行上海彭浦支行","accountName":"国药集团上海医疗器械有限公司","accountNumber":"36830188000041806","disableSign":0,"deleteSign":0,"createTime":"2021-05-06 10:46:15","updateTime":"2021-05-06 10:46:15","createBy":2795,"realName":"国药集团上海医疗器械有限公司admin"},"receiveInfo":[{"addressId":27568,"addressNo":82429,"addressName":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","provinceCode":null,"userId":null,"companyId":null,"receiverName":"/","address":"","isDefault":1,"type":null,"postcode":null,"mobile":"/","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"addressList":[{"addressId":27568,"addressNo":82429,"addressName":null,"provinceCode":null,"userId":null,"companyId":6,"receiverName":"/","address":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","isDefault":1,"type":3,"postcode":null,"mobile":"/","updateDate":120035,"updateTime":93623,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":27568,"receiverNote":"/","receiverAddressNote":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","addressNoNote":82429,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"48.2500","taxRate":null,"draftDemandId":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"48.2500","productAmount":48.25,"payableAmount":48.25,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"3111","productLineName":"康乐保","propertyStr":null,"storageType":"999","suppDist":null,"productId":7991,"productName":"水胶体油纱","productCode":"10056338","productNature":"01","brandName":null,"optionStr":"3915","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/13/be146b0a-4998-4e03-b250-17ed8d846f8b.jpg","lineNumber":null,"price":48.25,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":0,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":48.25,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"","manufacturer":"Coloplast A/S","produceRegisterNum":null,"riskRank":"003","productClassify":"6864","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":48.25,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"3915","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":true,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":1852.1,"useLimitEnd":1,"maxuseLimit":48.25,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":[{"rebateoperaskuid":null,"filialecode":"00111","rebateid":111,"customercode":null,"transactionamount":null,"transactiontype":null,"rebateStartTime":null,"rebateValidity":null,"balance":null,"deletesign":null,"note":null,"createtime":null,"updatetime":null,"demandId":null,"demandCode":null,"relevanceName":null,"rebateName":null,"customerCompanyName":null,"lineCodeDelete":null,"rebateTripId":null,"monNum":null,"relevanceCode":"3111","pageSize":null,"pageNum":null,"startTime":null,"endTime":null,"userId":null,"customerCodeList":null,"filialeCodeList":null,"companyName":null,"reSign":null,"demandParentCode":null,"distributionCode":null,"frontNote":null,"backNote":null,"cancelId":null,"effectivetype":null,"validityperiodSign":null,"soCode":null,"rebatename":"康乐保20230619","useLimitStart":0,"useLimitEnd":1,"istax":1,"taxround":0,"isdisposable":0,"productCode":null,"isOperated":null,"userPrice":null,"rebateFalg":null}],"rebateAmountList":null,"productLineCode":"3111","productLineName":"康乐保","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":1,"paymentAmountWholeLine":48.25,"discountAmountWholeLine":0,"payableAmountWholeLine":48.25,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":1852.1,"liquidCode":null,"shipmentTypeStr":null,"specifications":"3915","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"1","rebateControlSign":1,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":1,"countFormula":1,"countNumber":0,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":1,"singleRebateSign":0,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":48.25,"auditCompanyName":null,"auditCompanyNameCode":null,"edit":false,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":1852.1,"isEdit":true,"discountRateOne":100,"_rebateType":true,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":48.25,"paymentType":0,"accountId":3,"version":null,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","addressNumber":82429,"receiverName":"/","receiverContact":"/","receiverAddress":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","buyerCartIds":[""],"sellerCompanyCode":"00111","companyId":6}} +"payload19": {"国药集团联合医疗器械有限公司":{"datas":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"720.3800","productAmount":720.38,"payableAmount":720.38,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9184,"productName":"认证包","productCode":"14384307","productNature":"03","brandName":null,"optionStr":"TPVL200","imageUrl":null,"lineNumber":null,"price":720.38,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":720.38,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"TPVL200","manufacturer":"Dornoch Medical Systems, Inc.","produceRegisterNum":null,"riskRank":"","productClassify":"9998","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":720.38,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"TPVL200","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":0,"paymentAmountWholeLine":720.38,"discountAmountWholeLine":0,"payableAmountWholeLine":720.38,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"TPVL200","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":720.38,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false}],"addressConfig":2,"openPreTaxAmount":1,"notice":"站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示","remark":null,"receiverPhoneNote":"13810613577","promotionOrRebate":1,"promotionType":1,"productLineCodes":[""],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":720.38,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9184,"productName":"认证包","productCode":"14384307","productNature":"03","brandName":null,"optionStr":"TPVL200","imageUrl":null,"lineNumber":null,"price":720.38,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":720.38,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"TPVL200","manufacturer":"Dornoch Medical Systems, Inc.","produceRegisterNum":null,"riskRank":"","productClassify":"9998","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":720.38,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"TPVL200","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"720.3800","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":37354,"addressNo":17823,"addressName":"上海市浦东新区浦电路3号1","provinceCode":null,"userId":null,"companyId":null,"receiverName":"张梦怡","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"13810613577","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":5,"companyId":7,"companyName":"国药集团联合医疗器械有限公司","registeredAddress":"北京市顺义区金航中路3号院天竺万科中心1号楼3单元2层201(北京天竺综合保税区)","bank":"中国工商银行股份有限公司北京新街口支行","accountName":"国药集团联合医疗器械有限公司","accountNumber":"0200002919200155850","disableSign":0,"deleteSign":0,"createTime":"2021-06-03 09:46:49","updateTime":"2021-06-03 09:46:49","createBy":114378,"realName":"国药集团联合医疗器械有限公司admin"},"addressList":[{"addressId":37354,"addressNo":17823,"addressName":null,"provinceCode":null,"userId":null,"companyId":7,"receiverName":"张梦怡","address":"上海市浦东新区浦电路3号1","isDefault":0,"type":3,"postcode":null,"mobile":"13810613577","updateDate":123354,"updateTime":95133,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":37354,"receiverNote":"张梦怡","receiverAddressNote":"上海市浦东新区浦电路3号1","addressNoNote":17823,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"720.3800","taxRate":null,"draftDemandId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"720.3800","productAmount":720.38,"payableAmount":720.38,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9184,"productName":"认证包","productCode":"14384307","productNature":"03","brandName":null,"optionStr":"TPVL200","imageUrl":null,"lineNumber":null,"price":720.38,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":720.38,"measuringUnit":"个","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","pricingMeasuringUnit":"EA","materialCode":"TPVL200","manufacturer":"Dornoch Medical Systems, Inc.","produceRegisterNum":null,"riskRank":"","productClassify":"9998","createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":720.38,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"TPVL200","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":0,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":0,"paymentAmountWholeLine":720.38,"discountAmountWholeLine":0,"payableAmountWholeLine":720.38,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":"TPVL200","pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":720.38,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"showInfo":false,"addressConfig":2,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":720.38,"paymentType":0,"accountId":5,"version":null,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","addressNumber":17823,"receiverName":"张梦怡","receiverContact":"13810613577","receiverAddress":"上海市浦东新区浦电路3号1","buyerCartIds":[""],"sellerCompanyCode":"00102","companyId":7}} #预期结果 checkDict19: {"message": "商品证照校验错误"} @@ -198,7 +204,7 @@ checkDict21: {"productAmount":"%s"} #验证进行订单提交时,修改商品金额,订单是否按修改前商品金额计算 #预期结果 -checkDict22: {"productAmount":"48.25"} +checkDict22: {"productAmount":"720.38"} #测试场景二十三:获取收款账号接口验证 @@ -210,4 +216,8 @@ checkDict23: {"companyId":"%s"} #商品无效断言结果 -checkDictInvalid: {"success":false,"code":"ERROR","message":"当前订单无有效商品","data":null,"freshToken":null} \ No newline at end of file +checkDictInvalid: {"success":false,"code":"ERROR","message":"当前订单无有效商品","data":null,"freshToken":null} +checkDict_30461: {"success":false,"code":"30461","message":"商品证照校验错误"} + +# 打印出存在问题的需求单信息 +checkDict_code: {"demandCode":"%s"} \ No newline at end of file diff --git a/data/cmdc_order_list/data b/data/cmdc_order_list/data new file mode 100644 index 0000000000000000000000000000000000000000..9434214f825b26ff82c07b85e8e2deeeb475e6b5 --- /dev/null +++ b/data/cmdc_order_list/data @@ -0,0 +1,1003 @@ +# 多采商城登录信息 +"username": "BJ0621" +"password": "Aa123456" + +"username3": "GL1000086" +"password3": "Aa123456" + +#后台运营管理系统登录信息(子站点上海医疗器械有限公司) +"username1": "Admin00111" +"password1": "Aa123456" + +#后台运营管理系统登录信息(子站点国联) +"username2": "Admin00102" +"password2": "Aa123456" + +"username_be": "admin2" +"password_be": "@Aa123456" + +#后台管理系统headers +json_headers: { + "Content-Type": "application/json", + "Cmdc_access_token": "%s" +} + +#文件上传headers +json_headers_file: { + "Cmdc_access_token": "%s" +} + +json_headers_file_1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#多采商城headers +json_headers1: { + "Cmdc_access_token": "%s", + "Sourcetype": "mall" +} + +#测试场景一:获取需求单列表_后台运营系统 +"url1": "/order/back/listDemand" +"payload1": {"times":[null],"listOrderStatus":[],"productName":null,"demandCode":null,"demandParentCode":null,"customerName":null,"manufacturer":null,"materialCode":null,"sellerCompanyName":null,"produceRegisterNum":null,"productLineName":null,"auditByName":null,"orderSource":null,"changeTypeList":null,"isRebateEdit":null,"jdeType":null,"pageSize":10,"pageStart":1,"orderChangeType":null,"snSgin":null,"changeSign":null,"customerCode":null,"distributionType":null,"busCustomerCode":null,"loginName":null,"cancelSign":0,"shipmentType":null,"siteType":null,"siteCompanyCode":null,"groupQuery":0,"promotionTypeList":[],"isGroup":[],"isReplace":null,"startTime":null,"itemStart":0} +#预期结果 +checkDict1: {"total":"%s"} + +#测试场景二:获取jde配货列表 +"url2": "/order/distributiondsJdeDs/getDistributiondsJdeDsList" +"payload2": {"demandCode":null,"distributionJdeDsCode":null,"pushType":null,"mergeSign":null,"customerInfo":null,"productCode":null,"soCode":null,"optionStr":null,"materialCode":null,"mergeTimeStart":null,"mergeTimeEnd":null,"submitTimeStart":null,"submitTimeEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"mergeCode":null,"code":null,"jdeType":null,"activityType":null,"fieldName":1,"filedSort":2,"isGroup":0,"pageNumber":1,"pageSize":10} +# 获取已推送配货单 +"payload2_1": {"demandCode":null,"distributionJdeDsCode":null,"pushType":2,"mergeSign":null,"customerInfo":null,"productCode":null,"soCode":null,"optionStr":null,"materialCode":null,"mergeTimeStart":null,"mergeTimeEnd":null,"submitTimeStart":null,"submitTimeEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"mergeCode":null,"code":null,"jdeType":null,"activityType":null,"fieldName":1,"filedSort":2,"isGroup":0,"pageNumber":1,"pageSize":10} +#预期结果 +checkDict2: {"total":"%s"} + +#测试场景三:配货单导出_jde配货列表 +"url3": "/order/distributiondsJdeDs/execlExportDetail" +"payload3": {"demandCode":"","distributionJdeDsCode":"","pushType":"","mergeSign":"","customerInfo":"","productCode":"","soCode":"","optionStr":"","materialCode":"","mergeTimeStart":"","mergeTimeEnd":"","submitTimeStart":"","submitTimeEnd":"","auditTimeStart":"","auditTimeEnd":"","mergeCode":"","code":"%s","jdeType":"","times":null,"times2":null,"times3":null,"activityType":"","fieldName":1,"filedSort":2,"isGroup":0,"pageNumber":1,"pageSize":10} +#预期结果 +checkDict3: {"code":"%s"} + +#测试场景四:获取导入日志信息_jde配货列表 +"url4": "/order/public/excelLog/list" +"payload4": {"sheetName":"distributiondsJdeDsTemplate","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict4: {"total":"%s"} + +#测试场景五:查询条件验证_jde配货列表 +"url5": "/order/distributiondsJdeDs/getDistributiondsJdeDsList" +"payload5": {"demandCode":null,"distributionJdeDsCode":"%s","pushType":"%s","mergeSign":"%s","customerInfo":"%s","productCode":"%s","soCode":"%s","optionStr":"%s","materialCode":"%s","mergeTimeStart":null,"mergeTimeEnd":null,"submitTimeStart":null,"submitTimeEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"mergeCode":"%s","code":"%s","jdeType":"%s","activityType":"%s","fieldName":1,"filedSort":2,"isGroup":"%s","pageNumber":1,"pageSize":10} +#预期结果 +checkDict5: {"code":"%s"} + +#测试场景六:获取采购单列表 +"url6": "/order/purchase/list" +"payload6": {"billNo":"","billStatusList":[],"creator":"","demandNo":"","startTime":"","endTime":"","times":null,"status":null,"pageNumber":1,"pageSize":8} +#预期结果 +checkDict6: {"total":"%s"} + +#测试场景七:查询条件验证_采购单列表 +"url7": "/order/purchase/list" +"payload7": {"billNo":"%s","billStatusList":["%s"],"creator":"%s","demandNo":"%s","startTime":"%s","endTime":"%s","times":["%s","%s"],"status":null,"pageNumber":1,"pageSize":8} +#预期结果 +checkDict7: {"billNo":"%s"} + + +#测试场景八:采购单导出验证_采购单列表 +"url8": "/order/purchase/exportList" +"payload8": {"billNo":"%s","billStatusList":[],"creator":"","demandNo":"","startTime":"","endTime":"","times":null,"status":null,"pageNumber":1,"pageSize":8} +#预期结果 +checkDict8: {"billNo":"%s"} + + +#测试场景九:查询采购单详情信息 +"url9": "/order/purchase/detail" +"payload9": {"purchaseId":"%s","purchaseCode":"%s"} +#预期结果 +checkDict9: {"purchaseId":"%s"} + +#测试场景十:采购单新增验证 +"url10": "/order/purchase/submit" +"payload10": {"purchaseEntryReqVos":[{"manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","materialCode":"VH-100","measuringUnit":"盒","productCode":"11852135","productId":7892,"productName":"测瓣器及其组件","purchaseEntryId":null,"purchaseId":null,"purchaseLineNumber":null,"purchaseQty":"1","specifications":"VH-100"}],"remark":""} +#预期结果 +checkDict10: {"productCode":"11852135"} + +#测试场景十一:采购数量不能为空_采购单新增 +"url11": "/order/purchase/submit" +"payload11": {"purchaseEntryReqVos":[{"manufacturer":"SORIN GROUP ITALIA S.R.L. 索林集团意大利有限责任公司","materialCode":"VH-100","measuringUnit":"盒","productCode":"11852135","productId":7892,"productName":"测瓣器及其组件","purchaseEntryId":null,"purchaseId":null,"purchaseLineNumber":null,"purchaseQty":null,"specifications":"VH-100"}],"remark":""} +#预期结果 +checkDict11: {"success":false,"code":"500","message":"采购数量不能为空","data":null,"freshToken":null} + +#测试场景十二:采购明细不能为空_采购单新增 +"url12": "/order/purchase/submit" +"payload12": {"purchaseEntryReqVos":null,"remark":""} +#预期结果 +checkDict12: {"success":false,"code":"500","message":"采购单明细不能为空","data":null,"freshToken":null} + +#测试场景十三:必填字段校验_查看采购单详情 +"url13": "/order/purchase/detail" +"payload13": {} +#预期结果 +checkDict13: {"success":false,"code":"500","message":"采购单id不能为空","data":null,"freshToken":null} + + +#测试场景十四:字段值有效性校验_查看采购单详情 +"url14": "/order/purchase/detail" +"payload14": {"purchaseId":"%s"} +#预期结果 +checkDict14: {"success":false,"code":"order-pur-001","message":"采购单单据不存在或已被删除","data":null,"freshToken":null} + + +#测试场景十五:查询商品信息_采购单新增 +"url15": "/product/mall/queryProductInfoByPage" +"payload15": {"companyCode":"00111","productCode":"%s"} +#预期结果 +checkDict15: {"productCode":"%s"} +# 查询商品信息 +"url15_1": "/product/mall/queryProductInfoByPage" +"payload15_1": {"isFbList":0,"filialeCode":null,"productName":null,"productCode":null,"specifications":null,"materialCode":null,"manufacturer":null,"lineName":null,"riskRank":null,"isRelease":"1","isExistImage":null,"jdeStatus":"P","isGift":"0","description":null,"tbsj":[],"pageNum":1,"pageSize":8,"total":1641,"firstQuery":true,"flag":true,"preInvalidStatus":null,"isControlSales":"0","startTime":null,"endTime":null,"status":101} + +#测试场景十六:通过Excel复制添加商品_采购单新增 +"url16": "/product/public/excelCopySku" +"payload16": {"queryList":[{"productCode":"%s","quantity":"1"}],"companyCode":"00111"} +#预期结果 +checkDict16: {"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,该商品不存在!\n","data":[],"maps":null},"freshToken":null} + + +#测试场景十七:必传字段校验_通过Excel复制添加商品 +"url17": "/product/public/excelCopySku" +"payload17": {"queryList":[{"productCode":"","quantity":""}],"companyCode":"00111"} +#预期结果 +checkDict17: {"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":null},"freshToken":null} + + +#测试场景十八:必填字段校验_勾选合并_jde配货管理 +"url18": "/order/distributiondsJdeDs/merge" +"payload18": {"ids":""} +#预期结果 +checkDict18: {"success":false,"code":"ERROR","message":"至少两个才能合并","data":null,"freshToken":null} + +#测试场景十九:合并已推送配货单校验验证 +"url19": "/order/distributiondsJdeDs/merge" +"payload19": {"ids":"%s"} +#预期结果 +checkDict19: {"success":false,"code":"ERROR","message":"%s配货状态错误","data":null,"freshToken":null} +# 获取已推送的配货单 +"url19_1": "/order/distributiondsJdeDs/getDistributiondsJdeDsList" +"payload19_1": {"demandCode":null,"distributionJdeDsCode":null,"pushType":2,"mergeSign":null,"customerInfo":null,"productCode":null,"soCode":null,"optionStr":null,"materialCode":null,"mergeTimeStart":null,"mergeTimeEnd":null,"submitTimeStart":null,"submitTimeEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"mergeCode":null,"code":null,"jdeType":null,"activityType":null,"fieldName":1,"filedSort":2,"isGroup":0,"pageNumber":1,"pageSize":10} + + +#测试场景二十:勾选合并_jde配货管理 +"url20": "/order/distributiondsJdeDs/merge" +"payload20": {"ids":"%s"} +#预期结果 +checkDict20: {"distributionJdeDsId":"%s"} +# 获取未推送的配货单 +"url20_1": "/order/distributiondsJdeDs/getDistributiondsJdeDsList" +"payload20_1": {"demandCode":null,"distributionJdeDsCode":null,"pushType":0,"mergeSign":null,"customerInfo":null,"productCode":null,"soCode":null,"optionStr":null,"materialCode":null,"mergeTimeStart":null,"mergeTimeEnd":null,"submitTimeStart":null,"submitTimeEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"mergeCode":null,"code":null,"jdeType":null,"activityType":null,"fieldName":1,"filedSort":2,"isGroup":0,"pageNumber":1,"pageSize":10} + + +#测试场景二十一:获取订单信息_jde配货合并页面 +"url21": "/order/distributiondsJdeDs/demandList" +"payload21": {"list":["%s"]} +#预期结果 +checkDict21: {"demandCode":"%s"} + +#测试场景二十二:必传字段校验_获取jde配货单信息 +"url22": "/order/distributiondsJdeDs/detail" +"payload22": {"distributionJdeDsId":""} +#预期结果 +checkDict22: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + +#测试场景二十三:传值有效性校验_获取jde配货单信息 +"url23": "/order/distributiondsJdeDs/detail" +"payload23": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict23: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + + +#测试场景二十四:获取jde配货单信息 +"url24": "/order/distributiondsJdeDs/detail" +"payload24": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict24: {"distributionJdeDsId":"%s"} + +#测试场景二十五:必传字段校验_jde配货单合并详情 +"url25": "/order/distributiondsJdeDs/mergeDetail" +"payload25": {"distributionJdeDsId":""} +#预期结果 +checkDict25: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + +#测试场景二十六:传值有效性校验_jde配货合并详情 +"url26": "/order/distributiondsJdeDs/mergeDetail" +"payload26": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict26: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + +#测试场景二十七:获取配货单合并详情 +"url27": "/order/distributiondsJdeDs/mergeDetail" +"payload27": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict27: {"distributionJdeDsId":"%s"} + +#测试场景二十八:根据推送单号获取配货单信息 +"url28": "/order/distributiondsJdeDs/getDistributiondsJdeDsList" +"payload28": {"distributionJdeDsCode":"%s"} +#预期结果 +checkDict28: {"distributionJdeDsCode":"%s"} + +#测试场景二十九:推送功能验证_jde配货 +"url29": "/order/distributiondsJdeDs/push" +"payload29": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict29: {"success":true,"code":"200","message":"OK","data":"fail"} + +#测试场景三十:必填字段校验_jde配货推送 +"url30": "/order/distributiondsJdeDs/push" +"payload30": {"distributionJdeDsId":""} +#预期结果 +checkDict30: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + +#测试场景三十一:传值有效性校验_jde配货推送 +"url31": "/order/distributiondsJdeDs/push" +"payload31": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict31: {"success":false,"code":"ERROR","message":"配货单不存在","data":null,"freshToken":null} + + +#测试场景三十二:推送已推送成功的jde配货单拦截验证 +"url32": "/order/distributiondsJdeDs/push" +"payload32": {"distributionJdeDsId":"%s"} +#预期结果 +checkDict32_1: {"success":true,"code":"200","message":"OK","data":"fail"} +checkDict32_2: {"success":false,"code":"ERROR","message":"该订单禁止手动推送!请联系管理员","data":null,"freshToken":null} + +#测试场景三十三:获取客户信息_代客下单 +"url33": "/user/querySubCustomerPage" +"payload33": {"disableSign":0,"status":3,"telephone":"","userNo":"","userName":"","customerCompanyName":"","pageSize":10,"pageStart":1,"total":0} +#预期结果 +checkDict33: {"success":true,"code":"200","message":"OK"} + +#测试场景三十四:查询条件验证_客户列表_代客下单 +"url34": "/user/querySubCustomerPage" +"payload34": {"disableSign":0,"status":3,"telephone":"%s","userNo":"%s","userName":"%s","customerCompanyName":"%s","pageSize":10,"pageStart":1,"total":null} +#预期结果 +checkDict34: {"userNo":"%s"} + + +#测试场景三十五:获取用户默认地址_代客下单 +"url35": "/user/quickOrder/listUserAddress" +"payload35": {"companyId":"%s","userId":"%s"} +#预期结果 +checkDict35: {"addressId":"%s"} +checkDict35_1: {"success":true,"code":"200","message":"OK","data":[],"freshToken":null} + + +#测试场景三十六:必传字段为空_获取用户默认地址_代客下单 +"url36": "/user/quickOrder/listUserAddress" +"payload36": {} +#预期结果 +checkDict36: {"success":false,"code":"NOUSERID","message":"USERID为空","data":null,"freshToken":null} + + +#测试场景三十七:获取收货地址列表_代客下单 +"url37": "/user/mall/getAddressList" +"payload37": {"companyId":"%s","userId":"%s","pageSize":5,"pageStart":1,"searchKey":1,"searchValue":""} +#预期结果 +checkDict37: {"total":"%s"} + +#测试场景三十八:收件人查询验证_收货地址列表_代客下单 +"url38": "/user/mall/getAddressList" +"payload38": {"companyId":"%s","userId":"%s","pageSize":5,"pageStart":1,"searchKey":1,"searchValue":"%s"} +#预期结果 +checkDict38: {"receiverName":"%s"} + +#测试场景三十九:手机号查询验证_收货地址列表_代客下单 +"url39": "/user/mall/getAddressList" +"payload39": {"companyId":"%s","userId":"%s","pageSize":5,"pageStart":1,"searchKey":2,"searchValue":"%s"} +#预期结果 +checkDict39: {"mobile":"%s"} + + +#测试场景四十:详细地址查询验证_收货地址列表_代客下单 +"url40": "/user/mall/getAddressList" +"payload40": {"companyId":"%s","userId":"%s","pageSize":5,"pageStart":1,"searchKey":3,"searchValue":"%s"} +#预期结果 +checkDict40: {"address":"%s"} + +#测试场景四十一:根据父id获取省市信息 +"url41": "/user/public/queryAreaByParentId" +"payload41": {"parentId":19} +#预期结果 +checkDict41: {"success":true,"code":"200","message":"OK","data":[{"areaId":20,"areaCode":"120100","areaName":"天津城区","level":null,"cityCode":null,"center":null,"parentId":null}],"freshToken":null} + +#测试场景四十二:收货地址新增验证_代客下单 +"url42": "/user/mall/addAddresses" +"payload42": {"receiverName":"收货地址新增测试","mobile":"18700000000","address":"收货地址新增测试","type":2,"province":null,"city":null,"area":null,"cityList":[],"areaList":[],"companyId":"%s","userId":"%s"} +#预期结果 +checkDict42: {"success":true,"code":"200","message":"OK","data":true,"freshToken":null} + +#测试场景四十三:收货地址删除功能验证_代客下单 +"url43": "/user/mall/deleteById" +"payload43": {"id":"%s"} +#预期结果 +checkDict43: {"deleteSign":1} + +#测试场景四十四:id为空_收货地址删除_代客下单 +"url44": "/user/mall/deleteById" +"payload44": {"id":""} +#预期结果 +checkDict44: {"success":true,"code":"200","message":"OK","data":false} + +#测试场景四十五:收货地址批量导入空数据_代客下单 +"url45": "/user/public/importAddress" +"payload45": {"type":2,"userId":"32"} +#预期结果 +checkDict45: {"success":false,"code":"5000070","message":"1,0,1","data":null,"freshToken":null} + +#测试场景四十六:收货地址批量导入_代客下单 +"url46": "/user/public/importAddress" +"payload46": {"type":2,"userId":"32"} +#预期结果 +checkDict46: {"userId":"32"} + +#测试场景四十七:客户信息为空_通过Excel添加商品_代客下单 +"url47": "/product/public/listQuickOrderProductExcel" +"payload47": {"queryList":[{"productCode":"10145854","quantity":"10"}],"productCodeList":[],"companyCode":"00102","userNo":""} +#预期结果 +checkDict47: {"success":false,"code":"ERROR","message":"用户信息不完整","data":null,"freshToken":null} + +#测试场景四十八:通过Excel添加无效商品_代客下单 +"url48": "/product/public/listQuickOrderProductExcel" +"payload48": {"queryList":[{"productCode":"%s","quantity":"1"}],"productCodeList":[],"companyCode":"00102","userNo":"%s"} +#预期结果 +checkDict48: {"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,该商品不存在!\n","data":[],"maps":[]},"freshToken":null} + + +#测试场景四十九:必填字段校验_通过Excel添加商品_代客下单 +"url49": "/product/public/listQuickOrderProductExcel" +"payload49": {"queryList":[{"productCode":"","quantity":""}],"productCodeList":[],"companyCode":"00102","userNo":"%s"} +#预期结果 +checkDict49: {"success":true,"code":"200","message":"OK","data":{"status":0,"countSuccess":0,"countFail":1,"message":"第1行,商品编码或物料编码为空!\n","data":[],"maps":[]},"freshToken":null} + + +#测试场景五十:通过Excel添加商品_代客下单 +"url50": "/product/public/listQuickOrderProductExcel" +"payload50": {"queryList":[{"productCode":"%s","quantity":"1"}],"productCodeList":[],"companyCode":"00102","userNo":"%s"} +#预期结果 +checkDict50: {"productCode":"%s"} +#获取客户对应的商品信息 +"url50_1": "/product/public/listQuickOrderProduct" +"payload50_1": {"productCode":null,"productName":null,"materialCode":null,"specifications":null,"productLineName":null,"isGift":null,"ref":1,"userNo":"%s","companyCode":"00102","pageSize":10,"pageNum":1} + + +#测试场景五十一:获取草稿列表_代客下单 +"url51": "/product/public/draft/list" +"payload51": {"userName":"","userNo":"","type":1,"startTime":"","endTime":"","pageSize":10,"pageNum":1,"total":null} +#预期结果 +checkDict51: {"success":True,"code":"200","message":"OK"} + + +#测试场景五十二:查询条件验证_草稿列表_代客下单 +"url52": "/product/public/draft/list" +"payload52": {"userName":"%s","userNo":"%s","type":1,"startTime":"%s","endTime":"%s","pageSize":10,"pageNum":1,"total":null} +#预期结果 +checkDict52: {"userNo":"%s"} + +#测试场景五十三:草稿订单删除功能验证_代客下单 +"url53": "/product/public/draft/del" +"payload53": {"id":"%s"} +#预期结果 +checkDict53: {"success":true,"code":"200","message":"OK","data":true} + +#测试场景五十四:删除无效草稿订单验证_代客下单 +"url54": "/product/public/draft/del" +"payload54": {"id":"%s"} +#预期结果 +checkDict54: {"success":true,"code":"200","message":"OK","data":false,"freshToken":null} + + +#测试场景五十五:必填字段校验_草稿订单删除_代客下单 +"url55": "/product/public/draft/del" +"payload55": {"id":"%s"} +#预期结果 +checkDict55: {"success":true,"code":"200","message":"OK","data":false,"freshToken":null} + +#测试场景五十六:草稿单创建功能验证_代客下单 +"url56": "/product/public/draft/add" +"payload56": {"productMap":{"orderStatus":102,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","productCode":"10145928","productId":9,"materialCode":"","productName":"威尔特","specifications":"犬瘟热","manufacturer":"北京康思润业生物技术有限公司-黄翼","productLineName":"电商产品线","productLineCode":"DS-002","zonePriceVOList":null,"price":68.88,"storageType":"999","optionStr":"犬瘟热","measuringUnit":"EA","ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"quantity":1,"isGift":0,"measuringUnit1":"个","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2020/12/30/a5937bce-1fd4-4219-8271-b15d0e9260ca.JPG","companyCode":"00102","areaName":null,"areaPrice":68.88,"agreementPriceId":null,"hidden":null,"description":"","taxRate":"0.17","allMaterialSign":null,"materialCodeExact":null,"specificationsExact":null,"hospitalOrderType":null,"hospitalHopeDate":null,"siteCompanyCode":null,"propertyName":"商品属性名","propertyVal":"10145928","propertyNote":"10145928","mustInstallDate":false,"showDemandAuditLineLabel":false,"yaPei":false,"installedDateMust":0,"yapeiPrice":null,"editProductCode":false,"quantityErr":false,"fresenuis":false,"zeroSign":false,"purchaseZeroProductList":[],"activityBasicId":null,"giftList":[],"selectGiftArr":[],"selectZeroGiftObj":{"mainProductList":[],"giftProductList":[]},"giftGroupQuantity":1,"propertyStr":"商品属性名:10145928&10145928"}],"paymentAmount":68.88,"productAmount":68.88,"userId":124100,"userNo":"1000086","customerCode":"1000086","userName":"北京海德锐视科技有限公司","companyId":"7","paymentType":1,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","accountId":5,"receiverName":"张梦怡","receiverContact":"13810613577","receiverAddress":"上海市浦东新区浦电路3号1","addressNumber":17823,"remark":"","receiverNote":"张梦怡","receiverPhoneNote":"13810613577","receiverAddressNote":"上海市浦东新区浦电路3号1","addressNoNote":17823,"fileList":[],"sellerCompanyCode":"00102","sellerCompanyName":"国药集团联合医疗器械有限公司","orderSource":2,"customerInfo":{"userId":124100,"userName":"GL1000086","rejectUserName":null,"password":null,"realName":"张梦","userNo":"1000086","telephone":"18008613531","rejectTelephone":null,"registerAddress":null,"detailAddress":"国联客户地址","businessScope":null,"companyProperty":101,"companyId":null,"companyCode":null,"companyName":"国药集团联合医疗器械有限公司","companyNameList":null,"customerCompanyName":"北京海德锐视科技有限公司","lienceNo":"91110106579004448R","userType":2,"companyType":null,"status":3,"disableSign":0,"deleteSign":null,"createBy":null,"updateBy":null,"createTime":null,"updateTime":null,"licenceSketchUrl":null,"licenceUrl":null,"openId":null,"referrer":null,"gift":null,"identity":null,"department":null,"platformStatus":1,"rejectionReason":null,"registerType":null,"siteType":null,"departmentCode":null,"personName":null,"registration":null,"realPassword":null,"recommend":null,"merchantsStatus":null,"backAuditing":false,"taxRate":0.17,"roleNames":null,"subCompanyName":"国药集团联合医疗器械有限公司","roleIds":null,"addressList":null,"licenseList":null,"labelList":null,"managerList":null,"createTimeStr":null,"categoriesList":null,"merchantsAddress":null,"merchantStatus":null,"refuseReason":null,"merchantsId":null,"userTransactionAmount":"630.63","gray":null,"bindingTime":null,"bindSign":1,"jdeStatus":0,"jdePhone":"","recommender":null,"coopeSgin":null,"cusCompanyName":null,"registerLicenceList":null,"bindflowList":null,"userJDEInfo":null}},"id":null,"type":1,"userNo":"1000086","customerCode":"1000086","userName":"北京海德锐视科技有限公司"} +#预期结果 +checkDict56: {"userNo":"1000086"} + +#测试场景五十七:草稿单创建验证_代客下单_套包 +"url57": "/product/public/draft/add" +"payload57": {"productMap":{"orderStatus":102,"demandItems":[{"manufacturerGroupName":"","groupCode1":"sspg00304409","groupId":1077,"customerCode":"1000086","timeStr":"2024-02-11至2036-03-31","productName":null,"documentNo":"123321test","multipleSign":null,"booleaTime":1,"groupPrice":642,"groupPriceStatus":1,"purchaseMultiple":null,"miniPurchaseNum":null,"limitStr":"5.0000","surplusQuantity":5,"groupCode":"sspg00304409","companyCode":"00102","groupProductType":3,"subList":[{"productLineCode":null,"optionStr":"RF*PA35263M","groupId":1077,"description":"","productName":"导丝","manufacturer":"泰尔茂株式会社(テルモ株式会社)","propertyNote":"10000841","installedDateMust":0,"booleaTime":"1","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/123149d7-fe49-462d-9111-3438af9b8a01.png","id":1037,"activityUnitAmount":"321.0000","class":null,"groupCode":"sspg00304409","companyCode":"00102","product":{"firstCategory":"冠脉介入器械","secondCategory":"介入耗材","thirdCategory":"导丝","productId":8853,"productName":"导丝","productCode":"10000841","firstCategoryId":517,"firstCategoryName":null,"secondCategoryId":518,"secondCategoryName":null,"thirdCategoryId":524,"thirdCategoryName":null,"defaultImageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/123149d7-fe49-462d-9111-3438af9b8a01.png","referencePrice":10,"filialeName":"","filialeCode":"00102","brandId":null,"brandName":null,"status":101,"uploadTime":1701065990000,"deleteSign":0,"isSee":0,"isGift":0,"isControlSales":0,"specifications":"RF*PA35263M","productCategories":"01","productNature":"01","riskRank":"003","specialSort":"0103","productClassify":"6877","storageCondition":"999","otherStorageCondition":"不要在超常温度和湿度环境中存放,避免阳光直射。","countryOfOrigin":"JP","diagnosticMedicineCategories":"","materialCode":"RF*PA35263M","manufacturer":"泰尔茂株式会社(テルモ株式会社)","manufacturerCode":"7000333","newRiskRank":"003","newProductClassify":"03","newProductClassify2":"","newClassifyLevel":"003","approvalNumber":"","dosageForm":"","atcCategories":"","atcClassify":"","serialNumber":"","medicineType":"","measuringUnit":"EA","keyWords":"DS","jdeStatus":"P","commonName":"导丝","isSerialNumberManage":"","medicalInsuranceCode":"","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","applicationDepartment":"","pricingMeasuringUnit":"EA","productAuditId":null,"imageUrls":null,"detailImageUrls":null,"groupId":null,"measuringUnitName":"个","productNo":null,"busProductCode":null,"description":"","taxRate":"0.17","jdeUpdate":null,"jdeUpdateStr":null,"startTime":null,"endTime":null,"conSign":0,"medicaCode":null,"classCode":null,"mappinCode":null,"measuringUnitStr":null,"productLineName":null,"productLineCode":null,"pageNum":null,"pageSize":null,"isUpload":null,"relevanceCode":null,"produceRegisterNum":"国械注进20153032566","relevanceName":null,"prescription":null,"sdOutStorage":0,"installedDateMust":0,"miniPurchaseNum":null,"multipleSign":null,"purchaseMultiple":null,"inventoryTotal":null,"kpde8YX02":null,"prescriptionStr":null,"replaceSgin":0},"quantity":1,"productId":8853,"propertyVal":"10000841","freseniusPriceId":568,"materialCode":"RF*PA35263M","updateTime":null,"manufacturerCode":"7000333","measuringUnitStr":"个","produceRegisterNum":"国械注进20153032566","showDemandAuditLineLabel":false,"taxRate":"0.17","productCode":"10000841","defaultimageurl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/123149d7-fe49-462d-9111-3438af9b8a01.png","createTime":null,"propertyName":"商品属性名","measuringUnit":"个","productLineName":null,"storageType":"999","storageCondition":"999","fsGroupId":1077,"groupProductType":3,"propertyStr":"商品属性名:10000841&10000841"},{"productLineCode":null,"optionStr":"RF*GA35263M","groupId":1077,"description":"","productName":"导丝","manufacturer":"泰尔茂株式会社(テルモ株式会社)","propertyNote":"10000842","installedDateMust":0,"booleaTime":"1","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/a228c369-ad79-4a11-bbab-9949a65d433f.png","id":1038,"activityUnitAmount":"321.0000","class":null,"groupCode":"sspg00304409","companyCode":"00102","product":{"firstCategory":"冠脉介入器械","secondCategory":"介入耗材","thirdCategory":"导丝","productId":8854,"productName":"导丝","productCode":"10000842","firstCategoryId":517,"firstCategoryName":null,"secondCategoryId":518,"secondCategoryName":null,"thirdCategoryId":524,"thirdCategoryName":null,"defaultImageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/a228c369-ad79-4a11-bbab-9949a65d433f.png","referencePrice":9999999.99,"filialeName":"","filialeCode":"00102","brandId":null,"brandName":null,"status":101,"uploadTime":1618553482000,"deleteSign":0,"isSee":0,"isGift":0,"isControlSales":0,"specifications":"RF*GA35263M","productCategories":"01","productNature":"01","riskRank":"003","specialSort":"0103","productClassify":"6877","storageCondition":"999","otherStorageCondition":"不要再超常温度和湿度环境中存放,避免阳光直射","countryOfOrigin":"JP","diagnosticMedicineCategories":"","materialCode":"","manufacturer":"泰尔茂株式会社(テルモ株式会社)","manufacturerCode":"7000333","newRiskRank":"","newProductClassify":"03","newProductClassify2":"","newClassifyLevel":"003","approvalNumber":"","dosageForm":"","atcCategories":"","atcClassify":"","serialNumber":"","medicineType":"","measuringUnit":"EA","keyWords":"DS","jdeStatus":"P","commonName":"导丝","isSerialNumberManage":"","medicalInsuranceCode":"","auxiliaryMeasuringUnit":"EA","procurementMeasuringUnit":"EA","applicationDepartment":"","pricingMeasuringUnit":"EA","productAuditId":null,"imageUrls":null,"detailImageUrls":null,"groupId":null,"measuringUnitName":"个","productNo":null,"busProductCode":"","description":"","taxRate":"0.17","jdeUpdate":null,"jdeUpdateStr":null,"startTime":null,"endTime":null,"conSign":0,"medicaCode":null,"classCode":null,"mappinCode":null,"measuringUnitStr":null,"productLineName":null,"productLineCode":null,"pageNum":null,"pageSize":null,"isUpload":null,"relevanceCode":null,"produceRegisterNum":"国械注进20153032566","relevanceName":null,"prescription":null,"sdOutStorage":0,"installedDateMust":0,"miniPurchaseNum":null,"multipleSign":null,"purchaseMultiple":null,"inventoryTotal":null,"kpde8YX02":null,"prescriptionStr":null,"replaceSgin":0},"quantity":1,"productId":8854,"propertyVal":"10000842","freseniusPriceId":568,"materialCode":"","updateTime":null,"manufacturerCode":"7000333","measuringUnitStr":"个","produceRegisterNum":"国械注进20153032566","showDemandAuditLineLabel":false,"taxRate":"0.17","productCode":"10000842","defaultimageurl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/16/a228c369-ad79-4a11-bbab-9949a65d433f.png","createTime":null,"propertyName":"商品属性名","measuringUnit":"个","productLineName":null,"storageType":"999","storageCondition":"999","fsGroupId":1077,"groupProductType":3,"propertyStr":"商品属性名:10000842&10000842"}],"calSubFreName":"导丝(RF*PA35263M)*1个+导丝(RF*GA35263M)*1个","quantity":1,"freseniusPriceId":568,"manufacturerGroupCode":"","groupName":"套包协议价验证测试","productCode":null,"limitPurchase":5,"buyCartNum":1,"isLimit":1,"isRegularPrice":0,"giftList":[]}],"paymentAmount":642,"productAmount":642,"userId":124100,"userNo":"1000086","customerCode":"1000086","userName":"北京海德锐视科技有限公司","companyId":"7","paymentType":1,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","accountId":5,"receiverName":"张梦怡","receiverContact":"","receiverAddress":"上海市浦东新区浦电路3号1","addressNumber":17823,"remark":"","receiverNote":"张梦怡","receiverPhoneNote":"","receiverAddressNote":"上海市浦东新区浦电路3号1","addressNoNote":17823,"fileList":[],"sellerCompanyCode":"00102","sellerCompanyName":"国药集团联合医疗器械有限公司","orderSource":2,"customerInfo":{"userId":124100,"userName":"GL1000086","rejectUserName":null,"password":null,"realName":"张梦","userNo":"1000086","telephone":"18008613531","rejectTelephone":null,"registerAddress":null,"detailAddress":"国联客户地址","businessScope":null,"companyProperty":101,"companyId":null,"companyCode":null,"companyName":"国药集团联合医疗器械有限公司","companyNameList":null,"customerCompanyName":"北京海德锐视科技有限公司","lienceNo":"91110106579004448R","userType":2,"companyType":null,"status":3,"disableSign":0,"deleteSign":null,"createBy":null,"updateBy":null,"createTime":null,"updateTime":null,"licenceSketchUrl":null,"licenceUrl":null,"openId":null,"referrer":null,"gift":null,"identity":null,"department":null,"platformStatus":1,"rejectionReason":null,"registerType":null,"siteType":null,"departmentCode":null,"personName":null,"registration":null,"realPassword":null,"recommend":null,"merchantsStatus":null,"backAuditing":false,"taxRate":0.17,"roleNames":null,"subCompanyName":"国药集团联合医疗器械有限公司","roleIds":null,"addressList":null,"licenseList":null,"labelList":null,"managerList":null,"createTimeStr":null,"categoriesList":null,"merchantsAddress":null,"merchantStatus":null,"refuseReason":null,"merchantsId":null,"userTransactionAmount":"630.63","gray":null,"bindingTime":null,"bindSign":1,"jdeStatus":0,"jdePhone":"","recommender":null,"coopeSgin":null,"cusCompanyName":null,"registerLicenceList":null,"bindflowList":null,"userJDEInfo":null}},"id":null,"type":1,"userNo":"1000086","customerCode":"1000086","userName":"北京海德锐视科技有限公司"} +#预期结果 +checkDict57: {"userNo":"1000086"} + +#测试场景五十八:获取用户注册方式 +"url58": "/user/public/manufacturerAccount/getUserRegisterType" +"payload58": {} +#预期结果 +checkDict58: {"registerType":"1"} + +#测试场景五十九:获取待上传发票统计信息 +"url59": "/order/public/queryUploadInvoiceCount" +"payload59": {} +#预期结果 +checkDict59: {"success":true,"code":"200","message":"OK"} + +#测试场景六十:获取终端流向列表信息 +"url60": "/order/back/queryFlowDirectionManagePage" +"payload60": {"table":1,"endCustomerName":"","invoiceNo":"","manufacturer":"","productInfo":"","materialCode":"","orderStartTime":"","orderEndTime":"","customerCode":"","customerName":"","companyCode":"","uploadStartTime":"","uploadEndTime":"","pageStart":1,"pageSize":10,"total":59} +#预期结果 +checkDict60: {"success":true,"code":"200","message":"OK"} + +#测试场景六十五:获取终端流向详情 +"url65": "/order/back/queryFlowDirectionManageDetailPage" +"payload65": {"demandCode":"%s","invoiceNo":"%s","table":1,"deleteSign":"%s","flowId":"%s"} +#预期结果 +checkDict65: {"demandCode":"%s"} + +#测试场景六十一:列表查询条件验证_终端流向 +"url61": "/order/back/queryFlowDirectionManagePage" +"payload61": {"table":1,"endCustomerName":"%s","invoiceNo":"%s","manufacturer":"%s","productInfo":"%s","materialCode":"%s","orderStartTime":"%s","customerCode":"%s","customerName":"%s","companyCode":"","uploadStartTime":"%s","uploadEndTime":"%s","productCode":"%s","demandCode":"%s","orderEndTime":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict61: {"demandCode":"%s"} + +#测试场景六十二:导出功能验证_终端流向 +"url62": "/order/public/exportTrendFlowInfo" +"payload62": {"table":1,"endCustomerName":"","invoiceNo":"","manufacturer":"","productInfo":"","materialCode":"","orderStartTime":"","orderEndTime":"","customerCode":"","customerName":"","companyCode":"","uploadStartTime":"","uploadEndTime":"","demandCode":"%s"} +#预期结果 +checkDict62: {"demandCode":"%s"} + + +#测试场景六十三:获取附件操作流水 +"url63": "/order/public/queryOperationLogList" +"payload63": {"soCode":"24000258","companyCode":"00102"} +#预期结果 +checkDict63: {"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} + + +#测试场景六十四:下载资质文件功能验证 +"url64": "/order/public/exportTrendFlowInfo" +"payload64": {"soCode":"24000258","companyCode":"00102"} +#预期结果 +checkDict64: {"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} + +#测试场景六十六:按产品线查询商品信息_厂家销售任务下发 +"url66": "/order/suppliersaleTask/queryProductByLine" +"payload66": {"productLineCode":"10052433"} +#预期结果 +checkDict66: {"success":true,"code":"200","message":"OK"} + +#测试场景六十七:销售任务新增验证 +"url67": "/order/suppliersaleTask/addTask" +"payload67": {"taskYear":"2029","taskName":"供应商销售任务下发新增功能验证","taskType":0,"taskCycleStart":"2024-02-20","taskCycleEnd":"2024-02-29","taskDescription":"供应商销售任务下发新增功能验证","products":[{"id":null,"supplierSaleTaskId":null,"userId":null,"dataType":null,"productCode":"10146153 ","productName":"一次性使用活检针-电商专用 ","specifications":"25MM ","materialCode":"507677 ","manufacturer":"山东育达医疗设备有限公司-电商专用 ","productLineName":"泰尔茂支架","customerCode":null,"customerName":null,"unit":"支","missionObjectivesYuan":null,"missionObjectivesNum":null,"createTime":null,"updateTime":null},{"id":null,"supplierSaleTaskId":null,"userId":null,"dataType":null,"productCode":"10213110 ","productName":"宋雅丽测试商品1 ","specifications":"1 ","materialCode":" ","manufacturer":"生产厂家-宋雅丽 ","productLineName":"泰尔茂支架","customerCode":null,"customerName":null,"unit":"副","missionObjectivesYuan":null,"missionObjectivesNum":null,"createTime":null,"updateTime":null}],"customers":[{"id":null,"supplierSaleTaskId":null,"userId":124100,"dataType":null,"productCode":null,"productName":null,"specifications":null,"materialCode":null,"manufacturer":null,"productLineName":null,"customerCode":"1000086","customerName":"北京海德锐视科技有限公司","unit":null,"missionObjectivesYuan":1000,"missionObjectivesNum":null,"createTime":null,"updateTime":null}]} +#预期结果 +checkDict67: {"success":true,"code":"200","message":"OK","data":"success","freshToken":null} + +#测试场景六十八:销售任务编辑功能验证 +"url68": "/order/suppliersaleTask/updateTask" +#预期结果 +checkDict68: {"success":true,"code":"200","message":"OK","data":"success","freshToken":null} +#获取指定销售任务 +"url68_1": "/order/back/suppliersaleTaskPage" +"payload68_1": {"customerCode":null,"customerName":null,"filialeCode":null,"materialCode":null,"productCode":null,"productLineName":null,"productName":null,"specifications":null,"taskName":"供应商销售任务下发新增功能验证","taskYear":null,"useSign":null,"pageNum":1,"pageSize":8,"total":1} + +#测试场景七十一:销售任务删除功能验证 +"url71": "/order/suppliersaleTask/deleteTask" +"payload71": {"supplierSaleTaskId":"%s"} +#预期结果 +checkDict71: {"deleteSign":1} + +#测试场景七十二:获取销售任务下发列表 +"url72": "/order/back/suppliersaleTaskPage" +"payload72": {"customerCode":null,"customerName":null,"filialeCode":null,"materialCode":null,"productCode":null,"productLineName":null,"productName":null,"specifications":null,"taskName":null,"taskYear":null,"useSign":null,"pageNum":1,"pageSize":8,"total":null} +#预期结果 +checkDict72: {"success":true,"code":"200","message":"OK"} + +#测试场景七十三:列表查询条件验证_销售任务列表 +"url73": "/order/back/suppliersaleTaskPage" +"payload73": {"customerCode":"%s","customerName":"%s","filialeCode":null,"materialCode":"%s","productCode":"%s","productLineName":"%s","productName":"%s","specifications":"%s","taskName":"%s","taskYear":"%s","useSign":"%s","pageNum":1,"pageSize":8,"total":null} +#预期结果 +checkDict73: {"taskName":"%s"} + + +#测试场景六十九:销售下发任务启用功能验证 +"url69": "/order/suppliersaleTask/updateUseSign" +"payload69": {"supplierSaleTaskId":"%s","useSign":1} +#预期结果 +checkDict69: {"useSign":1} + +#测试场景七十:销售下发任务停用功能验证 +"url70": "/order/suppliersaleTask/updateUseSign" +"payload70": {"supplierSaleTaskId":"%s","useSign":2} +#预期结果 +checkDict70: {"useSign":2} + +#查询指定状态的销售下发任务 +"payload_use": {"customerCode":null,"customerName":null,"filialeCode":null,"materialCode":null,"productCode":null,"productLineName":null,"productName":null,"specifications":null,"taskName":null,"taskYear":null,"useSign":"%s","pageNum":1,"pageSize":8,"total":null} + +#测试场景七十四:获取红票明细列表 +"url74": "/order/back/findRedTicketDetailsList" +"payload74": {"demandParentCode":"","demandCode":"","customerName":"","orderStatus":"","pageStart":1,"pageSize":10} +#预期结果 +checkDict74: {"success":true,"code":"200","message":"OK"} + +#测试场景七十五:列表查询条件验证_红票明细列表 +"url75": "/order/back/findRedTicketDetailsList" +"payload75": {"demandParentCode":"%s","demandCode":"%s","customerName":"%s","orderStatus":"%s","startTime":"%s","endTime":"%s","pageStart":1,"pageSize":10} +#预期结果 +checkDict75: {"demandCode":"%s"} + +#测试场景七十六:红票明细导出功能验证 +"url76": "/order/back/exportRedTicketDetails" +"payload76": {"demandParentCode":"%s","demandCode":"","customerName":"","orderStatus":""} +#预期结果 +checkDict76: {"demandParentCode":"%s"} + +#测试场景七十七:根据id查询站点信息 +"url77": "/cms/public/website/queryWebsiteByCompanyId" +"payload77": {"companyId":7} +#预期结果 +checkDict77: {"success":true,"code":"200","message":"操作成功"} + +#测试场景七十八:获取采购计划日期列表 +"url78": "/order/public/procurement/getProcurementDateList" +"payload78": {} +#预期结果 +checkDict78: {"success":true,"code":"200"} + +#测试场景七十九:获取客户采购计划列表 +"url79": "/order/public/procurement/queryProcurementPage" +"payload79": {"startTime":null,"endTime":null,"customerInfo":null,"procurementTime":null,"procurementDate":null,"lockSign":null,"mergeSign":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict79: {"success":true,"code":"200","message":"OK"} + +#测试场景八十:列表查询条件验证_客户采购计划 +"url80": "/order/public/procurement/queryProcurementPage" +"payload80": {"startTime":"%s","endTime":"%s","customerInfo":"%s","procurementTime":["%s","%s"],"procurementDate":"%s","lockSign":"%s","mergeSign":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict80: {"customerCode":"%s"} + + +#测试场景八十一:导出功能验证_客户采购计划 +"url81": "/order/public/procurement/exportSummaryExcel" +"payload81": {"customerInfo":"%s","procurementTime":[null],"procurementDate":null,"lockSign":null,"mergeSign":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict81: {"customerCode":"%s"} + + +#测试场景八十二:获取采购计划汇总信息 +"url82": "/order/public/procurement/getProcurementSummaryDetail" +"payload82": {"procurementDate":"2024-02","type":0} +#预期结果 +checkDict82: {"success":true,"code":"200","message":"成功","freshToken":null} + +#测试场景八十三:获取商品预测明细 +"url83": "/order/public/procurement/getPredictionList" +"payload83": {"startTime":null,"endTime":null,"productInfo":"","customerInfo":"","procurementTime":null,"procurementDate":""} +#预期结果 +checkDict83: {"success":true,"code":"200","message":"OK"} + +#测试场景八十四:列表查询条件验证_商品预测明细 +"url84": "/order/public/procurement/getPredictionList" +"payload84": {"startTime":"%s","endTime":"%s","productInfo":"%s","customerInfo":"%s","procurementTime":["%s","%s"],"procurementDate":"%s"} +#预期结果 +checkDict84: {"productInfo":"%s"} + +#测试场景八十五:导出功能验证_商品预测明细 +"url85": "/order/public/procurement/exportPredictionListExcel" +"payload85": {"productInfo":"","customerInfo":"%s","procurementTime":[null],"procurementDate":""} +#预期结果 +checkDict85: {"customerInfo":"%s"} + +#测试场景八十六:获取客户清单列表 +"url86": "/order/public/procure/queryCustomerPage" +"payload86": {"customerInfo":null,"pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict86: {"success":true,"code":"200","message":"OK"} + +#测试场景八十八:查询条件验证_客户清单列表 +"url88": "/order/public/procure/queryCustomerPage" +"payload88": {"customerInfo":"%s","pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict88: {"customerInfo":"%s"} + +#测试场景八十九:导出功能验证_客户清单 +"url89": "/order/public/procure/exportCustomer" +"payload89": {"customerInfo":"%s","pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict89: {"customerInfo":"%s"} + +#测试场景八十七:获取客户商品列表 +"url87": "/order/public/procure/queryProductPage" +"payload87": {"productInfo":null,"pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict87: {"success":true,"code":"200","message":"OK"} + +#测试场景九十:列表查询条件验证_商品清单 +"url90": "/order/public/procure/queryProductPage" +"payload90": {"productInfo":"%s","pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict90: {"productInfo":"%s"} + +#测试场景九十一:导出功能验证_商品清单 +"url91": "/order/public/procure/exportProduct" +"payload91": {"productInfo":"%s","pageStart":1,"pageSize":10,"total":null,"companyCode":"00102"} +#预期结果 +checkDict91: {"productInfo":"%s"} + +#测试场景九十二:附件上传功能验证_代客下单 +"url92": "/order/mall/demandFileUpload" +#预期结果 +checkDict92: {"success":true,"code":"200","message":"OK"} + +#测试场景九十三:获取客户申请取消订单数量 +"url93": "/order/public/demand/getCustomerApplyCancelNum" +"payload93": {} +#预期结果 +checkDict93: {"success":true,"code":"200","message":"OK"} + +# 获取需求单列表 +"url_list": "/order/back/listDemand" +"payload_list": {"times":[null],"listOrderStatus":["1021","132","112","103","104"],"productName":null,"demandCode":null,"demandParentCode":null,"customerName":null,"manufacturer":null,"materialCode":null,"sellerCompanyName":null,"produceRegisterNum":null,"productLineName":null,"auditByName":null,"orderSource":null,"changeTypeList":null,"isRebateEdit":null,"jdeType":null,"pageSize":10,"pageStart":1,"orderChangeType":null,"snSgin":null,"changeSign":null,"customerCode":null,"distributionType":null,"busCustomerCode":null,"loginName":null,"cancelSign":0,"shipmentType":null,"siteType":null,"siteCompanyCode":null,"groupQuery":0,"promotionTypeList":[],"isGroup":[],"isReplace":null,"startTime":null} + +#测试场景九十四:获取需求单详情信息 +"url94": "/order/back/demandDetail" +"payload94": {"demandId":"%s"} +#预期结果 +checkDict94: {"demandId":"%s"} + +#测试场景九十五:获取审核后商品信息 +"url95": "/order/back/listDemandSku" +"payload95": {"demandId":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict95: {"total":"%s"} + +#测试场景九十六:通过需求单号获取审核后商品清单 +"url96": "/order/public/demandMergeSku/listByDemandCode" +"payload96": {"demandCode":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict96: {"total":"%s"} + +#测试场景九十七:获取用户下单原始清单信息 +"url97": "/order/public/demandSkuOrg/list" +"payload97": {"demandCode":"%s","pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict97: {"total":"%s"} + +#测试场景九十八:验证需求单是否被占用 +"url98": "/order/public/isDemandTakeUp" +"payload98": {"demandId":"%s","type":3} +#预期结果 +checkDict98: {"data":"%s"} + +#测试场景九十九:获取需求单审核详情信息 +"url99": "/order/back/demandAuditDetail" +"payload99": {"demandId":"%s"} +#预期结果 +checkDict99: {"auditStatus":"%s"} + +#测试场景一百:查询站点是否开启电子印章 +"url100": "/cms/website/isOpenElectronicSeal" +"payload100": {"companyCode":"00102"} +#预期结果 +checkDict100: {"sealSiteSign":"%s"} + +#测试场景一百零一:核验站点是否具有二次审核权限 +"url101": "/cms/public/website/chekcSecondAuditSignByCompanyId" +"payload101": {"companyId":"7"} +#预期结果 +checkDict101: {"secondAuditSign":"%s"} + +#测试场景一百零二:获取用户JDE地址信息 +"url102": "/user/public/queryJdeUserAddress" +"payload102": {"userId":"%s","companyId":7} +#预期结果 +checkDict102: {"total":"%s"} + +#测试场景一百零三:获取具备二次审核权限站点信息 +"url103": "/user/public/getSecondAuditList" +"payload103": {} +#预期结果 +checkDict103: {"success":true,"code":"200"} + +#测试场景一百一十一:获取项目列表_需求单审核 +"url111": "/user/public/getProjectList" +"payload111": {} +#预期结果 +checkDict111: {"total":"%s"} + +#测试场景一百一零七:根据客户code获取采购协议信息 +"url107": "/user/public/vptihtxyJde/getVptihtxyByUserNo" +"payload107": {"customerCode":"%s","productLineCode":"%s"} +#预期结果 +checkDict107: {"customerCode":"%s"} + +#测试场景一百一十四:获取jde项目列表 +"url114": "/user/public/getProjectJdeList" +"payload114": {"projectName":"","projectCode":"%s","pageSize":10,"pageStart":1} +#预期结果 +checkDict114: {"projectCode":"%s"} + +#测试场景一百一十二:获取部门信息 +"url112": "/user/public/vapimcuJde/getAlesDepartment" +"payload112": {"alesDepartmentName":"%s","sourceSign":"%s"} +#预期结果 +checkDict112: {"total":"%s"} + +#测试场景一百一十三:获取业务人员信息 +"url113": "/user/public/vapimcuJde/getSalesPerson" +"payload113": {"alesDepartmentNo":"%s"} +#预期结果 +checkDict113: {"total":"%s"} + +#测试场景一百零五:获取活动信息 +"url105": "/order/public/getCircleActivity" +"payload105": {"companyCode":"%s","userId":"%s"} +#预期结果 +checkDict105: {"userId":"%s"} + +#测试场景一百零四:获取活动规则 +"url104": "/order/public/getGiftCircleActivityRule" +"payload104": {"activityCircleProductVoList":[{"productLineCode":"","productLineName":"","areaName":null,"agreementPriceId":0,"price":720.38,"productCode":"14384307","purchaseQuantity":1,"serviceSign":0,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"offerPrice":null,"yapeiPriceId":null}],"companyCode":"00102","userId":"124100"} +#预期结果 +checkDict104: {"success":true,"code":"200","message":"OK","data":[{"areaName":"","14384307":[]}],"freshToken":null} + +#测试场景一百一十:获取商品库存 +"url110": "/order/public/queryProductInventory" +"payload110": {"companyCode":"%s","productCode":"%s"} +#预期结果 +checkDict110: {"productCode":"%s"} + + +#测试场景一百一十五:获取商品详情页库存信息 +"url115": "/product/public/stockRule/getStockByRule" +"payload115": {"companyCode":"00102","customerCode":"1000086","productCodes":["10146174"],"refreshStock":true} +#预期结果 +checkDict115: {"stockQty":"%s"} + +#测试场景一百零九:获取库存列表信息 +"url109": "/product/public/stockRule/stockList" +"payload109": {"productCode":"10146174","filialeCode":"00102","companyCode":"00102","customerCode":1000086,"sort":"1","pageStart":"1","pageSize":"999999999","productCodes":["10146174"],"IOBODJStart":"","IOBODJEnd":"","expireDateStart":"","expireDateEnd":"","effectiveDateStart":"","effectiveDateEnd":"","FCD01Start":"","FCD01End":""} +#预期结果 +checkDict109: {"stockQty":"%s"} + +#测试场景116:列表查询条件验证_库存列表 +"url116": "/product/public/stockRule/stockList" +"payload116": {"location":"%s","mcrp12":"%s","distributionSign":"%s","produceNumber":"%s","LILOTN":"%s","FCE8ZZBM":"%s","LIVEND":"1000472","fcdl01":"16000419","E8DLCG":"%s","FCDL03":"%s","ACQAVALStart":"%s","ACQAVALEnd":"%s","productCode":"10146174","filialeCode":"00102","companyCode":"00102","customerCode":1000086,"sort":"1","pageStart":"1","pageSize":"999999999","productCodes":["10146174"],"IOBODJStart":"%s","IOBODJEnd":"%s","expireDateStart":"%s","expireDateEnd":"%s","effectiveDateStart":"%s","effectiveDateEnd":"%s","FCD01Start":"%s","FCD01End":"%s"} +#预期结果 +checkDict116: {"lilotn":"%s"} + +#测试场景117:获取销售商信息 +"url117": "/user/getSellerCompanyList" +"payload117": {} +#预期结果 +checkDict117: {"total":"%s"} + +#测试场景118:欠货综合管理列表_订单维度查询 +"url118": "/order/debtStatementList" +"payload118": {"demandCode":"","customerName":"","customerCode":"","demandParentCode":"","lackStatusList":[],"orderMark":"","afterPayStatus":"","sellerCompanyName":"","productLineName":"","materialCode":"","optionStr":"","projectName":"","projectCode":"","paidSearch":[],"auditSearch":[],"createSearch":[],"distributionType":null,"shipmentType":null,"demandSubCode":"","auditByName":"","productCode":"","sortSign":2,"afterPay":0,"debtTabSign":"0","productInfoValue":"","mergeSige":null,"pageStart":1,"pageSize":10} +#预期结果 +checkDict118: {"success":true,"code":"200","message":"OK"} + +#测试场景119:商品行明细导出验证_订单维度_欠货综合管理 +"url119": "/order/back/exportDebtDetail" +"payload119": {"demandCode":"","customerName":"","customerCode":"","demandParentCode":"%s","lackStatusList":[],"orderMark":"","afterPayStatus":"","sellerCompanyName":"","productLineName":"","materialCode":"","optionStr":"","projectName":"","projectCode":"","paidSearch":[],"auditSearch":[],"createSearch":[],"distributionType":null,"shipmentType":null,"demandSubCode":"","auditByName":"","productCode":"","sortSign":2,"afterPay":0,"debtTabSign":"0","productInfoValue":"","mergeSige":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict119: {"demandParentCode":"%s"} + +#测试场景120:获取欠货详情 +"url120": "/order/debtDetail" +"payload120": {"demandId":"%s","demandSubId":"%s","orderMark":"","manufacturer":"","productName":"","materialCode":"","productCode":"","optionStr":""} +#预期结果 +checkDict120: {"customerCode":"%s"} + +#测试场景121:获取需求单详情_综合欠货管理 +"url121": "/order/back/demandDetail" +"payload121": {"demandId":"%s","demandSubId":"%s"} +#预期结果 +checkDict121: {"demandId":"%s"} + +#测试场景122:查询待配货明细列表 +"url122": "/order/public/queryDistributeList" +"payload122": {"demandSubCode":"%s","distributionType":"%s"} +#预期结果 +checkDict122: {"success":true,"code":"200","message":"OK"} + +#测试场景123:商品清单筛选功能验证_欠货详情 +"url123": "/order/debtDetail" +"payload123": {"demandId":"%s","demandSubId":"%s","orderMark":"%s","manufacturer":"%s","productName":"%s","materialCode":"%s","productCode":"%s","optionStr":"%s"} +#预期结果 +checkDict123: {"productCode":"%s"} + +#测试场景124:同步SO接口验证 +"url124": "/order/public/getFlowSync" +"payload124": {} +#预期结果 +checkDict124: {"success":true,"code":"200","message":null,"data":null,"freshToken":null} + +#测试场景125:刷新jde侧库存接口验证 +"url125": "/order/public/inventoryRefresh" +"payload125": {"sellerCompanyCode":"00102"} +#预期结果 +checkDict125: {"success":true,"code":"200","message":null,"data":null,"freshToken":null} + +#测试场景106:库存重新获取刷新接口验证 +"url106": "/product/public/getActualInventorys" +"payload106": {"productCodes":"%s","companyCode":"%s","f":true} +#预期结果 +checkDict106: {"status":1,"errorLog":null} + +#测试场景126:电商配货中接口验证 +"url126": "/order/public/back/distributeEditIng" +"payload126": {"distributionId":"%s"} +#预期结果 +checkDict126: {"distributionId":"%s"} +#获取配货单列表 +"url126_1": "/order/distributionorder/list" +"payload126_1": {"demandParentCode":"","demandCode":"","distributionCode":"","customerCode":"","sellerCompanyName":"","submitTime":"","auditTime":"","distributionTime":"","auditByName":"","productLineName":"","distributionStatus":"","pushType":"","submitStartTime":"","submitEndTime":"","updateStartTime":"","updateEndTime":"","auditStartTime":"","auditEndTime":"","distributionTimeStart":"","distributionTimeEnd":"","pageNum":1,"pageSize":10,"mergeTimeStart":"","mergeTimeEnd":""} + + +#测试场景127:获取基础配置信息 +"url127": "/user/public/getBaseConfig" +"payload127": {"type":3} +#预期结果 +checkDict127: {"success":true,"code":"200","message":"OK","data":true,"freshToken":null} + +#测试场景128:获取资信额度 +"url128": "/order/distributionorder/getCredit" +"payload128": {"distributionId":"%s"} +#预期结果 +checkDict128: {"success":true,"code":"200","message":"OK"} + +#测试场景130:获取批号清单列表 +"url130": "/product/distribution/optionList?distributionCode=17061473594454750-SO02&productCode=10145853&location=102302&rules=&projectCode=&num=1" +"payload130": {} +#预期结果 +checkDict130: {"success":true,"code":"200","message":"OK"} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/data/cmdc_order_merge/data b/data/cmdc_order_merge/data index 95b3507c54cc73afb4b4ed1664ebc9be7d80cd2f..89f369a097addefd5882e3c854c3ccda0f8055e1 100644 --- a/data/cmdc_order_merge/data +++ b/data/cmdc_order_merge/data @@ -6,6 +6,10 @@ "username1": "Admin00111" "password1": "Aa123456" +#后台运营管理系统登录信息(子站点国联医疗器械有限公司) +"username2": "Admin00102" +"password2": "Aa123456" + #后台管理系统headers json_headers: { @@ -38,19 +42,27 @@ checkDict2: {"cusCompanyName":"%s"} #测试场景三:模糊查询商品编码信息 "url3": "/product/public/getProductVoAll" -"payload3": {"productCodeList":["%s"],"filialeCode":"00111"} +"payload3": {"productCodeList":["%s"],"filialeCode":"00102"} #预期结果 checkDict3: {"productCode":"%s"} #测试场景四:列表查询条件验证_配货单列表获取 "url4": "/order/distributionorder/list" -"payload4": {"productCodeList":["%s"],"filialeCode":"00111"} +"payload4": {"demandParentCode":"%s","demandCode":"%s","distributionCode":"%s","customerCode":"%s","sellerCompanyName":"","submitTime":"","auditTime":"","distributionTime":"","auditByName":"%s","productLineName":"%s","distributionStatus":"%s","pushType":"%s","submitStartTime":"","submitEndTime":"","updateStartTime":"","updateEndTime":"","auditStartTime":"","auditEndTime":"","distributionTimeStart":"","distributionTimeEnd":"","pageNum":1,"pageSize":10,"code":"","productCodeList":["%s"],"materialCodeList":["%s"],"jdeType":"%s","isMerge":"%s","optionStr":"%s","customerData":"%s","promotionType":"%s","isGroupSign":"%s","mergeVersionCode":"%s","outCode":"%s"} #预期结果 -checkDict4: {"productCode":"%s"} - - +checkDict4: {"demandParentCode":"%s"} +#测试场景五:获取电商配货详情 +"url5": "/order/distributionorder/queryAllByDistributionId" +"payload5": {"distributionId":"%s"} +#预期结果 +checkDict5: {"distributionId":"%s"} +#测试场景六:模糊查询物料编码 +"url6": "/product/public/getMaterialCode" +"payload6": {"materialCode":"%s"} +#预期结果 +checkDict6: {"data":"%s"} diff --git a/data/cmdc_product/data b/data/cmdc_product/data index 021596281226f4acb6493c281d08ea165b98b14c..4e790bd3be5bf39863917cb87b27d3a1b887963a 100644 --- a/data/cmdc_product/data +++ b/data/cmdc_product/data @@ -6,6 +6,9 @@ "username1": "Admin00111" "password1": "Aa123456" +#后台运营管理系统登录信息(子站点国联医疗器械有限公司) +"username2": "Admin00102" +"password2": "Aa123456" #后台管理系统headers json_headers: { @@ -24,6 +27,9 @@ json_headers1: { "Sourcetype": "mall" } +# 登录失败 +"payload_401": {"code":"401","message":"Unauthorized","success":false} + #测试场景一:获取商品属性列表 "url1": "/product/productProperties/list" "payload1": {"productCode":"","productName":"","specifications":"","materialCode":"","manufacturer":"","propertyName":"","propertyNote":"","propertyVal":"","createTimeStart":"","createTimeEnd":"","updateTimeEnd":"","updateTimeStart":"","times":null,"times2":null,"pageNumber":1,"pageSize":8} @@ -153,13 +159,13 @@ checkDict19: {"lineCode":"%s"} #测试场景二十:获取商品列表_库存配置 "url20": "/product/public/getListed" -"payload20": {"pageNumber":10,"pageStart":1,"productCode":"","productName":"","userNo":"","companyCode":"00111","pageSize":10,"pageNum":1,"specifications":""} +"payload20": {"pageNumber":10,"pageStart":1,"productCode":"","productName":"","userNo":"","companyCode":"00102","pageSize":10,"pageNum":1,"specifications":""} #预期结果 checkDict20: {"success":true,"code":"200","message":"OK"} #测试场景二十一:列表查询条件验证_商品列表_库存配置 "url21": "/product/public/getListed" -"payload21": {"pageNumber":10,"pageStart":1,"productCode":"%s","productName":"%s","userNo":"","companyCode":"00111","pageSize":10,"pageNum":1,"specifications":"","total":1629} +"payload21": {"pageNumber":10,"pageStart":1,"productCode":"%s","productName":"%s","userNo":"","companyCode":"00102","pageSize":10,"pageNum":1,"specifications":"","total":1629} #预期结果 checkDict21: {"productCode":"%s"} @@ -334,7 +340,7 @@ checkDict46: {"success":true,"code":"200","message":"OK"} "url47": "/product/productLimitBuy/del" "payload47": {"ids":"%s"} # 查询指定商品限购规则请求报文 -"payload47_1": {"pageNum":1,"pageSize":8,"total":1,"productCode":"12364265"} +"payload47_1": {"pageNum":1,"pageSize":8,"total":1,"productCode":"10145131"} #预期结果 checkDict47: {"success":true,"code":"200","message":"OK","data":True} @@ -391,7 +397,7 @@ checkDict54: {"success":true,"code":"200","message":"OK"} #预期结果 checkDict55: {"success":true,"code":"200"} # 获取指定商品折扣信息报文 -"payload55": {"companyName":null,"productCode":"10082402","productName":null,"areaName":null,"productLineName":null,"specifications":null,"materialCode":null,"manufacturer":null,"customerCode":null,"customerName":null,"queryTimes":[],"pageNum":1,"pageSize":8,"total":null,"startTime":null,"endTime":null} +"payload55": {"companyName":null,"productCode":"10016229","productName":null,"areaName":null,"productLineName":null,"specifications":null,"materialCode":null,"manufacturer":null,"customerCode":null,"customerName":null,"queryTimes":[],"pageNum":1,"pageSize":8,"total":null,"startTime":null,"endTime":null} #测试场景五十六:按条件删除协议价验证 @@ -403,7 +409,7 @@ checkDict55: {"success":true,"code":"200"} #预期结果 checkDict56: {"success":true,"code":"200","message":"OK","data":true,"freshToken":null} - +checkDict56_1: {"success": True, "code": "200", "message": "OK"} #测试场景五十七:获取下单数量列表 "url57": "/product/productPackage/getListPage" @@ -460,8 +466,7 @@ checkDict63: {"success": False,"code":"200","message":"删除成功"} "url64": "/product/productPackage/deletePackageBatchById" #预期结果 -checkDict64: {"success": False,"code":"200","message":"OK","data":1} - +checkDict64: {"success":true,"code":"200","message":"OK","data":1,"freshToken":null} # 获取商品列表 @@ -529,21 +534,51 @@ checkDict72: {"productLineCode":"%s"} #预期结果 checkDict73: {"success":true,"code":"200","message":"正在同步中","data":null,"freshToken":null} +#测试场景七十四:获取产品线制单员列表 +"url74": "/product/back/queryMemberList" +"payload74": {"productLineCode":"%s","memberName":"","pageStart":1,"pageSize":5} +#预期结果 +checkDict74: {"total":"%s"} +# 查询已分配制单员的产品线信息 +"payload74_1": {"productLineCode":null,"productLineName":null,"memberId":null,"isDistribution":1,"pageStart":1,"pageSize":10} +#测试场景七十五:查询条件验证_制单员列表 +"url75": "/user/queryMarkerList" +"payload75": {"productLineCode":"","realName":"%s","memberIdsList":[],"pageNumber":1,"pageSize":5} +#预期结果 +checkDict75: {"realName":"%s"} +checkDict75_1: {"realName":[]} +#测试场景七十六:产品线分配制单员功能验证 +"url76": "/product/back/addMakerMember" +#预期结果 +checkDict76: {"success":false,"code":"200","message":"操作成功!","data":null,"freshToken":null} +#测试场景七十七:获取产品线详情 +"url77": "/product/back/queryProductLineDetail" +"payload77": {"productCode":"","productName":"","specifications":"","materialCode":"","manufacturer":"","pageNum":1,"pageSize":10,"productLineCode":"10052433"} +#预期结果 +checkDict77: {"success":true,"code":"200","message":"OK"} +#测试场景七十八:查询条件验证_产品线详情 +"url78": "/product/back/queryProductLineDetail" +"payload78": {"productCode":"%s","productName":"%s","specifications":"%s","materialCode":"%s","manufacturer":"%s","pageNum":1,"pageSize":10,"productLineCode":"10052433"} +#预期结果 +checkDict78: {"productCode":"%s"} +#测试场景七十九:产品线制单员删除功能验证 +"url79": "/product/back/deleteMakerMember" +"payload79": {"pageStart":1,"productLineCode":"%s","memberId":"%s"} +#预期结果 +checkDict79: {"success":false,"code":"200","message":"操作成功!","data":null,"freshToken":null} - - - - - - - +#测试场景八十:必填字段校验_产品线制单员删除 +"url80": "/product/back/deleteMakerMember" +"payload80": {"pageStart":1,"productLineCode":"100008","memberId":null} +#预期结果 +checkDict80: {"success":false,"code":"ADD MARKERMEMBER ERROR","message":"操作失败:制单员Id为空!","data":null,"freshToken":null} diff --git a/data/cmdc_rebate/data b/data/cmdc_rebate/data index d77257cebe9ff9142de40c9ce37224da95267436..530298d31285c2035f96c14cd639c1a5b41b34bb 100644 --- a/data/cmdc_rebate/data +++ b/data/cmdc_rebate/data @@ -6,6 +6,9 @@ "username1": "Admin00111" "password1": "Aa123456" +#后台运营管理系统登录信息(子站点国联医疗器械有限公司) +"username2": "Admin00102" +"password2": "Aa123456" #后台管理系统headers json_headers: { @@ -128,13 +131,13 @@ checkDict14: {"customercode":"%s"} #测试场景十六:产品线商品获取验证 "url15": "/product/queryProductForControlSalesByPage" -"payload15": {"productName":"","productCode":"","relevanceCode":"3111","pageNum":1,"pageSize":10,"pageTotal":0} +"payload15": {"productName":"","productCode":"","relevanceCode":"10052433","pageNum":1,"pageSize":10,"pageTotal":0} #预期结果 checkDict15: {"success":true,"code":"200","message":"OK"} #测试场景十七:列表查询条件验证_产品线商品 "url16": "/product/queryProductForControlSalesByPage" -"payload16": {"productName":"%s","productCode":"%s","relevanceCode":"3111","pageNum":1,"pageSize":10,"pageTotal":143} +"payload16": {"productName":"%s","productCode":"%s","relevanceCode":"10052433","pageNum":1,"pageSize":10,"pageTotal":143} #预期结果 checkDict16: {"relevanceCode":"%s"} @@ -149,7 +152,7 @@ checkDict17: {"success":true,"code":"200","message":"OK"} "url18": "/product/uploadCustomerExcel" #获取客户信息 "url_customer": "/user/queryUserForControlSalesByPage" -"payload_customer": {"customerName":"","customerCode":"","pageNum":1,"pageSize":10,"pageTotal":4960,"currentPage":1} +"payload_customer": {"customerName":"","customerCode":"","pageNum":1,"pageSize":10,"pageTotal":null,"currentPage":1} #预期结果 checkDict18: {"success":true} @@ -157,10 +160,10 @@ checkDict18: {"success":true} #测试场景二十:商品黑名单批量导入验证_返利规则 "url19": "/product/uploadProductExcel" -"payload19": {"relevanceCode":3111} +"payload19": {"relevanceCode":10052433} #获取商品信息 "url_product": "/product/queryProductForControlSalesByPage" -"payload_product": {"productName":"","productCode":"","relevanceCode":"3111","pageNum":1,"pageSize":10,"pageTotal":0} +"payload_product": {"productName":"","productCode":"","relevanceCode":"10052433","pageNum":1,"pageSize":10,"pageTotal":0} #预期结果 checkDict19: {"success":true} @@ -172,9 +175,9 @@ checkDict20: {"success":false} #测试场景二十二:返利规则新增验证 "url21": "/order/rebate/addRebates" -"payload21": {"relevanceCode":"2011","rebatename":"新增返利规则验证","useLimitStart":"1","useLimitEnd":"2","istax":"1","taxround":"0","isdisposable":"0","isaudit":0,"auditlevel":"1","auditidfirst":"","auditidsecond":"","customerDataList":[{"customername":"%s","customercode":"%s"}],"productDataList":[{"productcode":"%s","productname":"%s","specifications":"%s","manufacturer":"%s"}],"auditstatus":"","relevanceName":"施乐辉敷料"} +"payload21": {"relevanceCode":"1099","rebatename":"新增返利规则验证","useLimitStart":"10","useLimitEnd":"20","istax":"1","taxround":"0","isdisposable":"0","isaudit":0,"auditlevel":"1","auditidfirst":"","auditidsecond":"","customerDataList":[{"customername":"%s","customercode":"%s"}],"productDataList":[{"productcode":"%s","productname":"%s","specifications":"%s","manufacturer":"%s"}],"auditstatus":"","relevanceName":"施乐辉"} #查询商品信息 -"payload2011_product": {"productName":"","productCode":"","relevanceCode":"2011","pageNum":1,"pageSize":10,"pageTotal":0} +"payload2011_product": {"productName":"","productCode":"","relevanceCode":"1099","pageNum":1,"pageSize":10,"pageTotal":0} #预期结果 checkDict21: {"success":True,"code":"200","message":"ok"} diff --git a/data/cmdc_special_fresenius_group/data b/data/cmdc_special_fresenius_group/data index cbfc2800a92d602d8f81f2e4999ae877c330bfde..776f7bd4b4b80c1be4f691797c459031ab468858 100644 --- a/data/cmdc_special_fresenius_group/data +++ b/data/cmdc_special_fresenius_group/data @@ -2,11 +2,18 @@ "username": "BJ0621" "password": "Aa123456" +"username4": "GL1000086" +"password4": "Aa123456" + #后台运营管理系统登录信息(子站点上海医疗器械有限公司) "username1": "Admin00111" "password1": "Aa123456" +"username2": "Admin00102" +"password2": "Aa123456" + + #后台管理系统headers json_headers: { "Content-Type": "application/json", @@ -105,7 +112,7 @@ checkDict11: {"errList":["%s"]} #批量新增功能_套包商品管理功能验证 #商品列表接口地址和报文 "product_list": "/product/public/productGroupList" -"product_payload": {"productCode":"","productName":"","materialCode":"","specifications":"","productLineName":"麦迪康","userNo":"","companyCode":"00111","pageSize":10,"pageNum":1} +"product_payload": {"productCode":"","productName":"","materialCode":"","specifications":"","productLineName":"泰尔茂支架","userNo":"","companyCode":"00102","pageSize":10,"pageNum":1} #批量导入url "import_url": "/order/public/importFreseniusGroup" #预期结果 @@ -242,24 +249,23 @@ checkDict31: {"groupCode": "%s"} #测试场景:获取特殊套包详情 #获取特殊套包详情接口信息 "url38": "/order/public/getDetailFreseniusGroup" -"payload38": {"productCode":"14037826","companyCode":"00111"} +"payload38": {"productCode":"10145853","companyCode":"00102"} #预期结果 -checkDict38: {"productCode": "14037826"} +checkDict38: {"productCode": "10145853"} +checkDict38_1: {"success":true,"code":"200","message":"OK"} #切换站点信息 "url_website": "/user/mall/switchWebsite" -"payload_website": {"companyId":6,"companyCode":"00111"} - - +"payload_website": {"companyId":7,"companyCode":"00102"} #测试场景:验证特价单品商品详情页面,显示特价信息 #获取特价单品信息 -"payload40": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"特价单品验证毋动","groupType":1,"groupPriceStatus":null,"pageStart":1,"pageSize":8} +"payload40": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"test-test-tset1231","groupType":1,"groupPriceStatus":null,"pageStart":1,"pageSize":8} #获取特殊套包详情接口信息 "url41": "/order/public/getDetailFreseniusGroup" "payload41": {"productCode":"%s","companyCode":"%s"} #预期结果 -checkDict41: {"activityName":"每只特价101元,有效期2023-11-09至2031-12-31"} +checkDict41: {"activityName":"每支特价11.11元,有效期2024-02-11至2036-03-29"} #测试场景:特价单品限购验证 @@ -288,13 +294,13 @@ checkDict45: {"success":true,"code":"200","message":"OK"} #测试场景:特价单品_创建需求单 "url46": "/order/public/saveAllDemandOrder" -"payload46": {"国药集团上海医疗器械有限公司":{"datas":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"705.0000","productAmount":705,"payableAmount":705,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":101,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":5,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":505,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":505,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":501,"fsGroupId":501,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":5,"groupName":null,"skuGroup":{"id":null,"groupId":501,"companyCode":"00111","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00825034\\\",\\\"groupCode1\\\":\\\"sspg00825034\\\",\\\"groupPrice\\\":101,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"特价单品验证毋动\\\",\\\"realPay\\\":505,\\\"subtotal\\\":505,\\\"timeStr\\\":\\\"2023-11-09至2031-12-31\\\",\\\"quantity\\\":5,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}]}","lineNumber":null,"freseniusPriceId":285,"groupNumber":5,"demandSkuList":null,"demandSkuVOList":null,"surplusQuantity":5,"groupCode":"sspg00825034","groupCode1":"sspg00825034","groupPrice":101,"limitPurchase":5,"isLimit":1,"documentNo":"特价单品验证毋动","realPay":505,"subtotal":505,"timeStr":"2023-11-09至2031-12-31","quantity":5,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只","subList":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"oldObjArr":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":285,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"sspg00825034","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":null,"lineNumber":null,"price":100,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":200,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":200,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"1131C 丁腈无粉 M 蓝紫色","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":100,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"2012","productLineName":"麦迪康","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":705,"discountAmountWholeLine":0,"payableAmountWholeLine":705,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":705,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":7,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"showInfo":false,"addressConfig":2}],"addressConfig":2,"openPreTaxAmount":0,"remark":null,"receiverPhoneNote":"/","promotionOrRebate":1,"promotionType":1,"productLineCodes":["2012"],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":7,"totalPrice":705,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":101,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":5,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":505,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":505,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":501,"fsGroupId":501,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":5,"groupName":null,"skuGroup":{"id":null,"groupId":501,"companyCode":"00111","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00825034\\\",\\\"groupCode1\\\":\\\"sspg00825034\\\",\\\"groupPrice\\\":101,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"特价单品验证毋动\\\",\\\"realPay\\\":505,\\\"subtotal\\\":505,\\\"timeStr\\\":\\\"2023-11-09至2031-12-31\\\",\\\"quantity\\\":5,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}]}","lineNumber":null,"freseniusPriceId":285,"groupNumber":5,"demandSkuList":null,"demandSkuVOList":null,"surplusQuantity":5,"groupCode":"sspg00825034","groupCode1":"sspg00825034","groupPrice":101,"limitPurchase":5,"isLimit":1,"documentNo":"特价单品验证毋动","realPay":505,"subtotal":505,"timeStr":"2023-11-09至2031-12-31","quantity":5,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只","subList":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"oldObjArr":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":285,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"sspg00825034","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":null,"lineNumber":null,"price":100,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":200,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":200,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"1131C 丁腈无粉 M 蓝紫色","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":100,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"705.0000","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":27568,"addressNo":82429,"addressName":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","provinceCode":null,"userId":null,"companyId":null,"receiverName":"/","address":"","isDefault":1,"type":null,"postcode":null,"mobile":"/","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":3,"companyId":6,"companyName":"国药集团上海医疗器械有限公司","registeredAddress":"上海市宝山区江杨南路880号厂房7幢V008","bank":"中国光大银行上海彭浦支行","accountName":"国药集团上海医疗器械有限公司","accountNumber":"36830188000041806","disableSign":0,"deleteSign":0,"createTime":"2021-05-06 10:46:15","updateTime":"2021-05-06 10:46:15","createBy":2795,"realName":"国药集团上海医疗器械有限公司admin"},"addressList":[{"addressId":27568,"addressNo":82429,"addressName":null,"provinceCode":null,"userId":null,"companyId":6,"receiverName":"/","address":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","isDefault":1,"type":3,"postcode":null,"mobile":"/","updateDate":120035,"updateTime":93623,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":27568,"receiverNote":"/","receiverAddressNote":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","addressNoNote":82429,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"705.0000","taxRate":null,"draftDemandId":null,"demands":[{"demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1126384,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"sellerCompanyCode":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"705.0000","productAmount":705,"payableAmount":705,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":"","lineNumber":null,"price":101,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":5,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":505,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":"国械备20181202号","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":505,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":6,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":501,"fsGroupId":501,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":5,"groupName":null,"skuGroup":{"id":null,"groupId":501,"companyCode":"00111","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00825034\\\",\\\"groupCode1\\\":\\\"sspg00825034\\\",\\\"groupPrice\\\":101,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"特价单品验证毋动\\\",\\\"realPay\\\":505,\\\"subtotal\\\":505,\\\"timeStr\\\":\\\"2023-11-09至2031-12-31\\\",\\\"quantity\\\":5,\\\"calSubFreName\\\":\\\"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"101.0000\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14037826\\\"}]}","lineNumber":null,"freseniusPriceId":285,"groupNumber":5,"demandSkuList":null,"demandSkuVOList":null,"surplusQuantity":5,"groupCode":"sspg00825034","groupCode1":"sspg00825034","groupPrice":101,"limitPurchase":5,"isLimit":1,"documentNo":"特价单品验证毋动","realPay":505,"subtotal":505,"timeStr":"2023-11-09至2031-12-31","quantity":5,"calSubFreName":"检查手套(1131C 丁腈无粉 M 蓝紫色)*1只","subList":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"oldObjArr":[{"activityUnitAmount":"101.0000","quantity":1,"productCode":"14037826"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":285,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":"sspg00825034","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null},{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00111","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"2012","productLineName":"麦迪康","propertyStr":null,"storageType":"002","suppDist":null,"productId":7438,"productName":"检查手套","productCode":"14037826","productNature":null,"brandName":null,"optionStr":"1131C 丁腈无粉 M 蓝紫色","imageUrl":null,"lineNumber":null,"price":100,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":null,"salesDiscountTax":null,"quantity":2,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":200,"measuringUnit":"只","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"SFTCN1131C-0100100","manufacturer":"麦迪康(马来西亚)公司 A R Medicom (M) Sdn Bhd","produceRegisterNum":null,"riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":200,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":"1131C 丁腈无粉 M 蓝紫色","lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":null,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":100,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":null,"ptbfa2":null,"ptbfa3":null,"ptbfa4":null,"ptbfa5":null,"yapeiPriceId":null,"ypLinePromotion":null,"yapeiPrice":null,"companyId":null,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":null,"fsGroupId":null,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.13,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":null,"groupName":null,"skuGroup":null,"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":null,"quantityAndGroupAll":null,"booleaTime":null,"spitSgin":0,"groupSpitSign":0,"sort":0,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"groupCode":null,"groupProductType":null,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"rebate":false,"giftList":[],"purchaseZeroProductList":[],"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineCode":"2012","productLineName":"麦迪康","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.13,"rebateType":0,"paymentAmountWholeLine":705,"discountAmountWholeLine":0,"payableAmountWholeLine":705,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"otherNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":6,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"productAmountWholeLine":705,"edit":false,"auditCompanyName":null,"auditCompanyNameCode":null,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":7,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"_rebateType":false,"showInfo":false,"addressConfig":2,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":705,"paymentType":0,"accountId":3,"version":null,"receiveBankName":"国药集团上海医疗器械有限公司","receiveBankAccount":"36830188000041806","addressNumber":82429,"receiverName":"/","receiverContact":"/","receiverAddress":"昆明高新技术产业开发区马金铺高登路1676号水科技园标准工业厂房1号办公楼4层405室,2号工业厂房一层101、102、103、104-2室","buyerCartIds":[null,null],"sellerCompanyCode":"00111","companyId":6}} +"payload46": {"国药集团联合医疗器械有限公司":{"datas":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"11.1100","productAmount":11.11,"payableAmount":11.11,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9216,"productName":"真空采血管","productCode":"14622505","productNature":null,"brandName":null,"optionStr":"NP-FH0205G","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/19/b859d0ce-0884-42f7-897c-ea856b9d9c75.png","lineNumber":null,"price":11.11,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":11.11,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"尼普洛(上海)有限公司","produceRegisterNum":"沪械注准20172410220","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":11.11,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":1076,"fsGroupId":1076,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":1076,"companyCode":"00102","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00302106\\\",\\\"groupCode1\\\":\\\"sspg00302106\\\",\\\"groupPrice\\\":11.11,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"test-test-tset1231\\\",\\\"realPay\\\":11.11,\\\"subtotal\\\":11.11,\\\"timeStr\\\":\\\"2024-02-11至2036-03-29\\\",\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"真空采血管(NP-FH0205G)*1支\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"freseniusPriceId\\\":566}","lineNumber":null,"freseniusPriceId":566,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"surplusQuantity":5,"groupCode":"sspg00302106","groupCode1":"sspg00302106","groupPrice":11.11,"limitPurchase":5,"isLimit":1,"documentNo":"test-test-tset1231","realPay":11.11,"subtotal":11.11,"timeStr":"2024-02-11至2036-03-29","quantity":1,"calSubFreName":"真空采血管(NP-FH0205G)*1支","subList":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"oldObjArr":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":566,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"sspg00302106","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":0,"paymentAmountWholeLine":11.11,"discountAmountWholeLine":0,"payableAmountWholeLine":11.11,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"edit":false,"productAmountWholeLine":11.11,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"showInfo":false,"addressConfig":2}],"addressConfig":2,"openPreTaxAmount":1,"notice":"站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示站点级提示","remark":null,"receiverPhoneNote":"13810613577","promotionOrRebate":1,"promotionType":1,"productLineCodes":[""],"addressIsCommon":true,"showChangePromotionOrRebate":false,"couponTotalAmount":0,"activityTotalAmount":0,"totalQuantity":1,"totalPrice":11.11,"discountAmount":0,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9216,"productName":"真空采血管","productCode":"14622505","productNature":null,"brandName":null,"optionStr":"NP-FH0205G","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/19/b859d0ce-0884-42f7-897c-ea856b9d9c75.png","lineNumber":null,"price":11.11,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":11.11,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"尼普洛(上海)有限公司","produceRegisterNum":"沪械注准20172410220","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":11.11,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":1076,"fsGroupId":1076,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":1076,"companyCode":"00102","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00302106\\\",\\\"groupCode1\\\":\\\"sspg00302106\\\",\\\"groupPrice\\\":11.11,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"test-test-tset1231\\\",\\\"realPay\\\":11.11,\\\"subtotal\\\":11.11,\\\"timeStr\\\":\\\"2024-02-11至2036-03-29\\\",\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"真空采血管(NP-FH0205G)*1支\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"freseniusPriceId\\\":566}","lineNumber":null,"freseniusPriceId":566,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"surplusQuantity":5,"groupCode":"sspg00302106","groupCode1":"sspg00302106","groupPrice":11.11,"limitPurchase":5,"isLimit":1,"documentNo":"test-test-tset1231","realPay":11.11,"subtotal":11.11,"timeStr":"2024-02-11至2036-03-29","quantity":1,"calSubFreName":"真空采血管(NP-FH0205G)*1支","subList":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"oldObjArr":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":566,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"sspg00302106","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0}],"productPrice":"11.1100","fileList":[],"showInfo":false,"pageStart":1,"pageSize":5,"receiveInfo":[{"addressId":37354,"addressNo":17823,"addressName":"上海市浦东新区浦电路3号1","provinceCode":null,"userId":null,"companyId":null,"receiverName":"张梦怡","address":"","isDefault":0,"type":null,"postcode":null,"mobile":"13810613577","updateDate":null,"updateTime":null,"flag":null,"deleteSign":null,"province":null,"city":null,"area":null,"dateTime":null,"provinceStr":null,"cityStr":null,"areaStr":null,"isJde":0}],"defaultBankInfo":{"accountId":5,"companyId":7,"companyName":"国药集团联合医疗器械有限公司","registeredAddress":"北京市顺义区金航中路3号院天竺万科中心1号楼3单元2层201(北京天竺综合保税区)","bank":"中国工商银行股份有限公司北京新街口支行","accountName":"国药集团联合医疗器械有限公司","accountNumber":"0200002919200155850","disableSign":0,"deleteSign":0,"createTime":"2021-06-03 09:46:49","updateTime":"2021-06-03 09:46:49","createBy":114378,"realName":"国药集团联合医疗器械有限公司admin"},"addressList":[{"addressId":37354,"addressNo":17823,"addressName":null,"provinceCode":null,"userId":null,"companyId":7,"receiverName":"张梦怡","address":"上海市浦东新区浦电路3号1","isDefault":0,"type":3,"postcode":null,"mobile":"13810613577","updateDate":123354,"updateTime":95133,"flag":null,"deleteSign":null,"province":0,"city":0,"area":0,"dateTime":null,"provinceStr":"","cityStr":"","areaStr":"","isJde":0,"cityList":[],"areaList":[]}],"selecteAddresId":37354,"receiverNote":"张梦怡","receiverAddressNote":"上海市浦东新区浦电路3号1","addressNoNote":17823,"province":0,"city":0,"cityList":[],"area":0,"areaList":[],"paymentAmount":"11.1100","taxRate":null,"draftDemandId":null,"demands":[{"otherNote":null,"sellerCompanyCode":null,"productLineCode":"","demandId":null,"demandParentId":null,"demandParentCode":null,"demandCode":null,"customerId":null,"customerName":null,"customerCode":1000086,"loginName":null,"realName":null,"addressNumber":null,"mobile":null,"productName":null,"productCode":null,"sellerCompanyName":null,"paymentType":null,"receiveBankName":null,"receiveBankAccount":null,"paymentAmount":"11.1100","productAmount":11.11,"payableAmount":11.11,"refundAmount":null,"cancelAmount":null,"discountAmount":0,"orderStatus":null,"refundStatus":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"remark":null,"revokedReason":null,"auditById":null,"auditByName":null,"auditTime":null,"auditRemark":null,"flhsStatus":null,"pushJdeStatus":null,"createTime":null,"updateTime":null,"submitTime":null,"pushJdeTime":null,"successTime":null,"auditStatus":null,"deleteSign":null,"firstOrderFlag":null,"demandItems":[{"maxProductNum":999999,"minProductNum":1,"addMinProductNum":1,"minProductNumSign":false,"isMultiple":false,"quantityTip":"","demandSkuId":null,"demandId":null,"distributionId":null,"companyCode":"00102","demandCode":null,"demandParentId":null,"sellerCompanyId":null,"sellerCompanyName":null,"sellerCompanyCode":null,"customerCode":null,"productLineCode":"","productLineName":"","propertyStr":null,"storageType":"999","suppDist":null,"productId":9216,"productName":"真空采血管","productCode":"14622505","productNature":null,"brandName":null,"optionStr":"NP-FH0205G","imageUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2021/04/19/b859d0ce-0884-42f7-897c-ea856b9d9c75.png","lineNumber":null,"price":11.11,"rebateId":null,"rebateDetail":null,"useMaxLimit":null,"useLimitStart":null,"useBalance":null,"originalPrice":null,"biddingDiscountTax":0,"salesDiscountTax":0,"quantity":1,"sumQuantity":null,"sendQuantity":null,"lackQuantity":null,"cancelQuantity":null,"cancelAmount":null,"refundQuantity":null,"refundAmount":null,"discountQuantity":null,"discountAmount":null,"subtotal":11.11,"measuringUnit":"支","auxiliaryMeasuringUnit":null,"procurementMeasuringUnit":null,"pricingMeasuringUnit":null,"materialCode":"","manufacturer":"尼普洛(上海)有限公司","produceRegisterNum":"沪械注准20172410220","riskRank":null,"productClassify":null,"createTime":null,"updateTime":null,"deleteSign":null,"calCancelFlag":null,"refundFlag":null,"discountRate":1,"realPay":11.11,"promotionPrice":null,"promotionTotalPrice":0,"demandParentCode":null,"regionId":null,"regionName":null,"spitSign":null,"activityAmount":0,"couponAmount":0,"activityUnitAmount":0,"couponUnitAmount":null,"activityBasicId":null,"couponSgin":null,"couponSgin2":null,"returnQuantity":null,"returnAmount":null,"customerId":null,"prescription":null,"specifications":null,"lineCodeDelete":null,"sdOutStorage":null,"licenseNo":null,"demandCodes":null,"areaName":null,"agreementPriceId":null,"offerPrice":0,"orderMark":null,"totalPrice":null,"productLimitBuyList":null,"giftSign":0,"giftProductCode":null,"activityCarDataVoList":null,"productReplaceLogs":null,"orderSource":null,"receiverName":null,"receiverContact":null,"receiverAddress":null,"rebateTripId":null,"allSign":null,"replaceSgin":null,"salesReturn":null,"nowAmount":null,"taxSign":0,"plusMinuKey":null,"rebateRule":null,"areaPrice":null,"lockType":null,"estimatedDeliveryDate":null,"licenseInfoFeignDtos":null,"receivedQty":null,"version":null,"installedDateMust":0,"sizeSign":0,"rebateSign":null,"ippMiniPurchaseNum":null,"ippMultipleSign":null,"ippPurchaseMultiple":null,"ippStatus":null,"lineNumberOrg":null,"changeSgin":null,"addSgin":null,"ptbfa1":0,"ptbfa2":0,"ptbfa3":0,"ptbfa4":0,"ptbfa5":0,"yapeiPriceId":0,"ypLinePromotion":null,"yapeiPrice":null,"companyId":7,"buyerCartId":null,"userReceiveIdx":null,"userReceiveIdx2":null,"limitNum":null,"productLimitBuyId":null,"alreadyBuyNum":null,"limitBuySign":0,"proposeNum":null,"takeEffectRange":null,"takeEffectTime":null,"endTime1":null,"groupId":1076,"fsGroupId":1076,"proposalQuantity":null,"proposalSign":0,"manufacturerUserNo":null,"manufacturerUserDesc":null,"manufacturerProductNo":null,"manufacturerProductDesc":null,"manufacturerUserId":null,"manufacturerProductId":null,"busProductCode":null,"paidTime":null,"customerName":null,"paymentAmount":null,"specQuantity":null,"disQuantity":null,"fulfilledQuantity":null,"fulCancelQuantity":null,"couponId":null,"couponId2":null,"limitS":null,"starts":null,"ends":null,"userId":null,"productTax":"","taxRate":0.17,"demandSplitSign":"1","hospitalHopeDate":null,"uniqueKey":null,"productType":null,"activityRuleId":null,"allowanceBeginTime":null,"allowanceEndTime":null,"sign":null,"differenceActivityUserId":null,"groupNumber":1,"groupName":null,"skuGroup":{"id":null,"groupId":1076,"companyCode":"00102","groupProductType":1,"createTime":null,"updateTime":null,"demandSkuId":null,"demandId":null,"dataJson":"{\\\"surplusQuantity\\\":5,\\\"groupCode\\\":\\\"sspg00302106\\\",\\\"groupCode1\\\":\\\"sspg00302106\\\",\\\"groupPrice\\\":11.11,\\\"groupProductType\\\":1,\\\"limitPurchase\\\":5,\\\"isLimit\\\":1,\\\"documentNo\\\":\\\"test-test-tset1231\\\",\\\"realPay\\\":11.11,\\\"subtotal\\\":11.11,\\\"timeStr\\\":\\\"2024-02-11至2036-03-29\\\",\\\"quantity\\\":1,\\\"calSubFreName\\\":\\\"真空采血管(NP-FH0205G)*1支\\\",\\\"subList\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"oldObjArr\\\":[{\\\"activityUnitAmount\\\":\\\"11.1100\\\",\\\"quantity\\\":1,\\\"productCode\\\":\\\"14622505\\\"}],\\\"freseniusPriceId\\\":566}","lineNumber":null,"freseniusPriceId":566,"groupNumber":1,"demandSkuList":null,"demandSkuVOList":null,"groupProductTypeList":null,"tjSign":null,"surplusQuantity":5,"groupCode":"sspg00302106","groupCode1":"sspg00302106","groupPrice":11.11,"limitPurchase":5,"isLimit":1,"documentNo":"test-test-tset1231","realPay":11.11,"subtotal":11.11,"timeStr":"2024-02-11至2036-03-29","quantity":1,"calSubFreName":"真空采血管(NP-FH0205G)*1支","subList":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"oldObjArr":[{"activityUnitAmount":"11.1100","quantity":1,"productCode":"14622505"}],"_rebateType":false},"subList":null,"dataJson":null,"skuMergeSign":null,"freseniusPriceId":566,"quantityAndGroupAll":1,"booleaTime":1,"spitSgin":0,"groupSpitSign":0,"sort":2,"circleArea":null,"purchaseEntryId":null,"mustInstallDate":false,"installedDate":null,"installedDateStr":null,"demandLines":null,"subLineNumber":null,"demandSubCode":null,"propertyName":null,"propertyVal":null,"propertyNote":null,"sendManualSign":0,"activityType":0,"giftSettlementMethod":null,"giftInitQuantity":null,"packageCode":null,"giftGroupQuantity":null,"siteCompanyCode":null,"hospitalOrderType":null,"isCollectionAllocation":null,"recDifferenceQty":null,"orderStatus":null,"distributionType":null,"replaceSign":null,"groupCode":"sspg00302106","groupProductType":1,"pSign":0,"backSign":0,"description":"","stockNumber":null,"priceChange":false,"jdeStockNumber":null,"rebate":false,"giftList":[],"bol":true,"prePromotionPrice":null,"prepromotionTotalPrice":0,"preDiscountRate":null,"userBalance":0,"orderType":null}],"expireDemandSkus":null,"demandSubItems":null,"rebateDetail":null,"rebateAmountList":null,"productLineName":"","auditLoginName":null,"showPurchaseNo":false,"isRebate":null,"isShowReate":null,"taxRate":0.17,"rebateType":0,"paymentAmountWholeLine":11.11,"discountAmountWholeLine":0,"payableAmountWholeLine":11.11,"discountRate":null,"singleRebateAmount":null,"isRebateEdit":null,"payCertUrl":null,"rebateAmount":null,"demandCance":null,"soAdd":null,"soCance":null,"orderReturn":null,"needCustomerConfirm":false,"measuringUnit":null,"productId":null,"version":null,"mainVersion":null,"agencyConfigId":null,"confirmSign":null,"replySign":null,"agencySign":null,"editIng":null,"editIngStr":null,"jdeType":null,"isElectronicSeal":null,"contractAgreementNo":null,"alesDepartmentNo":null,"alesDepartmentName":null,"salesPersonNo":null,"salesPersonName":null,"customerNote":null,"contractAgreementCode":null,"projectName":null,"projectCode":null,"regionId":null,"regionName":null,"productLineBindSign":null,"shipVia":null,"orderSource":null,"userBalance":null,"liquidCode":null,"shipmentTypeStr":null,"distributionTypeStr":null,"soStr":null,"soList":null,"specifications":null,"pageStart":1,"pageSize":5,"changeSgin":null,"yapei":2,"companyId":7,"preemptConfig":null,"productSpec":null,"secondAuditSign":null,"secondAuditById":null,"secondAuditByName":null,"secondAuditTime":null,"secondAuditRemark":null,"secondAuditStatus":null,"rebateRule":"0","rebateControlSign":0,"rebateId":null,"preferenceType":null,"preferenceName":null,"disPrice":null,"lineNum":0,"auditStaySign":0,"fileList":null,"imageUrls":null,"total":null,"submitTimeStr":null,"updateTimeStr":null,"auditTimeStr":null,"acceptTime":null,"acceptTimeStr":null,"paidTime":null,"paidTimeStr":null,"erpHandingTime":null,"erpHandingTimeStr":null,"partShippingTime":null,"partShippingTimeStr":null,"allShippingTime":null,"allShippingTimeStr":null,"pushJdeTimeStr":null,"successTimeStr":null,"onlinePaySuccessTime":null,"onlinePaySuccessTimeStr":null,"bankTransactionSerial":null,"newIsTax":null,"countFormula":null,"countNumber":null,"noTaxRebateAmount":0,"isCollectionAllocation":0,"siteCompanyCode":null,"hospitalOrderType":null,"proofTime":null,"proofURL":null,"proofRemark":null,"proofSign":0,"customerCancelSign":null,"cancelRecords":null,"cancelCount":0,"updateNewTime":null,"updateNewTimeStr":null,"fsDedUseSign":null,"notice":null,"shareType":null,"singleRebateSign":null,"cf":false,"isPre":null,"showDemandAuditLineLabel":false,"orderType":null,"newDiscountRate":null,"oldOrderType":null,"oldNewDiscountRate":null,"pendding":null,"modifySign":null,"refuseType":null,"groupChangeSign":null,"custModify":null,"demandSubCode":null,"pushJdeStatusDemandSub":null,"circleGiftSign":0,"delay":null,"limitS":null,"starts":null,"ends":null,"completedS":null,"confirmDays":null,"remindS":null,"skuGroupList":null,"groupProductType":0,"purchaseId":null,"purchaseCode":null,"sdCancelTime":null,"sdTipSign":0,"receiverNote":null,"receiverPhoneNote":null,"receiverAddressNote":null,"flag":null,"sourceStr":null,"addressNoNote":null,"detailIsSpit":false,"spitSgin":null,"distributionType":null,"rebateValidity":null,"orderChangeType":null,"logoIcon":null,"detail":null,"changeBigType":null,"promotionType":1,"activityTotalAmount":0,"couponTotalAmount":0,"userReceiveId":null,"editSgin":null,"snSgin":null,"jdeOutAmount":null,"totalAllPaAmount":null,"diffShowSgin":0,"lineCodeDelete":null,"startTime":null,"endTime":null,"changeSign":null,"distributionId":null,"limitBuySign":0,"companyType":null,"afterSale":null,"csId":null,"sdStatusNodeParamList":null,"ypPromotionTotal":null,"acrossMainCode":null,"forceApprovedSign":0,"circleGiftContinueSgin":0,"customerCharge":null,"onlinePaySign":0,"recodeDemandSkuList":null,"mergeDemandSkuList":null,"inventoryNode":null,"customCode":null,"terminalSource":null,"potentialClientsId":null,"settlementStatus":null,"firstOrderAuditStatus":null,"confirmReceiptSign":null,"confirmReceiptTime":null,"afterSaleDays":null,"deliveryCompletedTime":null,"taxSign":0,"orderSplitSign":0,"demandRebateSkuList":null,"confirmTime":null,"customerPurchaseNo":null,"mustInstallDate":false,"secondAddressList":null,"splitOrMerge":null,"spitOrderSign":null,"edit":false,"productAmountWholeLine":11.11,"auditCompanyName":null,"auditCompanyNameCode":null,"installedDateMust":true,"editProductListFlag":false,"ratio":null,"showMoreAttribute":false,"lastNoTaxDiscountAmount":0,"lastDiscountAmount":0,"isExpire":false,"settementQuantity":1,"userBalancePrice":0,"isEdit":true,"discountRateOne":100,"showInfo":false,"addressConfig":2,"pSign":0}],"orderStatus":102,"userReceiveId":null,"userReceiveId2":null,"productAmount":11.11,"paymentType":0,"accountId":5,"version":null,"receiveBankName":"国药集团联合医疗器械有限公司","receiveBankAccount":"0200002919200155850","addressNumber":17823,"receiverName":"张梦怡","receiverContact":"13810613577","receiverAddress":"上海市浦东新区浦电路3号1","buyerCartIds":[null],"sellerCompanyCode":"00102","companyId":7}} checkDict46: {"demandParentCode": "%s"} #测试场景:验证商品详情页面套包正价的展示 #查询指定套包正价信息 -"payload_14260024": {"groupCode":"","groupName":"费森尤斯套包000002","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"","companyCode":"","groupType":0,"status":null,"pageStart":1,"pageSize":8,"regularPriceSign":1,"groupPriceStatus":1,"isRegularPrice":1} +"payload_14260024": {"groupCode":"sspg00921347","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"","companyCode":"","groupType":0,"status":null,"pageStart":1,"pageSize":8,"isRegularPrice":2,"regularPriceSign":2} #获取套包信息 "url47": "/order/public/getFreseniusGroup" "payload47": {"productCode":"%s","companyCode":"%s","detail":true,"buyCart":true,"num":1} @@ -304,21 +310,24 @@ checkDict47: {"groupPrice":"%s","groupName":"%s"} checkDict48: {"groupPrice":"%s","documentNo":"%s"} #查询指定套包协议特价信息 "payload49": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"协议套包","companyCode":"","groupType":0,"status":null,"pageStart":1,"pageSize":8} -"payload49_1": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"套包协议特价商品显示验证","companyCode":"","groupType":0,"status":null,"pageStart":1,"pageSize":8} +"payload49_1": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"","description":"","manufacturerProductDesc":"","manufacturerProductNo":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"123321test","companyCode":"","groupType":0,"status":null,"pageStart":1,"pageSize":8} #测试场景:代客下单_套包清单_查询条件验证 #套包清单列表获取 "url50": "/order/public/getFreseniusGroup" -"payload50": {"userNo":1126384,"companyCode":"00111","back":true,"buyCart":true,"num":1,"p":true} +"payload50": {"userNo":1000008,"companyCode":"00102","back":true,"buyCart":true,"num":1,"p":true} #查询条件验证 -"payload51": {"groupName":"%s","groupProductCode":"%s","groupProductName":"%s","groupOptionStr":"%s","documentNo":"%s","productLineCode":"%s","userNo":1126384,"companyCode":"00111","materialCodeSplit":"%s","back":true,"p":true,"buyCart":true,"num":1} +"payload51": {"groupName":"%s","groupProductCode":"%s","groupProductName":"%s","groupOptionStr":"%s","documentNo":"%s","productLineCode":"%s","userNo":1000008,"companyCode":"00102","materialCodeSplit":"%s","back":true,"p":true,"buyCart":true,"num":1} #预期结果 checkDict51: {"productLineCode":"%s"} - - +#新老编码替换明细导出验证 +"url60": "/order/public/exportProductMaintainPage" +"payload60": {"groupCode":"","groupName":"","productCode":"","productInfo":"","materialCode":"","manufacturerList":[],"productLineName":"%s","description":"","manufacturerGroupCode":"","manufacturerGroupName":"","customerCode":"","customerName":"","manufacturerUserNo":"","manufacturerUserDesc":"","documentNo":"","groupType":2,"status":null,"pageStart":1,"pageSize":8} +#预期结果 +checkDict60: {"productLineName":"%s"} diff --git a/data/cmdc_trade/data b/data/cmdc_trade/data index 93ed3ec9d996cbee927a95862de58dec36f1cfaf..758d974645188b7c2488b7a1d819680ecd2ba8fe 100644 --- a/data/cmdc_trade/data +++ b/data/cmdc_trade/data @@ -2,10 +2,18 @@ "username": "BJ0621" "password": "Aa123456" +"username3": "GL1000086" +"password3": "Aa123456" + +"username_be": "testtest" +"password_be": "Aa123456" + #后台运营管理系统登录信息(子站点上海医疗器械有限公司) "username1": "Admin00111" "password1": "Aa123456" +"username4": "Admin00102" +"password4": "Aa123456" #后台管理系统headers json_headers: { @@ -85,39 +93,207 @@ checkDict9: {"productCode":"%s"} #预期结果 checkDict10: {"demandCode":"%s"} +#测试场景十一:获取发货单物流信息列表 +"url11": "/order/public/jde580Jde" +"payload11": {"pageSize":null,"pageStart":null} +#预期结果 +checkDict11: {"success":true,"code":"200","message":"OK"} +#测试场景十二:查询条件验证_发货单物流信息列表 +"url12": "/order/public/jde580Jde" +"payload12": {"demandParentCode":"%s","productCode":"%s","endTime":"%s","startTime":"%s","sendEndTime":"%s","sendStartTime":"%s","demandCode":"%s","sellerCompanyCode":"00102","sddoco_1":"%s","pageStart":1,"pageSize":10,"optionStr":"%s"} +#预期结果 +checkDict12: {"demandParentCode":"%s"} +#测试场景十三:获取物流详情 +"url13": "/order/public/dde580Detail" +"payload13": {"demandParentCode":"%s"} +#预期结果 +checkDict13: {"demandCode":"%s"} +#测试场景十四:必传字段校验_获取物流详情 +"url14": "/order/public/dde580Detail" +"payload14": {"demandParentCode":""} +#预期结果 +checkDict14: {"success":false,"code":"ERROR","message":"单号必传","data":null,"freshToken":null} +#测试场景十五:订单不存在验证_获取物流详情 +"url15": "/order/public/dde580Detail" +"payload15": {"demandParentCode":"54363463456436534645"} +#预期结果 +checkDict15: {"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +#测试场景十六:获取发货单号验证 +"url16": "/order/public/soByDemandCode" +"payload16": {"demandCode":"%s"} +#预期结果 +checkDict16: {"data":"%s"} +#测试场景十七:必传字段校验_获取发货单号 +"url17": "/order/public/soByDemandCode" +"payload17": {"demandCode":""} +#预期结果 +checkDict17: {"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +#测试场景十八:订单不存在验证_获取发货单号 +"url18": "/order/public/soByDemandCode" +"payload18": {"demandCode":"%s"} +#预期结果 +checkDict18: {"success":false,"code":"500","message":"内部系统错误","data":null,"freshToken":null} +#测试场景十九:发货单据导出验证 +"url19": "/order/public/export/jde580Jde" +"payload19": {"demandCode":"%s","pageSize":10,"pageStart":1} +#预期结果 +checkDict19: {"demandCode":"%s"} +#测试场景二十:订单发货明细导出验证 +"url20": "/order/public/export/jde580Jde" +"payload20": {"demandParentCode":"%s"} +#预期结果 +checkDict20: {"demandParentCode":"%s"} +#测试场景二十一:随货同行单导出验证 +"url21": "/order/public/exportSo" +"payload21": {"demandCode":"%s","so":"%s","type":1} +#预期结果 +checkDict21: {"so":null} +#测试场景二十二:获取退货单管理列表 +"url22": "/order/public/listJdeRefund" +"payload22": {"pageSize":null,"pageStart":null,"total":null} +#预期结果 +checkDict22: {"success":true,"code":"200","message":"OK"} +#测试场景二十三:查询条件验证_退货单管理 +"url23": "/order/public/listJdeRefund" +"payload23": {"jdeRefundCode":"%s","customerName":"%s","manufacturer":"%s","materialCode":"%s","demandParentCode":"%s","pageSize":null,"pageStart":null,"total":null,"startTime":"%s","endTime":"%s"} +#预期结果 +checkDict23: {"jdeRefundCode":"%s"} +#测试场景二十四:获取退货单详情 +"url24": "/order/public/listJdeRefund" +"payload24": {"pageSize":null,"pageStart":null,"total":null,"jdeRefundCode":"%s"} +#预期结果 +checkDict24: {"jdeRefundCode":"%s"} +#测试场景二十五:获取发货单列表 +"url25": "/order/public/getOutDemand" +"payload25": {"times1":[],"times2":[],"times3":[],"times4":[],"times5":[],"SDDOCO":null,"customerCode":null,"customerName":null,"demandCode":null,"productCode":null,"optionStr":null,"materialCode":null,"invoiceNo":null,"productLineName":null,"sellerCompanyName":null,"projectName":null,"sddcto":null,"distributionType":null,"demandSubCode":null,"pageStart":1,"pageSize":8,"total":null,"startTime":null,"endTime":null,"sdaddjStrStart":null,"sdaddjStrEnd":null,"sdtrdjStrStart":null,"sdtrdjStrEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"paidTimeStart":null,"paidTimeEnd":null} +#预期结果 +checkDict25: {"success":true,"code":"200","message":"OK"} +#测试场景二十六:查询条件验证_发货单列表 +"url27": "/order/public/getOutDemand" +"payload27": {"times1":[],"times2":[],"times3":[],"times4":[],"times5":[],"SDDOCO":null,"customerCode":null,"customerName":null,"demandCode":"%s","productCode":null,"optionStr":null,"materialCode":null,"demandParentCode":"%s","invoiceNo":null,"productLineName":null,"sellerCompanyName":null,"projectName":null,"sddcto":null,"distributionType":null,"demandSubCode":null,"pageStart":1,"pageSize":8,"total":null,"startTime":null,"endTime":null,"sdaddjStrStart":null,"sdaddjStrEnd":null,"sdtrdjStrStart":null,"sdtrdjStrEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"paidTimeStart":null,"paidTimeEnd":null} +#预期结果 +checkDict27: {"demandCode":"%s"} +#测试场景二十七:获取发货单详情 +"url26": "/order/public/getOutDemandDetail" +"payload26": {"manufacturer":null,"materialCode":null,"productCode":null,"productName":null,"optionStr":null,"demandCode":"%s","SDDOCO":"%s","sddcto":"%s"} +#预期结果 +checkDict26: {"demandCode":"%s"} +#测试场景二十八:发货商品清单查询条件验证_发货详情 +"url28": "/order/public/getOutDemandDetail" +"payload28": {"manufacturer":"%s","materialCode":"%s","productCode":"%s","productName":"%s","optionStr":"%s","demandCode":"%s","SDDOCO":"%s","sddcto":"%s"} +#预期结果 +checkDict28: {"productCode":"%s"} +#测试场景二十九:获取关联单据图信息_发货单详情 +"url29": "/order/public/getFlowByDemandCode" +"payload29": {"demandCode":"%s"} +#预期结果 +checkDict29: {"demandCode":"%s"} +#测试场景三十:发货单据导出验证_发货单管理 +"url30": "/order/public/exportOutDemandExcel" +"payload30": {"times1":[],"times2":[],"times3":[],"times4":[],"times5":[],"SDDOCO":null,"customerCode":null,"customerName":null,"demandCode":"%s","productCode":null,"optionStr":null,"materialCode":null,"demandParentCode":null,"invoiceNo":null,"productLineName":null,"sellerCompanyName":null,"projectName":null,"sddcto":null,"distributionType":2,"demandSubCode":null,"pageStart":1,"pageSize":8,"total":1,"startTime":null,"endTime":null,"sdaddjStrStart":null,"sdaddjStrEnd":null,"sdtrdjStrStart":null,"sdtrdjStrEnd":null,"auditTimeStart":null,"auditTimeEnd":null,"paidTimeStart":null,"paidTimeEnd":null} +#预期结果 +checkDict30: {"demandCode":"%s"} +#测试场景三十一:发货同步_发货单管理 +"url31": "/order/public/getFlowSync" +"payload31": {"companyCode":"00111"} +#预期结果 +checkDict31: {"success":true,"code":"200","message":null,"data":null,"freshToken":null} +#测试场景三十二:获取退货记录列表 +"url32": "/order/mall/queryRefundListMall" +"payload32": {"pageStart":1,"pageSize":10,"refundCode":"","customerName":"","returnType":"","pageNumber":1} +#预期结果 +checkDict32: {"success":true,"code":"200","message":"OK"} - - - +#测试场景三十三:查询条件验证_退货记录列表 +"url33": "/order/mall/queryRefundListMall" +"payload33": {"pageStart":1,"pageSize":10,"refundCode":"%s","customerName":"%s","returnType":"%s","pageNumber":null,"startTime":"%s","endTime":"%s","sellerCompanyCode":"%s"} +#预期结果 +checkDict33: {"refundCode":"%s"} + +#测试场景三十四:获取退货记录详情 +"url34": "/order/mall/queryRefundSkuList" +"payload34": {"refundId":"%s","pageStart":1,"pageSize":10} +checkDict34: {"refundId":"%s"} + +#测试场景三十五:获取发票清单列表 +"url35": "/order/mall/queryInvoicePage" +"payload35": {"companyId":"","demandCode":"","invoiceNo":"","invoiceTimeBegin":"","invoiceTimeEnd":"","pageNumber":1,"pageSize":10} +checkDict35: {"success":true,"code":"200","message":"操作成功"} + +#测试场景三十六:查询条件验证_发票清单列表 +"url36": "/order/mall/queryInvoicePage" +"payload36": {"companyId":"","demandCode":"","invoiceNo":"%s","invoiceTimeBegin":"%s","invoiceTimeEnd":"%s","pageNumber":1,"pageSize":10,"companyCode":"%s","demandParentCode":"%s"} +checkDict36: {"invoiceNo":"%s"} + +#测试场景三十七:查询物流信息_发票清单列表 +"url37": "/order/public/invoice/express" +"payload37": {"invoiceNo":"%s"} +checkDict37: {"success":true,"code":"200","message":"未查询到数据","data":null,"freshToken":null} +checkDict37_1: {"success":true,"code":"200","message":"操作成功"} + +#测试场景三十八:获取库存上报列表 +"url38": "/cms/public/ls/getCustomerStockReportList" +"payload38": {"hospInfo":"","source":"","statisticYear":"","statisticMonth":"","invoiceCode":"","pageStart":1,"pageSize":10} +checkDict38: {"success":true,"code":"200","message":"OK"} + +#测试场景三十九:查询条件验证_库存上报列表 +"url39": "/cms/public/ls/getCustomerStockReportList" +"payload39": {"hospInfo":"","source":"%s","statisticYear":"%s","statisticMonth":"%s","invoiceCode":"","pageStart":1,"pageSize":10} +checkDict39: {"source":"%s"} + +#测试场景四十:库存信息修改功能验证 +"url40": "/cms/public/ls/editStockReport" +"payload40": {"statisticInvReportId":"%s","inventoryCostAmount":"%s","source":"%s"} +checkDict40: {"inventoryCostAmount":"%s"} + +#测试场景四十一:库存上报信息导出验证 +"url41": "/cms/public/ls/exportExcel" +"payload41": {"hospInfo":"","source":"","statisticYear":"%s","statisticMonth":"","invoiceCode":"","pageStart":1,"pageSize":10,"type":"10"} +checkDict41: {"statisticYear":"%s"} + +#测试场景四十二:获取所属站点列表_采购计划 +"url42": "/order/public/procurement/customerWebsiteList" +"payload42": {} +checkDict42: {"total":"%s"} + +#测试场景四十三:获取采购计划详情 +"url43": "/order/public/procurement/queryProcurementDetail" +"payload43": {"companyCode":"00103","procurementDate":"2024-02","type":"0"} +checkDict43: {"total":"%s"} + +#测试场景四十四:获取采购计划修改记录 +"url44": "/order/public/procurementRecord/getProcurementRecordListById" +"payload44": {"procurementId":"92"} +checkDict44: {"total":"%s"} diff --git a/data/cmdc_website/data b/data/cmdc_website/data index 0c8023efa94447e9f6ff3a7b4b1a24f0974eb64e..53aaebf01fe6aabb0aa9fc4c8605e981d3a92c2b 100644 --- a/data/cmdc_website/data +++ b/data/cmdc_website/data @@ -1,34 +1,416 @@ -#后台运营管理系统登录信息(子公司-上海公司) -"username": "Admin00111" +#后台运营管理系统登录信息(总公司) +"username2": "admin" +"password2": "Aa123456" + +#后台运营管理系统登录信息(总公司-beta) +"username_beta": "admin1" +"password_beta": "Aa123456" + +#后台运营管理系统登录信息(子公司-国联公司) +"username": "Admin00102" "password": "Aa123456" + # 多采商城登录信息 "username1": "BJ0621" "password1": "Aa123456" + + json_headers: { "Cmdc_access_token": "%s", "Sourcetype": "mall" } -#获取站点信息接口地址 +#后台管理系统headers +json_headers1: { + "Content-Type": "application/json", + "Cmdc_access_token": "%s" +} + +#测试场景1:获取站点信息接口地址 "url1": "/cms/public/website/queryAll" "payload1": {} #预期结果 checkDict1: {"success":true,"code":"200","message":"操作成功"} -#站点切换接口地址 +#测试场景2:站点切换接口地址 "url2": "/user/mall/switchWebsite" "payload2": {"companyId":3,"companyCode":"00103"} #预期结果 checkDict2: {"success":true,"code":"200","message":"OK","data":null} -#获取站点商品接口地址 +#测试场景3:获取站点商品接口地址 "url3": "/product/mall/queryPcProductInfoByPage" "payload3": {"filterConditions":[],"ranking":"","searchName":"","pageNum":1,"pageSize":40,"orderBy":"","orderByType":""} #预期结果 checkDict3: {"success":true,"code":"200","message":"OK"} #登录失败预期结果 -checkDict_401: {"code":"401","message":"Unauthorized","success":false} \ No newline at end of file +checkDict_401: {"code":"401","message":"Unauthorized","success":false} + +#测试场景4:获取站点列表 +"url4": "/cms/website/queryListPage" +"payload4": {"websiteName":"","orderApportionPrinciple":"","companyName":"","companyType":"","allocationSite":"","pageStart":1,"pageSize":10,"total":10,"pageNumber":1,"pageTotal":0} +#预期结果 +checkDict4: {"total":"%s"} + +#测试场景5:列表查询条件验证_站点列表 +"url5": "/cms/website/queryListPage" +"payload5": {"websiteName":"%s","orderApportionPrinciple":"%s","companyName":"%s","companyType":"%s","allocationSite":"","pageStart":1,"pageSize":10,"total":null,"pageNumber":1,"pageTotal":null} +#预期结果 +checkDict5: {"websiteName":"%s"} + + +#测试场景6:获取子站信息列表 +"url6": "/user/querySubCompanyPage" +"payload6": {"pageStart":1,"pageSize":10,"companyName":"","companyCode":""} +#预期结果 +checkDict6: {"total":"%s"} + +#测试场景7:列表查询条件验证_子站点列表 +"url7": "/user/querySubCompanyPage" +"payload7": {"pageStart":1,"pageSize":10,"companyName":"%s","companyCode":"%s"} +#预期结果 +checkDict7: {"companyCode":"%s"} + +#测试场景8:站点新增功能验证 +"url8": "/cms/website/add" +"payload8": {"companyId":18,"websiteName":"站点新增测试","websiteId":"","companyName":"万能较长","companyCode":"-121833","linkUrl":"https://portal-uat.gyqxmall.com/otherStoreIndex/storeOtherStore?companyId=18","orderApportionPrinciple":"1","ypRelevanceCode":[],"freseniusDownLoadLineList":[],"demandAuditLineLabelList":[],"valetSign":0,"contractSign":0,"equalShareSgin":0,"quickOrderSign":0,"sealSiteSign":0,"sealCustomerSign":0,"businessId":"","sealNo":"","signatoryName":"","signatoryTel":"","distributionType":2,"sdDistributionType":1,"sjDistributionType":1,"soDistributionType":1,"demandSplitSign":1,"secondAuditSign":0,"orderSplitSign":0,"custConfirmSign":0,"isCollectionAllocation":0,"allocationSite":"","jdeCompanyCode":"","orderType":"","visitor":2,"noClient":2,"priceSecAudit":0,"trendSign":0,"isProcure":0,"customerPurchaseNos":[],"customerCancelSign":1,"installedDateSettings":[],"invoiceTemplateUrl":"","jdePush":0,"businessTypeList":["1"],"companyType":3} +#预期结果 +checkDict8: {"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} + +#测试场景9:站点信息编辑功能验证 +"url9": "/cms/website/modify" +"payload9": {"companyId":18,"websiteName":"站点新增测试","websiteId":"%s","companyName":"万能较长","companyCode":"-121833","linkUrl":"https://portal-uat.gyqxmall.com/otherStoreIndex/storeOtherStore?companyId=18","orderApportionPrinciple":"1","ypRelevanceCode":[],"valetSign":0,"contractSign":0,"equalShareSgin":0,"quickOrderSign":0,"sealSiteSign":0,"sealCustomerSign":0,"businessId":"","sealNo":"","signatoryName":"","signatoryTel":"","distributionType":2,"sdDistributionType":1,"sjDistributionType":1,"soDistributionType":1,"demandSplitSign":1,"secondAuditSign":0,"orderSplitSign":0,"custConfirmSign":0,"isCollectionAllocation":0,"orderType":"","visitor":2,"noClient":2,"priceSecAudit":0,"trendSign":0,"isProcure":0,"customerPurchaseNos":[],"customerCancelSign":1,"installedDateSettings":[],"jdePush":0,"businessTypeList":["1"],"creditSign":0,"openPreTaxAmount":0,"modifyPrice":0,"companyType":3} +#预期结果 +checkDict9: {"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} + +# 获取新增站点 +"url_list": "/cms/website/queryListPage" +"payload_list": {"websiteName":"站点新增测试","orderApportionPrinciple":"","companyName":"","companyType":"","allocationSite":"","pageStart":1,"pageSize":10,"total":10,"pageNumber":1,"pageTotal":1} + + +#测试场景10:站点直通车开启_站点管理 +"url10": "/cms/website/isPublish" + +#预期结果 +checkDict10: {"passSign":2} + +#测试场景11:站点直通车关闭_站点管理 +"url11": "/cms/website/isPublish" + +#预期结果 +checkDict11: {"passSign":1} + +#测试场景12:站点删除功能验证 +"url12": "/cms/website/delete" +"payload12": {"websiteId":"%s"} +#预期结果 +checkDict12: {"deleteSign":1} + +#测试场景13:根据公司id获取公司信息 +"url13": "/user/public/getCompanyById" +"payload13": {"companyId":"%s"} +#预期结果 +checkDict13: {"companyId":"%s"} + + +#测试场景14:获取站点退货地址信息 +"url14": "/user/public/getReturnAddressList" +"payload14": {"companyId":"%s"} +#预期结果 +checkDict14: {"data":"%s"} + +#测试场景15:获取公司站点信息 +"url15": "/cms/public/website/queryListByCompanyId" +"payload15": {"companyId":"%s"} +#预期结果 +checkDict15: {"companyId":"%s"} + +#测试场景16:获取产品线code信息 +"url16": "/user/back/getProductLineCodes" +"payload16": {} +#预期结果 +checkDict16: {"success":true,"code":"200","message":"OK","data":["DS-电商专用"]} + +#测试场景17:获取站点备注配置 +"url17": "/user/back/remarksConfigList" +"payload17": {"companyId":"%s"} +#预期结果 +checkDict17: {"total":"%s"} + +#测试场景19:获取产品备注列表 +"url19": "/cms/public/lineRemark/getLineRemarkList" +"payload19": {} +#预期结果 +checkDict19: {"total":"%s"} + +#测试场景18:新增产品线备注功能验证 +"url18": "/cms/public/lineRemark/addLineRemark" +"payload18": {"lineCode":"%s","remark":"产品线备注新增测试验证"} +#预期结果 +checkDict18: {"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +checkDict18_1: {"success":false,"code":"ERROR","message":"产品线冲突","data":null} +#获取产品线信息 +"url_line": "/product/public/queryProductLineNameByAll?filialeCode=00102" + + +#测试场景20:备注为空校验_新增产品线备注 +"url20": "/cms/public/lineRemark/addLineRemark" +"payload20": {"lineCode":"%s","remark":""} +#预期结果 +checkDict20: {"success":false,"code":"ERROR","message":"备注不能为空","data":null,"freshToken":null} + +#测试场景21:获取站点jde配货手动推送设置信息 +"url21": "/order/public/queryJdePushConfigList" +"payload21": {"companyId":"%s"} +#预期结果 +checkDict21: {"total":"%s"} + + +#测试场景22:站点产品线备注设置删除验证 +"url22": "/cms/public/lineRemark/deleteLineRemark" +"payload22": {"id":"%s"} +#预期结果 +checkDict22: {"success":true,"code":"200","message":"OK","data":1,"freshToken":null} +checkDict22_1: {"success":false,"code":"ERROR","message":"找不到配置","data":null,"freshToken":null} + + +#测试场景23:查询三方站点详情信息 +"url23": "/user/public/queryTripartiteCompanyDetail" +"payload23": {} +#预期结果 +checkDict23: {"success":true,"code":"200","message":"OK"} + +#测试场景24:参数必填性校验_站点产品线备注设置删除 +"url24": "/cms/public/lineRemark/deleteLineRemark" +"payload24": {"id":""} +#预期结果 +checkDict24: {"success":false,"code":"ERROR","message":"找不到配置","data":null,"freshToken":null} + +#测试场景25:查询站点详情JDE +"url25": "/user/back/getSiteInformation" +"payload25": {"companyId":"7"} +#预期结果 +checkDict25: {"companyId":"7"} + +#测试场景26:查询站点变更记录详情 +"url26": "/user/tripartiteChange/queryTripartiteChangeDetail" +"payload26": {"tripartiteId":"%s"} +#预期结果 +checkDict26: {"tripartiteId":"%s"} + + +#测试场景27:站点新增客户联系人信息功能验证 +"url27": "/cms/contact/add" +"payload27": {"name":"测试勿动","telephone":"18700000000"} +#预期结果 +checkDict27: {"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} + +#测试场景28:获取站点客户联系人列表 +"url28": "/cms/contact/queryPage" +"payload28": {"name":"","telephone":"","pageNumber":1,"pageSize":10} +#预期结果 +checkDict28: {"total":"%s"} + +#测试场景29:客户联系人信息修改功能验证 +"url29": "/cms/contact/modify" +"payload29": {"name":"%s","telephone":"%s","contactId":"%s"} +#预期结果 +checkDict29: {"success":true,"code":"200","message":"操作成功","data":null,"freshToken":null} + +#测试场景30:客户联系人信息删除功能验证 +"url30": "/cms/contact/delete" +"payload30": {"contactId":"%s"} +#预期结果 +checkDict30: {"deleteSign":1} + +#测试场景31:站点退货地址新增验证 +"url31": "/user/public/addReturnAddress" +"payload31": [{"provinceList":[{"areaId":1,"areaCode":"110000","areaName":"北京市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":19,"areaCode":"120000","areaName":"天津市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":37,"areaCode":"130000","areaName":"河北省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":217,"areaCode":"140000","areaName":"山西省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":348,"areaCode":"150000","areaName":"内蒙古自治区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":464,"areaCode":"210000","areaName":"辽宁省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":579,"areaCode":"220000","areaName":"吉林省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":649,"areaCode":"230000","areaName":"黑龙江省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":792,"areaCode":"310000","areaName":"上海市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":810,"areaCode":"320000","areaName":"江苏省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":920,"areaCode":"330000","areaName":"浙江省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1021,"areaCode":"340000","areaName":"安徽省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1143,"areaCode":"350000","areaName":"福建省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1238,"areaCode":"360000","areaName":"江西省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1350,"areaCode":"370000","areaName":"山东省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1505,"areaCode":"410000","areaName":"河南省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1681,"areaCode":"420000","areaName":"湖北省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1798,"areaCode":"430000","areaName":"湖南省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1935,"areaCode":"440000","areaName":"广东省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2079,"areaCode":"450000","areaName":"广西壮族自治区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2205,"areaCode":"460000","areaName":"海南省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2236,"areaCode":"500000","areaName":"重庆市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2277,"areaCode":"510000","areaName":"四川省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2482,"areaCode":"520000","areaName":"贵州省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2580,"areaCode":"530000","areaName":"云南省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2726,"areaCode":"540000","areaName":"西藏自治区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2808,"areaCode":"610000","areaName":"陕西省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":2926,"areaCode":"620000","areaName":"甘肃省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3027,"areaCode":"630000","areaName":"青海省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3080,"areaCode":"640000","areaName":"宁夏回族自治区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3108,"areaCode":"650000","areaName":"新疆维吾尔自治区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3228,"areaCode":"710000","areaName":"台湾省","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3229,"areaCode":"810000","areaName":"香港特别行政区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":3251,"areaCode":"820000","areaName":"澳门特别行政区","level":null,"cityCode":null,"center":null,"parentId":null}],"cityList":[{"areaId":1682,"areaCode":"420100","areaName":"武汉市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1696,"areaCode":"420200","areaName":"黄石市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1703,"areaCode":"420300","areaName":"十堰市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1712,"areaCode":"420500","areaName":"宜昌市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1726,"areaCode":"420600","areaName":"襄阳市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1736,"areaCode":"420700","areaName":"鄂州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1740,"areaCode":"420800","areaName":"荆门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1746,"areaCode":"420900","areaName":"孝感市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1754,"areaCode":"421000","areaName":"荆州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1763,"areaCode":"421100","areaName":"黄冈市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1774,"areaCode":"421200","areaName":"咸宁市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1781,"areaCode":"421300","areaName":"随州市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1785,"areaCode":"422800","areaName":"恩施土家族苗族自治州","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1794,"areaCode":"429005","areaName":"潜江市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1795,"areaCode":"429021","areaName":"神农架林区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1796,"areaCode":"429006","areaName":"天门市","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1797,"areaCode":"429004","areaName":"仙桃市","level":null,"cityCode":null,"center":null,"parentId":null}],"areaList":[{"areaId":1683,"areaCode":"420102","areaName":"江岸区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1684,"areaCode":"420103","areaName":"江汉区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1685,"areaCode":"420104","areaName":"硚口区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1686,"areaCode":"420105","areaName":"汉阳区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1687,"areaCode":"420106","areaName":"武昌区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1688,"areaCode":"420107","areaName":"青山区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1689,"areaCode":"420111","areaName":"洪山区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1690,"areaCode":"420112","areaName":"东西湖区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1691,"areaCode":"420113","areaName":"汉南区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1692,"areaCode":"420114","areaName":"蔡甸区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1693,"areaCode":"420115","areaName":"江夏区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1694,"areaCode":"420116","areaName":"黄陂区","level":null,"cityCode":null,"center":null,"parentId":null},{"areaId":1695,"areaCode":"420117","areaName":"新洲区","level":null,"cityCode":null,"center":null,"parentId":null}],"provinceCode":1681,"cityCode":1682,"province":"湖北省","city":"武汉市","area":"洪山区","receiverName":"测试勿动","receiverPhone":"18700000000","detailAddress":"测试勿动","districtCode":1689}] +#预期结果 +checkDict31: {"success":true,"code":"200","message":"OK","data":1,"freshToken":null} + +#测试场景32:站点退货地址删除验证 +"url32": "/user/public/deleteReturnAddress" +"payload32": {"id":"%s"} +#预期结果 +checkDict32: {"success":true,"code":"200","message":"OK","data":1,"freshToken":null} + +#测试场景33:站点JDE配货手动推送设置新增验证 +"url33": "/order/public/saveJdePushConfigList" +#预期结果 +checkDict33: {"success":true,"code":"200","message":"OK","data":"success"} + +#测试场景34:获取公司基础配置信息 +"url34": "/user/queryJdeConfigPage" +"payload34": {"companyCode":"","companyName":"","settlementType":null,"payMerchantNo":null,"siteType":null,"affiliationCode":null,"pageStart":1,"pageSize":10,"total":null} +#预期结果 +checkDict34: {"success":true,"code":"200","message":"OK"} + +#测试场景35:列表查询条件验证_公司基础配置列表 +"url35": "/user/queryJdeConfigPage" +"payload35": {"companyCode":"%s","companyName":"%s","settlementType":"%s","payMerchantNo":"%s","siteType":"%s","affiliationCode":"%s","pageStart":1,"pageSize":100,"total":null} +#预期结果 +checkDict35: {"companyCode":"%s"} + +#测试场景36:获取三方站点信息 +"url36": "/user/public/querySubCompany" +"payload36": {"companyType":3} +#预期结果 +checkDict36: {"total":"%s"} + +#测试场景37:获取集配站点信息 +"url37": "/user/public/getAffiliationList" +"payload37": {} +#预期结果 +checkDict37: {"total":"%s"} + +#测试场景38:公司基础配置信息新增验证 +"url38": "/user/addJdeConfig" +"payload38": {"companyCode":"testtest123","companyName":"test123","siteType":0,"licenceUrl":"https://pro-cmdc.oss-cn-beijing.aliyuncs.com/productFile/2024/03/05/f1ce7c07-f443-4631-ae01-45f301f9e09f.jpg","userNo":null,"areaSign":0,"pricingStrategy":1,"businessType":0,"qdaCode":"","qdaPassword":"","appId":"12345678","secretKey":"12345678","qyAppId":"","qyAppSecret":"","qyKf":"","settlementType":3,"collectionAccountNumber":"","receivingBank":"","beneficiaryName":"","receivingProvince":"","receivingCity":"","bankAssociationNumber":"","payMerchantNo":"","enterpriseUserNo":"","chargePayer":1,"transferType":1,"chargeDeduction":null,"settlementNode":1,"settlementTimes":"","companyList":[{"companyId":15,"companyName":"呵呵呵","companyCode":"-123277","companyType":3,"createBy":null,"updateBy":null,"createTime":"2021-06-3015:49:12","updateTime":"2021-06-3015:49:12","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":16,"companyName":"万能膏药厂","companyCode":"-121843","companyType":3,"createBy":null,"updateBy":null,"createTime":"2021-06-3017:31:52","updateTime":"2021-06-3017:31:52","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":18,"companyName":"万能较长","companyCode":"-121833","companyType":3,"createBy":null,"updateBy":null,"createTime":"2021-07-2423:42:11","updateTime":"2021-07-2423:42:11","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":20,"companyName":"西门子医疗系统有限公司","companyCode":"-132145","companyType":3,"createBy":null,"updateBy":null,"createTime":"2021-08-3015:27:17","updateTime":"2021-08-3015:27:17","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":32,"companyName":"三方厂家001","companyCode":"-88893353","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-08-2209:49:06","updateTime":"2022-08-2209:49:06","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":34,"companyName":"三方南博万药业","companyCode":"-88893354","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-08-2308:43:10","updateTime":"2022-08-2308:43:10","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":35,"companyName":"三方经销商001","companyCode":"-88893359","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-08-2316:38:16","updateTime":"2022-08-2316:38:16","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":36,"companyName":"南博图药业","companyCode":"-88893358","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-08-2316:48:23","updateTime":"2022-08-2316:48:23","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":37,"companyName":"南波佛","companyCode":"-88893366","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-08-2408:36:41","updateTime":"2022-08-2408:36:41","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":38,"companyName":"周娟的店","companyCode":"-88893395","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-10-1711:03:08","updateTime":"2022-10-1711:03:08","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":39,"companyName":"周娟的测试店铺","companyCode":"-88893397","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-10-1814:58:04","updateTime":"2022-10-1814:58:04","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":40,"companyName":"三方站点202","companyCode":"-88893412","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-10-3115:51:45","updateTime":"2022-10-3115:51:45","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":41,"companyName":"三方厂家203","companyCode":"-88893416","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-11-0309:49:30","updateTime":"2022-11-0309:49:30","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":42,"companyName":"三方站点2021","companyCode":"-88893415","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-11-0417:02:18","updateTime":"2022-11-0417:02:18","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":43,"companyName":"测试厂家8910","companyCode":"-88893435","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-12-1415:10:50","updateTime":"2022-12-1415:10:50","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":44,"companyName":"我是一家生产厂家","companyCode":"-88893437","companyType":3,"createBy":null,"updateBy":null,"createTime":"2022-12-1509:18:39","updateTime":"2022-12-1509:18:39","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":45,"companyName":"三方经销商002","companyCode":"-88893450","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-02-2114:31:00","updateTime":"2023-02-2114:31:00","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":46,"companyName":"北京航川科技有限公司","companyCode":"-88893463","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1310:58:59","updateTime":"2023-04-1310:58:59","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":47,"companyName":"北京艾凯尔医学仪器有限公司","companyCode":"-88893466","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1316:50:52","updateTime":"2023-04-1316:50:52","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":48,"companyName":"上海敦凯医疗器械销售中心","companyCode":"-88893470","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1317:16:19","updateTime":"2023-04-1317:16:19","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":49,"companyName":"北京德泉兴业商贸有限公司","companyCode":"-88893471","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1317:21:20","updateTime":"2023-04-1317:21:20","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":50,"companyName":"北京英孚锐德信息技术有限公司","companyCode":"-88893473","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1317:27:37","updateTime":"2023-04-1317:27:37","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":51,"companyName":"上海举联电子科技有限公司","companyCode":"-88893431","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1409:37:39","updateTime":"2023-04-1409:37:39","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":52,"companyName":"蓝网科技股份有限公司","companyCode":"-88893476","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1414:36:37","updateTime":"2023-04-1414:36:37","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":53,"companyName":"北京圣洁盛科贸有限公司","companyCode":"-88893480","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-04-1713:57:05","updateTime":"2023-04-1713:57:05","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":54,"companyName":"武汉泰利美信医疗科技有限公司","companyCode":"-88893483","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-05-0614:18:46","updateTime":"2023-05-0614:18:46","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":70,"companyName":"北京康明晖医疗科技发展有限公司","companyCode":"-88893531","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-10-2716:06:44","updateTime":"2023-10-2716:06:44","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":71,"companyName":"福建海鹏医疗设备有限公司","companyCode":"-88893532","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-10-2716:08:17","updateTime":"2023-10-2716:08:17","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":72,"companyName":"湖南迪斯生物技术股份有限公司","companyCode":"-88893533","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-10-2716:08:22","updateTime":"2023-10-2716:08:22","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":73,"companyName":"中国仪器进出口(集团)公司","companyCode":"-88893534","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-10-3009:42:31","updateTime":"2023-10-3009:42:31","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":74,"companyName":"深圳市金康桥科技有限公司","companyCode":"-88893537","companyType":3,"createBy":null,"updateBy":null,"createTime":"2023-10-3011:13:44","updateTime":"2023-10-3011:13:44","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":75,"companyName":"北京威联德骨科技术有限公司","companyCode":"-88893543","companyType":3,"createBy":null,"updateBy":null,"createTime":"2024-01-1713:44:33","updateTime":"2024-01-1713:44:33","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null},{"companyId":76,"companyName":"三方站点130","companyCode":"-88893545","companyType":3,"createBy":null,"updateBy":null,"createTime":"2024-01-3016:50:51","updateTime":"2024-01-3016:50:51","deleteSign":null,"disableSign":null,"linkUrl":null,"websiteName":null,"isCollectionAllocation":0,"affiliationName":null,"affiliationCode":null}]} +#预期结果 +checkDict38: {"success":true,"code":"200","message":"OK","data":"success","freshToken":null} + +#测试场景39:获取公司配置信息 +"url39": "/cms/account/public/list" +"payload39": {"companyId":null,"disableSign":0} +#预期结果 +checkDict39: {"success":true,"code":"200","message":"OK"} + +#测试场景40:公司基础信息删除功能验证 +"url40": "/user/deleteJdeConfig" +"payload40": {"configId":"%s"} +#预期结果 +checkDict40: {"deleteSign":1} +#查询指定公司信息 +"url40_1": "/user/queryJdeConfigPage" +"payload40_1": {"companyCode":"testtest123","companyName":"","settlementType":null,"payMerchantNo":null,"siteType":null,"affiliationCode":null,"pageStart":1,"pageSize":10,"total":1} + +#测试场景41:必填字段校验_公司基础信息删除 +"url41": "/user/deleteJdeConfig" +"payload41": {"configId":""} +#预期结果 +checkDict41: {"success":false,"code":"CONFIGIDNULL","message":"configId为空","data":null,"freshToken":null} + +#测试场景42:传参无效性校验_公司基础信息删除 +"url42": "/user/deleteJdeConfig" +"payload42": {"configId":"%s"} +#预期结果 +checkDict42: {"success":true,"code":"200","message":"OK","data":"fail","freshToken":null} + +#测试场景43:获取站点资质明细列表 +"url43": "/user/public/websiteLicense/queryWebsiteLicenseDetailInfoPage" +"payload43": {"companyName":null,"companyType":null,"isPublish":null,"companyProperty":null,"licenceTypes":null,"isOverdue":null,"startTime":null,"endTime":null,"typeList":[],"appsNum":0,"pageStart":1,"pageSize":10} +#预期结果 +checkDict43: {"success":true,"code":"200","message":"OK"} + +#测试场景44:列表查询条件验证_站点资质明细列表 +"url44": "/user/public/websiteLicense/queryWebsiteLicenseDetailInfoPage" +"payload44": {"companyName":"%s","companyType":"%s","isPublish":null,"companyProperty":"%s","licenceTypes":"%s","isOverdue":"%s","startTime":"%s","endTime":"%s","typeList":["%s"],"appsNum":1,"pageStart":1,"pageSize":10} +#预期结果 +checkDict44: {"companyName":"%s"} + +#测试场景45:站点资质明细导功能验证 +"url45": "/user/public/websiteLicense/detailExport" +"payload45": {"websiteIdList":[2]} +#预期结果 +checkDict45: {"companyName":"%s"} + +#测试场景46:获取站点证照列表 +"url46": "/user/public/websiteLicense/queryWebsiteLicenseInfoPage" +"payload46": {"companyName":null,"companyType":null,"isPublish":null,"companyProperty":null,"licenceStatus":null,"isWarning":null,"isSuspend":null,"isTermination":null,"startTime":null,"endTime":null,"sortKey":null,"sortValue":null,"typeList":[],"pageStart":1,"pageSize":10} +#预期结果 +checkDict46: {"success":true,"code":"200","message":"OK"} + +#测试场景47:获取用户信息 +"url47": "/user/mall/queryUserInfoNow" +"payload47": {} +#预期结果 +checkDict47: {"userName":"%s"} + + +#测试场景48:获取用户证照信息 +"url48": "/user/public/queryLicensesForUser" +"payload48": {"pageNum":1,"pageSize":2,"total":null} +#预期结果 +checkDict48: {"success":true,"code":"200","message":"OK"} + +#测试场景49:获取已合作站点列表 +"url49": "/user/mall/listUserCompany" +"payload49": {"userId":"69","companyName":""} +#预期结果 +checkDict49: {"success":true,"code":"200","message":"OK"} + +#测试场景50:查询条件验证_合作站点列表 +"url50": "/user/mall/listUserCompany" +"payload50": {"userId":69,"companyName":"%s"} +#预期结果 +checkDict50: {"companyName":"%s"} + +#测试场景51:获取合作站点详情信息 +"url51": "/user/mall/listUserInfo" +"payload51": {"userId":"%s","companyId":"%s","type":1} +#预期结果 +checkDict51: {"userId":"%s"} + +#测试场景52:获取资料申请变更记录列表 +"url52": "/user/mall/firstSellList" +"payload52": {"applycompany":"","pageNum":1,"pageSize":10,"total":null,"customerType":1} +#预期结果 +checkDict52: {"success":true,"code":"200","message":"OK"} + +#测试场景53:查询条件验证_资料申请变更记录列表 +"url53": "/user/mall/firstSellList" +"payload53": {"applycompany":"%s","pageNum":1,"pageSize":10,"total":null,"customerType":1} +#预期结果 +checkDict53: {"applycompany":"%s"} + +#测试场景54:获取资料申请变更记录详情信息 +"url54": "/user/public/selectScheduleByUser" +"payload54": {"firstid":"%s"} +#预期结果 +checkDict54: {"success":true,"code":"200"} + + +#测试场景55:获取合作站点信息 +"url55": "/user/mall/getCompanyByUser" +"payload55": {} +#预期结果 +checkDict55: {"success":true,"code":"200"} + +#测试场景56:获取资料变更原记录信息 +"url56": "/user/public/queryOldChangeByUserName" +"payload56": {} +#预期结果 +checkDict56: {"success":true,"code":"200"} + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/templates/summary_template.html b/templates/summary_template.html index ab8fb5092bd7e6348dff6eb2dfd824485749e34a..9df75913f44a4309f4aaa4ae8ef404692c02cf6c 100644 --- a/templates/summary_template.html +++ b/templates/summary_template.html @@ -69,6 +69,7 @@ 执行结果 执行时间(秒) 用例作者 + 接口响应时间(秒) {% for r in case_results %} @@ -76,6 +77,7 @@ {{"成功" if r.result else "失败"}} {{r.time}} {{r.author}} + {{r.api_time}} {% endfor %}