备料
This commit is contained in:
@@ -115,11 +115,12 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { searchtable, searchtable2, change, handlechange, searchtable3, change2 } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
||||
import { searchtable, searchtable2, change, handlechange, searchtable3, change2, handlechange2 } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
||||
import { mapGetters } from 'vuex'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
editTime: '',
|
||||
bianliang1: [],
|
||||
bianliang2: [],
|
||||
num: 0,
|
||||
@@ -179,13 +180,21 @@ export default {
|
||||
备料到货: this.Data[i].备料到货,
|
||||
工艺要求: response.data[0].工艺要求,
|
||||
工序流水号: response.data[0].工序流水号,
|
||||
重量: response.data[0].重量
|
||||
重量: response.data[0].重量,
|
||||
单价: 0
|
||||
})
|
||||
})
|
||||
this.loading = false
|
||||
}
|
||||
})
|
||||
},
|
||||
zeroFill(i) {
|
||||
if (i >= 0 && i <= 9) {
|
||||
return '0' + i
|
||||
} else {
|
||||
return i
|
||||
}
|
||||
},
|
||||
// 自家备料出库
|
||||
handleChange1(row) {
|
||||
if (row.重量 === '' || row.重量 === null) {
|
||||
@@ -193,8 +202,14 @@ export default {
|
||||
} else if (row.单价 === '' || row.单价 === null) {
|
||||
this.$message.error('请输入单价')
|
||||
} else {
|
||||
var date = new Date()
|
||||
var month = this.zeroFill(date.getMonth() + 1)
|
||||
var day = this.zeroFill(date.getDate())
|
||||
this.editTime = date.getFullYear() + '-' + month + '-' + day
|
||||
change(row.工艺计划流水号, row.重量, row.单价).then(() => {
|
||||
handlechange(row.工序流水号, '0000')
|
||||
handlechange(row.工序流水号, '0000').then(response => {
|
||||
handlechange2(row.工序流水号, this.form.完成时间)
|
||||
})
|
||||
}).then(response => {
|
||||
this.searchTable()
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user