Commit 0441d068 authored by xiao-hesheng's avatar xiao-hesheng
Browse files

流程十四脚本编写

parent f4f68943
...@@ -467,7 +467,7 @@ def second_dept_consume_in_Stock(type=1): ...@@ -467,7 +467,7 @@ def second_dept_consume_in_Stock(type=1):
# 消耗退回 == == == == == == == == == == == == == == == == # 消耗退回 == == == == == == == == == == == == == == == ==
url = commonFuc().get_api_add_port_url() + commonFuc().get_business_data(module, url = commonFuc().get_api_add_port_url() + commonFuc().get_business_data(module,
"dept_stock_rtn_submit_url") "dept_stock_rtn_submit_url")
print('消耗退回,url', url) print('高值消耗退回,url', url)
billMode = '20' billMode = '20'
deptid2 = FileUtils().r_info8('b2_herp3_bs', '所有科室id', 'message6')["deptid2"] deptid2 = FileUtils().r_info8('b2_herp3_bs', '所有科室id', 'message6')["deptid2"]
request_body = commonFuc().get_business_data(module, "payload35", viewId2, hosGoodsId, DRh_id, request_body = commonFuc().get_business_data(module, "payload35", viewId2, hosGoodsId, DRh_id,
......
...@@ -17,34 +17,38 @@ from air_case.mdm_login.登录外网系统.登录外网系统 import login_syste ...@@ -17,34 +17,38 @@ from air_case.mdm_login.登录外网系统.登录外网系统 import login_syste
from airtest.core.api import using from airtest.core.api import using
import sys import sys
# 第一种方式 # 第一种方式===========================
# hos_goods_id = FileUtils().r_info8('b5_spd3_core_business_flow', '产品审核信息', 'message2')["hosGoodsId"]
# actual_value=delData().check_goods_info(hos_goods_id)
# print('actual_value',actual_value)
# expected_value=commonFuc().get_business_data('b5_spd3_core_business_flow','expected_value')
# print('expected_value',expected_value)
# if actual_value==expected_value:
# print('ok')
# commonFuc().check_text_exist_result_text('succees', 'succees')
# else:
# print('error')
# commonFuc().check_text_exist_result_text('error', 'succees')
# 第二种方式
hos_goods_id = FileUtils().r_info8('b5_spd3_core_business_flow', '产品审核信息', 'message2')["hosGoodsId"] hos_goods_id = FileUtils().r_info8('b5_spd3_core_business_flow', '产品审核信息', 'message2')["hosGoodsId"]
actual_value1 = main2(hos_goods_id) actual_value=delData().check_goods_info(hos_goods_id)
print(actual_value1) print('actual_value',actual_value)
# print('actual_value2',actual_value1) expected_value=commonFuc().get_business_data('b5_spd3_core_business_flow','expected_value')
actual_value2 = get_process_list2(actual_value1) print('expected_value',expected_value)
print('actual_value2', actual_value2, type(actual_value2)) if actual_value==expected_value:
prov_hos_goods_id = '8d6273b7bca84dd8aace12b9422d7fd6'
expected_value2 = commonFuc().get_business_data('b5_spd3_core_business_flow', 'expected_value2', prov_hos_goods_id)
print('expected_value2', expected_value2, type(expected_value2))
actual_value2 = actual_value2.replace(" ", "")
expected_value2 = expected_value2.replace(" ", "")
print(actual_value2 == expected_value2)
if actual_value2 == expected_value2:
print('ok') print('ok')
commonFuc().check_text_exist_result_text('succees', 'succees') commonFuc().check_text_exist_result_text('succees', 'succees')
else: else:
print('error') print('error')
commonFuc().check_text_exist_result_text('error', 'succees') commonFuc().check_text_exist_result_text('error', 'succees')
# 第一种方式===========================
# 第二种方式=================================
# hos_goods_id = FileUtils().r_info8('b5_spd3_core_business_flow', '产品审核信息', 'message2')["hosGoodsId"]
# actual_value1 = main2(hos_goods_id)
# print(actual_value1)
# # print('actual_value2',actual_value1)
# actual_value2 = get_process_list2(actual_value1)
# print('actual_value2', actual_value2, type(actual_value2))
# prov_hos_goods_id = '8d6273b7bca84dd8aace12b9422d7fd6'
# expected_value2 = commonFuc().get_business_data('b5_spd3_core_business_flow', 'expected_value2', prov_hos_goods_id)
# print('expected_value2', expected_value2, type(expected_value2))
# actual_value2 = actual_value2.replace(" ", "")
# expected_value2 = expected_value2.replace(" ", "")
# print(actual_value2 == expected_value2)
# if actual_value2 == expected_value2:
# print('ok')
# commonFuc().check_text_exist_result_text('succees', 'succees')
# else:
# print('error')
# commonFuc().check_text_exist_result_text('error', 'succees')
# 第二种方式=================================
\ No newline at end of file
...@@ -444,5 +444,5 @@ json_headers2: { ...@@ -444,5 +444,5 @@ json_headers2: {
"pickType": "TH" "pickType": "TH"
} }
"expected_value": "('00004220', 'h0347', 'p1e2ba', '22f19044b8ae40f08aa5e170dcedc66e', None, '11661168', '11661168', '11661168', '一次性注射器_低值2^p7l', '一次性注射器', 'mfrs-11229', '德国歌德公司 Geuder AG', '', None, '', 'ycxzsq_dz2^p7l', None, '支', 'G-31891', Decimal('1.000000'), 2, '3', 10, None, None, '', None, Decimal('99.9999'), None, '德国', None, None, '', 1, None, 0, None, 0, '', '', None, None, 1, 0, 1, 'p1e2ba:UID-051933', datetime.datetime(2024, 6, 23, 7, 0, 59), 'p1e2ba:UID-051933', 0, 0, 1, None)" "expected_value": "('00004249', 'h0347', 'p1e2c6', '8d6273b7bca84dd8aace12b9422d7fd6', None, '11661197', '11661197', '11661197', '一次性注射器_低值qPW6a', '一次性注射器', 'mfrs-11229', '德国歌德公司 Geuder AG', '', None, '', 'ycxzsq_dzqPW6a', None, '支', 'G-31891', Decimal('1.000000'), 2, '3', 10, None, None, '', None, Decimal('99.9999'), None, '德国', None, None, '', 1, None, 0, None, 0, '', '', None, None, 1, 0, 1, 'p1e2c6:UID-051946', datetime.datetime(2024, 6, 25, 7, 1, 34), 'p1e2c6:UID-051946', 0, 0, 1, None)"
"expected_value2": '{"hos_goods_code": "00004249","hos_id": "h0347","prov_id": "p1e2c6","prov_hos_goods_id": "%s","srv_id": null,"mdm_goods_code": "11661197","mdm_goods_spec_code": "11661197","spd_goods_code": "11661197","goods_name": "一次性注射器_低值qPW6a","goods_general_name": "一次性注射器","goods_mfrs_id": "mfrs-11229","goods_mfrs_name": "德国歌德公司 Geuder AG","goods_reg_cert": "","goods_agent_mfrs_id": null,"brand": "","short_pinyin": "ycxzsq_dzqPW6a","kind_sixtyeight_code": null,"unit": "支","goods_spec": "G-31891","goods_package": Decimal("1.000000"),"bar_code_mng": 2,"unique_code_strategy": "3","pur_mode": 10,"sub_pur_mode": null,"erp_code": null,"herp_code": "","hrp": null,"price": Decimal("99.9999"),"abroad_flag": null,"made": "德国","property": null,"mgr_level": null,"goods_desc": "","charge_flag": 1,"focus_control_type": null,"temp_flag": 0,"official_status": null,"focus_control": 0,"storage_conditions": "","transport_conditions": "","into_cost_flag": null,"rfid_flag": null,"purchase_flag": 1,"tb_status": 0,"version": 1,"create_user": "p1e2c6:UID-051946","create_time": datetime.datetime(2024,6,25,7,1,34),"last_modified_user": "p1e2c6:UID-051946","sterilize_flag": 0,"multi_charge_flag": 0,"use_frequency": 1,"charge_unit": null}' "expected_value2": '{"hos_goods_code": "00004249","hos_id": "h0347","prov_id": "p1e2c6","prov_hos_goods_id": "%s","srv_id": null,"mdm_goods_code": "11661197","mdm_goods_spec_code": "11661197","spd_goods_code": "11661197","goods_name": "一次性注射器_低值qPW6a","goods_general_name": "一次性注射器","goods_mfrs_id": "mfrs-11229","goods_mfrs_name": "德国歌德公司 Geuder AG","goods_reg_cert": "","goods_agent_mfrs_id": null,"brand": "","short_pinyin": "ycxzsq_dzqPW6a","kind_sixtyeight_code": null,"unit": "支","goods_spec": "G-31891","goods_package": Decimal("1.000000"),"bar_code_mng": 2,"unique_code_strategy": "3","pur_mode": 10,"sub_pur_mode": null,"erp_code": null,"herp_code": "","hrp": null,"price": Decimal("99.9999"),"abroad_flag": null,"made": "德国","property": null,"mgr_level": null,"goods_desc": "","charge_flag": 1,"focus_control_type": null,"temp_flag": 0,"official_status": null,"focus_control": 0,"storage_conditions": "","transport_conditions": "","into_cost_flag": null,"rfid_flag": null,"purchase_flag": 1,"tb_status": 0,"version": 1,"create_user": "p1e2c6:UID-051946","create_time": datetime.datetime(2024,6,25,7,1,34),"last_modified_user": "p1e2c6:UID-051946","sterilize_flag": 0,"multi_charge_flag": 0,"use_frequency": 1,"charge_unit": null}'
...@@ -95,7 +95,7 @@ setInterval(updateTime, 1000); // 每秒更新一次时间 ...@@ -95,7 +95,7 @@ setInterval(updateTime, 1000); // 每秒更新一次时间
<tr width="600"> <tr width="600">
<td class="details-col-elapsed"><a href='../log/产品检查/log.html' target='_blank'>产品检查</a></td> <td class="details-col-elapsed"><a href='../log/产品检查/log.html' target='_blank'>产品检查</a></td>
<td class="success">成功</td> <td class="success">成功</td>
<td class="details-col-elapsed">0.352</td> <td class="details-col-elapsed">0.347</td>
<td class="details-col-elapsed">xiaohesheng</td> <td class="details-col-elapsed">xiaohesheng</td>
</tr> </tr>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment