v.planCode === this.form.planCode))
// })
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
@@ -1719,15 +1723,21 @@ export default {
completeCollectMaterials() {
const loginStationCode = this.loginStationInfo.stationCode;
//const loginStationCode = 'ZP_06';
+ this.submitLoading = true;
completeCollectMaterials({endStationCode: loginStationCode}).then(v => {
this.$modal.msgSuccess("操作成功");
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
},
completeReturnMaterials() {
+ this.submitLoading = true;
completeReturnMaterials({endStationCode: this.loginStationInfo.stationCode}).then(v => {
this.$modal.msgSuccess("操作成功");
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
},
@@ -1759,6 +1769,7 @@ export default {
/** 提交暂停按钮 */
submitProductPlanDetailPause() {
+ this.submitLoading = true;
let pauseForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要暂停么?').then(function () {
return productPlanDetailPause(pauseForm);
@@ -1766,12 +1777,15 @@ export default {
this.$modal.msgSuccess("暂停成功");
this.form.planDetailStatus = setState("4");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
/** 提交继续按钮 */
submitProductPlanDetailContinue() {
+ this.submitLoading = true;
let continueForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要继续么?').then(function () {
return productPlanDetailContinue(continueForm);
@@ -1779,6 +1793,8 @@ export default {
this.form.planDetailStatus = setState("2");
this.$modal.msgSuccess("继续成功");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
diff --git a/hw-ui/src/views/board/firstFloor/index.vue b/hw-ui/src/views/board/firstFloor/index.vue
index 7e8bfc2..2cd4f18 100644
--- a/hw-ui/src/views/board/firstFloor/index.vue
+++ b/hw-ui/src/views/board/firstFloor/index.vue
@@ -214,6 +214,7 @@
v-if="scope.row.planDetailStatus !== '3' && scope.row.planDetailStatus !== '9'"
size="small"
type="text"
+ :loading="submitLoading"
@click="planExecute(scope.row)"
>
{{ scope.row.planDetailStatus === '1' ? '开始' : '完成' }}
@@ -223,6 +224,7 @@
size="small"
type="text"
@click="submitProductPlanDetailPause(scope.row)"
+ :loading="submitLoading"
v-if="scope.row.planDetailStatus === PLAN_DETAIL_STATUS.STARTED"
>
暂停
@@ -232,6 +234,7 @@
size="small"
type="text"
@click="submitProductPlanDetailContinue(scope.row)"
+ :loading="submitLoading"
v-if="scope.row.planDetailStatus === PLAN_DETAIL_STATUS.PAUSE"
>
继续
@@ -537,7 +540,7 @@ export default {
tableData1: [],
tableData2: [],
tableData3: [],
-
+ submitLoading:false,
productInstockVisible: false,
productInstockForm: {
materialBarcode: null
@@ -721,6 +724,7 @@ export default {
// 开始/继续计划
planExecute(e) {
if (e.planDetailStatus === '1') {
+ this.submitLoading = true;
this.$confirm('是否开始生产明细', '确认', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -740,9 +744,12 @@ export default {
type: 'info',
message: '已取消'
});
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
}
if (e.planDetailStatus === '2') {
+ this.submitLoading = true;
this.$confirm('是否完成生产明细', '确认', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -764,7 +771,9 @@ export default {
type: 'info',
message: '已取消'
});
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
}
},
// 生成/获取明细
@@ -1097,6 +1106,7 @@ export default {
/** 提交暂停按钮 */
submitProductPlanDetailPause(row) {
+ this.submitLoading = true;
let pauseForm = {planDetailId:row.planDetailId};
this.$modal.confirm('确认要暂停么?').then(function () {
return productPlanDetailPause(pauseForm);
@@ -1104,12 +1114,15 @@ export default {
this.$modal.msgSuccess("暂停成功");
row.planDetailStatus = this.PLAN_DETAIL_STATUS.PAUSE;
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
/** 提交继续按钮 */
submitProductPlanDetailContinue(row) {
+ this.submitLoading = true;
let continueForm = {planDetailId:row.planDetailId};
this.$modal.confirm('确认要继续么?').then(function () {
return productPlanDetailContinue(continueForm);
@@ -1117,6 +1130,8 @@ export default {
row.planDetailStatus = this.PLAN_DETAIL_STATUS.STARTED;
this.$modal.msgSuccess("继续成功");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
diff --git a/hw-ui/src/views/board/fourthFloor/assemble.vue b/hw-ui/src/views/board/fourthFloor/assemble.vue
index f7d77f1..69fc7e8 100644
--- a/hw-ui/src/views/board/fourthFloor/assemble.vue
+++ b/hw-ui/src/views/board/fourthFloor/assemble.vue
@@ -163,6 +163,7 @@
size="small"
type="text"
@click="planExecute(scope.row)"
+ :loading="submitLoading"
>
{{ scope.row.planDetailStatus === '1' ? '开始' : '完成' }}
@@ -171,6 +172,7 @@
size="small"
type="text"
@click="submitProductPlanDetailPause(scope.row)"
+ :loading="submitLoading"
v-if="scope.row.planDetailStatus === PLAN_DETAIL_STATUS.STARTED"
>
暂停
@@ -180,6 +182,7 @@
size="small"
type="text"
@click="submitProductPlanDetailContinue(scope.row)"
+ :loading="submitLoading"
v-if="scope.row.planDetailStatus === PLAN_DETAIL_STATUS.PAUSE"
>
继续
@@ -459,7 +462,7 @@ export default {
{required: true, message: "成品条码不能为空", trigger: "blur"}
],
},
-
+ submitLoading:false,
materialConfirmVisible: false,
materialConfirmForm: {
materialBarcode: null,
@@ -821,6 +824,7 @@ export default {
// 开始/继续计划
planExecute(e) {
if (e.planDetailStatus === '1') {
+ this.submitLoading = true;
this.$confirm('是否开始生产明细', '确认', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -848,9 +852,12 @@ export default {
type: 'info',
message: '已取消'
});
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
}
if (e.planDetailStatus === '2') {
+ this.submitLoading = true;
this.$confirm('是否完成生产明细', '确认', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -868,11 +875,10 @@ export default {
})
})
.catch(() => {
- this.$message({
- type: 'info',
- message: '已取消'
- });
- })
+
+ }).finally(e => {
+ this.submitLoading = false;
+ });
}
},
@@ -1219,6 +1225,7 @@ export default {
/** 提交暂停按钮 */
submitProductPlanDetailPause(row) {
+ this.submitLoading = true;
let pauseForm = {planDetailId:row.planDetailId};
this.$modal.confirm('确认要暂停么?').then(function () {
return productPlanDetailPause(pauseForm);
@@ -1226,12 +1233,15 @@ export default {
this.$modal.msgSuccess("暂停成功");
row.planDetailStatus = this.PLAN_DETAIL_STATUS.PAUSE;
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
/** 提交继续按钮 */
submitProductPlanDetailContinue(row) {
+ this.submitLoading = true;
let continueForm = {planDetailId:row.planDetailId};
this.$modal.confirm('确认要继续么?').then(function () {
return productPlanDetailContinue(continueForm);
@@ -1239,6 +1249,8 @@ export default {
row.planDetailStatus = this.PLAN_DETAIL_STATUS.STARTED;
this.$modal.msgSuccess("继续成功");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
diff --git a/hw-ui/src/views/board/fourthFloor/laserLight.vue b/hw-ui/src/views/board/fourthFloor/laserLight.vue
index 5766089..80e8d6f 100644
--- a/hw-ui/src/views/board/fourthFloor/laserLight.vue
+++ b/hw-ui/src/views/board/fourthFloor/laserLight.vue
@@ -39,15 +39,15 @@
板材退库
- 完成
- 暂停
- 继续
@@ -969,6 +969,7 @@ export default {
},
// 完成
accomplishPlan() {
+ this.submitLoading = true;
this.$confirm('确定完成么', '确认', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -997,7 +998,9 @@ export default {
type: 'info',
message: '已取消'
});
- })
+ }).finally(e => {
+ this.submitLoading = false;
+ });
},
// 表单重置
@@ -1251,6 +1254,7 @@ export default {
/** 提交暂停按钮 */
submitProductPlanDetailPause() {
+ this.submitLoading = true;
let pauseForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要暂停么?').then(function () {
return productPlanDetailPause(pauseForm);
@@ -1258,12 +1262,15 @@ export default {
this.$modal.msgSuccess("暂停成功");
this.form.planDetailStatus = setState("4");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
/** 提交继续按钮 */
submitProductPlanDetailContinue() {
+ this.submitLoading = true;
let continueForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要继续么?').then(function () {
return productPlanDetailContinue(continueForm);
@@ -1271,6 +1278,8 @@ export default {
this.form.planDetailStatus = setState("2");
this.$modal.msgSuccess("继续成功");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
diff --git a/hw-ui/src/views/board/fourthFloor/weld.vue b/hw-ui/src/views/board/fourthFloor/weld.vue
index 0def586..feb5de1 100644
--- a/hw-ui/src/views/board/fourthFloor/weld.vue
+++ b/hw-ui/src/views/board/fourthFloor/weld.vue
@@ -24,13 +24,13 @@
- 完成
+ 完成
- 暂停
- 继续
@@ -288,6 +288,7 @@ export default {
nowNum1: 1,
totalNum1: 0,
form: {},
+ submitLoading:false,
tableData: [],
vw: (document.documentElement.clientWidth || document.body.clientWidth) / 100,
//显示预览文件
@@ -847,7 +848,7 @@ export default {
})
},
async finish() {
-
+ this.submitLoading = true;
this.$confirm('确认计划完成?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -872,6 +873,8 @@ export default {
type: 'info',
message: '已取消'
});
+ }).finally(e => {
+ this.submitLoading = false;
});
},
@@ -900,6 +903,7 @@ export default {
/** 提交暂停按钮 */
submitProductPlanDetailPause() {
+ this.submitLoading = true;
let pauseForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要暂停么?').then(function () {
return productPlanDetailPause(pauseForm);
@@ -907,12 +911,15 @@ export default {
this.$modal.msgSuccess("暂停成功");
this.form.planDetailStatus = setState("4");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
/** 提交继续按钮 */
submitProductPlanDetailContinue() {
+ this.submitLoading = true;
let continueForm = {planDetailId:this.form.planDetailId};
this.$modal.confirm('确认要继续么?').then(function () {
return productPlanDetailContinue(continueForm);
@@ -920,6 +927,8 @@ export default {
this.form.planDetailStatus = setState("2");
this.$modal.msgSuccess("继续成功");
}).catch(() => {
+ }).finally(e => {
+ this.submitLoading = false;
});
},
}