车数逻辑V2

yangwl
wws 1 year ago
parent 141e226271
commit a1aef0a3e4

@ -655,7 +655,6 @@ export default {
splitNumChange(e) {
// -
if (this.splitForm.routeCode == null) {
console.log("请先选择工艺")
this.$message({
message: "请先选择工艺!",
type: "warning"
@ -663,7 +662,6 @@ export default {
this.splitForm.splitNum = null
return
}
console.log("变换了拆分数量")
//
if (e <= 0) {
this.$message({
@ -699,7 +697,6 @@ export default {
}
this.product = this.productData[0];
//
console.log("车数逻辑------>")
if (this.converCarNum != null) {
this.splitForm.carNum = Math.ceil(this.splitForm.splitNum / this.converCarNum);
}else {

@ -388,7 +388,7 @@
<el-col :offset="1" :span="7">
<!-- 车数 -->
<el-form-item v-if="checkType" size="small" label="分配车数:">
<el-input required type="number" @input="changeCarNum" v-model="splitForm.carNum"></el-input>
<el-input required disabled type="number" @input="changeCarNum" v-model="splitForm.carNum"></el-input>
</el-form-item>
</el-col>
</el-row>
@ -698,10 +698,6 @@ export default {
})
//
getProRoutes(this.selectWork.productCode).then(response => {
console.log("这里是选中工单信息")
console.log(this.selectWork)
console.log("这里是开始获取工艺信息")
console.log(response.data)
this.routes = response.data
getProEquipment(this.selectWork.routeCode).then(response => {
this.proline = response.data
@ -712,8 +708,6 @@ export default {
this.converCarNum = this.routes[i].carNumUnit;
}
}
console.log("车数设置成功")
console.log(this.converCarNum)
})
//
getProEquipment(this.selectWork.routeCode).then(response2 => {
@ -811,8 +805,6 @@ export default {
},
// -
routeChange(routeCode) {
console.log("工艺变更")
console.log(routeCode)
getProEquipment(routeCode).then(response => {
this.eRouteOptions = response.data
})
@ -825,8 +817,11 @@ export default {
}
}
console.log("设置好车数换算值")
console.log(this.converCarNum)
//
//
this.splitForm.carNum = Math.ceil(this.splitForm.splitNum / this.converCarNum);
//
this.workForm.carNum = Math.ceil(this.splitForm.splitNum / this.converCarNum);
},
// -
shiftChange(e) {
@ -916,6 +911,16 @@ export default {
})
this.workForm.splitNum = this.splitForm.splitNum
//
if (this.converCarNum != null) {
this.splitForm.carNum = Math.ceil(this.splitForm.splitNum / this.converCarNum);
this.workForm.carNum = Math.ceil(this.splitForm.splitNum / this.converCarNum);
}else {
this.$message({
message: '获取车数换算值异常!',
type: 'error'
})
}
}
this.product = this.productData[0]
},

Loading…
Cancel
Save