Browse Source

修改合格转隔离任务

wms3.0_pda
聂喜婷 1 year ago
parent
commit
3a484c20fb
  1. 18
      mycomponents/qty/balanceQtyEdit.vue
  2. 3
      pages/inventoryMove/coms/comInventoryDetailCard.vue
  3. 8
      pages/inventoryMove/coms/comMove.vue
  4. 4
      pages/inventoryMove/coms/comMoveJob.vue
  5. 5
      pages/inventoryMove/coms/comMoveRecord.vue
  6. 64
      pages/inventoryMove/job/inventoryMoveDetail.vue
  7. 2
      pages/inventoryMove/job/okToHoldMoveJob.vue
  8. 2
      static/config.json

18
mycomponents/qty/balanceQtyEdit.vue

@ -35,7 +35,8 @@
<view class="uni-flex uni-row space-between padding title u-col-center"> <view class="uni-flex uni-row space-between padding title u-col-center">
<text>数量 : </text> <text>数量 : </text>
<view class="uni-flex uni-row uni-center" style="align-items: center;"> <view class="uni-flex uni-row uni-center" style="align-items: center;">
<input class="qty_input" v-model="allQty" :focus="true" type="number" @confirm="confirm()" /> <input class="qty_input" v-model="allQty" :focus="true" type="number"
@confirm="confirm()" />
<uom :uom="dataContent.uom"></uom> <uom :uom="dataContent.uom"></uom>
</view> </view>
</view> </view>
@ -48,7 +49,8 @@
</view> </view>
</view> </view>
<u-line /> <u-line />
<view v-if="isShowStatus" class="uni-flex uni-row space-between title u-col-center" style="padding-left: 30rpx;"> <view v-if="isShowStatus" class="uni-flex uni-row space-between title u-col-center"
style="padding-left: 30rpx;">
<text>库存状态 : </text> <text>库存状态 : </text>
<view class="uni-flex uni-row uni-center" style="align-items: center;"> <view class="uni-flex uni-row uni-center" style="align-items: center;">
<balanceStatus ref="balanceStatus" :status="inventoryStatus" <balanceStatus ref="balanceStatus" :status="inventoryStatus"
@ -126,9 +128,9 @@
this.inventoryStatus = this.dataContent.inventoryStatus this.inventoryStatus = this.dataContent.inventoryStatus
this.toInventoryStatus = this.dataContent.toInventoryStatus this.toInventoryStatus = this.dataContent.toInventoryStatus
this.allQty = Number(handleQty) this.allQty = Number(handleQty)
setTimeout(res=>{ setTimeout(res => {
this.$refs.popup.open('bottom') this.$refs.popup.open('bottom')
},500) }, 500)
}, },
closeEditPopup() { closeEditPopup() {
this.$refs.popup.close() this.$refs.popup.close()
@ -141,7 +143,7 @@
this.closeEditPopup(); this.closeEditPopup();
}, },
calcQty(val) { calcQty(val) {
if(val>0){ if (val > 0) {
this.allQty = val * Number(this.dataContent.stdPackQty); this.allQty = val * Number(this.dataContent.stdPackQty);
} }
}, },
@ -162,8 +164,10 @@
} }
}, },
callback() { callback() {
this.dataContent.toInventoryStatus = this.inventoryStatus let qty = Number(this.allQty);
this.$emit("confirm", Number(this.allQty)); this.dataContent.toInventoryStatus = this.inventoryStatus;
this.dataContent.handleQty = qty;
this.$emit("confirm", qty);
this.closeEditPopup(); this.closeEditPopup();
}, },
updateStatus(value) { updateStatus(value) {

3
pages/inventoryMove/coms/comInventoryDetailCard.vue

@ -124,7 +124,8 @@
}); });
}, },
confirm(qty) { confirm(qty) {
this.editItem.qty = qty; // this.editItem.handleQty=qty;
//this.editItem.qty = qty;
this.$emit('updateData') this.$emit('updateData')
}, },
showLocation(item) { showLocation(item) {

8
pages/inventoryMove/coms/comMove.vue

@ -287,7 +287,6 @@
this.toWarehouseCode = "" this.toWarehouseCode = ""
}, },
commit() { commit() {
if (this.toLocationCode == "") { if (this.toLocationCode == "") {
this.showMessage("请先选择目标库位") this.showMessage("请先选择目标库位")
return; return;
@ -373,7 +372,6 @@
detail.itemDesc2 = detail.package.itemDesc2; detail.itemDesc2 = detail.package.itemDesc2;
detail.fromInventoryStatus = detail.inventoryStatus; detail.fromInventoryStatus = detail.inventoryStatus;
// detail.toInventoryStatus = this.toInventoryStatus;
detail.fromPackingNumber = info.packingNumber; detail.fromPackingNumber = info.packingNumber;
detail.toPackingNumber = info.packingNumber; detail.toPackingNumber = info.packingNumber;
@ -385,7 +383,11 @@
detail.toBatch = info.batch; detail.toBatch = info.batch;
detail.fromLocationCode = detail.locationCode; detail.fromLocationCode = detail.locationCode;
detail.toLocationCode = detail.toLocationCode;
if (this.businessType != '') {
detail.toLocationCode = this.toLocationCode;
detail.toInventoryStatus = this.toInventoryStatus;
}
subList.push(detail) subList.push(detail)
} }

4
pages/inventoryMove/coms/comMoveJob.vue

@ -200,11 +200,9 @@
}) })
}, },
openJobDetail(item) { openJobDetail(item) {
uni.navigateTo({ uni.navigateTo({
url: './inventoryMoveDetail?id=' + item.id + '&status=' + item.status url: './inventoryMoveDetail?id=' + item.id + '&status=' + item.status+'&businessTypeCode='+this.businessTypeCode
}); });
}, },

