模具 发料完工增加确认框
This commit is contained in:
parent
637d61250b
commit
9e49b56978
|
|
@ -90,7 +90,7 @@
|
||||||
<div v-if="row.is_send">
|
<div v-if="row.is_send">
|
||||||
|
|
||||||
{{ $mk.getDateString(row.send_time) }}
|
{{ $mk.getDateString(row.send_time) }}
|
||||||
<a-button @click.stop="pageSend(row,true)" >撤销</a-button>
|
<a-button v-if="!row.is_complete" @click.stop="pageSend(row, true)">撤销</a-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -457,6 +457,9 @@ export default {
|
||||||
return this.$mk.toBigInt(dataId);
|
return this.$mk.toBigInt(dataId);
|
||||||
},
|
},
|
||||||
pageComplete(row) {
|
pageComplete(row) {
|
||||||
|
|
||||||
|
this.$mk.confirm('您确定完成吗?').then(type => {
|
||||||
|
if (type == 'confirm') {
|
||||||
this.$mk.post({
|
this.$mk.post({
|
||||||
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/reporting`,
|
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/reporting`,
|
||||||
data: {
|
data: {
|
||||||
|
|
@ -469,9 +472,17 @@ export default {
|
||||||
this.$emit("reloadData");
|
this.$emit("reloadData");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
pageDone(row, isUndo) {
|
pageDone(row, isUndo) {
|
||||||
|
|
||||||
|
|
||||||
|
this.$mk.confirm(!isUndo ? '您确定要报工吗?' : '您确定撤销吗?').then(type => {
|
||||||
|
if (type == 'confirm') {
|
||||||
this.$mk.post({
|
this.$mk.post({
|
||||||
url: isUndo ?
|
url: isUndo ?
|
||||||
`${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/CancelReporting` :
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/CancelReporting` :
|
||||||
|
|
@ -486,9 +497,16 @@ export default {
|
||||||
this.$emit("reloadData");
|
this.$emit("reloadData");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
pageSend(row, isUndo) {
|
pageSend(row, isUndo) {
|
||||||
|
|
||||||
|
this.$mk.confirm(!isUndo ? '您确定要发料吗?' : '您确定撤销吗?').then(type => {
|
||||||
|
if (type == 'confirm') {
|
||||||
this.$mk.post({
|
this.$mk.post({
|
||||||
url: isUndo ?
|
url: isUndo ?
|
||||||
`${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/CancelSendMaterial` :
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/CancelSendMaterial` :
|
||||||
|
|
@ -503,6 +521,10 @@ export default {
|
||||||
this.$emit("reloadData");
|
this.$emit("reloadData");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
pageAdd(row) {
|
pageAdd(row) {
|
||||||
|
|
|
||||||
|
|
@ -37,9 +37,14 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="gx-item-col">
|
<div class="gx-item-col">
|
||||||
<a-button type="primary" @click="pageSend(item)" v-if="item.is_send !== 1">发料</a-button>
|
<a-button type="primary" @click="pageSend(item)" v-if="item.is_send !== 1">发料</a-button>
|
||||||
|
<a-button @click="pageSend(item, true)" v-else-if="!item.is_complete">撤销发料</a-button>
|
||||||
|
|
||||||
<a-button type="primary" @click="pageReport(item)"
|
<a-button style="margin-left: 3px;" type="primary" @click="pageReport(item)"
|
||||||
v-if="item.is_send && item.is_complete !== 1">报工</a-button>
|
v-if="item.is_send && item.is_complete !== 1">报工</a-button>
|
||||||
|
|
||||||
|
<a-button style="margin-left: 3px;" @click="pageReport(item,true)"
|
||||||
|
v-if="item.is_complete == 1">撤销报工</a-button>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-item-progress">
|
<div class="card-item-progress">
|
||||||
|
|
@ -346,6 +351,8 @@ export default {
|
||||||
this.tableDataOrders = JSON.parse(JSON.stringify(a.data.mold_production_order || []));
|
this.tableDataOrders = JSON.parse(JSON.stringify(a.data.mold_production_order || []));
|
||||||
|
|
||||||
this.allDetailsData = JSON.parse(JSON.stringify(a.data.mold_production_order_component_processes || []));
|
this.allDetailsData = JSON.parse(JSON.stringify(a.data.mold_production_order_component_processes || []));
|
||||||
|
|
||||||
|
|
||||||
}).catch((a) => {
|
}).catch((a) => {
|
||||||
this.loading = false
|
this.loading = false
|
||||||
this.$mk.error(a.data.msg);
|
this.$mk.error(a.data.msg);
|
||||||
|
|
@ -477,6 +484,8 @@ export default {
|
||||||
this.detailsData = [];
|
this.detailsData = [];
|
||||||
|
|
||||||
|
|
||||||
|
//this.detailsData = JSON.parse(JSON.stringify(row.mold_production_order_component_processes || []));
|
||||||
|
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
@ -547,12 +556,18 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
pageReport(item) {
|
pageReport(item, isUndo) {
|
||||||
|
|
||||||
|
this.$mk.confirm(!isUndo ? '您确定要报工吗?' : '您确定撤销吗?').then(type => {
|
||||||
|
if (type == 'confirm') {
|
||||||
|
|
||||||
this.$mk.post({
|
this.$mk.post({
|
||||||
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/create`,
|
url:
|
||||||
loading: "报工中...",
|
isUndo ?
|
||||||
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/cancel` :
|
||||||
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/create`,
|
||||||
|
|
||||||
|
loading: "操作中...",
|
||||||
data: {
|
data: {
|
||||||
"ptyid": parseInt(process.env.VUE_APP_PTYID),
|
"ptyid": parseInt(process.env.VUE_APP_PTYID),
|
||||||
"project_token": process.env.VUE_APP_APPTOKEN,
|
"project_token": process.env.VUE_APP_APPTOKEN,
|
||||||
|
|
@ -566,7 +581,7 @@ export default {
|
||||||
}).then(a => {
|
}).then(a => {
|
||||||
console.log(a)
|
console.log(a)
|
||||||
if (a.code == 200) {
|
if (a.code == 200) {
|
||||||
this.$mk.success("报工成功");
|
this.$mk.success("操作成功");
|
||||||
|
|
||||||
this.loadProductionOrder({ id: this.currentId });
|
this.loadProductionOrder({ id: this.currentId });
|
||||||
|
|
||||||
|
|
@ -576,13 +591,23 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
pageSend(item) {
|
pageSend(item, isUndo) {
|
||||||
|
|
||||||
console.log(item)
|
console.log(item)
|
||||||
|
|
||||||
|
this.$mk.confirm(!isUndo ? '您确定要发料吗?' : '您确定撤销吗?').then(type => {
|
||||||
|
if (type == 'confirm') {
|
||||||
this.$mk.post({
|
this.$mk.post({
|
||||||
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/sendMaterial`,
|
url: isUndo ?
|
||||||
loading: "发料中...",
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/cancelSendMaterial` :
|
||||||
|
`${BASE_URL.BASE_URL}/MoldProductionOrder/Get/TouchScreen/v1/mold/production/order/touchScreen/sendMaterial`,
|
||||||
|
loading: "操作中...",
|
||||||
data: {
|
data: {
|
||||||
"ptyid": parseInt(process.env.VUE_APP_PTYID),
|
"ptyid": parseInt(process.env.VUE_APP_PTYID),
|
||||||
"project_token": process.env.VUE_APP_APPTOKEN,
|
"project_token": process.env.VUE_APP_APPTOKEN,
|
||||||
|
|
@ -596,7 +621,7 @@ export default {
|
||||||
}).then(a => {
|
}).then(a => {
|
||||||
console.log(a)
|
console.log(a)
|
||||||
if (a.code == 200) {
|
if (a.code == 200) {
|
||||||
this.$mk.success("发料成功");
|
this.$mk.success("操作成功");
|
||||||
|
|
||||||
this.loadProductionOrder({ id: this.currentId });
|
this.loadProductionOrder({ id: this.currentId });
|
||||||
|
|
||||||
|
|
@ -606,6 +631,10 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue