合
This commit is contained in:
@@ -269,7 +269,7 @@
|
||||
</el-card>
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogeditVisible" :title="title" :close-on-click-modal="false" width="400px" center >
|
||||
<el-form ref="form2" :model="form2" :rules="rules" label-position="left">
|
||||
<el-form-item label="零件号" label-width="80px" style="width: 299px ; display: inline-block; text-align: left;margin-left: 20px" size="small">
|
||||
<el-form-item label="零件图号" label-width="90px" style="width: 299px ; display: inline-block; text-align: left;margin-left: 10px" size="small">
|
||||
<el-input v-model="form.input1" :disabled="true" auto-complete="off" style="width: 200px"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="报废数量" prop="报废数量" label-width="100px" style="width: 299px ; display: inline-block; text-align: left" size="small">
|
||||
@@ -480,15 +480,19 @@ export default {
|
||||
submit(formName) {
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
editSpare(this.code, this.form2.报废数量, this.form2.报废原因, this.form2.报废时间).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('报废成功')
|
||||
this.dialogeditVisible = false
|
||||
this.fetchTableData()
|
||||
} else {
|
||||
this.$message.success('报废失败')
|
||||
}
|
||||
})
|
||||
if (this.form2.报废数量 > 0) {
|
||||
editSpare(this.code, this.form2.报废数量, this.form2.报废原因, this.form2.报废时间).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('报废成功')
|
||||
this.dialogeditVisible = false
|
||||
this.fetchTableData()
|
||||
} else {
|
||||
this.$message.success('报废失败')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('报废数量不能为零')
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
@@ -511,14 +515,19 @@ export default {
|
||||
},
|
||||
editB() {
|
||||
if (this.spareNumber - this.SupplementationNumber > 0) {
|
||||
editA(this.CutCodeBefore, this.inputC).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('补投成功')
|
||||
this.fetchTableData()
|
||||
} else {
|
||||
this.$message.error('补投失败')
|
||||
}
|
||||
})
|
||||
if (this.inputC > 0) {
|
||||
editA(this.CutCodeBefore, this.inputC).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('补投成功')
|
||||
this.fetchTableData()
|
||||
this.inputC = 0
|
||||
} else {
|
||||
this.$message.error('补投失败')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('补投数量不能为零')
|
||||
}
|
||||
} else { alert('请选择停产零件') }
|
||||
},
|
||||
goToCapacityBalance() {
|
||||
|
||||
Reference in New Issue
Block a user