Browse Source

修改直接完工功能

hella_online_20240829
niexiting 4 months ago
parent
commit
b321a9efb7
  1. 9
      src/api/request2.js
  2. 81
      src/pages/fg/coms/comReceiptPopup.vue
  3. 1
      src/pages/index/index.vue
  4. 2
      src/uni_modules/vk-uview-ui/components/u-select/u-select.vue

9
src/api/request2.js

@ -4263,5 +4263,10 @@ export function planReceiptSubmit(params) {
}); });
} }
export function getProductionlineAndWorkStation() {
return request({
url: baseApi + "/wms/production-main/getProductionlineAndWorkStation",
method: "get",
data: {},
});
}

81
src/pages/fg/coms/comReceiptPopup.vue

@ -19,8 +19,8 @@
<view class="customerBorder" @click="showSelectLine"> <view class="customerBorder" @click="showSelectLine">
{{productionLineName}} {{productionLineName}}
</view> </view>
<u-select v-model="showProductLineSelect" mode="single-column" :list="productLineList" <u-select v-model="showProductLineSelect" mode="mutil-column-auto"
@confirm="confirmSelectLine"></u-select> :list="productLineList" @confirm="confirmSelectLine"></u-select>
<view class=""> <view class="">
<image src="/static/icons/down.svg" mode="" <image src="/static/icons/down.svg" mode=""
@ -28,8 +28,6 @@
</image> </image>
</view> </view>
</view> </view>
<view class='split_line'></view> <view class='split_line'></view>
<view class="title " style="display: flex;align-items: center;padding: 10rpx;"> <view class="title " style="display: flex;align-items: center;padding: 10rpx;">
@ -37,6 +35,7 @@
<view class="customerBorder"> <view class="customerBorder">
{{itemCode}} {{itemCode}}
</view> </view>
<view v-if="planQty>0">{{planQty}}({{getUomInfo(uom)}})</view>
<u-select v-model="showItemCodeSelect" mode="single-column" :list="itemCodeList" <u-select v-model="showItemCodeSelect" mode="single-column" :list="itemCodeList"
@confirm="confirmSelectItem"></u-select> @confirm="confirmSelectItem"></u-select>
<view class=""> <view class="">
@ -58,25 +57,23 @@
</view> </view>
</view> </view>
<view class='split_line'></view> <view class='split_line'></view>
<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"> <view class="customerBorder">
{{planQty}} {{planQty}}
</view> </view>
<view class=""> <view class="">
<image src="" mode="" <image src="" mode="" style=" width: 40rpx;height: 40rpx;margin-left: 20rpx;">
style=" width: 40rpx;height: 40rpx;margin-left: 20rpx;"
>
</image> </image>
</view> </view>
</view> </view> -->
<view class='split_line'></view> <view class='split_line'></view>
<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"> <view class="customerBorder">
{{packUnit}} {{packUnit}}
</view> </view>
<u-select v-model="showPackUnitSelect" mode="mutil-column-auto" :list="packUnitList" <u-select v-model="showPackUnitSelect" mode="mutil-column" :list="packUnitList"
@confirm="confirmSelectPackUnit"></u-select> @confirm="confirmSelectPackUnit"></u-select>
<view class=""> <view class="">
<image src="/static/icons/down.svg" mode="" <image src="/static/icons/down.svg" mode=""
@ -104,7 +101,8 @@
import { import {
getIssueJobByProductionline, getIssueJobByProductionline,
getPlaneInfoByproductLine, getPlaneInfoByproductLine,
getPackUnitByItemCode getPackUnitByItemCode,
getProductionlineAndWorkStation
} from '@/api/request2.js'; } from '@/api/request2.js';
import { import {
getPackUnitName, getPackUnitName,
@ -144,38 +142,7 @@
showPackUnitSelect: false, showPackUnitSelect: false,
itemCodeList: [], itemCodeList: [],
showItemCodeSelect: false, showItemCodeSelect: false,
packUnitList: [{ packUnitList: [],
value: 1,
label: '中国',
children: [{
value: 2,
label: '广东',
},
{
value: 5,
label: '广西',
}
]
},
{
value: 8,
label: '美国',
children: [{
value: 9,
label: '纽约',
},
{
value: 10,
label: '华盛顿',
}
]
}
]
} }
}, },
props: { props: {
@ -210,6 +177,7 @@
// this.packUnitList = [] // this.packUnitList = []
this.itemCodeList = [] this.itemCodeList = []
this.showItemCodeSelect = false this.showItemCodeSelect = false
}, },
closeRequestPopup() { closeRequestPopup() {
@ -279,12 +247,12 @@
title: "加载中", title: "加载中",
mask: true mask: true
}) })
getIssueJobByProductionline().then(res => { getProductionlineAndWorkStation().then(res => {
uni.hideLoading() uni.hideLoading()
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
res.data.forEach(item => { // res.data.forEach(item => {
item.label = item.name // item.label = item.name
}) // })
this.productLineList = res.data this.productLineList = res.data
this.showProductLineSelect = true this.showProductLineSelect = true
} else { } else {
@ -317,7 +285,8 @@
uni.hideLoading() uni.hideLoading()
if (res.data && res.data.length > 0) { if (res.data && res.data.length > 0) {
res.data.forEach(item => { res.data.forEach(item => {
item.label = item.itemCode item.label = item.itemCode + "(" + item.planQty + item.uom + ")"
item.value = item
}) })
this.itemCodeList = res.data this.itemCodeList = res.data
this.showItemCodeSelect = true this.showItemCodeSelect = true
@ -335,11 +304,17 @@
}, },
confirmSelectItem(data) { confirmSelectItem(data) {
this.itemCode = data[0].label let productionPlan = data[0].value;
var item = this.itemCodeList.find(res => res.itemCode == this.itemCode) this.itemCode = productionPlan.itemCode;
this.uom = item.uom // var item = this.itemCodeList.find(res => res.itemCode == this.itemCode)
this.planQty = item.planQty this.uom = productionPlan.uom
this.number = item.number this.planQty = productionPlan.planQty
this.number = productionPlan.number
// this.itemCode = data[0].label
// var item = this.itemCodeList.find(res => res.itemCode == this.itemCode)
// this.uom = item.uom
// this.planQty = item.planQty
// this.number = item.number
}, },
showSelectPackUnit() { showSelectPackUnit() {

1
src/pages/index/index.vue

@ -59,7 +59,6 @@
</view> </view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>

2
src/uni_modules/vk-uview-ui/components/u-select/u-select.vue

@ -415,7 +415,7 @@ export default {
&__body { &__body {
width: 100%; width: 100%;
height: 300rpx; height: 500rpx;
overflow: hidden; overflow: hidden;
background-color: #fff; background-color: #fff;

Loading…
Cancel
Save