diff --git a/src/api/httpRequest3.js b/src/api/httpRequest3.js
index e6714f5e..98afe0df 100644
--- a/src/api/httpRequest3.js
+++ b/src/api/httpRequest3.js
@@ -36,6 +36,7 @@ function service(options = {}) {
}else {
if(res.data.code==401){
uni.clearStorageSync()
+ uni.removeStorageSync('overPackageRecord') // 删除直接翻包中缓存的来源库位
removeToken();
uni.reLaunch({
url: '/pages/login/index'
diff --git a/src/mycomponents/scan/winScanLocation.vue b/src/mycomponents/scan/winScanLocation.vue
index 24515c2e..8b0ae440 100644
--- a/src/mycomponents/scan/winScanLocation.vue
+++ b/src/mycomponents/scan/winScanLocation.vue
@@ -19,6 +19,8 @@
+
+
@@ -67,8 +69,15 @@
this.$refs.popup.open('bottom')
}, 500)
},
+ openScanPopupSimulate(location) {
+ this.$refs.comscansimulate.setItemCodeSimulate(location)
+ this.$refs.comscansimulate.clickScanMsg();
+ },
closeScanPopup() {
- this.$refs.popup.close()
+ if(this.$refs.popup){
+ this.$refs.popup.close()
+ }
+
},
scanClick() {
this.$refs.scan.clickScanMsg();
@@ -77,6 +86,7 @@
this.$refs.scan.clearScanValue();
},
getScanResult(result) {
+
uni.showLoading({
title: '扫描中...',
mask: true
@@ -94,6 +104,7 @@
}
getBasicLocationByCode(this.code).then(res => {
+
uni.hideLoading();
if (res.data.total > 0) {
let result = res.data.list[0];
@@ -142,10 +153,14 @@
return isPass
},
getfocus() {
- this.$refs.scan.getfocus();
+ if(this.$refs.scan){
+ this.$refs.scan.getfocus();
+ }
},
losefocus() {
- this.$refs.scan.losefocus();
+ if(this.$refs.scan){
+ this.$refs.scan.losefocus();
+ }
},
showErrorMessage(message) {
setTimeout(r => {
diff --git a/src/mycomponents/scan/winScanPackAndLocation.vue b/src/mycomponents/scan/winScanPackAndLocation.vue
index fe64744a..96b0d9cf 100644
--- a/src/mycomponents/scan/winScanPackAndLocation.vue
+++ b/src/mycomponents/scan/winScanPackAndLocation.vue
@@ -1,507 +1,516 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/pages/package/record/overPackageRecord.vue b/src/pages/package/record/overPackageRecord.vue
index b066203f..228b3757 100644
--- a/src/pages/package/record/overPackageRecord.vue
+++ b/src/pages/package/record/overPackageRecord.vue
@@ -60,8 +60,8 @@
-
-
+
+
@@ -139,7 +139,7 @@
itemCode: ""
};
},
- onLoad(option) {
+ onShow(){
var typeCode = "OverPackage"
getBusinessType(typeCode, res => {
if (res.success) {
@@ -209,7 +209,10 @@
this.toPackQty = pack.packQty;
this.toPackUnitShow = e[0].label
},
-
+ //修改库位
+ handleConfirm(fromLocationCode){
+ this.$refs.scanLocationCode.openScanPopupSimulate(fromLocationCode)
+ },
getScanResult(result) {
let balance = result.balance;
let label = result.label;
@@ -289,7 +292,13 @@
},
showFromLocationPopup() {
this.$nextTick(() => {
- this.$refs.scanLocationCode.openScanPopup();
+ let overPackageRecord = uni.getStorageSync('overPackageRecord')
+
+ if(overPackageRecord){
+ this.$refs.scanLocationCode.openScanPopupSimulate(overPackageRecord)
+ }else{
+ this.$refs.scanLocationCode.openScanPopup();
+ }
})
},
@@ -429,6 +438,9 @@
this.scanPopupGetFocus();
},
getLocation(location, code) {
+ if(code){
+ uni.setStorageSync('overPackageRecord', code)
+ }
this.getFromLocationCode(location, code)
},
getFromLocationCode(location, code) {
diff --git a/src/store/modules/user.js b/src/store/modules/user.js
index 06a8cb07..509c9484 100644
--- a/src/store/modules/user.js
+++ b/src/store/modules/user.js
@@ -118,6 +118,7 @@ const user = {
commit('SET_ID',[])
storage.removeStorage(storage.constant.token)
storage.clearStorage()
+ uni.removeStorageSync('overPackageRecord') // 删除直接翻包中缓存的来源库位
resolve()
}).catch(error => {
reject(error)