lijuncheng 1 year ago
parent
commit
76cbf82798
  1. 2
      mycomponents/container/targetContainer.vue
  2. 2
      mycomponents/recommend/recommend.vue
  3. 2
      pages.json
  4. 9
      pages/inspect/coms/inspectComDetailCard.vue
  5. 6
      pages/pallet/record/bindPalletRecord.vue
  6. 120
      pages/productionReturn/job/returnDetail.vue
  7. 65
      pages/purchaseReturn/record/returnRecord.vue
  8. 1
      static/config.json

2
mycomponents/container/targetContainer.vue

@ -3,7 +3,7 @@
padding-bottom: 15rpx;
padding-left: 10rpx;
padding-right: 10rpx;
font-size:32rpx;background-color: #fff;">
font-size:32rpx;">
<text style="font-size: 35rpx;">{{title}} </text>
<view class="uni-flex u-col-center" @click="showLocation">
<text style="color:#3FBAFF;font-size: 35rpx;" v-if="containerCode==''&&isShowEdit==true">&nbsp 请扫描</text>

2
mycomponents/recommend/recommend.vue

@ -11,7 +11,7 @@
</location>
</view>
<view>
<!-- ||detail.handleQty==0 -->
<!-- ||detail.handleQty==0 可能会有扫描到0的情况-->
<recommend-qty v-if="detail.handleQty==null || detail.handleQty==undefined" :dataContent="detail"
:isShowStdPack="false"></recommend-qty>
<compare-qty v-else :dataContent="detail" :recommendQty="Number(detail.qty)"

2
pages.json

@ -230,7 +230,7 @@
{
"path": "pages/inspect/job/inspectFullDetail",
"style": {
"navigationBarTitleText": "到货检验(全检)详情",
"navigationBarTitleText": "全检检验详情",
"enablePullDownRefresh": true
}
},

9
pages/inspect/coms/inspectComDetailCard.vue

@ -32,7 +32,8 @@
<uni-collapse ref="collapse1" @change="">
<uni-collapse-item :open="true">
<template v-slot:title>
<item-compare-qty :dataContent="dataContent" :handleQty="Number(dataContent.handleQty)" :isShowStdPack="false">
<item-compare-qty :dataContent="dataContent" :handleQty="Number(dataContent.handleQty)"
:isShowStdPack="false">
</item-compare-qty>
<view class="" style="margin-left: 20rpx; ">
<batch :batch="jobContent.batch"></batch>
@ -45,7 +46,8 @@
:right-options="item.scaned?scanOptions:detailOptions">
<recommend :detail="item" :isShowPack="isShowPack" :isShowBatch="isShowBatch"
:isShowFromLocation="isShowLocation"></recommend>
<view v-if="item.failedQty>0||item.crackQty>0" :class="item.scaned?'scan_view':''" style="font-size: 32rpx;padding-left: 2px;">
<view v-if="item.failedQty>0||item.crackQty>0" :class="item.scaned?'scan_view':''"
style="font-size: 32rpx;padding-left: 2px;">
<view class="cell_box uni-flex uni-row">
<view class="cell_info uni-flex uni-row">
<view class="text_lightblue">
@ -203,7 +205,8 @@
item.notPassedQty = 0;
item.inspectResult = ""
item.failedReason = ""
item.handleQty = 0;
// item.handleQty = 0;
item.handleQty = null;
item.photos = ""
this.$forceUpdate()
this.$emit('remove', item)

6
pages/pallet/record/bindPalletRecord.vue

@ -16,13 +16,13 @@
</scroll-view>
</view>
<targetContainer ref="scanContainer" title="托盘" :containerCode="containerCode" @getContainer="getContainer">
</targetContainer>
<view class="page-footer">
<view class="uni-flex u-col-center space-between padding_10"
style="background-color:ghostwhite; width: 100%; ">
<view class="">
<targetContainer ref="scanContainer" title="托盘" :containerCode="containerCode"
@getContainer="getContainer">
</targetContainer>
</view>
<view class=" uni-flex uni-row">
<button class="btn_single_commit" hover-class="btn_commit_after" @click="commit">提交</button>

120
pages/productionReturn/job/returnDetail.vue

