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

流程十二脚本编写

parent 5869cb84
......@@ -77,27 +77,19 @@ def putaway():
list_a = info['list_a']
print('list_a', list_a)
sourceId = 'sourceId'
sourceType='sourceType'
for i in list_a:
for j in i:
sourceId = j['sourceId']
break
# 从message13文件中获取信息
info = FileUtils().r_info8('b5_spd3_core_business_flow', "验收单信息", 'message13')
# print('info', info)
list_a = info['list_a']
print('list_a', list_a)
sourceType = "sourceType"
for i in list_a:
print('i', i)
for j in i:
sourceType = j["sourceType"]
break
request_body = commonFuc().get_business_data(module, "payload4", deptid1, areaCode, hosId, sourceId, sourceType)
request_body = commonFuc().get_business_data(module, "payload4_1", deptid1, areaCode, hosId, sourceId, sourceType)
print('request_body', 'd', request_body)
result = commonFuc().http_post(url, request_body, headers)
print('result', result)
targetDeptId =commonFuc().analysis_json('targetDeptId',commonFuc().analysis_json('data',result))
# 将验收单详情写入文件
data = commonFuc().analysis_json('data', result)
list_a = []
......@@ -119,12 +111,11 @@ def putaway():
viewId = 'viewId'
shelfCode = 'shelfCode'
sourceId = 'sourceId'
sourceType = 'PSD'
sourceVersion = '0'
sourceVersion = '1'
targetDeptId = deptid1
targetDeptName = 'targetDeptName'
targetAreaCode = 'targetAreaCode'
targetAreaName = 'targetAreaName'
targetDeptName = FileUtils().r_info8('b2_herp3_bs', '所有科室name', 'message6')["deptid1"]
targetAreaCode = FileUtils().r_info8('b2_herp3_bs', 'shelfinfo', 'message7')["shelfCode"]
targetAreaName = FileUtils().r_info8('b2_herp3_bs', 'shelfinfo', 'message7')["areaName"]
# 从message17文件中获取信息
info = FileUtils().r_info8('b5_spd3_core_business_flow', "验收单库存详情信息", 'message17')
# print('info', info)
......@@ -135,18 +126,18 @@ def putaway():
for j in i:
viewId = j["viewId"]
shelfCode = j['shelfCode']
sourceId = j['id']
break
# 从message16文件中获取信息
info = FileUtils().r_info8('b5_spd3_core_business_flow', "上架入库列表数据", 'message16')
list_a = info['list_a']
print('list_a', list_a)
for i in list_a:
for j in i:
sourceId = j['sourceId']
targetAreaName = j['areaName']
targetAreaCode = j['areaCode']
sourceId = j['pid']
break
# # 从message16文件中获取信息
# info = FileUtils().r_info8('b5_spd3_core_business_flow', "上架入库列表数据", 'message16')
# list_a = info['list_a']
# print('list_a', list_a)
# for i in list_a:
# for j in i:
# sourceId = j['sourceId']
# targetAreaName = j['areaName']
# targetAreaCode = j['areaCode']
# break
request_body = commonFuc().get_business_data(module, "payload5", viewId, shelfCode, sourceId, sourceType,
sourceVersion, targetDeptId,
targetDeptName, targetAreaCode, targetAreaName)
......@@ -562,9 +553,9 @@ def second_dept_return_Out_Stock(type): # 二级库退库出库
try:
# updateUserLoginDefaultRange(get_listUserMgrRangePage1(2)) # 设置登录账号默认权限是二级库
# second_dept_return_Out_Stock(2) #高值耗材退货出库
# approval_center()#审批
updateUserLoginDefaultRange(get_listUserMgrRangePage1(2)) # 设置登录账号默认权限是二级库
second_dept_return_Out_Stock(2) #高值耗材退货出库
approval_center()#审批
putaway()#中心库上架
# second_dept_return_Out_Stock(1) #低值耗材退货出库
# second_dept_return_Out_Stock(3) #低值耗材退货出库
......
......@@ -90,7 +90,10 @@ json_headers2: {
"payload3": {"billMode":"%s","branchId":"%s","checkAll":1,"deptId":"%s","deptName":"%s","hosId":"%s","provId":"%s","provName":"%s","recOrgId":"%s","recOrgName":"%s","resendStatus":null,"rejectReason":null,"rejectRemark":null,"sourceId":"%s","sourceVersion":"%s","sourceType":"%s","tbStatus":"%s","createUser":"%s","sourceNo":"%s","sterilizeList":[],"remark":"","rejectFlag":0,"detailList":[{"id":"%s","hosGoodsId":"%s","viewId":"%s","settlement":"%s","checkQty":"%s","distrPkgQty":"%s","checkPkgQty":"%s","recTemperature":"%s","recHumidity":"%s"}]}
"payload3_1_bak": {"billMode":"%s","branchId":"%s","checkAll":1,"deptId":"%s","deptName":"%s","hosId":"%s","provId":"%s","provName":"%s","recOrgId":"%s","recOrgName":"%s","resendStatus":null,"rejectReason":null,"sourceId":"%s","sourceVersion":"%s","sourceType":"%s","tbStatus":"%s","createUser":"%s","sourceNo":"%s","sterilizeList":[],"remark":"","rejectFlag":0,"detailList":[{"id":"%s","viewId":"%s","settlement":"%s","checkQty":100,"recTemperature":"%s","recHumidity":"%s"}]}
"payload4": {"targetDeptId":"%s","targetAreaCode":"%s","hosId":"%s","sourceId":"%s","sourceType":"%s","pkgTaskId":null}
"payload4_1": {"targetDeptId":"%s","targetAreaCode":"%s","hosId":"%s","sourceId":"%s","sourceType":"%s","pkgTaskId":null}
"payload5": {"batchList":[{"viewId":"%s","shelfCode":"%s"}],"sourceId":"%s","sourceType":"%s","sourceVersion":"%s","targetDeptId":"%s","targetDeptName":"%s","targetAreaCode":"%s","targetAreaName":"%s","pkgTaskId":null}
"payload6": {"pageNum":1,"pageSize":50,"orderBy":"","queryObject":{"branchId":"%s","taskType":0,"stockKind":"","sourceOrgName":"","hosId":"%s"}}
"payload7": {"pageNum":1,"pageSize":50,"queryObject":{"goodsInfo":"","provId":"%s",barCodeInfo":"","fromOrderNo":"","purModeList":["10"],"accountDate1":"%s","accountDate2":"%s","tbStatus":0,"hosId":"%s"},"hosId":"%s"}
......
......@@ -11,7 +11,7 @@
recType:
stockKind:
purMode:
sourceId: DRh034720240613000121
sourceId: DRh034720240613000122
sourceType: CK_TK
sourceVersion: 1
batchList:
......@@ -24,15 +24,15 @@
taskType: 2
sourceOrgId: 7020cc82c12a46e0a8ca998a00bf6760
sourceOrgName: 二级检验科002
sourceOrderNo: DN20240613000121
taskSourceNo: DN20240613000121
sourceOrderNo: DN20240613000122
taskSourceNo: DN20240613000122
areaCode:
areaName:
goodsName:
goodsGg:
startDate:
endDate:
taskDate: '2024-06-13 15:16:38'
taskDate: '2024-06-13 15:37:11'
pkgTaskId:
pkgFlag:
remark: ''
......
验收单库存详情信息:
list_a:
- &id001 []
- &id001
- id: DRh0347202406130001220001
lastModified:
version:
createTime:
createUser:
lastModifiedUser:
rowIdx:
purMode: 20
unitName: 1支
pid: DRh034720240613000122
hosGoodsId: h034700004089
batchCode: '222'
expdtDate: '2024-12-20'
productDate: '2024-06-13'
batchPrice: 99.9999
settlement: 1
batchType: 40
srcBatchId: Ph034724061300011
srcBatchPrice: 99.9999
shelfCode: areah03472305-2-01-01
shelfKind:
barcodeId: '8800000001066031'
subBarcodeId:
qty: 1.0
pkgQty: 1
distrId: PSh0347202406130019
distrDetailId: '03838424'
pkgDefQty:
pkgDefName:
viewId: h0347000040892222024-12-201支
codingType:
batchFlag:
hasSterilize: 0
sterilizeQty:
sterilizePassQty:
sterilizeRejectQty:
orderNo:
sourceDetailId: PICKh03472406130083200001
mdmGoodsCode: '11661037'
goodsCode: '00004089'
tbStatus:
billMode:
hosId:
branchId:
purBillId: Ch034720240613000079
provId: p1e292
provName:
subProvId: p1e292
purDetailId:
goodsName: 高值牙钻机fJVl@
goodsGg: G-31891
mfrsId: mfrs-11229
mfrsName: 德国歌德公司 Geuder AG
made: 德国
unit:
sourceBatchId: Ph034724061300011
targetBatchId: Ph034724061300011
pkgDefId:
certificateCode: ''
productCertCode:
extInfo:
psiPrice: 99.9999
ext:
goodsGg: G-31891
goodsCode: '00004089'
purMode: 20
goodsName: 高值牙钻机fJVl@
ygptCode: ''
transCond: ''
storageCond: ''
erpCode: '11661037'
ybDefId: ''
contractId: ''
normalContractId: ''
fcatId: ''
fcatName: ''
goodsKindId: ''
goodsKindName: ''
miTwentysevenCode: ''
focus_control: '0'
focus_control_type:
rtnQty:
hisChargeNo:
trustMrfsName:
pkgCodeSee:
chargeFlag:
stockKind: CK_TK
sourceDeptId: 7020cc82c12a46e0a8ca998a00bf6760
targetDeptId: e65c6628c20e4c9cb6f4beacd41cd390
ableDelFlag:
pickType: KS_TK
list_b:
- *id001
list_c:
......
条码信息:
list_a:
- &id001
id: '8800000001066030'
snCode: '8800000001066030'
ssccCode: '010839000184145927'
pkgCodeSee: '0100000000004089102221124061317241220218800000001066030'
id: '8800000001066031'
snCode: '8800000001066031'
ssccCode: '010839000184146221'
pkgCodeSee: '0100000000004089102221124061317241220218800000001066031'
hosGoodsId: h034700004089
hosGoodsCode: '00004089'
goodsCode: '00004089'
......@@ -27,8 +27,8 @@
shelfCode: areah03472303-A-01-01
shelfNo: A01-A-01-01
pkgDefId:
extInfo: '{"pkgDefQty": 1, "purBillId": "CG2024061318649", "distrBillId": "PSh0347202406130016",
"inStockTime": "2024-06-13 15:14:49", "useFrequency": 1, "distrDetailId": "03838421",
extInfo: '{"pkgDefQty": 1, "purBillId": "CG2024061318652", "distrBillId": "PSh0347202406130019",
"inStockTime": "2024-06-13 15:02:53", "useFrequency": 1, "distrDetailId": "03838424",
"certificateCode": "", "multiChargeFlag": 0}'
bottleId:
pkgType: '20'
......@@ -40,7 +40,7 @@
shelfKindName: 普通货位
provName: 国药集团公司K19@c
provId: p1e292
inStockDate: '2024-06-13 15:14:49'
inStockDate: '2024-06-13 15:02:53'
mfrCode:
made: 德国
price:
......
......@@ -95,7 +95,7 @@ setInterval(updateTime, 1000); // 每秒更新一次时间
<tr width="600">
<td class="details-col-elapsed"><a href='../log/a_b9流程十六退库业务_二级库向一级库退库/log.html' target='_blank'>a_b9流程十六退库业务_二级库向一级库退库</a></td>
<td class="success">成功</td>
<td class="details-col-elapsed">15.574</td>
<td class="details-col-elapsed">15.297</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