|
@@ -126,12 +126,20 @@
|
|
<div>
|
|
<div>
|
|
<el-button
|
|
<el-button
|
|
v-if="checkPrivilege('button', 'BatchEnd')"
|
|
v-if="checkPrivilege('button', 'BatchEnd')"
|
|
- icon="el-icon-download"
|
|
|
|
|
|
+ icon="el-icon-bottom-left"
|
|
type="danger"
|
|
type="danger"
|
|
- @click="toBatchCancel"
|
|
|
|
|
|
+ @click="toBatchCancelOrSubmit('cancel')"
|
|
>
|
|
>
|
|
批量撤回
|
|
批量撤回
|
|
</el-button>
|
|
</el-button>
|
|
|
|
+ <el-button
|
|
|
|
+ v-if="checkPrivilege('button', 'BatchEnd')"
|
|
|
|
+ icon="el-icon-top-right"
|
|
|
|
+ type="primary"
|
|
|
|
+ @click="toBatchCancelOrSubmit('submit')"
|
|
|
|
+ >
|
|
|
|
+ 批量提交
|
|
|
|
+ </el-button>
|
|
<el-button
|
|
<el-button
|
|
v-if="checkPrivilege('button', 'BatchDownload')"
|
|
v-if="checkPrivilege('button', 'BatchDownload')"
|
|
icon="el-icon-download"
|
|
icon="el-icon-download"
|
|
@@ -612,21 +620,23 @@ export default {
|
|
})
|
|
})
|
|
.catch(() => {});
|
|
.catch(() => {});
|
|
},
|
|
},
|
|
- toBatchCancel() {
|
|
|
|
|
|
+ toBatchCancelOrSubmit(type) {
|
|
|
|
+ const name = type === "submit" ? "提交" : "撤回";
|
|
if (!this.multipleSelection.length) {
|
|
if (!this.multipleSelection.length) {
|
|
- this.$message.error("请选择要撤回的记录!");
|
|
|
|
|
|
+ this.$message.error(`请选择要${name}的记录!`);
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- this.$confirm("确定撤回选中的印刷任务的提交吗?", "提示", {
|
|
|
|
|
|
+ this.$confirm(`确定${name}选中的印刷任务的提交吗?`, "提示", {
|
|
type: "warning",
|
|
type: "warning",
|
|
})
|
|
})
|
|
.then(async () => {
|
|
.then(async () => {
|
|
const data = await batchCancelPrintTask(
|
|
const data = await batchCancelPrintTask(
|
|
- this.multipleSelection.join()
|
|
|
|
|
|
+ this.multipleSelection.join(),
|
|
|
|
+ type
|
|
);
|
|
);
|
|
if (!data) return;
|
|
if (!data) return;
|
|
|
|
|
|
- this.$message.success("撤回成功!");
|
|
|
|
|
|
+ this.$message.success("操作成功!");
|
|
this.getList();
|
|
this.getList();
|
|
})
|
|
})
|
|
.catch(() => {});
|
|
.catch(() => {});
|