|
|
|
@ -778,9 +778,10 @@
|
|
|
|
|
:loading="AbnormalReviewloading" |
|
|
|
|
@inputTxt="inputscReservationPackage" |
|
|
|
|
@timeCheck="timescReservationPackage" |
|
|
|
|
@selectCheck="selectscReservationPackage" |
|
|
|
|
@selectCheck="selectAbnormalpackage" |
|
|
|
|
ref="YcwtableBox" |
|
|
|
|
@selection="selectionChange" |
|
|
|
|
:isselectfun="ProhibitSelection" |
|
|
|
|
> |
|
|
|
|
<template #default="slotProps"> |
|
|
|
|
<template v-if="slotProps.scope.column.label == '操作'"> |
|
|
|
@ -801,17 +802,18 @@
|
|
|
|
|
</el-text> |
|
|
|
|
|
|
|
|
|
<el-text |
|
|
|
|
@click="Canceldelivery(slotProps.scope.row)" |
|
|
|
|
v-if="slotProps.scope.row.abnormalTypeName == '装车异常'" |
|
|
|
|
>取消</el-text |
|
|
|
|
> |
|
|
|
|
@click="Canceldelivery(slotProps.scope.row)" |
|
|
|
|
v-if="slotProps.scope.row.abnormalTypeName == '装车异常'" |
|
|
|
|
>取消</el-text |
|
|
|
|
> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-text |
|
|
|
|
@click="abnormalViewQRcode(2, slotProps.scope.row)" |
|
|
|
|
style="margin-left: 10px" |
|
|
|
|
type="primary" |
|
|
|
|
text |
|
|
|
|
v-if="slotProps.scope.row.packageCode" |
|
|
|
|
> |
|
|
|
|
查看二维码 |
|
|
|
|
</el-text> |
|
|
|
@ -894,6 +896,7 @@ import {
|
|
|
|
|
printBatch, |
|
|
|
|
$_deliveryZeroPackage, |
|
|
|
|
$_showInventoryPackgeCode, |
|
|
|
|
$_showInventoryPackgeCodes, |
|
|
|
|
$_loadingAbnormalPackageListTurnDown, |
|
|
|
|
$_retentionScan, |
|
|
|
|
$_cancelLoadingAbnormal, |
|
|
|
@ -954,6 +957,7 @@ export default {
|
|
|
|
|
], |
|
|
|
|
dialogViReject: false, //驳回弹窗 |
|
|
|
|
RejectRow: {}, //驳回点击当前单子 |
|
|
|
|
selectAbnormalpackageList: [], //异常包件list用于下拉搜索 |
|
|
|
|
yesOrNo: false, |
|
|
|
|
accessControl: '', |
|
|
|
|
html: '', |
|
|
|
@ -3263,32 +3267,25 @@ export default {
|
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
async abnormalViewQRcode(index, row) { |
|
|
|
|
let qr = {}; |
|
|
|
|
if (index == 1) { |
|
|
|
|
if (!this.selectionList.length) { |
|
|
|
|
ElMessage({ |
|
|
|
|
message: `请勾选要查看二维码的数据`, |
|
|
|
|
type: 'warning', |
|
|
|
|
}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
qr.ids = this.selectionList.map(res => res.packageId).join(','); |
|
|
|
|
} else { |
|
|
|
|
qr.ids = row.packageId; |
|
|
|
|
} |
|
|
|
|
console.log(row, 'row'); |
|
|
|
|
try { |
|
|
|
|
if (index == 1 && !this.checkSelection()) return; |
|
|
|
|
|
|
|
|
|
const qr = {}; |
|
|
|
|
let res = ''; |
|
|
|
|
|
|
|
|
|
if (index == 1) { |
|
|
|
|
res = await this.handleIndexOne(); |
|
|
|
|
} else { |
|
|
|
|
res = await this.handleNotIndexOne(row); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
this.AbnormalReviewloading = true; |
|
|
|
|
this.html = ''; |
|
|
|
|
const res = await showOrderPackgeCode(qr); |
|
|
|
|
|
|
|
|
|
const { code, data } = res.data; |
|
|
|
|
|
|
|
|
|
if (code !== 200) return; |
|
|
|
|
if (res.data.code !== 200) return; |
|
|
|
|
|
|
|
|
|
for (let i = 0; i < data.moldList.length; i++) { |
|
|
|
|
const element = data.moldList[i]; |
|
|
|
|
this.html += element; |
|
|
|
|
} |
|
|
|
|
this.html = res.data.data.moldList.join(''); |
|
|
|
|
this.isShowPrint = true; //开启二维码弹出框 |
|
|
|
|
} catch (error) { |
|
|
|
|
console.log('error :>> ', error); |
|
|
|
@ -3296,6 +3293,51 @@ export default {
|
|
|
|
|
this.AbnormalReviewloading = false; |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
checkSelection() { |
|
|
|
|
if (!this.selectionList.length) { |
|
|
|
|
ElMessage({ |
|
|
|
|
message: '请勾选要查看二维码的数据', |
|
|
|
|
type: 'warning', |
|
|
|
|
}); |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
if (!this.isUniformType()) { |
|
|
|
|
ElMessage({ |
|
|
|
|
message: '请勾选同一种类型的数据', |
|
|
|
|
type: 'warning', |
|
|
|
|
}); |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
return true; |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
isUniformType() { |
|
|
|
|
const type = this.selectionList[0].goodsTypeName; |
|
|
|
|
return this.selectionList.every(item => item.goodsTypeName === type); |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
async handleIndexOne() { |
|
|
|
|
const qr = {}; |
|
|
|
|
if (this.selectionList[0].goodsTypeName === '订制品') { |
|
|
|
|
qr.ids = this.selectionList.map(res => res.packageId).join(','); |
|
|
|
|
return await showOrderPackgeCode(qr); |
|
|
|
|
} else { |
|
|
|
|
qr.orderPackgeCodes = this.selectionList.map(res => res.packageCode).join(','); |
|
|
|
|
return await $_showInventoryPackgeCodes(qr); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
async handleNotIndexOne(row) { |
|
|
|
|
const qr = {}; |
|
|
|
|
if (row.goodsTypeName === '库存品') { |
|
|
|
|
qr.orderPackgeCodes = row.packageCode; |
|
|
|
|
return await $_showInventoryPackgeCodes(qr); |
|
|
|
|
} else { |
|
|
|
|
qr.ids = row.packageId; |
|
|
|
|
return await showOrderPackgeCode(qr); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
// 异常审核函数 |
|
|
|
|
viewAbnormalLoading(scope) { |
|
|
|
|
console.log(this.$refs.YcwtableBox, '2'); |
|
|
|
@ -3304,6 +3346,7 @@ export default {
|
|
|
|
|
this.AbnormalReviewloading = true; //开启加载 |
|
|
|
|
console.log(scope, 'scope'); |
|
|
|
|
this.abnormalBox = true; |
|
|
|
|
this.AbnormalReview.forEach(item => (item.values = '')); |
|
|
|
|
$_newLoadingAbnormalPackageListDetail(scope.signId) |
|
|
|
|
.then(res => { |
|
|
|
|
console.log(res, '异常审核查询'); |
|
|
|
@ -3320,6 +3363,7 @@ export default {
|
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
this.AbnormalReviewData = res.data.data; |
|
|
|
|
this.selectAbnormalpackageList = res.data.data; //用于存储全部值 |
|
|
|
|
}) |
|
|
|
|
.catch(res => { |
|
|
|
|
console.log(res, '关闭加载效果'); |
|
|
|
@ -3702,6 +3746,26 @@ export default {
|
|
|
|
|
} |
|
|
|
|
this.getWrapdetails(this.page); |
|
|
|
|
}, |
|
|
|
|
// 异常包件选择 |
|
|
|
|
selectAbnormalpackage(index, row) { |
|
|
|
|
console.log(index, row); |
|
|
|
|
console.log(index, 'indexxx'); |
|
|
|
|
|
|
|
|
|
if (!index) { |
|
|
|
|
this.AbnormalReviewData = this.selectAbnormalpackageList; |
|
|
|
|
} else { |
|
|
|
|
this.AbnormalReviewData = this.selectAbnormalpackageList.filter( |
|
|
|
|
item => item[row.prop] == row.values |
|
|
|
|
); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
ProhibitSelection(val, index) { |
|
|
|
|
if (val.packageCode) { |
|
|
|
|
return true; |
|
|
|
|
} else { |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
selectscReservationInventoryPackage(index, row) { |
|
|
|
|
console.log(index, row); |
|
|
|
|
if (row.prop === 'stockSignfoStatusName') { |
|
|
|
@ -3758,7 +3822,6 @@ export default {
|
|
|
|
|
// }; |
|
|
|
|
this.html = ''; |
|
|
|
|
const res = await showInventoryPackgeCode(row.reservationId, row.id); |
|
|
|
|
|
|
|
|
|
const { code, data } = res.data; |
|
|
|
|
if (code !== 200) return; |
|
|
|
|
// this.orderPackageCode = res.data |
|
|
|
@ -3860,12 +3923,15 @@ export default {
|
|
|
|
|
BatchcancellationAll() { |
|
|
|
|
if (!this.selectionList.length) { |
|
|
|
|
ElMessage({ |
|
|
|
|
message: '请勾选要取消的数据,【审核状态】必须为待审核,斌且【异常类型】状态只能为装车异常', |
|
|
|
|
message: |
|
|
|
|
'请勾选要取消的数据,【审核状态】必须为待审核,斌且【异常类型】状态只能为装车异常', |
|
|
|
|
type: 'warning', |
|
|
|
|
}); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
let _state = this.selectionList.every(item => item.auditingStatusName =='待审核' && item.abnormalTypeName == '装车异常' ); |
|
|
|
|
let _state = this.selectionList.every( |
|
|
|
|
item => item.auditingStatusName == '待审核' && item.abnormalTypeName == '装车异常' |
|
|
|
|
); |
|
|
|
|
console.log(_state); |
|
|
|
|
if (!_state) { |
|
|
|
|
ElMessage({ |
|
|
|
|