模具发料及完成的操作 #2

This commit is contained in:
xielue 2023-09-16 09:42:04 +08:00
parent 4cd2cbd9db
commit 513838b72f
1 changed files with 21 additions and 10 deletions

View File

@ -83,20 +83,27 @@
:edit-render="{ name: '$input', props: { type: 'date' } }"></vxe-column>
<vxe-column title="发料" width="160">
<vxe-column title="发料" width="210">
<template #default="{ row }">
<div v-if="getDataId()">
<a-button v-if="!row.is_send" @click.stop="pageSend(row)">发料</a-button>
<div v-if="row.is_send">{{ $mk.getDateString(row.send_time) }}</div>
<a-button v-if="!row.is_send" @click.stop="pageSend(row)" type="primary">发料</a-button>
<div v-if="row.is_send">
{{ $mk.getDateString(row.send_time) }}
<a-button @click.stop="pageSend(row,true)" >撤销</a-button>
</div>
</div>
</template>
</vxe-column>
<vxe-column title="完成" width="160">
<vxe-column title="完成" width="210">
<template #default="{ row }">
<div v-if="getDataId()">
<a-button v-if="!row.is_complete" @click.stop="pageDone(row)">完成</a-button>
<div v-if="row.is_complete">{{ $mk.getDateString(row.complete_time) }}</div>
<a-button v-if="!row.is_complete" @click.stop="pageDone(row)" type="primary">完成</a-button>
<div v-if="row.is_complete">
{{ $mk.getDateString(row.complete_time) }}
<a-button @click.stop="pageDone(row,true)" >撤销</a-button>
</div>
</div>
</template>
</vxe-column>
@ -464,9 +471,11 @@ export default {
});
},
pageDone(row) {
pageDone(row,isUndo) {
this.$mk.post({
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/Reporting`,
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/Reporting`,
data: {
id: this.$mk.toBigInt( row.id)
},
@ -479,9 +488,11 @@ export default {
});
},
pageSend(row) {
pageSend(row,isUndo) {
this.$mk.post({
url: `${BASE_URL.BASE_URL}/MoldProductionOrder/v1/mold/production/order/component/processes/SendMaterial`,
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/SendMaterial`,
data: {
id:this.$mk.toBigInt( row.id)
},