update 修改调拨入库、销售退库入库、其它入库、退料入库、立库入库、立库转库、盘点、无单据转库、上架/转货位页面的仓库、库位下拉框由展示组织下所有改为仓库、库位级联选择

This commit is contained in:
18110972313 2025-05-26 11:12:05 +08:00
parent 8834df11d4
commit 9ff164297d
9 changed files with 299 additions and 88 deletions

View File

@ -287,7 +287,7 @@
}) })
this.getERPLocation(); this.getERPLocation();
this.getTimeData(); this.getTimeData();
this.getLocationName(); // this.getLocationName();
// let Things = 20 // let Things = 20
// for (var i = 0; i < Things; i++) { // for (var i = 0; i < Things; i++) {
// this.BoxListInfo.push({aa:"1"}) // this.BoxListInfo.push({aa:"1"})
@ -337,8 +337,8 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
//this.LOCATIONNAME = "" this.LOCATIONNAME = ""
//this.getLocationName(); this.getLocationName();
}, },
// //
getfocus(nextfocus) { getfocus(nextfocus) {
@ -374,9 +374,10 @@
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
this.BoxListInfo = []; this.BoxListInfo = [];
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; this.items_LocationAll = [];
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: this.ERPLOCATION
}).then(res => { }).then(res => {
if (res.data.success) { if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) { for (let i = 0; i < res.data.resultObj.length; i++) {
@ -395,7 +396,32 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
} else {
this.$showMessage("请先选择仓库")
}
// let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
/*
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_LocationAll.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
this.getitems_LocationAll('');
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
*/
}, },
getitems_LocationAll(query){ getitems_LocationAll(query){
console.log(query + "&&&&&&&&&&&&&&") console.log(query + "&&&&&&&&&&&&&&")

View File

@ -133,7 +133,7 @@
}, },
mounted() { mounted() {
this.getERPLocation(); this.getERPLocation();
this.getLocationName(); // this.getLocationName();
// let Things = 20 // let Things = 20
// for (var i = 0; i < Things; i++) { // for (var i = 0; i < Things; i++) {
// this.BoxListInfo.push({aa:"1"}) // this.BoxListInfo.push({aa:"1"})
@ -172,9 +172,9 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; if (this.ERPLOCATION1 != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY, ERPLocation: this.ERPLOCATION1,
}).then(res => { }).then(res => {
console.log(res.data.resultObj) console.log(res.data.resultObj)
if (res.data.success) { if (res.data.success) {
@ -184,35 +184,37 @@
text: _Arr.DESCRIPTION, text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME value: _Arr.STORAGENAME
}); });
} }
// this.items_Location(''); // this.items_Location('');
this.getitems_LocationAll(''); this.getitems_LocationAll('');
} else { } else {
this.$showMessage(res.data.message) this.$showMessage(res.data.message)
}
this.focusBarCode = true this.focusBarCode = true
this.focusShipRequest = false this.focusShipRequest = false
}
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
}else {
this.$showMessage("请先选择仓库")
}
}, },
change(e) { change(e) {
//this.LOCATIONNAME1 = "" this.ERPLOCATION1 = e.value;
//this.getLocationName(); this.LOCATIONNAME1 = ""
this.getLocationName();
}, },
getitems_LocationAll(query){ getitems_LocationAll(query){
console.log(query + "&&&&&&&&&&&&&&") console.log(query + "&&&&&&&&&&&&&&")
var arr = this.items_LocationAll.filter(item => { var arr = this.items_LocationAll.filter(item => {
return (item.text.includes(query)) || (item.value.includes(query)) return (item.text.includes(query)) || (item.value.includes(query))
}) })
this.items_Location = arr.slice(0, arr.length) // this.items_Location = arr.slice(0, arr.length)
/* if(arr.length > 50){ if(arr.length > 50){
this.items_Location = arr.slice(0,50) this.items_Location = arr.slice(0,50)
} else { } else {
this.items_Location = arr this.items_Location = arr
} */ }
console.log(this.items_Location) console.log(this.items_Location)
}, },
getERPLocation() { getERPLocation() {

View File

@ -228,7 +228,7 @@
this.orgObject = JSON.parse(uni.getStorageSync('orgObject')) this.orgObject = JSON.parse(uni.getStorageSync('orgObject'))
this.getTimeData(); this.getTimeData();
this.getERPLocation(); this.getERPLocation();
this.getLocationName2() // this.getLocationName2()
}, },
methods: { methods: {
@ -312,7 +312,7 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
//this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.bqts = 0 this.bqts = 0
this.bqkcs = 0 this.bqkcs = 0
this.Huowei = e.Huowei this.Huowei = e.Huowei
@ -325,7 +325,7 @@
// this.focusKw = true // this.focusKw = true
// } // }
this.Locatiaon_state = false this.Locatiaon_state = false
//this.getLocationName2(); this.getLocationName2();
}, },
changeLocation() { changeLocation() {
@ -364,6 +364,35 @@
getLocationName2() { getLocationName2() {
this.items_Location = [] this.items_Location = []
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME,
Huowei: _Arr.USE_LOCATION,
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
this.focusKw = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/**
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
}).then(res => { }).then(res => {
@ -386,7 +415,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
getLocationName() { getLocationName() {
this.$MyRequest('/storage/getLocationName', { this.$MyRequest('/storage/getLocationName', {

View File

@ -245,7 +245,7 @@
this.orgObject = JSON.parse(uni.getStorageSync('orgObject')) this.orgObject = JSON.parse(uni.getStorageSync('orgObject'))
this.getTimeData(); this.getTimeData();
this.getERPLocation(); this.getERPLocation();
this.getLocationName(); // this.getLocationName();
}, },
methods: { methods: {
getTimeData() { getTimeData() {
@ -264,7 +264,7 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
/* this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.Huowei = e.Huowei this.Huowei = e.Huowei
if (e.Huowei == 'Y') { if (e.Huowei == 'Y') {
this.Locatiaon_state = false this.Locatiaon_state = false
@ -273,7 +273,7 @@
this.$showMessage(e.text + "仓库没有启用货位管理") this.$showMessage(e.text + "仓库没有启用货位管理")
this.Locatiaon_state = true this.Locatiaon_state = true
this.focusPalletName = true this.focusPalletName = true
} */ }
}, },
getERPLocation() { getERPLocation() {
this.items = []; this.items = [];
@ -296,6 +296,31 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/**
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
@ -317,7 +342,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
selConfirm(e) { selConfirm(e) {
this.ReceiveRequestName = e[0].value; this.ReceiveRequestName = e[0].value;

View File

@ -406,7 +406,7 @@
this.orgObject = JSON.parse(uni.getStorageSync('orgObject')) this.orgObject = JSON.parse(uni.getStorageSync('orgObject'))
this.getERPLocation(); this.getERPLocation();
this.getLocationName(); // this.getLocationName();
this.getTimeData(); this.getTimeData();
// let Things = 20 // let Things = 20
// for (var i = 0; i < Things; i++) { // for (var i = 0; i < Things; i++) {
@ -476,7 +476,7 @@
} }
this.$showMessage("删除成功") this.$showMessage("删除成功")
}, },
/*change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.Huowei = e.Huowei, this.Huowei = e.Huowei,
@ -490,7 +490,7 @@
this.Locatiaon_state = true this.Locatiaon_state = true
this.focusBarCode = true this.focusBarCode = true
} }
},*/ },
// //
getfocus(nextfocus) { getfocus(nextfocus) {
this.initfocus() this.initfocus()
@ -853,14 +853,40 @@
this.DESC_CN = ""; this.DESC_CN = "";
this.CHARGE = ""; this.CHARGE = "";
}, },
/*
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
//this.LOCATIONNAME = "" //this.LOCATIONNAME = ""
//this.getLocationName(); this.getLocationName();
}, },
*/
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
this.items_Location = [] if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/*
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
@ -883,7 +909,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
getitems_LocationAll(query) { getitems_LocationAll(query) {
console.log(query + "&&&&&&&&&&&&&&") console.log(query + "&&&&&&&&&&&&&&")

View File

@ -233,7 +233,7 @@
this.orgObject = JSON.parse(uni.getStorageSync('orgObject')) this.orgObject = JSON.parse(uni.getStorageSync('orgObject'))
this.getERPLocation(); this.getERPLocation();
this.getTimeData(); this.getTimeData();
this.getLocationName(); // this.getLocationName();
}, },
methods: { methods: {
getTimeData(){ getTimeData(){
@ -291,7 +291,7 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
/* this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.Huowei = e.Huowei this.Huowei = e.Huowei
if (e.Huowei == 'Y') { if (e.Huowei == 'Y') {
this.Locatiaon_state = false this.Locatiaon_state = false
@ -300,7 +300,7 @@
this.$showMessage(e.text + "仓库没有启用货位管理") this.$showMessage(e.text + "仓库没有启用货位管理")
this.Locatiaon_state = true this.Locatiaon_state = true
this.focusPalletName = true this.focusPalletName = true
} */ }
}, },
changeLocationName(e) { changeLocationName(e) {
this.LOCATIONNAME = e.value; this.LOCATIONNAME = e.value;
@ -326,6 +326,31 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/*
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
@ -347,7 +372,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
selConfirm(e) { selConfirm(e) {

View File

@ -267,7 +267,7 @@
this.orgObject = JSON.parse(uni.getStorageSync('orgObject')) this.orgObject = JSON.parse(uni.getStorageSync('orgObject'))
this.getTimeData(); this.getTimeData();
this.getERPLocation(); this.getERPLocation();
this.getLocationName(); // this.getLocationName();
}, },
computed: {}, computed: {},
methods: { methods: {
@ -316,7 +316,7 @@
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
console.log(e) console.log(e)
/* this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.Huowei=e.Huowei this.Huowei=e.Huowei
if (e.Huowei == 'Y') { if (e.Huowei == 'Y') {
this.Locatiaon_state = false this.Locatiaon_state = false
@ -325,7 +325,7 @@
this.$showMessage(e.text + "仓库没有启用货位管理") this.$showMessage(e.text + "仓库没有启用货位管理")
this.Locatiaon_state = true this.Locatiaon_state = true
this.focusPalletName = true this.focusPalletName = true
} */ }
}, },
changeLocationName(e) { changeLocationName(e) {
@ -352,6 +352,31 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_LocationAll.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
this.getitems_LocationAll('')
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/*
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
@ -373,7 +398,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
getitems_LocationAll(query){ getitems_LocationAll(query){
console.log(111) console.log(111)

View File

@ -266,7 +266,7 @@
this.GetLiberaryBaeEn() this.GetLiberaryBaeEn()
this.GetPRODUCTLINES() this.GetPRODUCTLINES()
this.getTimeData(); this.getTimeData();
this.getLocationName(); // this.getLocationName();
}, },
methods: { methods: {
handleScan() { handleScan() {
@ -296,8 +296,8 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
/* this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.getLocationName(); */ this.getLocationName();
}, },
GetArea() { GetArea() {
this.$MyRequest('/api/storage/getArea', {}).then(res => { this.$MyRequest('/api/storage/getArea', {}).then(res => {
@ -415,7 +415,35 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; //let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
try {
Vue.prototype.$playFail()
} catch (e) {}
this.$showMessage("请先选择仓库")
}
/*
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
}).then(res => { }).then(res => {
@ -436,7 +464,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
ScanFGBarCode() { ScanFGBarCode() {

View File

@ -356,7 +356,7 @@
this.GetLiberaryBaeIn() this.GetLiberaryBaeIn()
this.GetLiberaryBaeEn() this.GetLiberaryBaeEn()
this.getTimeData(); this.getTimeData();
this.getLocationName(); // this.getLocationName();
// let Things = 20 // let Things = 20
// for (var i = 0; i < Things; i++) { // for (var i = 0; i < Things; i++) {
// this.list_detail.push({aa:"1"}) // this.list_detail.push({aa:"1"})
@ -559,8 +559,8 @@
}, },
change(e) { change(e) {
this.ERPLOCATION = e.value; this.ERPLOCATION = e.value;
/* this.LOCATIONNAME = "" this.LOCATIONNAME = ""
this.getLocationName(); */ this.getLocationName();
}, },
GetArea() { GetArea() {
this.$MyRequest('/api/storage/getArea2', {}).then(res => { this.$MyRequest('/api/storage/getArea2', {}).then(res => {
@ -652,6 +652,31 @@
}, },
getLocationName() { getLocationName() {
this.items_Location = [] this.items_Location = []
if (this.ERPLOCATION != '') {
this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: this.ERPLOCATION
}).then(res => {
if (res.data.success) {
for (let i = 0; i < res.data.resultObj.length; i++) {
var _Arr = res.data.resultObj[i];
this.items_Location.push({
text: _Arr.DESCRIPTION,
value: _Arr.STORAGENAME
});
}
} else {
this.$showMessage(res.data.message)
}
this.focusBarCode = true
this.focusShipRequest = false
}).catch(err => {
this.$showMessage(err)
});
} else {
this.$showMessage("请先选择仓库")
}
/*
let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY; let ERPFACTORY = JSON.parse(uni.getStorageSync('orgObject')).ERPFACTORY;
this.$MyRequest('/api/storage/getLocationNameForERPLocation', { this.$MyRequest('/api/storage/getLocationNameForERPLocation', {
ERPLocation: ERPFACTORY ERPLocation: ERPFACTORY
@ -673,7 +698,7 @@
}).catch(err => { }).catch(err => {
this.$showMessage(err) this.$showMessage(err)
}); });
*/
}, },
/** /**
* 转库保存 * 转库保存