Commit afc88772 authored by xiao-hesheng's avatar xiao-hesheng
Browse files

优化脚本

parent ce8bfee7
......@@ -100,6 +100,11 @@ def test1():
print('resultaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa', result)
data = commonFuc().analysis_json('data', result)
id1 = commonFuc().analysis_json('id', data[0])
orderNo = commonFuc().analysis_json('orderNo', data[0])
print('orderNo',orderNo)
titlename=('orderNo1','orderNo2')
info=(orderNo,orderNo)
FileUtils().w_info8(info,'b5_spd3_core_business_flow', '采购计划单号', titlename, 'message7')
# =====================================
url = commonFuc().get_api_url() + commonFuc().get_business_data(module, "herpService_purPlan_submitPurPlan_url")
......@@ -109,12 +114,13 @@ def test1():
commonFuc().get_business_data(module, "json_contentType"), token,
commonFuc().get_business_data(module, "X-APP-CODE"))
print('headers', headers)
provId= FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_corpId"]
provName= FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_username"]
subProvId=FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_corpId"]
subProvName= FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_username"]
provId = FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_corpId"]
provName = FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_username"]
subProvId = FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_corpId"]
subProvName = FileUtils().r_info8('b5_spd3_core_business_flow', '供货关系申请2', 'message')["e_username"]
# # 请求体
request_body = commonFuc().get_business_data(module, "payload12_1_1", pid,id1,provId,provName,subProvId,subProvName,hosGoodsId,pkgDefId)
request_body = commonFuc().get_business_data(module, "payload12_1_1", pid, id1, provId, provName, subProvId,
subProvName, hosGoodsId, pkgDefId)
# 发送请求
result = commonFuc().http_post(url, request_body, headers)
print('resultbbbbbbbbbbbbbbbbbbbb', result)
......@@ -192,14 +198,13 @@ def get_GoodsPkgDef(hosGoodsId):
print('unitPackageid', unitPackageid)
info = (unitPackageid, unitPackageid)
titlename = ('unitPackageid1', 'unitPackageid2')
FileUtils().w_info8(info, 'b5_spd3_core_business_flow', '产品包装信息', titlename, 'message6')
try:
# 获取低值的hosGoodsId
hosGoodsId = FileUtils().r_info8('b5_spd3_core_business_flow', '产品审核信息', 'message2')["hosGoodsId"]
get_GoodsPkgDef(hosGoodsId) # 获取单元包id
except:
print('流程五获取hosGoodsId出现错误,请检查数据')
test1()
\ No newline at end of file
test1()
#审批
execute_command("python runner_test.py tag id2263-80 debug sit")
\ No newline at end of file
......@@ -55,9 +55,9 @@
<tr width="600">
<td class='details-col-elapsed'>1</td>
<td class='details-col-elapsed'>1</td>
<td class='details-col-elapsed'>0分6</td>
<td class="details-col-elapsed">100.0%</td>
<td class='details-col-elapsed'>0</td>
<td class='details-col-elapsed'>0分5</td>
<td class="details-col-elapsed">0.0%</td>
</tr>
</table>
......@@ -72,9 +72,9 @@
</tr>
<tr width="600">
<td class="details-col-elapsed"><a href='../log/a_a5流程五_中心库入库结算_正结算/log.html' target='_blank'>a_a5流程五_中心库入库结算_正结算</a></td>
<td class="success">成功</td>
<td class="details-col-elapsed">5.875</td>
<td class="details-col-elapsed"><a href='../log/a_a5流程五_中心库入库结算_正结算1/log.html' target='_blank'>a_a5流程五_中心库入库结算_正结算1</a></td>
<td class="fail">失败</td>
<td class="details-col-elapsed">5.482</td>
<td class="details-col-elapsed">xiaohesheng</td>
</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