feat: 工单强制报工
This commit is contained in:
@@ -82,6 +82,17 @@
|
||||
>
|
||||
同步
|
||||
</el-button>
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
type="danger"
|
||||
icon="el-icon-position"
|
||||
size="mini"
|
||||
:disabled="!(crud.selections[0]) || crud.selections[1]"
|
||||
@click="forceFinish(crud.selections[0])"
|
||||
>
|
||||
强制完工
|
||||
</el-button>
|
||||
</crudOperation>
|
||||
<!--表单组件-->
|
||||
<el-dialog
|
||||
@@ -654,7 +665,7 @@ export default {
|
||||
submits(row) {
|
||||
this.fullscreenLoading = true
|
||||
crudPdmBdWorkorder.submits(row).then(res => {
|
||||
this.crud.notify('下发成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.notify('报工完成', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
}).catch(() => {
|
||||
this.fullscreenLoading = false
|
||||
@@ -672,6 +683,17 @@ export default {
|
||||
}).finally(() => {
|
||||
this.fullscreenLoading = false
|
||||
})
|
||||
},
|
||||
forceFinish(row) {
|
||||
this.fullscreenLoading = true
|
||||
crudPdmBdWorkorder.forceFinish(row).then(res => {
|
||||
this.crud.notify('下发成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
}).catch(() => {
|
||||
this.fullscreenLoading = false
|
||||
}).finally(() => {
|
||||
this.fullscreenLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,6 +32,13 @@ export function submits(param) {
|
||||
data: param
|
||||
})
|
||||
}
|
||||
export function forceFinish(param) {
|
||||
return request({
|
||||
url: 'api/pdmBdWorkorder/forceFinish',
|
||||
method: 'post',
|
||||
data: param
|
||||
})
|
||||
}
|
||||
|
||||
export function orderSynchronize(data) {
|
||||
return request({
|
||||
@@ -55,4 +62,4 @@ export function getCuster() {
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, submits, orderSynchronize, queryMaterials, getCuster }
|
||||
export default { add, edit, del, submits, forceFinish, orderSynchronize, queryMaterials, getCuster }
|
||||
|
||||
Reference in New Issue
Block a user