@ -9,6 +9,7 @@
</view>
<u-line color="#D8D8D8" style="margin-bottom: 15rpx;margin-top: 10rpx;"></u-line>
</view>
<view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll">
<view class="detail-list" v-for="(item, index) in detailSource" :key="item.id">
@ -23,7 +24,6 @@
</scroll-view>
</view>
<view class="page-footer">
<view class="uni-flex u-col-center space-between padding_10"
style="background-color:ghostwhite; width: 100%; ">
@ -39,7 +39,8 @@
</view>
<win-scan-button @goScan='openScanPopup'></win-scan-button>
<win-scan-pack-and-location ref="scanPopup" @getResult='getScanResult'></win-scan-pack-and-location>
<!-- <win-scan-pack-and-location ref="scanPopup" @getResult='getScanResult'></win-scan-pack-and-location> -->
<win-scan-pack ref="scanPopup" @getResult='getScanResult'></win-scan-pack>
<detail-info-popup ref="detailInfoPopup"></detail-info-popup>
<com-message ref="comMessage"></com-message>
</view>
@ -81,13 +82,15 @@
import detailInfoPopup from '@/pages/productionReturn/coms/detailInfoPopup.vue'
import comMessage from '@/mycomponents/common/comMessage.vue'
import jobTop from '@/mycomponents/job/jobTop.vue'
import winScanPack from '@/mycomponents/scan/winScanPack.vue'
export default {
name: 'receipt_detail',
components: {
winScanButton,
requiredLocation,
winScanPackAndLocation,
// winScanPackAndLocation,
winScanPack,
comDetailCard,
detailInfoPopup,
comMessage,
@ -228,25 +231,28 @@
},
openScanPopup() {
let fromlocationCode = '';
let fromlocationList = [];
for (var i = 0; i < this.detailSource.length; i++) {
let item = this.detailSource[i];
item.subList.forEach(l => {
//
var location = fromlocationList.filter(res => res.fromLocationCode != l.fromLocationCode)
if (location.length == 0) {
fromlocationList.push(l.fromLocationCode);
}
//
if (fromlocationCode == '') {
if (!l.scaned) {
fromlocationCode = l.fromLocationCode;
}
}
})
}
this.$refs.scanPopup.openScanPopupForJob(fromlocationCode, fromlocationList, this.jobContent);
this.$refs.scanPopup.openScanPopup();
// let fromlocationCode = '';
// let fromlocationList = [];
// for (var i = 0; i < this.detailSource.length; i++) {
// let item = this.detailSource[i];
// item.subList.forEach(l => {
// //
// var location = fromlocationList.filter(res => res.fromLocationCode != l.fromLocationCode)
// if (location.length == 0) {
// fromlocationList.push(l.fromLocationCode);
// }
// //
// if (fromlocationCode == '') {
// if (!l.scaned) {
// fromlocationCode = l.fromLocationCode;
// }
// }
// })
// }
// this.$refs.scanPopup.openScanPopupForJob(fromlocationCode, fromlocationList, this.jobContent);
},
@ -270,32 +276,40 @@
if (itemDetail.scaned) {
this.showErrorMessage("箱码[" + packingNumber + "]" + "批次[" + batch + "]已经扫描")
} else {
let balanceStatus = getInventoryStatusName(result.balance.inventoryStatus);
let itemStatus = getInventoryStatusName(itemDetail.inventoryStatus);
if (itemDetail.inventoryStatus != result.balance.inventoryStatus) {
this.showQuestionMessage('实际库存状态[' + balanceStatus + ']与推荐库存状态[' + itemStatus +
']不一致,是否继续上架?', res => {
if (res) {
itemDetail.scaned = true;
itemDetail.handleQty = Number(result.balance.qty)
itemDetail.balance = result.balance;
itemDetail.balance.balanceQty = result.balance.qty;
itemDetail.balance.stdPackQty = result.package.stdPackQty
itemDetail.balance.stdPackUnit = result.package.stdPackUnit
itemDetail.handleQty = Number(result.package.qty)
itemDetail.stdPackQty = result.package.stdPackQty
itemDetail.stdPackUnit = result.package.stdPackUnit
this.calcHandleQty();
} else {
this.scanPopupGetFocus();
}
});
} else {
itemDetail.scaned = true;
itemDetail.handleQty = Number(result.balance.qty)
itemDetail.balance = result.balance;
itemDetail.balance.balanceQty = result.balance.qty;
itemDetail.balance.stdPackQty = result.package.stdPackQty
itemDetail.balance.stdPackUnit = result.package.stdPackUnit
this.calcHandleQty();
}
//退,退000000 --nxt
// let balanceStatus = getInventoryStatusName(result.balance.inventoryStatus);
// let itemStatus = getInventoryStatusName(itemDetail.inventoryStatus);
// if (itemDetail.inventoryStatus != result.balance.inventoryStatus) {
// this.showQuestionMessage('[' + balanceStatus + '][' + itemStatus +
// '],?', res => {
// if (res) {
// itemDetail.scaned = true;
// itemDetail.handleQty = Number(result.balance.qty)
// itemDetail.balance = result.balance;
// itemDetail.balance.balanceQty = result.balance.qty;
// itemDetail.balance.stdPackQty = result.package.stdPackQty
// itemDetail.balance.stdPackUnit = result.package.stdPackUnit
// this.calcHandleQty();
// } else {
// this.scanPopupGetFocus();
// }
// });
// } else {
// itemDetail.scaned = true;
// itemDetail.handleQty = Number(result.balance.qty)
// itemDetail.balance = result.balance;
// itemDetail.balance.balanceQty = result.balance.qty;
// itemDetail.balance.stdPackQty = result.package.stdPackQty
// itemDetail.balance.stdPackUnit = result.package.stdPackUnit
// this.calcHandleQty();
// }
}
}
}
@ -451,14 +465,24 @@
this.$refs.scanPopup.closeScanPopup();
},
// scanPopupGetFocus() {
// this.$refs.scanPopup.getFocus();
// },
// scanPopupLoseFocus() {
// this.$refs.scanPopup.loseFocus();
// },
scanPopupGetFocus() {
this.$refs.scanPopup.packGetFocus();
this.$refs.scanPopup.getfocus();
},
scanPopupLoseFocus() {
this.$refs.scanPopup.packLoseFocus();
this.$refs.scanPopup.losefocus();
},
showQuestionMessage(message, callback) {
setTimeout(r => {
this.scanPopupLoseFocus();

65
pages/purchaseReturn/record/returnRecord.vue

@ -223,6 +223,7 @@
if (this.detailSource.length > 0 && this.detailSource[0].subList.length > 0) {
console.log("提交参数", JSON.stringify(params));
//
if (this.fromType == "requestType") {
var params = this.setRequestParams();
console.log("提交" + JSON.stringify(params))
@ -239,34 +240,25 @@
})
} else {
var itemCodes = []
this.detailSource.forEach(item => {
itemCodes.push(item.itemCode)
})
//
//退
//
getManagementPrecisions(itemCodes, this.toLocationCode, res => {
if (res.success) {
this.managementList = res.list;
var params = this.setRecordParams(true)
console.log("提交参数", JSON.stringify(params));
// purchaseReturnRecordSubmit(params).then(res => {
// uni.hideLoading()
// if (res.data) {
// this.showCommitSuccessMessage("<br>退" + res.data )
// } else {
// this.showErrorMessage(""+res.msg)
// }
// }).catch(error => {
// uni.hideLoading()
// this.showErrorMessage(error)
// })
purchaseReturnRecordSubmit(params).then(res => {
uni.hideLoading()
if (res.data) {
this.showCommitSuccessMessage("提交成功<br>生成采购退货记录" + res.data)
} else {
uni.hideLoading();
this.showErrorMessage(res.message);
this.showErrorMessage("提交失败" + res.msg)
}
});
}).catch(error => {
uni.hideLoading()
this.showErrorMessage(error)
})
}
@ -279,31 +271,32 @@
setRecordParams(queryModel) {
var subList = []
var creator = this.$store.state.user.id
this.dataContent.creator = creator;
this.detailSource.forEach(item => {
item.subList.forEach(detail => {
if (detail.scaned) {
if (queryModel) {
var info = getPackingNumberAndBatch(this.managementList, detail.itemCode,
detail.packingNumber, detail.batch);
detail.toPackingNumber = info.packingNumber;;
detail.toContainerNumber = detail.containerNumber
detail.toBatch = info.batch;
detail.toInventoryStatus = detail.inventoryStatus
detail.toLocationCode = this.toLocationCode
} else {
detail.toPackingNumber = detail.packingNumber;
detail.itemCode = detail.itemCode;
detail.inventoryStatus = detail.inventoryStatus;
detail.fromPackingNumber = detail.packingNumber;
detail.toPackingNumber = detail.packingNumber;;
detail.fromContainerNumber = detail.containerNumber;
detail.toContainerNumber = detail.containerNumber
detail.toBatch = detail.toBatch;
detail.toInventoryStatus = detail.inventoryStatus
detail.toLocationCode = ""
}
detail.fromBatch = detail.batch;
detail.toBatch = detail.batch;
detail.fromLocationCode = this.fromLocationCode;
detail.toLocationCode = ''; //退
subList.push(detail)
}
})
})
this.dataContent.subList = subList
this.dataContent.creator = creator;
// this.dataContent.jobNumber = '';
return this.dataContent;
},

1
static/config.json

@ -22,6 +22,7 @@
"dev2": "http://192.168.0.157:12080/admin-api",
"chefang": "http://192.168.0.180:12080/admin-api",
"chenxinming": "http://192.168.0.230:12080/admin-api",
"liuchen": "http://192.168.0.159:12080/admin-api",
"dev": "http://dev.ccwin-in.com:25100/api/admin-api",
"local": "http://localhost:12080",
"desc": "api请求地址"

Loading…
Cancel
Save