Commit 1771ba0e authored by xiao-hesheng's avatar xiao-hesheng
Browse files

流程五脚本提交

parent 18f2d583
......@@ -895,9 +895,13 @@ try:
# # 调用审批结算单
# approval_center(OBh_ID)
# time.sleep(6)
OBh_ID='OBh0347202409190004'
check_mcms_out_balance_approve_after(1, 'OBh0347202409190004') # 结算审批后的结算数据
time.sleep(3)
invoice(3, OBh_ID) # type=2 传递结算单号,外网查询开票
time.sleep(3)
#检查最终的发票数据,过程数据在流程五中检查
commonFuc().check_text_exist_result_text('succees', 'succees')
except Exception as e:
# 打印错误信息
......
#
# from common.fileUtls import FileUtils
#
# id2,name='1234','ddd院区'
# oldinfo=(id2,name)
# info=('new1234','new_ddd院区')
# FileUtils().w_info2_new(info,'demo-ui','院区新增',oldinfo)
# str=""" DR_ID, order_no, target_corp_id, target_branch_id,
# target_dept_id, target_dept_name, target_stock_id
# , target_area_code, source_id, source_corp_id, source_branch_id,
# source_dept_id, source_dept_name, source_stock_id, source_area_code,
# accounter, account_date,
# pickOrderNo, pickBillId, psiDeptOutBillId, psiDeptOutOrderNo
# , create_user, create_time, last_modified, last_modified_user
# """
#
# str2=str.split(',')
# print(len(str2))
import sys
class Logger(object):
def __init__(self, filename):
self.terminal = sys.stdout
self.log = open(filename, "a")
def write(self, message):
self.terminal.write(message)
self.log.write(message)
def flush(self):
pass
# sys.stdout = Logger("output.txt")
# sys.stderr = Logger("error.txt")
# print("Hello, this is a test message.")
\ No newline at end of file
......@@ -6,6 +6,8 @@ import os
import traceback
from air_case.public1.public1.public1 import approval_center, approval_center_all
from common.Logger_Utils import Logger
from common.timeUtils import timeUtils
curPath = os.path.abspath(os.path.dirname(__file__)) # 获取当前文件的所在目录的绝对路径
# print('将路径中的/换成\\', curPath) # C:\Users\Administrator\Desktop\temp\dbshop99\main
......@@ -227,6 +229,10 @@ def main_text():
print('Cancel')
def flow5_flow18():
date1= timeUtils().get_time_hms(1)
sys.stdout = Logger(date1+"output.txt")
sys.stderr = Logger(date1+"error.txt")
# 脚本运行前清空所有待审批数据
approval_center_all()
approval_center_all()
......
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