Commit 8d13a70e by qinjianhui

fix:下载素材提示修改

parent b51eec5f
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -60,8 +60,8 @@ function submitTask(params) {
})
.finally(() => {
taskState.isRunning = false;
taskState.currentBatchNo = "";
broadcastStatus();
taskState.currentBatchNo = "";
});
return {
......
......@@ -56,6 +56,7 @@ function broadcastStatus() {
if (!win.isDestroyed()) {
win.webContents.send("download-typesetting:status", {
isRunning: taskState.isRunning,
currentBatchNo: taskState.currentBatchNo,
result: taskState.latestResult
});
}
......@@ -98,9 +99,9 @@ function submitTask(params) {
};
})
.finally(() => {
// 释放锁
taskState.isRunning = false;
broadcastStatus();
taskState.currentBatchNo = "";
});
return {
......
......@@ -94,9 +94,8 @@ export default {
if (!this.podOrderProductIds.length) {
return this.$message.warning("请选择操作单");
}
console.log(1111)
try {
let res = await this.$api.post(
const res = await this.$api.post(
pathMap["downloadBySubOrderNumber"]["OP"],
{
ids: this.podOrderProductIds,
......@@ -109,9 +108,15 @@ export default {
)
}
);
console.log(77, res);
if (res.code === 200) {
this.$message.success(
`批次号:${this.curBatchArrangeNum},素材下载成功`
);
} else {
this.$message.error(res.msg || "下载失败");
}
} catch (error) {
this.$message.error(error);
this.$message.error(error.message || "下载失败");
}
},
getDataInfo() {
......
......@@ -377,7 +377,8 @@ export default {
this[statusKey] = status.isRunning;
if (!status.isRunning && status.result) {
const { success, failed, currentBatchNo } = status.result;
const { success, failed } = status.result;
const { currentBatchNo } = status;
this.$message.success(
`批次号:${currentBatchNo},下载完成:成功 ${success.length} 个,失败 ${failed.length} 个`
);
......
Markdown is supported
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