diff --git "a/air_case/a2_herp3_bs/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.air/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.py" "b/air_case/a2_herp3_bs/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.air/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.py" index 155fb608c53acf6f8c5bfbaaaf4da58fe20a2e1d..ce72135f7eb9c4ab56a1134eff158627b064f66f 100644 --- "a/air_case/a2_herp3_bs/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.air/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.py" +++ "b/air_case/a2_herp3_bs/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.air/f7_\351\231\242\345\214\272\345\215\225\345\205\203\345\214\205\350\256\276\347\275\256_\347\274\226\350\276\221\345\215\225\345\205\203\345\214\205\344\277\241\346\201\257_\345\274\202\345\270\270\344\277\235\345\255\230.py" @@ -60,7 +60,7 @@ def branch_branchGoodsPkgDef_edit(): result = commonFuc().http_post(url,request_body,headers) print('result', result) #断言 - checkDict=commonFuc().get_business_data(module,'checkDict10') + checkDict=commonFuc().get_business_data(module,'checkDict17') commonFuc().check_result(checkDict,result) # total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) # if total>=0: diff --git "a/air_case/a2_herp3_bs/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.air/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.py" "b/air_case/a2_herp3_bs/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.air/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.py" new file mode 100644 index 0000000000000000000000000000000000000000..82b02ef2c2a3f63b228081b034e4194909b03556 --- /dev/null +++ "b/air_case/a2_herp3_bs/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.air/f8_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +import sys + +from airtest.core.helper import using + +from common.db.sql.sql_del_branch_info import delByBranchId +from common.db.sql.sql_del_kind_goodsinfo import delKindGoodsinfo +from common.db.sql.sql_del_notices_info import delByNoticeName +from common.fileUtls import FileUtils +from common.timeUtils import timeUtils + +__author__ = "xiaohesheng" + +""" +case_tag:api,herp-web,f8_请领出库渠道设置_查询产品信息,id2263,id2263-58,sit,on +内网:f8_请领出库渠道设置_查询产品信息 +""" + +from common.common_func import commonFuc +from air_case.a1_herp3_login.登录内网系统.登录内网系统 import login_system +module = "a2_herp3_bs" +def goods_select(): + """ + 场景:f8_请领出库渠道设置_查询产品信息 + 用例名称:f8_请领出库渠道设置_查询产品信息 + 输入:无 + 输出:"rtn_msg": {"code": 0, "msg": null, "data": 1} + """ + #内网登录 + username = commonFuc().get_business_data(module, "username") + # # print('医院名称',username) + password = commonFuc().get_business_data(module, "password") + # print(username, password,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + # 获取token和projectCode + token,projectCode,uxid,corpId,info= login_system(username, password).get_token() + # print( token,projectCode,uxid,corpId,info) + #f8_请领出库渠道设置_查询产品信息 + url=commonFuc().get_api_url()+commonFuc().get_business_data(module, "mcmsBranchGoodsInfo_url") + + # 获取请求头信息 + headers = commonFuc().get_business_data(module, "json_headers2", + commonFuc().get_business_data(module, "json_contentType"), token, + commonFuc().get_business_data(module, "X-APP-CODE")) + # 获取院区id + branch_id = FileUtils().r_info(module, '院区新增')["branch_id"] + # #请求体 + request_body = commonFuc().get_business_data(module, "payload45", branch_id) + print(request_body) + # # # 发送请求 + result = commonFuc().http_post(url, request_body, headers) + print('result', result) + #断言 + # checkDict=commonFuc().get_business_data(module,'checkDict17') + # commonFuc().check_result(checkDict,result) + total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) + if total>=1: + commonFuc().check_text_exist(0, result) + data=commonFuc().analysis_json('data',commonFuc().analysis_json('data',result)) + branchGoodsId=commonFuc().analysis_json('branchGoodsId',data) + return branchGoodsId + else: + commonFuc().check_text_exist(500, result) +goods_select() diff --git "a/air_case/a2_herp3_bs/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.air/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.py" "b/air_case/a2_herp3_bs/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.air/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.py" new file mode 100644 index 0000000000000000000000000000000000000000..76e51c9349c89f0942efeb7ea2ee6c6e0791a4c1 --- /dev/null +++ "b/air_case/a2_herp3_bs/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.air/f9_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\346\237\245\350\257\242\344\272\247\345\223\201\344\277\241\346\201\257_\344\270\215\345\255\230\345\234\250\347\232\204\344\272\247\345\223\201.py" @@ -0,0 +1,60 @@ +# -*- encoding=utf8 -*- +import sys + +from airtest.core.helper import using + +from common.db.sql.sql_del_branch_info import delByBranchId +from common.db.sql.sql_del_kind_goodsinfo import delKindGoodsinfo +from common.db.sql.sql_del_notices_info import delByNoticeName +from common.fileUtls import FileUtils +from common.timeUtils import timeUtils + +__author__ = "xiaohesheng" + +""" +case_tag:api,herp-web,f9_请领出库渠道设置_查询产品信息_不存在的产品,id2263,id2263-59,sit,on +内网:f9_请领出库渠道设置_查询产品信息_不存在的产品 +""" + +from common.common_func import commonFuc +from air_case.a1_herp3_login.登录内网系统.登录内网系统 import login_system +module = "a2_herp3_bs" +def goods_select(): + """ + 场景:f9_请领出库渠道设置_查询产品信息_不存在的产品 + 用例名称:f9_请领出库渠道设置_查询产品信息_不存在的产品 + 输入:无 + 输出:"rtn_msg": {"code": 0, "msg": null, "data": 1} + """ + #内网登录 + username = commonFuc().get_business_data(module, "username") + # # print('医院名称',username) + password = commonFuc().get_business_data(module, "password") + # print(username, password,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + # 获取token和projectCode + token,projectCode,uxid,corpId,info= login_system(username, password).get_token() + # print( token,projectCode,uxid,corpId,info) + #f9_请领出库渠道设置_查询产品信息_不存在的产品 + url=commonFuc().get_api_url()+commonFuc().get_business_data(module, "mcmsBranchGoodsInfo_url") + + # 获取请求头信息 + headers = commonFuc().get_business_data(module, "json_headers2", + commonFuc().get_business_data(module, "json_contentType"), token, + commonFuc().get_business_data(module, "X-APP-CODE")) + # 获取院区id + branch_id = FileUtils().r_info(module, '院区新增')["branch_id"] + # #请求体 + request_body = commonFuc().get_business_data(module, "payload46", branch_id) + print(request_body) + # # # 发送请求 + result = commonFuc().http_post(url, request_body, headers) + print('result', result) + #断言 + # checkDict=commonFuc().get_business_data(module,'checkDict17') + # commonFuc().check_result(checkDict,result) + total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) + if total==0: + commonFuc().check_text_exist(0, result) + else: + commonFuc().check_text_exist(500, result) +goods_select() diff --git "a/air_case/a2_herp3_bs/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.air/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.py" "b/air_case/a2_herp3_bs/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.air/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.py" new file mode 100644 index 0000000000000000000000000000000000000000..2c32268a701a39a46fab9fbcc02a9d3bfb7c254a --- /dev/null +++ "b/air_case/a2_herp3_bs/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.air/g0_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\350\276\271\344\273\223.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +import sys + +from airtest.core.helper import using + +from common.db.sql.sql_del_branch_info import delByBranchId +from common.db.sql.sql_del_kind_goodsinfo import delKindGoodsinfo +from common.db.sql.sql_del_notices_info import delByNoticeName +from common.fileUtls import FileUtils +from common.timeUtils import timeUtils + +__author__ = "xiaohesheng" + +""" +case_tag:api,herp-web,g0_请领出库渠道设置_转移产品到边仓,id2263,id2263-60,sit,on +内网:g0_请领出库渠道设置_转移产品到边仓 +""" + +from common.common_func import commonFuc +from air_case.a1_herp3_login.登录内网系统.登录内网系统 import login_system +module = "a2_herp3_bs" +def goods_move(): + """ + 场景:g0_请领出库渠道设置_转移产品到边仓 + 用例名称:g0_请领出库渠道设置_转移产品到边仓 + 输入:无 + 输出:"rtn_msg": {"code": 0, "msg": null, "data": 1} + """ + #内网登录 + username = commonFuc().get_business_data(module, "username") + # # print('医院名称',username) + password = commonFuc().get_business_data(module, "password") + # print(username, password,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + # 获取token和projectCode + token,projectCode,uxid,corpId,info= login_system(username, password).get_token() + # print( token,projectCode,uxid,corpId,info) + #g0_请领出库渠道设置_转移产品到边仓 + url=commonFuc().get_api_url()+commonFuc().get_business_data(module, "updateSettleType_url") + + # 获取请求头信息 + headers = commonFuc().get_business_data(module, "json_headers2", + commonFuc().get_business_data(module, "json_contentType"), token, + commonFuc().get_business_data(module, "X-APP-CODE")) + # 获取单元包信息 + branchGoodsId = FileUtils().r_info(module, '单元包信息')["branchGoodsId"] + hosGoodsId = FileUtils().r_info(module, '单元包信息')["hosGoodsId"] + # 获取院区id + branch_id = FileUtils().r_info(module, '院区新增')["branch_id"] + # #请求体 + request_body = commonFuc().get_business_data(module, "payload47", branchGoodsId,hosGoodsId,branch_id) + print(request_body) + # # # 发送请求 + result = commonFuc().http_post(url, request_body, headers) + print('result', result) + #断言 + checkDict=commonFuc().get_business_data(module,'checkDict10') + commonFuc().check_result(checkDict,result) + # total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) + # if total==0: + # commonFuc().check_text_exist(0, result) + # else: + # commonFuc().check_text_exist(500, result) +goods_move() diff --git "a/air_case/a2_herp3_bs/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.air/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.py" "b/air_case/a2_herp3_bs/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.air/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.py" new file mode 100644 index 0000000000000000000000000000000000000000..2ec236bdb40d70d548f16136d4b9e65f8e67fb4a --- /dev/null +++ "b/air_case/a2_herp3_bs/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.air/g1_\350\257\267\351\242\206\345\207\272\345\272\223\346\270\240\351\201\223\350\256\276\347\275\256_\350\275\254\347\247\273\344\272\247\345\223\201\345\210\260\344\276\233\345\272\224\345\225\206\347\233\264\351\205\215.py" @@ -0,0 +1,63 @@ +# -*- encoding=utf8 -*- +import sys + +from airtest.core.helper import using + +from common.db.sql.sql_del_branch_info import delByBranchId +from common.db.sql.sql_del_kind_goodsinfo import delKindGoodsinfo +from common.db.sql.sql_del_notices_info import delByNoticeName +from common.fileUtls import FileUtils +from common.timeUtils import timeUtils + +__author__ = "xiaohesheng" + +""" +case_tag:api,herp-web,g0_请领出库渠道设置_转移产品到供应商直配,id2263,id2263-61,sit,on +内网:g0_请领出库渠道设置_转移产品到供应商直配 +""" + +from common.common_func import commonFuc +from air_case.a1_herp3_login.登录内网系统.登录内网系统 import login_system +module = "a2_herp3_bs" +def goods_move(): + """ + 场景:g0_请领出库渠道设置_转移产品到供应商直配 + 用例名称:g0_请领出库渠道设置_转移产品到供应商直配 + 输入:无 + 输出:"rtn_msg": {"code": 0, "msg": null, "data": 1} + """ + #内网登录 + username = commonFuc().get_business_data(module, "username") + # # print('医院名称',username) + password = commonFuc().get_business_data(module, "password") + # print(username, password,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa') + # 获取token和projectCode + token,projectCode,uxid,corpId,info= login_system(username, password).get_token() + # print( token,projectCode,uxid,corpId,info) + #g0_请领出库渠道设置_转移产品到供应商直配 + url=commonFuc().get_api_url()+commonFuc().get_business_data(module, "updateSettleType_url") + + # 获取请求头信息 + headers = commonFuc().get_business_data(module, "json_headers2", + commonFuc().get_business_data(module, "json_contentType"), token, + commonFuc().get_business_data(module, "X-APP-CODE")) + # 获取单元包信息 + branchGoodsId = FileUtils().r_info(module, '单元包信息')["branchGoodsId"] + hosGoodsId = FileUtils().r_info(module, '单元包信息')["hosGoodsId"] + # 获取院区id + branch_id = FileUtils().r_info(module, '院区新增')["branch_id"] + # #请求体 + request_body = commonFuc().get_business_data(module, "payload48", branchGoodsId,hosGoodsId,branch_id) + print(request_body) + # # # 发送请求 + result = commonFuc().http_post(url, request_body, headers) + print('result', result) + #断言 + checkDict=commonFuc().get_business_data(module,'checkDict10') + commonFuc().check_result(checkDict,result) + # total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) + # if total==0: + # commonFuc().check_text_exist(0, result) + # else: + # commonFuc().check_text_exist(500, result) +goods_move() diff --git a/data/a2_herp3_bs/data b/data/a2_herp3_bs/data index ca9e7abe7b86a368ab20d561c0ce11d1cf8561db..c396c044c300106d8eb021a7ceddd79ecc5f1757 100644 --- a/data/a2_herp3_bs/data +++ b/data/a2_herp3_bs/data @@ -27,6 +27,7 @@ "branchGoodsPkgDef_url": "/hospitaltest2api/herpService/branchGoodsPkgDef/list" "branchGoodsPkgDef_insert_url": "/hospitaltest2api/herpService/branchGoodsPkgDef/insert" "branchGoodsPkgDef_update_url": "/hospitaltest2api/herpService/branchGoodsPkgDef/updateById" +"updateSettleType_url": "/hospitaltest2api/herpService/basic/mcmsBranchGoodsInfo/updateSettleType" "username": "xhs1009" "password": "1qaz!QAZ" "X-APP-CODE": "herp.pc" @@ -211,7 +212,10 @@ json_headers2: { "payload42": {"hosId": "h0347",branchId": "%s", "branchGoodsId": "%s"} "payload43": {"id": "%s","effFlag": 1,"pkgLowQty": "555","pkgUperQty": 555,"hosGoodsId": "%s","branchGoodsId": "%s","branchId": "%s"} "payload44": {"id": "%s","effFlag": 1,"pkgLowQty": "555","pkgUperQty": 554,"hosGoodsId": "%s","branchGoodsId": "%s","branchId": "%s"} - +"payload45": {"queryObject": {"goodsName": "","goodsMfrsName": "","purModes": [],"hosId": "h0347","branchId": "%s","grantRule": 1,"goodsSpec": ""},"pageNum": 1, "pageSize": 50} +"payload46": {"queryObject": {"goodsName": "","goodsMfrsName": "","purModes": [],"hosId": "h0347","branchId": "%s","grantRule": 1,"goodsSpec": "xhs"},"pageNum": 1, "pageSize": 50} +"payload47": {"branchGoodsIds": ["%s"],"hosGoodsIds": ["%s"],"grantRule": 2,"branchId": "%s"} +"payload48": {"branchGoodsIds": ["%s"],"hosGoodsIds": ["%s"],"grantRule": 3,"branchId": "%s"} checkDict: {"code": 0,'msg': None,'data': True} checkDict1: { @@ -291,3 +295,5 @@ pl:423', 'data': None} checkDict15: {'code': 0, 'msg': None, 'tag': None, 'data': []} checkDict16: {'code': 14030004, 'msg': '单元包含量重复,请修改后继续操作', 'tag': '/herpService:gyqx.spd.herp.basic.service.impl.BranchGoodsPkgDefServiceImpl:178', 'data': None} +checkDict17: {'code': 1100000, 'msg': '暂时没有定义异码,中文描述为:单元包上限必须大于等于单元包下限!', 'tag': '/herpService:gyqx.spd.herp.basic.service.impl.BranchGoodsPkg +DefServiceImpl:208', 'data': None} diff --git a/report/summary.html b/report/summary.html index 961f691b8c99992151db384b19494f998ae4be7b..0aa31efcb5e894146537843f58f3545d2b2fd9f1 100644 --- a/report/summary.html +++ b/report/summary.html @@ -55,9 +55,9 @@