|
@@ -1203,12 +1203,13 @@
|
1203
|
1203
|
//获取药包信息
|
1204
|
1204
|
getInfo(responeseData, code){
|
1205
|
1205
|
console.log(responeseData);
|
|
1206
|
+ let gdValue = responeseData.workOrderDTO ? responeseData.workOrderDTO.gdState.value : null;
|
1206
|
1207
|
uni.showLoading({
|
1207
|
1208
|
title: "加载中",
|
1208
|
1209
|
mask: true,
|
1209
|
1210
|
});
|
1210
|
1211
|
|
1211
|
|
- post(`/transflow/scanInfo`, {type: responeseData.drugsBagType.value, id: responeseData.id, orderStateValue: responeseData.drugsState.value}).then(res => {
|
|
1212
|
+ post(`/transflow/scanInfo`, {type: responeseData.drugsBagType.value, id: responeseData.id, orderStateValue: gdValue}).then(res => {
|
1212
|
1213
|
uni.hideLoading();
|
1213
|
1214
|
if(res.state == 200){
|
1214
|
1215
|
if(res.data){
|
|
@@ -1216,12 +1217,12 @@
|
1216
|
1217
|
let orderId = responeseData.gdId;
|
1217
|
1218
|
let config = res.data.taskTypeConfig || {};
|
1218
|
1219
|
console.log(res);
|
1219
|
|
- if(responeseData.drugsState.value == 2 || responeseData.drugsState.value == 3 || (responeseData.drugsState.value == 4 && responeseData.workOrderDTO.worker.id == uni.getStorageSync('userData').user.id)){
|
|
1220
|
+ if(gdValue == 2 || gdValue == 3 || (gdValue == 4 && responeseData.workOrderDTO.worker.id == uni.getStorageSync('userData').user.id)){
|
1220
|
1221
|
// 待抢单、待接单、待到达(本人),进入起点科室流程
|
1221
|
1222
|
uni.navigateTo({
|
1222
|
1223
|
url: `/pages/newDrug/createOrder/createOrder?drugsBagType=${responeseData.drugsBagType.value}&drugsBagId=${responeseData.id}&orderId=${responeseData.gdId || ''}&type=receive`,
|
1223
|
1224
|
});
|
1224
|
|
- }else if(responeseData.drugsState.value == 5 && responeseData.workOrderDTO.worker.id == uni.getStorageSync('userData').user.id){
|
|
1225
|
+ }else if(gdValue == 5 && responeseData.workOrderDTO.worker.id == uni.getStorageSync('userData').user.id){
|
1225
|
1226
|
// 待送达(本人),进入终点科室流程
|
1226
|
1227
|
this.pageNavigateByConfig(config, responeseData, responeseData, code)
|
1227
|
1228
|
}else{
|
|
@@ -1244,10 +1245,10 @@
|
1244
|
1245
|
let drugsBagType = queryObj.drugsBagType.value;
|
1245
|
1246
|
let orderId = responseData.gdId;
|
1246
|
1247
|
let drugsBagId = responseData.id;
|
1247
|
|
- let orderStateValue = responseData.drugsState;
|
|
1248
|
+ let orderStateValue = responeseData.workOrderDTO ? responeseData.workOrderDTO.gdState.value : null;
|
1248
|
1249
|
if(config.drugsModel === 1){
|
1249
|
1250
|
// 一单一码
|
1250
|
|
- if(responseData.drugsState.value == 4){
|
|
1251
|
+ if(orderStateValue == 4){
|
1251
|
1252
|
// 待到达
|
1252
|
1253
|
if(config.drugsStartCheck === 1){
|
1253
|
1254
|
// 起点科室支持核对
|
|
@@ -1266,7 +1267,7 @@
|
1266
|
1267
|
this.completeOrder(responseData, queryObj);
|
1267
|
1268
|
}
|
1268
|
1269
|
}
|
1269
|
|
- }else if(responseData.drugsState.value == 5){
|
|
1270
|
+ }else if(orderStateValue == 5){
|
1270
|
1271
|
// 待送达
|
1271
|
1272
|
uni.showLoading({
|
1272
|
1273
|
title: "加载中",
|
|
@@ -1323,7 +1324,7 @@
|
1323
|
1324
|
});
|
1324
|
1325
|
}else{
|
1325
|
1326
|
uni.navigateTo({
|
1326
|
|
- url: `/pages/newDrug/continueScanning/continueScanning?drugsBagType=${drugsBagType}&orderId=${orderId}&drugsBagId=${drugsBagId}&orderStateValue=${orderStateValue.value}`,
|
|
1327
|
+ url: `/pages/newDrug/continueScanning/continueScanning?drugsBagType=${drugsBagType}&orderId=${orderId}&drugsBagId=${drugsBagId}&orderStateValue=${orderStateValue}`,
|
1327
|
1328
|
});
|
1328
|
1329
|
}
|
1329
|
1330
|
} else {
|
|
@@ -1351,7 +1352,7 @@
|
1351
|
1352
|
if(res.state == 200){
|
1352
|
1353
|
uni.showToast({
|
1353
|
1354
|
icon: "none",
|
1354
|
|
- title: responseData.drugsState.value == 4 ? "交接成功,请尽快送达科室!" : (responseData.drugsState.value == 5 ? "交接成功,完成配送!" : ""),
|
|
1355
|
+ title: orderStateValue == 4 ? "交接成功,请尽快送达科室!" : (orderStateValue == 5 ? "交接成功,完成配送!" : ""),
|
1355
|
1356
|
duration: 60000,
|
1356
|
1357
|
mask: true,
|
1357
|
1358
|
complete(){
|