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

流程一脚本提交

parent 341aca50
......@@ -68,10 +68,13 @@ def test1(type=1):
#导入同步过来的新产品,防止因同步时间差导致新建的产品没有导入过来
for i in range(1, 6):
info = FileUtils().r_info8('b5_spd3_core_business_flow', "产品审核信息", 'message%s' % i)
hosGoodsId = info['hosGoodsId']
import_goods(hosGoodsId)
break
for i in range(1, 6):
info = FileUtils().r_info8('b5_spd3_core_business_flow', "产品审核信息", 'message%s' % i)
hosGoodsId = info['hosGoodsId']
......@@ -116,12 +119,19 @@ def import_goods(hosGoodsId):
# 获取院区id
branch_id = FileUtils().r_info(module, '院区新增')["branch_id"]
# #请求体
request_body = commonFuc().get_business_data(module, "payload35", hosGoodsId, branch_id)
print(request_body)
# # # 发送请求
result = commonFuc().http_post(url, request_body, headers)
print('导入新增的产品result', result)
while True:
# #请求体
request_body = commonFuc().get_business_data(module, "payload35", hosGoodsId, branch_id)
print(request_body)
# # # 发送请求
result = commonFuc().http_post(url, request_body, headers)
print('导入新增的产品result', result)
code= commonFuc().analysis_json('code',result)
if code==1004:
continue
elif code==0:
break
def check_import_goods(hosGoodsId):
module = "b2_herp3_bs"
......
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