|
|
@ -185,6 +185,13 @@ export default { |
|
|
|
btnKey: 'tobeSelect', |
|
|
|
btnLabel: '选择' |
|
|
|
}, |
|
|
|
{ |
|
|
|
type: 'danger', |
|
|
|
size: 'small', |
|
|
|
icon: '', |
|
|
|
btnKey: 'doCancellation', |
|
|
|
btnLabel: '作废' |
|
|
|
}, |
|
|
|
{ |
|
|
|
type: 'info', |
|
|
|
size: 'small', |
|
|
@ -284,6 +291,9 @@ export default { |
|
|
|
case 'tobeSelect': |
|
|
|
this.tobeSelect() |
|
|
|
break |
|
|
|
case 'doCancellation': |
|
|
|
this.doCancellation() |
|
|
|
break |
|
|
|
case 'doClose': |
|
|
|
this.doClose() |
|
|
|
break |
|
|
@ -353,11 +363,22 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
tobeSelect() { |
|
|
|
if (this.sids.length === 1) { |
|
|
|
if (this.sids.length > 0) { |
|
|
|
this.dialogVisible = true |
|
|
|
} else { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '请选择一条记录进行操作' }) |
|
|
|
return |
|
|
|
this.$message({ showClose: true, type: 'error', message: '请至少选择一条记录进行操作' }) |
|
|
|
} |
|
|
|
}, |
|
|
|
doCancellation() { |
|
|
|
if (this.sids.length > 0) { |
|
|
|
req.cancel(this.sids).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.$message({ showClose: true, type: 'success', message: '作废成功' }) |
|
|
|
this.getList() |
|
|
|
} |
|
|
|
}) |
|
|
|
} else { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '请至少选择一条记录进行操作' }) |
|
|
|
} |
|
|
|
}, |
|
|
|
changeOrgDept(value) { |
|
|
|