Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
test
autotest-airtest-web-spd
Commits
ff6bcebb
Commit
ff6bcebb
authored
Jul 05, 2024
by
xiao-hesheng
Browse files
脚本优化
parent
bea1aa1e
Changes
56
Expand all
Hide whitespace changes
Inline
Side-by-side
air_case/b5_spd3_core_business_flow/a_a1_流程一外网企业注册审批.air/a_a1_流程一外网企业注册审批.py
View file @
ff6bcebb
...
...
@@ -25,8 +25,11 @@ def test1():
execute_command
(
"python runner_test.py tag id2248 debug mdm3"
)
#医院注册审核
execute_command
(
"python runner_test.py tag id2249 debug mdm3"
)
try
:
test1
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'succees'
)
def
main
():
try
:
test1
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'succees'
)
# main()
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a2_流程二供货关系申请提交审批.air/a_a2_流程二供货关系申请提交审批.py
View file @
ff6bcebb
...
...
@@ -164,15 +164,18 @@ def supply_and_marketing_apply2():
e_corpId
=
corpId
e_username
=
username
return
e_corpId
,
h_corpId
,
e_username
,
h_name
try
:
h_login
()
#医院登录
e_login
(
1
)
#企业登录
#供应关系申请-客户类型医院
FileUtils
().
w_info1
(
supply_and_marketing_apply
(),
module
,
'供货关系申请'
)
submitSupplyRelation_pass
()
#供应关系申请-客户类型厂商
FileUtils
().
w_info1
(
supply_and_marketing_apply2
(),
module
,
'供货关系申请2'
)
submitSupplyRelation_pass
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
print
(
'a_a2_流程二供货关系申请提交审批,出现异常,请检查'
)
\ No newline at end of file
def
main
():
try
:
h_login
()
#医院登录
e_login
(
1
)
#企业登录
#供应关系申请-客户类型医院
FileUtils
().
w_info1
(
supply_and_marketing_apply
(),
module
,
'供货关系申请'
)
submitSupplyRelation_pass
()
#供应关系申请-客户类型厂商
FileUtils
().
w_info1
(
supply_and_marketing_apply2
(),
module
,
'供货关系申请2'
)
submitSupplyRelation_pass
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
print
(
'流程二结束'
)
except
:
print
(
'a_a2_流程二供货关系申请提交审批,出现异常,请检查'
)
# main()
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a3_流程三_产品导入和审批.air/a_a3_流程三_产品导入和审批.py
View file @
ff6bcebb
...
...
@@ -373,31 +373,34 @@ def supplyProvHosGoods_add_DI():
# print('产品数据删除出现异常')
# 删除上次新增的产品,避免产生过多的重复数据====这里不能每天删除,万一导入产品功能出现问题会影响后续脚本
# 每隔一段时间来删除重复的产品数据即可,内外网同步删除
try
:
# ==============分割线 暂时注释===============
add_goods
()
#直销高值
select1
(
'message1'
)
apply
()
add_goods1
()
#直销低值
select1
(
'message2'
)
apply
()
add_goods2
()
#直销试剂
select1
(
'message3'
)
apply
()
add_goods3
()
#集配
select1
(
'message4'
)
apply
()
add_goods4
()
#定向 "isSubprov": "1"
select1
(
'message5'
)
apply
()
#20240618外网在配送的时候增加了DI验证,加入维护di的脚本
supplyProvHosGoods_add_DI
()
# ==============分割线 暂时注释===============
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
print
(
'新增产品信息出现异常,后续的脚本必然无法走通,需要检查程序或者脚本或者环境是否出现问题'
)
commonFuc
().
check_text_exist_result_text
(
'产品新增失败'
,
'产品新增成功'
)
else
:
# 删除今天之前的产品信息(包含内外网)
delData
().
Del_goods_info_all
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
def
main
():
try
:
# ==============分割线 暂时注释===============
add_goods
()
#直销高值
select1
(
'message1'
)
apply
()
add_goods1
()
#直销低值
select1
(
'message2'
)
apply
()
add_goods2
()
#直销试剂
select1
(
'message3'
)
apply
()
add_goods3
()
#集配
select1
(
'message4'
)
apply
()
add_goods4
()
#定向 "isSubprov": "1"
select1
(
'message5'
)
apply
()
#20240618外网在配送的时候增加了DI验证,加入维护di的脚本
supplyProvHosGoods_add_DI
()
# ==============分割线 暂时注释===============
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
print
(
'新增产品信息出现异常,后续的脚本必然无法走通,需要检查程序或者脚本或者环境是否出现问题'
)
commonFuc
().
check_text_exist_result_text
(
'产品新增失败'
,
'产品新增成功'
)
else
:
# 删除今天之前的产品信息(包含内外网)
delData
().
Del_goods_info_all
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
print
(
'流程三结束'
)
# main()
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a4_流程四_基础模块设置.air/a_a4_流程四_基础模块设置.py
View file @
ff6bcebb
...
...
@@ -292,19 +292,20 @@ def add_StockArea():#添加货位
commonFuc
().
check_text_exist
(
0
,
result
)
else
:
commonFuc
().
check_text_exist
(
'error'
,
result
)
try
:
# ==============删除业务数据和报表数据
# delData().Delete_business_Data()#删除业务数据
# delData().Del_reporter_data() # 删除报表数据
#==============删除业务数据和报表数据
test1
()
test2
()
# 科室添加产品信息(产品是从外网同步过来的)
dept_query_all
()
# 科室查询,将科室id写入文件中
grants_user
()
#给用户授权
set_dept_lead1
()
#设置一级科室负责人
add_StockArea
()
#添加库区
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
Exception
as
e
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'error'
)
print
(
"发生异常:"
,
str
(
e
))
\ No newline at end of file
def
main
():
try
:
# ==============删除业务数据和报表数据
# delData().Delete_business_Data()#删除业务数据
# delData().Del_reporter_data() # 删除报表数据
#==============删除业务数据和报表数据
test1
()
test2
()
# 科室添加产品信息(产品是从外网同步过来的)
dept_query_all
()
# 科室查询,将科室id写入文件中
grants_user
()
#给用户授权
set_dept_lead1
()
#设置一级科室负责人
add_StockArea
()
#添加库区
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
print
(
'流程四结束'
)
except
Exception
as
e
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'error'
)
print
(
"发生异常:"
,
str
(
e
))
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a5流程五_中心库入库结算_正结算1_提交采购计划.air/a_a5流程五_中心库入库结算_正结算1_提交采购计划.py
View file @
ff6bcebb
...
...
@@ -454,47 +454,45 @@ def reagent_purchase_plan():
commonFuc
().
check_text_exist
(
0
,
result
)
else
:
commonFuc
().
check_text_exist
(
'error'
,
result
)
def
main
(
type
=
1
):
if
type
==
1
:
try
:
# 获取低值的hosGoodsId
hosGoodsId
=
FileUtils
().
r_info8
(
'b5_spd3_core_business_flow'
,
'产品审核信息'
,
'message2'
)[
"hosGoodsId"
]
get_GoodsPkgDef
(
hosGoodsId
)
# 获取单元包id
except
:
print
(
'流程五获取hosGoodsId出现错误,请检查脚本或者数据'
)
try
:
low_vaule_purchase_plan
()
except
Exception
as
e
:
print
(
'低值采购计划提交出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
#审批
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
hight_vaule_purchase_plan
()
except
Exception
as
e
:
print
(
'高值采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
reagent_purchase_plan
()
except
Exception
as
e
:
print
(
'试剂采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
else
:
print
(
'type=2时不执行任何内容'
)
main
()
\ No newline at end of file
def
main
():
try
:
# 获取低值的hosGoodsId
hosGoodsId
=
FileUtils
().
r_info8
(
'b5_spd3_core_business_flow'
,
'产品审核信息'
,
'message2'
)[
"hosGoodsId"
]
get_GoodsPkgDef
(
hosGoodsId
)
# 获取单元包id
except
:
print
(
'流程五获取hosGoodsId出现错误,请检查脚本或者数据'
)
try
:
low_vaule_purchase_plan
()
except
Exception
as
e
:
print
(
'低值采购计划提交出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
#审批
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
hight_vaule_purchase_plan
()
except
Exception
as
e
:
print
(
'高值采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
reagent_purchase_plan
()
except
Exception
as
e
:
print
(
'试剂采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
try
:
approval_center
()
except
Exception
as
e
:
print
(
'审批采购计划出现错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
# main()
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a6流程五_中心库入库结算_正结算2_外网配送.air/a_a6流程五_中心库入库结算_正结算2_外网配送.py
View file @
ff6bcebb
...
...
@@ -258,14 +258,14 @@ def order_dp(type=1):
commonFuc
().
check_text_exist
(
'error'
,
result
)
# ==================订单配送=====================================
try
:
order_dp
(
1
)
# 1低值
order_dp
(
2
)
#2高值
order_dp
(
3
)
#3试剂
except
Exception
as
e
:
print
(
'订单配送发生错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
else
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
\ No newline at end of file
def
main
():
try
:
order_dp
(
1
)
# 1低值
order_dp
(
2
)
#2高值
order_dp
(
3
)
#3试剂
except
Exception
as
e
:
print
(
'订单配送发生错误,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
else
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_a7流程五_中心库入库结算_正结算3_内网验收入库结算.air/a_a7流程五_中心库入库结算_正结算3_内网验收入库结算.py
View file @
ff6bcebb
...
...
@@ -404,21 +404,22 @@ def putaway():
# # ================== 生成结算单==============================
try
:
# 验收
check_accept_order
(
1
)
# 低值
check_accept_order
(
2
)
# 高值
check_accept_order
(
3
)
# 试剂
# 入库上架
putaway
()
putaway
()
putaway
()
OBD_ID
=
settle
()
# 生成结算单
# 调用审批结算单
approval_center
(
OBD_ID
)
except
Exception
as
e
:
print
(
'脚本出现异常,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
else
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
def
main
():
try
:
# 验收
check_accept_order
(
1
)
# 低值
check_accept_order
(
2
)
# 高值
check_accept_order
(
3
)
# 试剂
# 入库上架
putaway
()
putaway
()
putaway
()
OBD_ID
=
settle
()
# 生成结算单
# 调用审批结算单
approval_center
(
OBD_ID
)
except
Exception
as
e
:
print
(
'脚本出现异常,请检查脚本或者数据'
)
print
(
"发生异常:"
,
str
(
e
))
traceback
.
print_exc
()
else
:
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
air_case/b5_spd3_core_business_flow/a_a8流程五_中心库入库结算_正结算3_外网开票.air/a_a8流程五_中心库入库结算_正结算3_外网开票.py
View file @
ff6bcebb
This diff is collapsed.
Click to expand it.
air_case/b5_spd3_core_business_flow/a_a9流程六_中心库入库结算_负结算.air/a_a9流程六_中心库入库结算_负结算.py
View file @
ff6bcebb
...
...
@@ -218,23 +218,23 @@ def center_warehouse_return():
print
(
'herpService_stock_review_pass_submit_urlresult'
,
result
)
# ========出库复核提交
try
:
# test1() # 提交采购计划 # 外网配送 # 内网验收入库结算
# 先查询所有的部门信息写入文件
dept_query_all
()
# 设置库房人员,根据传入的科室id和科室名称来设置库房
# 中心库type=1 二级type=2三级type=3
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
#设置登录账号默认权限是中心库
center_warehouse_return
()
#中心库退货
# center_warehouse_return()#中心库退货
OBh_ID
=
settle
()
# 生成结算单
# print(OBh_ID)
# 调用审批结算单
approval_center
(
OBh_ID
)
invoice
(
2
,
OBh_ID
)
#type=2 传递结算单号,外网查询开票
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
# test1() # 提交采购计划 # 外网配送 # 内网验收入库结算
# 先查询所有的部门信息写入文件
dept_query_all
()
# 设置库房人员,根据传入的科室id和科室名称来设置库房
# 中心库type=1 二级type=2三级type=3
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
#设置登录账号默认权限是中心库
center_warehouse_return
()
#中心库退货
# center_warehouse_return()#中心库退货
OBh_ID
=
settle
()
# 生成结算单
# print(OBh_ID)
# 调用审批结算单
approval_center
(
OBh_ID
)
invoice
(
2
,
OBh_ID
)
#type=2 传递结算单号,外网查询开票
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b0流程七_中心库入库结算_正负结算.air/a_b0流程七_中心库入库结算_正负结算.py
View file @
ff6bcebb
...
...
@@ -218,21 +218,21 @@ def center_warehouse_return():
print
(
'herpService_stock_review_pass_submit_urlresult'
,
result
)
# ========出库复核提交
try
:
# test1() # 提交采购计划 # 外网配送 # 内网验收入库结算
# 先查询所有的部门信息写入文件
dept_query_all
()
# 设置库房人员,根据传入的科室id和科室名称来设置库房
# 中心库type=1 二级type=2三级type=3
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
center_warehouse_return
()
#中心库退货
OBh_ID
=
settle
()
# 生成结算单
# print(OBh_ID)
# 调用审批结算单
approval_center
(
OBh_ID
)
invoice
(
3
,
OBh_ID
)
#type=2 传递结算单号,外网查询开票
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'
1
'
)
def
main
():
try
:
# test1() # 提交采购计划 # 外网配送 # 内网验收入库结算
# 先查询所有的部门信息写入文件
dept_query_all
()
# 设置库房人员,根据传入的科室id和科室名称来设置库房
# 中心库type=1 二级type=2三级type=3
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
center_warehouse_return
()
#中心库退货
OBh_ID
=
settle
()
# 生成结算单
# print(OBh_ID)
# 调用审批结算单
approval_center
(
OBh_ID
)
invoice
(
3
,
OBh_ID
)
#type=2 传递结算单号,外网查询开票
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'
succees
'
)
air_case/b5_spd3_core_business_flow/a_b1流程八_高值跟台业务流程.air/a_b1流程八_高值跟台业务流程.py
View file @
ff6bcebb
...
...
@@ -322,25 +322,26 @@ def out_return_gt():
# 跟台退货出库确认========================
try
:
set_dept_lead
()
# 设置二级科室负责人
# # # # 设置默认科室,切换到二级科室,使用科室管理功能
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
herpService_mcmsDeptGoodsInfo_getByProvIdPage
()
operationApply
()
# 手术跟台申请单提交
approval_center
()
# 审批手术跟台申请单
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
approval_center1
()
# 再次审批手术跟台申请单
# # #内网查询手术通知单号
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
orderno
=
Search_OrderNO
()
# 手术通知单接口查询单号
print
(
orderno
)
height_value_order_dp
(
orderno
)
# 高值跟台外网配送
check_accept_order
()
# 内网验收
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
second_dept_in_warehouse
()
# 二级科室入库
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
out_return_gt
()
# 跟台退货出库_中心库处理
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
set_dept_lead
()
# 设置二级科室负责人
# # # # 设置默认科室,切换到二级科室,使用科室管理功能
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
herpService_mcmsDeptGoodsInfo_getByProvIdPage
()
operationApply
()
# 手术跟台申请单提交
approval_center
()
# 审批手术跟台申请单
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
approval_center1
()
# 再次审批手术跟台申请单
# # #内网查询手术通知单号
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
orderno
=
Search_OrderNO
()
# 手术通知单接口查询单号
print
(
orderno
)
height_value_order_dp
(
orderno
)
# 高值跟台外网配送
check_accept_order
()
# 内网验收
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
second_dept_in_warehouse
()
# 二级科室入库
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
# 设置登录账号默认权限是中心库
out_return_gt
()
# 跟台退货出库_中心库处理
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b2流程九请领业务流_二级库向中心库.air/a_b2流程九请领业务流_二级库向中心库.py
View file @
ff6bcebb
...
...
@@ -390,43 +390,44 @@ def pick_execute(GoodsId,type=1):
result
=
commonFuc
().
http_post
(
url
,
request_body
,
headers
)
print
(
'herpService_stock_review_pass_submit_urlresult'
,
result
)
#复核===================================
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
# 二级库区信息写入文件
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
# get_stockAreaId_new(FileUtils().r_info8("b2_herp3_bs", "所有科室id", 'message6')['deptid3'],FileUtils().r_info8("b2_herp3_bs", "所有科室name", 'message6')['deptid3'],3)
# 设置库区联系人
set_stockShelf_Linkman
()
# 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
def
main
():
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
# 二级库区信息写入文件
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid2'
],
2
)
# get_stockAreaId_new(FileUtils().r_info8("b2_herp3_bs", "所有科室id", 'message6')['deptid3'],FileUtils().r_info8("b2_herp3_bs", "所有科室name", 'message6')['deptid3'],3)
# 设置库区联系人
set_stockShelf_Linkman
()
# 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
#设置登录账号默认权限是中心库
#获取拣货单列表个数
for
i
in
range
(
get_centeStock_pick_list_counts
()):
centeStock_pick
()
#中心库拣货
#低值拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
1
)
# 高值拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
2
)
# 试剂拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
3
)
second_dept_one_key_in
()
second_dept_one_key_in
()
second_dept_one_key_in
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
1
))
#设置登录账号默认权限是中心库
#获取拣货单列表个数
for
i
in
range
(
get_centeStock_pick_list_counts
()):
centeStock_pick
()
#中心库拣货
#低值拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
1
)
# 高值拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
2
)
# 试剂拣货执行
hosGoodsId
=
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
]
GoodsId
=
hosGoodsId
.
replace
(
get_hosid
(),
''
)
pick_execute
(
GoodsId
,
3
)
second_dept_one_key_in
()
second_dept_one_key_in
()
second_dept_one_key_in
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b3流程十请领业务流_二级库向边仓.air/a_b3流程十请领业务流_二级库向边仓.py
View file @
ff6bcebb
...
...
@@ -308,31 +308,29 @@ def check_buyWayText():
def
main
1
(
type
=
1
):
def
main
(
):
try
:
if
type
==
1
:
set_dept_lead
()
# 设置二级科室负责人
# 科室必须同步到外网,集中管控平台创建边仓才能选择到用户,"deptType":"0"
add_logic_stock
()
# 设置产品出库渠道为边仓
goods_move
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
check_buyWayText
()
#验证出库渠道是否为边仓
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
else
:
print
(
'aa'
)
set_dept_lead
()
# 设置二级科室负责人
# 科室必须同步到外网,集中管控平台创建边仓才能选择到用户,"deptType":"0"
add_logic_stock
()
# 设置产品出库渠道为边仓
goods_move
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
check_buyWayText
()
#验证出库渠道是否为边仓
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'succees'
)
main1
()
\ No newline at end of file
air_case/b5_spd3_core_business_flow/a_b4流程十一请领业务流_二级库向直送.air/a_b4流程十一请领业务流_二级库向直送.py
View file @
ff6bcebb
...
...
@@ -807,41 +807,41 @@ def check_accept_order(type=1):
titlename
=
(
'CHECK_NO1'
,
'CHECK_NO2'
)
FileUtils
().
w_info8
(
info
,
'b5_spd3_core_business_flow'
,
'验收单号'
,
titlename
,
'message15'
)
try
:
# add_dept2() # 新增一个二级科室
# add_new_deptinfo() # 写入科室信息到文件中
# grants_user_new() #新增授权
# 设置部门用户
# set_dept_user(FileUtils().r_info8("b2_herp3_bs", "所有科室id", 'message6')['deptid5'],FileUtils().r_info8("b2_herp3_bs", "所有科室name", 'message6')['deptid5'],2)
# 设置部门负责人
# set_dept_lead_new(FileUtils().r_info8('b2_herp3_bs', '所有科室id', 'message6')["deptid5"]) # 设置二级科室负责人
# 从下面开始,上面的暂时注释
goods_move2
()
# 设置产品出库渠道为直送
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
for
i
in
range
(
6
):
# # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
# 采购模块处理
purchase_module_process
()
for
i
in
range
(
3
):
# 三个单据共审批3次
approval_center
()
order_dp
(
1
)
# 1低值
order_dp
(
2
)
# 2高值
order_dp
(
3
)
# 3试剂
check_accept_order
(
1
)
# 低值
check_accept_order
(
2
)
# 高值
check_accept_order
(
3
)
# 试剂
second_dept_one_key_in
()
second_dept_one_key_in
()
second_dept_one_key_in
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
# add_dept2() # 新增一个二级科室
# add_new_deptinfo() # 写入科室信息到文件中
# grants_user_new() #新增授权
# 设置部门用户
# set_dept_user(FileUtils().r_info8("b2_herp3_bs", "所有科室id", 'message6')['deptid5'],FileUtils().r_info8("b2_herp3_bs", "所有科室name", 'message6')['deptid5'],2)
# 设置部门负责人
# set_dept_lead_new(FileUtils().r_info8('b2_herp3_bs', '所有科室id', 'message6')["deptid5"]) # 设置二级科室负责人
# 从下面开始,上面的暂时注释
goods_move2
()
# 设置产品出库渠道为直送
updateUserLoginDefaultRange
(
get_listUserMgrRangePage
(
2
))
# 设置登录账号默认权限是二级库
for
i
in
range
(
6
):
# # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
# 采购模块处理
purchase_module_process
()
for
i
in
range
(
3
):
# 三个单据共审批3次
approval_center
()
order_dp
(
1
)
# 1低值
order_dp
(
2
)
# 2高值
order_dp
(
3
)
# 3试剂
check_accept_order
(
1
)
# 低值
check_accept_order
(
2
)
# 高值
check_accept_order
(
3
)
# 试剂
second_dept_one_key_in
()
second_dept_one_key_in
()
second_dept_one_key_in
()
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b5流程十二请领业务流_二级库向二级库.air/a_b5流程十二请领业务流_二级库向二级库.py
View file @
ff6bcebb
...
...
@@ -402,45 +402,45 @@ def pick_execute():
# 复核===================================
try
:
add_dept2
()
# 新增一个二级科室
add_new_deptinfo
()
# 写入科室信息到文件中
grants_user_new
()
# 新增授权
# 同步库房信息
execute_command
(
"python runner_test.py tag id2263-221 debug sit"
)
# 设置部门用户
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid5'
],
2
)
# 设置部门负责人
set_dept_lead_new
(
FileUtils
().
r_info8
(
'b2_herp3_bs'
,
'所有科室id'
,
'message6'
)[
"deptid5"
])
# 设置二级科室负责人
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid5'
],
2
)
set_stockShelf_Linkman
()
#设置库区联系人
#新建科室产品分配
dept_goods_distribute
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
])
#编辑产品请领目标为二级检验科002
currentDeptId
=
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
]
targetDeptId
=
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
]
edit_goods_target
(
currentDeptId
,
targetDeptId
)
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
5
))
# 设置登录账号默认权限是新二级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
# 设置登录账号默认权限是二级库
# 二级科室领用出库
# 低值拣货执行
pick_execute
()
second_dept_one_key_in
(
5
)
second_dept_one_key_in
(
5
)
second_dept_one_key_in
(
5
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
add_dept2
()
# 新增一个二级科室
add_new_deptinfo
()
# 写入科室信息到文件中
grants_user_new
()
# 新增授权
# 同步库房信息
execute_command
(
"python runner_test.py tag id2263-221 debug sit"
)
# 设置部门用户
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid5'
],
2
)
# 设置部门负责人
set_dept_lead_new
(
FileUtils
().
r_info8
(
'b2_herp3_bs'
,
'所有科室id'
,
'message6'
)[
"deptid5"
])
# 设置二级科室负责人
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid5'
],
2
)
set_stockShelf_Linkman
()
#设置库区联系人
#新建科室产品分配
dept_goods_distribute
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
])
#编辑产品请领目标为二级检验科002
currentDeptId
=
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid5'
]
targetDeptId
=
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid2'
]
edit_goods_target
(
currentDeptId
,
targetDeptId
)
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
5
))
# 设置登录账号默认权限是新二级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
# 设置登录账号默认权限是二级库
# 二级科室领用出库
# 低值拣货执行
pick_execute
()
second_dept_one_key_in
(
5
)
second_dept_one_key_in
(
5
)
second_dept_one_key_in
(
5
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b6流程十三请领业务流_三级库向二级库.air/a_b6流程十三请领业务流_三级库向二级库.py
View file @
ff6bcebb
...
...
@@ -326,37 +326,37 @@ def pick_execute():
result
=
commonFuc
().
http_post
(
url
,
request_body
,
headers
)
print
(
'提交拣货执行单,result1'
,
result
)
def
main
():
try
:
# 设置部门用户
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
# 设置部门负责人
set_dept_lead_new
(
FileUtils
().
r_info8
(
'b2_herp3_bs'
,
'所有科室id'
,
'message6'
)[
"deptid3"
])
# 设置二级科室负责人
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
set_stockShelf_Linkman
()
# 设置库区联系人
#三级科室产品分配
dept_goods_distribute
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
])
try
:
# 设置部门用户
set_dept_user
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
# 设置部门负责人
set_dept_lead_new
(
FileUtils
().
r_info8
(
'b2_herp3_bs'
,
'所有科室id'
,
'message6'
)[
"deptid3"
])
# 设置二级科室负责人
get_stockAreaId_new
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
],
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室name"
,
'message6'
)[
'deptid3'
],
3
)
set_stockShelf_Linkman
()
# 设置库区联系人
#三级科室产品分配
dept_goods_distribute
(
FileUtils
().
r_info8
(
"b2_herp3_bs"
,
"所有科室id"
,
'message6'
)[
'deptid3'
])
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
# 设置登录账号默认权限是三级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
#二级科室领用出库
# 低值拣货执行
pick_execute
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
#设置登录账号默认权限是三级库
second_dept_one_key_in
(
3
)
second_dept_one_key_in
(
3
)
second_dept_one_key_in
(
3
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error '
,
'1'
)
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
# 设置登录账号默认权限是三级库
# # # 低值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message2'
)[
'hosGoodsId'
],
1
)
# # # 高值
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message1'
)[
'hosGoodsId'
],
2
)
# # # 试剂
second_dept_Request
(
FileUtils
().
r_info8
(
"b5_spd3_core_business_flow"
,
"产品审核信息"
,
'message3'
)[
'hosGoodsId'
],
3
)
BuyCarSubmit
()
# 请领车提交
for
i
in
range
(
6
):
# 三个单据共审批6次
approval_center
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
#二级科室领用出库
# 低值拣货执行
pick_execute
()
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
#设置登录账号默认权限是三级库
second_dept_one_key_in
(
3
)
second_dept_one_key_in
(
3
)
second_dept_one_key_in
(
3
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error '
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b7流程十四退库业务_消耗退库.air/a_b7流程十四退库业务_消耗退库.py
View file @
ff6bcebb
...
...
@@ -576,17 +576,17 @@ def second_dept_consume_in_Stock(type=1):
else
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'succees'
)
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
# 设置登录账号默认权限是二级库
sCan_grant
(
1
)
# 低值扫码发放
sCan_grant
(
3
)
# 试剂扫码发放
second_dept_consume_Out_Stock
(
2
)
# 高值消耗出库
second_dept_consume_in_Stock
(
2
)
# 高值消耗退货入库
second_dept_consume_Out_Stock
(
1
)
# 低值消耗出库
second_dept_consume_in_Stock
(
1
)
# 低值消耗退回入库
second_dept_consume_Out_Stock
(
3
)
# 试剂消耗出库
second_dept_consume_in_Stock
(
3
)
# 试剂消耗退回入库
commonFuc
().
check_text_exist_result_text
(
'SUCCESS'
,
'SUCCESS'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'SUCCESS'
)
def
main
():
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
# 设置登录账号默认权限是二级库
sCan_grant
(
1
)
# 低值扫码发放
sCan_grant
(
3
)
# 试剂扫码发放
second_dept_consume_Out_Stock
(
2
)
# 高值消耗出库
second_dept_consume_in_Stock
(
2
)
# 高值消耗退货入库
second_dept_consume_Out_Stock
(
1
)
# 低值消耗出库
second_dept_consume_in_Stock
(
1
)
# 低值消耗退回入库
second_dept_consume_Out_Stock
(
3
)
# 试剂消耗出库
second_dept_consume_in_Stock
(
3
)
# 试剂消耗退回入库
commonFuc
().
check_text_exist_result_text
(
'SUCCESS'
,
'SUCCESS'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'SUCCESS'
)
air_case/b5_spd3_core_business_flow/a_b8流程十五退库业务_三级库向二级库退库.air/a_b8流程十五退库业务_三级库向二级库退库.py
View file @
ff6bcebb
...
...
@@ -422,15 +422,15 @@ def second_dept_return_Out_Stock(type): # 三级库退库出库
result
=
commonFuc
().
http_post
(
url
,
request_body
,
headers
)
print
(
'试剂产品退库出库,result'
,
result
)
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
# 设置登录账号默认权限是三级库
second_dept_return_Out_Stock
(
2
)
# 高值耗材退货出库
second_dept_return_Out_Stock
(
1
)
# 低值耗材退货出库
second_dept_return_Out_Stock
(
3
)
# 试剂耗材退货出库
second_dept_one_key_in
(
2
)
second_dept_one_key_in
(
2
)
second_dept_one_key_in
(
2
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
3
))
# 设置登录账号默认权限是三级库
second_dept_return_Out_Stock
(
2
)
# 高值耗材退货出库
second_dept_return_Out_Stock
(
1
)
# 低值耗材退货出库
second_dept_return_Out_Stock
(
3
)
# 试剂耗材退货出库
second_dept_one_key_in
(
2
)
second_dept_one_key_in
(
2
)
second_dept_one_key_in
(
2
)
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_b9流程十六退库业务_二级库向一级库退库.air/a_b9流程十六退库业务_二级库向一级库退库.py
View file @
ff6bcebb
...
...
@@ -553,21 +553,21 @@ def second_dept_return_Out_Stock(type): # 二级库退库出库
result
=
commonFuc
().
http_post
(
url
,
request_body
,
headers
)
print
(
'试剂产品退库出库,result'
,
result
)
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
2
)
#高值耗材退货出库
approval_center
()
#审批
putaway
()
#中心库上架
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
1
)
#低值耗材退货出库
approval_center
()
# 审批
putaway
()
# 中心库上架
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
3
)
#试剂耗材退货出库
approval_center
()
#审批
putaway
()
#中心库上架
# ===============上面调通了================================
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
2
)
#高值耗材退货出库
approval_center
()
#审批
putaway
()
#中心库上架
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
1
)
#低值耗材退货出库
approval_center
()
# 审批
putaway
()
# 中心库上架
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
2
))
#设置登录账号默认权限是二级库
second_dept_return_Out_Stock
(
3
)
#试剂耗材退货出库
approval_center
()
#审批
putaway
()
#中心库上架
# ===============上面调通了================================
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
air_case/b5_spd3_core_business_flow/a_c0流程十七退货业务_中心库退供应商.air/a_c0流程十七退货业务_中心库退供应商.py
View file @
ff6bcebb
...
...
@@ -626,12 +626,12 @@ def second_center_Stock_return_Out(type): # 中心库退供应商
result
=
commonFuc
().
http_post
(
url
,
request_body
,
headers
)
print
(
'herpService_stock_review_pass_submit_urlresult'
,
result
)
# ========出库复核提交
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
1
))
# 设置登录账号默认权限是二级库
second_center_Stock_return_Out
(
2
)
#高值耗材退货出库
second_center_Stock_return_Out
(
1
)
#低值耗材退货出库
second_center_Stock_return_Out
(
3
)
#试剂耗材退货出库
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
def
main
():
try
:
updateUserLoginDefaultRange
(
get_listUserMgrRangePage1
(
1
))
# 设置登录账号默认权限是二级库
second_center_Stock_return_Out
(
2
)
#高值耗材退货出库
second_center_Stock_return_Out
(
1
)
#低值耗材退货出库
second_center_Stock_return_Out
(
3
)
#试剂耗材退货出库
commonFuc
().
check_text_exist_result_text
(
'succees'
,
'succees'
)
except
:
commonFuc
().
check_text_exist_result_text
(
'error'
,
'1'
)
Prev
1
2
3
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment