|
@ -13,14 +13,13 @@ |
|
|
<view class='split_line'></view> |
|
|
<view class='split_line'></view> |
|
|
<view class="uni-flex uni-column" style="background-color: white; "> |
|
|
<view class="uni-flex uni-column" style="background-color: white; "> |
|
|
<view class="uni-flex uni-column"> |
|
|
<view class="uni-flex uni-column"> |
|
|
|
|
|
|
|
|
<view class="title " style="display: flex; align-items: center;padding: 10rpx;"> |
|
|
<view class="title " style="display: flex; align-items: center;padding: 10rpx;"> |
|
|
<text style=" flex-shrink: 0;width: 25%;">生产线:</text> |
|
|
<text style=" flex-shrink: 0;width: 25%;">生产线:</text> |
|
|
<view class="customerBorder" @click="showSelectLine"> |
|
|
<view class="customerBorder" @click="showSelectLine"> |
|
|
{{productionLineName}} |
|
|
{{productionLineName}} |
|
|
</view> |
|
|
</view> |
|
|
<u-select v-model="showProductLineSelect" mode="mutil-column-auto" title="请选择生产线和工位" |
|
|
<u-select v-model="showProductLineSelect" mode="mutil-column-auto" |
|
|
:list="productLineList" @confirm="confirmSelectLine"></u-select> |
|
|
:list="productLineList" @confirm="confirmSelectLine" title="生产线-工位"></u-select> |
|
|
|
|
|
|
|
|
<view class=""> |
|
|
<view class=""> |
|
|
<image src="/static/icons/down.svg" mode="" |
|
|
<image src="/static/icons/down.svg" mode="" |
|
@ -49,8 +48,11 @@ |
|
|
<view class="customerBorder"> |
|
|
<view class="customerBorder"> |
|
|
{{itemCode}} |
|
|
{{itemCode}} |
|
|
</view> |
|
|
</view> |
|
|
<u-select v-model="showItemCodeSelect" mode="single-column" :list="itemCodeList" |
|
|
<view v-if="bomVersion" class=""> |
|
|
@confirm="confirmSelectItem"></u-select> |
|
|
Bom版本{{bomVersion}} |
|
|
|
|
|
</view> |
|
|
|
|
|
<u-select v-model="showItemCodeSelect" mode="mutil-column-auto" :list="itemCodeList" |
|
|
|
|
|
@confirm="confirmSelectItem" title="物料代码-Bom版本"></u-select> |
|
|
<view class=""> |
|
|
<view class=""> |
|
|
<image src="/static/icons/down.svg" mode="" |
|
|
<image src="/static/icons/down.svg" mode="" |
|
|
style=" width: 40rpx;height: 40rpx;margin-left: 20rpx;" |
|
|
style=" width: 40rpx;height: 40rpx;margin-left: 20rpx;" |
|
@ -113,7 +115,7 @@ |
|
|
getPlaneInfoByproductLine, |
|
|
getPlaneInfoByproductLine, |
|
|
getPackUnitByItemCode, |
|
|
getPackUnitByItemCode, |
|
|
getProductionlineAndWorkStation, |
|
|
getProductionlineAndWorkStation, |
|
|
getProductionlineItem |
|
|
getBomVersionByProductionline |
|
|
} from '@/api/request2.js'; |
|
|
} from '@/api/request2.js'; |
|
|
import { |
|
|
import { |
|
|
getPackUnitName, |
|
|
getPackUnitName, |
|
@ -145,7 +147,8 @@ |
|
|
}, |
|
|
}, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
itemCode: '请选择物料信息', |
|
|
itemCode: '', |
|
|
|
|
|
itemName: '请选择物料信息', |
|
|
uom: "", |
|
|
uom: "", |
|
|
qty: null, |
|
|
qty: null, |
|
|
planQty: 0, |
|
|
planQty: 0, |
|
@ -170,7 +173,10 @@ |
|
|
showDateSelect: false, |
|
|
showDateSelect: false, |
|
|
planDateList: [], |
|
|
planDateList: [], |
|
|
fgLocationCode: "", |
|
|
fgLocationCode: "", |
|
|
rawLocationCode: "" |
|
|
rawLocationCode: "", |
|
|
|
|
|
workshop: "", |
|
|
|
|
|
bomVersion: "", |
|
|
|
|
|
uom:"" |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
props: { |
|
|
props: { |
|
@ -217,6 +223,7 @@ |
|
|
this.planDateList = [] |
|
|
this.planDateList = [] |
|
|
this.fgLocationCode = "" |
|
|
this.fgLocationCode = "" |
|
|
this.rawLocationCode = "" |
|
|
this.rawLocationCode = "" |
|
|
|
|
|
this.workshop="" |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
@ -264,7 +271,7 @@ |
|
|
callback() { |
|
|
callback() { |
|
|
let item = { |
|
|
let item = { |
|
|
productionLineName: "", |
|
|
productionLineName: "", |
|
|
productionLineCode: "", //生产线 |
|
|
productionLineCode: this.productLineCode, //生产线 |
|
|
itemCode: this.itemCode, |
|
|
itemCode: this.itemCode, |
|
|
itemName: this.itemName, |
|
|
itemName: this.itemName, |
|
|
uom: this.getUomInfo(this.uom), |
|
|
uom: this.getUomInfo(this.uom), |
|
@ -278,7 +285,8 @@ |
|
|
planNumber: "", |
|
|
planNumber: "", |
|
|
workStationCode: this.workStationCode, |
|
|
workStationCode: this.workStationCode, |
|
|
fgLocationCode: this.fgLocationCode, |
|
|
fgLocationCode: this.fgLocationCode, |
|
|
rawLocationCode: this.rawLocationCode |
|
|
rawLocationCode: this.rawLocationCode, |
|
|
|
|
|
workshop:this.workshop |
|
|
}; |
|
|
}; |
|
|
this.closeRequestPopup(); |
|
|
this.closeRequestPopup(); |
|
|
this.$emit("confirm", item); |
|
|
this.$emit("confirm", item); |
|
@ -300,6 +308,8 @@ |
|
|
var parent = this.productLineList.filter(res => res.value == this.productionLineCode) |
|
|
var parent = this.productLineList.filter(res => res.value == this.productionLineCode) |
|
|
var fgLocation = parent[0].children.filter(children => children.value == this.workStationCode) |
|
|
var fgLocation = parent[0].children.filter(children => children.value == this.workStationCode) |
|
|
this.fgLocationCode = fgLocation[0].fgLocationCode; |
|
|
this.fgLocationCode = fgLocation[0].fgLocationCode; |
|
|
|
|
|
this.workshop = parent[0].workshop; |
|
|
|
|
|
|
|
|
this.clearItemCode() |
|
|
this.clearItemCode() |
|
|
this.clearPackUnit() |
|
|
this.clearPackUnit() |
|
|
|
|
|
|
|
@ -363,20 +373,10 @@ |
|
|
title: "加载中", |
|
|
title: "加载中", |
|
|
mask: true |
|
|
mask: true |
|
|
}) |
|
|
}) |
|
|
let param = { |
|
|
getBomVersionByProductionline(this.productionLineCode).then(res => { |
|
|
pageSize: 20, |
|
|
|
|
|
pageNo: 1, |
|
|
|
|
|
productionLineCode: this.productionLineCode |
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
getProductionlineItem(param).then(res => { |
|
|
|
|
|
uni.hideLoading() |
|
|
uni.hideLoading() |
|
|
if (res.data.list && res.data.list.length > 0) { |
|
|
if (res.data && res.data.length > 0) { |
|
|
res.data.list.forEach(item => { |
|
|
this.itemCodeList = res.data |
|
|
item.label = item.itemCode |
|
|
|
|
|
item.value = item |
|
|
|
|
|
}) |
|
|
|
|
|
this.itemCodeList = res.data.list |
|
|
|
|
|
this.showItemCodeSelect = true |
|
|
this.showItemCodeSelect = true |
|
|
} else { |
|
|
} else { |
|
|
this.showErrorMessage('未查找到物料信息'); |
|
|
this.showErrorMessage('未查找到物料信息'); |
|
@ -387,9 +387,10 @@ |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
confirmSelectItem(data) { |
|
|
confirmSelectItem(data) { |
|
|
let itemInfo = data[0].value; |
|
|
this.itemCode = data[0].label; |
|
|
this.itemCode = itemInfo.itemCode; |
|
|
this.bomVersion = data[1].value; |
|
|
this.uom = itemInfo.uom |
|
|
this.uom=data[0].uom; |
|
|
|
|
|
// this.uom = itemInfo.uom |
|
|
|
|
|
|
|
|
//清除其他数据 |
|
|
//清除其他数据 |
|
|
this.clearPackUnit(); |
|
|
this.clearPackUnit(); |
|
@ -470,11 +471,6 @@ |
|
|
return item.label |
|
|
return item.label |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
</script> |
|
|
</script> |
|
|