5
pages/inventoryMove/coms/comMoveRecord.vue

@ -24,7 +24,8 @@
</view> </view>
</uni-collapse-item> </uni-collapse-item>
</uni-collapse> </uni-collapse>
<balanceQtyEdit ref="balanceQtyEdit" @confirm="confirm" :isShowStatus="isShowStatus" :allowEditStatus="allowEditStatus"> <balanceQtyEdit ref="balanceQtyEdit" @confirm="confirm" :isShowStatus="isShowStatus"
:allowEditStatus="allowEditStatus">
</balanceQtyEdit> </balanceQtyEdit>
<job-detail-popup ref="winHint" :dataContent="showItem"></job-detail-popup> <job-detail-popup ref="winHint" :dataContent="showItem"></job-detail-popup>
<comMessage ref="comMessage"></comMessage> <comMessage ref="comMessage"></comMessage>
@ -170,7 +171,9 @@
}); });
}, },
confirm(qty) { confirm(qty) {
debugger;
this.editItem.qty = qty; this.editItem.qty = qty;
this.editItem.handleQty = qty;
this.$emit('updateData') this.$emit('updateData')
} }
} }

64
pages/inventoryMove/job/inventoryMoveDetail.vue

@ -9,6 +9,7 @@
</view> </view>
<u-line color="#D8D8D8" style="margin-bottom: 15rpx;margin-top: 10rpx;"></u-line> <u-line color="#D8D8D8" style="margin-bottom: 15rpx;margin-top: 10rpx;"></u-line>
</view> </view>
<view class="page-main"> <view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll"> <scroll-view scroll-y="true" class="page-main-scroll">
<view class="detail-list" v-for="(item, index) in detailSource" :key="item.id"> <view class="detail-list" v-for="(item, index) in detailSource" :key="item.id">
@ -63,7 +64,7 @@
navigateBack, navigateBack,
getCurrDateTime, getCurrDateTime,
getPackingNumberAndBatchByList, getPackingNumberAndBatchByList,
getInventoryStatusName getInventoryStatusName,
} from '@/common/basic.js'; } from '@/common/basic.js';
import winScanButton from '@/mycomponents/scan/winScanButton.vue' import winScanButton from '@/mycomponents/scan/winScanButton.vue'
@ -77,7 +78,7 @@
export default { export default {
name: 'returnDetail', name: 'inventoryMoveDetail',
components: { components: {
winScanButton, winScanButton,
winScanPack, winScanPack,
@ -99,11 +100,18 @@
toLocationInfo: {}, toLocationInfo: {},
businessTypeInfo: {}, businessTypeInfo: {},
locationTypeList: [], locationTypeList: [],
managementList: [] managementList: [],
businessTypeCode: '',
toLocationCode: '',
toinventoryStatus: ''
}; };
},
props: {
}, },
onLoad(option) { onLoad(option) {
this.id = option.id; this.id = option.id;
this.businessTypeCode = option.businessTypeCode;
if (this.id != undefined) { if (this.id != undefined) {
// // // //
if (option.status == "1") { if (option.status == "1") {
@ -114,6 +122,7 @@
} else { } else {
this.getDetail(); this.getDetail();
} }
this.initData();
} }
}, },
// //
@ -151,6 +160,38 @@
}, },
methods: { methods: {
initData() {
var name = ""
if (this.businessTypeCode == "Move") {
name = "库存转移";
} else if (this.businessTypeCode == "HoldToOk") {
name = "隔离转合格";
this.toLocationCode = '';
this.toinventoryStatus = 'Ok';
} else if (this.businessTypeCode == "HoldToScrap") {
name = "隔离转报废";
this.toLocationCode = 'Scrap';
this.toinventoryStatus = 'Scrap';
} else if (this.businessTypeCode == "OkToHold") {
name = "合格转隔离";
this.toLocationCode = 'Hold';
this.toinventoryStatus = 'Hold';
} else if (this.businessTypeCode == "OktoScrap") {
name = "合格转报废";
this.toLocationCode = 'Scrap';
this.toinventoryStatus = 'Scrap';
} else if (this.businessTypeCode == "ScrapToHold") {
name = "报废转隔离";
this.toLocationCode = 'Hold';
this.toinventoryStatus = 'Hold';
}
uni.setNavigationBarTitle({
title: name + '详情'
})
},
// //
receive(callback) { receive(callback) {
uni.showLoading({ uni.showLoading({
@ -209,7 +250,6 @@
this.$refs.jobDetailPopup.openPopup(item) this.$refs.jobDetailPopup.openPopup(item)
}, },
updateData() { updateData() {
this.calcHandleQty(); this.calcHandleQty();
}, },
@ -273,7 +313,7 @@
if (res) { if (res) {
itemDetail.scaned = true; itemDetail.scaned = true;
itemDetail.handleQty = Number(result.balance.qty); itemDetail.handleQty = Number(result.balance.qty);
itemDetail.toInventoryStatus = result.balance.inventoryStatus; itemDetail.fromInventoryStatus = result.balance.inventoryStatus;
itemDetail.balance = result.balance; itemDetail.balance = result.balance;
itemDetail.balance.balanceQty = Number(result.balance.qty); itemDetail.balance.balanceQty = Number(result.balance.qty);
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) itemDetail.balance.stdPackQty = Number(result.package.stdPackQty)
@ -293,7 +333,7 @@
} else { } else {
itemDetail.scaned = true; itemDetail.scaned = true;
itemDetail.handleQty = Number(result.balance.qty); itemDetail.handleQty = Number(result.balance.qty);
itemDetail.toInventoryStatus = result.balance.inventoryStatus; itemDetail.fromInventoryStatus = result.balance.inventoryStatus;
itemDetail.balance = result.balance; itemDetail.balance = result.balance;
itemDetail.balance.balanceQty = Number(result.balance.qty); itemDetail.balance.balanceQty = Number(result.balance.qty);
itemDetail.balance.stdPackQty = Number(result.package.stdPackQty) itemDetail.balance.stdPackQty = Number(result.package.stdPackQty)
@ -374,19 +414,19 @@
}, },
setPrecisionStrategParams(){ setPrecisionStrategParams() {
var itemList = [] var itemList = []
this.detailSource.forEach(item => { this.detailSource.forEach(item => {
item.subList.forEach(detail => { item.subList.forEach(detail => {
if (detail.scaned) { if (detail.scaned) {
var filterResult = itemList.filter(res => { var filterResult = itemList.filter(res => {
if (res.itemCode == item.itemCode if (res.itemCode == item.itemCode &&
&&res.locationCode == detail.toLocationCode) { res.locationCode == detail.toLocationCode) {
return res return res
} }
}) })
// //
if(filterResult.length==0){ if (filterResult.length == 0) {
var result = { var result = {
itemCode: item.itemCode, itemCode: item.itemCode,
locationCode: detail.toLocationCode locationCode: detail.toLocationCode
@ -412,8 +452,8 @@
detail.toPackingNumber = info.packingNumber; detail.toPackingNumber = info.packingNumber;
detail.toBatch = info.batch; detail.toBatch = info.batch;
detail.toContainerNumber = ''; detail.toContainerNumber = '';
// detail.toLocationCode = this.toLocationCode;
detail.toLocationCode = detail.toLocationCode; detail.toinventoryStatus=this.toinventoryStatus;
subList.push(detail) subList.push(detail)
} }
}) })

2
pages/inventoryMove/job/okToHoldMoveJob.vue

@ -1,6 +1,6 @@
<template> <template>
<view class="page-wraper"> <view class="page-wraper">
<comMoveJob ref="comMoveJob" businessTypeCode='OkToHold'> </comMoveJob> <comMoveJob ref="comMoveJob" businessTypeCode='OkToHold' > </comMoveJob>
</view> </view>
</template> </template>

2
static/config.json

@ -18,7 +18,7 @@
"request_url": { "request_url": {
"name": "request_url", "name": "request_url",
"value": "http://192.168.0.176:12080/admin-api", "value": "http://dev.ccwin-in.com:25100/api/admin-api",
"dev2": "http://192.168.0.157:12080/admin-api", "dev2": "http://192.168.0.157:12080/admin-api",
"chefang": "http://192.168.0.176:12080/admin-api", "chefang": "http://192.168.0.176:12080/admin-api",
"chenxinming": "http://192.168.0.230:12080/admin-api", "chenxinming": "http://192.168.0.230:12080/admin-api",

Loading…
Cancel
Save