This commit is contained in:
caoxinyu
2018-12-29 10:58:13 +08:00

View File

@@ -59,6 +59,7 @@ import { searchtable, searchtable2, edit, handlechange } from '@/api/Manufacturi
export default { export default {
data() { data() {
return { return {
num: 0,
arrest: [], arrest: [],
all: false, all: false,
partName: '', partName: '',
@@ -114,9 +115,12 @@ export default {
this.$message.warning('请选择零件') this.$message.warning('请选择零件')
} else { } else {
for (let i = 0; i < this.arrest.length; i++) { for (let i = 0; i < this.arrest.length; i++) {
edit(this.arrest[i].工艺计划流水号) edit(this.arrest[i].工艺计划流水号).then(() => {
handlechange(this.arrest[i].工序流水号, '0000') handlechange(this.arrest[i].工序流水号, '0000').then(response => {
if (i === this.arrest.length - 1) { this.num = this.num + response.data[0].result
})
})
if (this.num === this.arrest.length) {
this.searchTable() this.searchTable()
} }
} }