Commit 974cb76f authored by xiao-hesheng's avatar xiao-hesheng
Browse files

流程九脚本编写

parent 89fe9065
...@@ -79,17 +79,17 @@ def import_goods(hosGoodsId): ...@@ -79,17 +79,17 @@ def import_goods(hosGoodsId):
print('import_goods',request_body) print('import_goods',request_body)
# # # 发送请求 # # # 发送请求
result='result' result='result'
j=1 # j=1
while True: while True:
if j==600: # if j==600:
print('600秒过去了,导入产品需要停止') # print('600秒过去了,导入产品需要停止')
break # break
result = commonFuc().http_post(url, request_body, headers) result = commonFuc().http_post(url, request_body, headers)
total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result)) total=commonFuc().analysis_json('total',commonFuc().analysis_json('data',result))
print('import_goods', total) print('import_goods', total)
if total==0: if total==0:
print('产品暂时没有同步到内网,等待6秒') print('产品暂时没有同步到内网,等待6秒')
j=j+6 # j=j+6
time.sleep(6) time.sleep(6)
# 再次调用一键导入产品 # 再次调用一键导入产品
execute_command("python runner_test.py tag id2263-48 debug sit") execute_command("python runner_test.py tag id2263-48 debug sit")
......
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