Browse Source

Merge branch 'intex' of http://dev.ccwin-in.com:3000/sfms3.0/sfms3.0-uniapp into intex

intex_online20241111
lijuncheng 3 months ago
parent
commit
a403b5db5d
  1. 2
      src/mycomponents/scan/winScanLocation.vue
  2. 3
      src/mycomponents/scan/winScanPackAndLocation.vue
  3. 40
      src/pages/inventoryMove/coms/comMoveRecord.vue
  4. 20
      src/pages/inventoryMove/coms/okToHoldRecordPack.vue
  5. 8
      src/pages/productReceipt/record/productReceiptRecordByBatch.vue

2
src/mycomponents/scan/winScanLocation.vue

@ -92,7 +92,6 @@
title: '扫描中...', title: '扫描中...',
mask: true mask: true
}); });
console.log(111,result)
let label = result.label; let label = result.label;
if (label.barType === 'QRCode') { if (label.barType === 'QRCode') {
this.code = label.locationCode; this.code = label.locationCode;
@ -104,7 +103,6 @@
this.showErrorMessage("扫描库位为空,请输入正确的库位") this.showErrorMessage("扫描库位为空,请输入正确的库位")
return return
} }
console.log(888,this.code)
getBasicLocationByCode(this.code).then(res => { getBasicLocationByCode(this.code).then(res => {
uni.hideLoading(); uni.hideLoading();

3
src/mycomponents/scan/winScanPackAndLocation.vue

@ -339,7 +339,7 @@
this.chooseWhich = '2' this.chooseWhich = '2'
if(!result.label.itemCode){ if(!result.label.itemCode){
this.showErrorMessage('扫描标签不对,请重新扫描') this.showErrorMessage('扫描标签不对,请重新扫描')
this.$emit('clearItemCode',result.label.code) this.$emit('clearItemCode',result.label)
return return
} }
if (res.data && res.data.list && res.data.list.length > 1) { if (res.data && res.data.list && res.data.list.length > 1) {
@ -397,6 +397,7 @@
mustHavaBalance(datas) { mustHavaBalance(datas) {
if (datas.length == 0) { if (datas.length == 0) {
this.showErrorMessage(this.getQueryCondition() + '\n未查找到库存记录', res => { this.showErrorMessage(this.getQueryCondition() + '\n未查找到库存记录', res => {
this.$emit('clearItemCode',this.scanResult)
this.packGetFocus(); this.packGetFocus();
}) })
} else if (datas.length == 1) { } else if (datas.length == 1) {

40
src/pages/inventoryMove/coms/comMoveRecord.vue

@ -32,7 +32,7 @@
</view> </view>
</view> </view>
</view> </view>
<win-scan-button @goScan='openScanPopup'></win-scan-button> <win-scan-button @goScan='showFromLocationPopup'></win-scan-button>
</view> </view>
<!-- 合格转隔离单独的弹窗--> <!-- 合格转隔离单独的弹窗-->
<okToHoldRecordPack ref="okToHoldRecordPackRef" :fromLocationCodeProps='fromLocationCode' :itemCodeProps='itemCode' :batchProps='batch' :showOnePop='showOnePop' :isClearFromLocationCode='isClearFromLocationCode' :isClearItemCode='isClearItemCode' @showFromLocationPopup='showFromLocationPopup' @itemCodeClick='openScanPopup' @confirm='okToHoldRecordPackConfirm' @getInputMsgResult="getInputMsgResult" @itemCodeScanMsg='itemCodeScanMsg'></okToHoldRecordPack> <okToHoldRecordPack ref="okToHoldRecordPackRef" :fromLocationCodeProps='fromLocationCode' :itemCodeProps='itemCode' :batchProps='batch' :showOnePop='showOnePop' :isClearFromLocationCode='isClearFromLocationCode' :isClearItemCode='isClearItemCode' @showFromLocationPopup='showFromLocationPopup' @itemCodeClick='openScanPopup' @confirm='okToHoldRecordPackConfirm' @getInputMsgResult="getInputMsgResult" @itemCodeScanMsg='itemCodeScanMsg'></okToHoldRecordPack>
@ -160,12 +160,7 @@
this.businessType = res.businessType; this.businessType = res.businessType;
this.fromLocationAreaTypeList = res.fromLocationAreaTypeList; this.fromLocationAreaTypeList = res.fromLocationAreaTypeList;
this.toLocationAreaTypeList = res.toLocationAreaTypeList; this.toLocationAreaTypeList = res.toLocationAreaTypeList;
if(this.showOnePop){
console.log(this.$refs.okToHoldRecordPackRef)
this.$refs.okToHoldRecordPackRef.show = true
}else{
this.showFromLocationPopup();
}
} else { } else {
this.showErrorMessage(res.message) this.showErrorMessage(res.message)
} }
@ -242,6 +237,7 @@
}, },
openScanPopup() { openScanPopup() {
if (this.fromLocationCode == "") { if (this.fromLocationCode == "") {
this.showFromLocationPopup(); this.showFromLocationPopup();
return return
@ -250,14 +246,21 @@
}, },
showFromLocationPopup() { showFromLocationPopup() {
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.scanFromLocationCode.openScanPopup(); if(this.showOnePop){
this.$refs.okToHoldRecordPackRef.showOne = true
}else{
this.$refs.scanFromLocationCode.openScanPopup();
}
}) })
}, },
getFromLocation(location) { getFromLocation(location) {
this.fromLocationCode = location.code; this.fromLocationCode = location.code;
this.fromLocationInfo = location; this.fromLocationInfo = location;
if(!this.showOnePop){ if(!this.showOnePop){
this.openScanPopup(); this.openScanPopup();
}else{
this.itemCode =''
this.batch =''
} }
}, },
getToLocation(location, code) { getToLocation(location, code) {
@ -265,12 +268,11 @@
this.toLocationInfo = location; this.toLocationInfo = location;
}, },
getScanResult(result,managementType) { getScanResult(result,managementType) {
console.log(356,result)
if(this.showOnePop){ if(this.showOnePop){
this.itemCode= result.balance.itemCode this.itemCode= result.balance.itemCode
this.batch = result.balance.batch this.batch = result.balance.batch
console.log(357,this.itemCode) this.isClearItemCode = false
console.log(358,this.batch ) debugger
this.getResult = result// this.getResult = result//
this.$refs.scanPopup.closeScanPopup() this.$refs.scanPopup.closeScanPopup()
@ -419,20 +421,20 @@
calcHandleQty(this.detailSource); calcHandleQty(this.detailSource);
}, },
getInputMsgResult(result,fromWitch){ getInputMsgResult(result,fromWitch){
console.log('pooo',result)
if(fromWitch == 'fromLocationScanMsg'){ if(fromWitch == 'fromLocationScanMsg'){
this.isClearFromLocationCode = false this.$refs.scanFromLocationCode.getScanResult(result) }else if(fromWitch == 'itemCodeScanMsg'){ this.isClearFromLocationCode = false this.$refs.scanFromLocationCode.getScanResult(result) }else if(fromWitch == 'itemCodeScanMsg'){ result.fromLocationCode = this.fromLocationCode this.$refs.scanPopup.getScanResult(result) }
console.log(7878,this.fromLocationCode) result.fromLocationCode = this.fromLocationCode this.$refs.scanPopup.getScanResult(result) }
}, },
// //
clearFromLocation(fromLocationCodeParams){ clearFromLocation(fromLocationCodeParams){
this.fromLocationCode = fromLocationCodeParams this.fromLocationCode = fromLocationCodeParams
console.log('rwyrwey',this.fromLocationCode) this.itemCode =''
this.batch =''
this.isClearFromLocationCode = true this.isClearFromLocationCode = true
}, },
// //
clearItemCode(itemCodeParams){ clearItemCode(label){
this.itemCode = itemCodeParams this.itemCode = label.itemCode
this.batch =''
this.isClearItemCode = true this.isClearItemCode = true
}, },
showErrorMessage(message) { showErrorMessage(message) {
@ -595,8 +597,6 @@
var info = getPackingNumberAndBatchByList(this.managementList, detail.itemCode, var info = getPackingNumberAndBatchByList(this.managementList, detail.itemCode,
detail.packingNumber, detail.toLocationCode, detail.batch); detail.packingNumber, detail.toLocationCode, detail.batch);
var submitItem = deepCopyData(detail) var submitItem = deepCopyData(detail)
console.log(233,submitItem)
console.log(244,info)
submitItem.itemCode = detail.itemCode; submitItem.itemCode = detail.itemCode;
submitItem.itemName = detail.package.itemName; submitItem.itemName = detail.package.itemName;
submitItem.itemDesc1 = detail.package.itemDesc1; submitItem.itemDesc1 = detail.package.itemDesc1;

20
src/pages/inventoryMove/coms/okToHoldRecordPack.vue

@ -9,14 +9,14 @@
</view> </view>
<view class="item"> <view class="item">
<view class="label">来源库位</view> <view class="label">来源库位</view>
<view class="value"><u-input v-model="fromLocationCode" @confirm="fromLocationScanMsg"></u-input></view> <view class="value"><u-input v-model="fromLocationCode" @confirm="fromLocationScanMsg" clearable></u-input></view>
<view class="searchIcon"> <view class="searchIcon">
<image src="/static/search.svg" mode="" @click="fromLocationClick"/> <image src="/static/search.svg" mode="" @click="fromLocationClick"/>
</view> </view>
</view> </view>
<view class="item"> <view class="item">
<view class="label">零件</view> <view class="label">零件</view>
<view class="value"><u-input v-model="itemCode" @confirm="itemCodeScanMsg"></u-input></view> <view class="value"><u-input v-model="itemCode" @confirm="itemCodeScanMsg" clearable></u-input></view>
<view class="searchIcon"> <view class="searchIcon">
<image src="/static/search.svg" mode="" @click="itemCodeClick"/> <image src="/static/search.svg" mode="" @click="itemCodeClick"/>
</view> </view>
@ -65,12 +65,11 @@
emits: ["showFromLocationPopup",'itemCodeClick','confirm','getInputMsgResult'], emits: ["showFromLocationPopup",'itemCodeClick','confirm','getInputMsgResult'],
data() { data() {
return { return {
show:true,
handleQty:0, handleQty:0,
fromLocationCode:'', fromLocationCode:'',
itemCode:'', itemCode:'',
batch:'', batch:'',
showOne:true showOne:false
} }
}, },
props: { props: {
@ -201,12 +200,13 @@
that.boxfocus = false; that.boxfocus = false;
}); });
}, },
onClear(){
console.log(111)
}
}, },
watch: { watch: {
fromLocationCodeProps:{ fromLocationCodeProps:{
handler(newVal, oldVal) { handler(newVal, oldVal) {
console.log('wer',this.isClearFromLocationCode)
console.log('wer',newVal)
if(this.isClearFromLocationCode){ if(this.isClearFromLocationCode){
this.fromLocationCode='' this.fromLocationCode=''
}else{ }else{
@ -220,15 +220,17 @@
handler(newVal, oldVal) { handler(newVal, oldVal) {
if(this.isClearItemCode){ if(this.isClearItemCode){
this.itemCode='' this.itemCode=''
this.batch=''
}else{ }else{
this.itemCode = newVal this.itemCode = newVal
} }
}, },
}, },
batchProps(newVal) { batchProps(newVal) {
this.batch = newVal if(this.isClearItemCode){
console.log(999,this.batch) this.batch=''
}else{
this.batch = newVal
}
}, },
} }
} }

8
src/pages/productReceipt/record/productReceiptRecordByBatch.vue

@ -145,13 +145,17 @@
getScanResult(result) { getScanResult(result) {
let label = result.label; let label = result.label;
let pack = result.package; let pack = result.package;
if(!result.label.itemCode){
this.showErrorMessage('扫描标签不对,请重新扫描')
this.$emit('clearItemCode',result.label)
return
}
var item = this.detailSource.find(res => { var item = this.detailSource.find(res => {
if (res.itemCode == label.itemCode) { if (res.itemCode == label.itemCode) {
return res return res
} }
}) })
if (item == undefined) { if (item == undefined) {
var itemp = this.createItemInfo(label, pack); var itemp = this.createItemInfo(label, pack);
let newDetail = this.createDetailInfo(label, pack); let newDetail = this.createDetailInfo(label, pack);

Loading…
Cancel
Save