From c7b8b96c79ce2d21adf864084eeb71d0693757dc Mon Sep 17 00:00:00 2001 From: guoshuang Date: Fri, 6 Oct 2023 18:31:20 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=98=E7=9B=98=E5=8F=98=E6=9B=B4=E6=B5=8B?= =?UTF-8?q?=E8=AF=95=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/mes/ChangePalletNew/index.vue | 11 ++++++----- src/pages/mes/ChangePalletNew/model.ts | 18 ++++++++++-------- src/pages/mes/PalletChange/index.vue | 8 ++++---- src/utils/request.ts | 2 +- vue.config.js | 4 ++-- 5 files changed, 23 insertions(+), 20 deletions(-) diff --git a/src/pages/mes/ChangePalletNew/index.vue b/src/pages/mes/ChangePalletNew/index.vue index 1b17010..b66d92f 100644 --- a/src/pages/mes/ChangePalletNew/index.vue +++ b/src/pages/mes/ChangePalletNew/index.vue @@ -19,12 +19,12 @@ 查询 - - + + - - + + @@ -164,10 +164,11 @@ export default class ChangePalletNew extends BasePage { Clear() { this.orderNo = ''; this.location = ''; - this.locationStatus = -1; + this.locationStatus = 1; this.productCodeList = {}; this.productCodelocList = {}; this.shouciFocus = false; + this.model.empty(); this.$nextTick(() => { this.shouciFocus = true; }); diff --git a/src/pages/mes/ChangePalletNew/model.ts b/src/pages/mes/ChangePalletNew/model.ts index 7f6c361..bc9ef01 100644 --- a/src/pages/mes/ChangePalletNew/model.ts +++ b/src/pages/mes/ChangePalletNew/model.ts @@ -43,20 +43,22 @@ export class ChangePalletNew extends VuexModule { const result: any = await http.post(url.lanjumes.product.getpalletLocation, { productionState: params, }); - const DictListoild: [] = result.data; - const DictList = DictListoild.map((item: any) => ({ - label: item.itemName, - value: item.itemCode, - })); - return { DictList }; + const DictListoild: [] = result; + if (DictListoild) { + const DictList = DictListoild.map((item: any) => ({ + label: item.location, + value: item.location, + })); + return { DictList }; + } } - //库位下拉列表 + //缓存区下拉列表 locList: any = []; @MutationAction async getDictList() { const result: any = await http.get(url.lanjumes.product.getDictList, { params: { - productionState: 'cache', + equipmentTypeCode: 'cache', }, }); const DictListoild: [] = result.data; diff --git a/src/pages/mes/PalletChange/index.vue b/src/pages/mes/PalletChange/index.vue index ba18313..956a959 100644 --- a/src/pages/mes/PalletChange/index.vue +++ b/src/pages/mes/PalletChange/index.vue @@ -119,7 +119,7 @@ export default class PalletChange extends BasePage { this.isshow = true; }); await this.model.requestDestinationStation(this.orderNo); - let stationNos = model.orderNoItemList.stationNos; + const stationNos = model.orderNoItemList.stationNos; for (let i = 0; i < stationNos.length; i++) { for (let j = 0; j < this.DictList.length; j++) { if (stationNos[i].stationNo === this.DictList[j].equipmentCode) { @@ -128,12 +128,12 @@ export default class PalletChange extends BasePage { } } } - stationNos.map((item) => ({ + console.log('111', stationNos); + this.oldstationNos = stationNos.map((item) => ({ label: item.equipmentName, - value: item.equipmentCode, + value: item.stationNo, ...item, })); - this.oldstationNos = stationNos; } generateGUID() { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) { diff --git a/src/utils/request.ts b/src/utils/request.ts index 78c8e10..ff2e322 100644 --- a/src/utils/request.ts +++ b/src/utils/request.ts @@ -27,7 +27,7 @@ http.interceptors.request.use( // if (config.url.includes('/api')) { // config.baseURL = 'http://192.168.202.23:5001'; // } else { - // config.baseURL = 'http://192.168.202.34:30000'; + // config.baseURL = 'http://192.168.202.20:9000'; // } // 所有请求默认提示加载中 if (!loading) { diff --git a/vue.config.js b/vue.config.js index 63ac076..0a74e69 100644 --- a/vue.config.js +++ b/vue.config.js @@ -3,9 +3,9 @@ module.exports = { proxy: { '/prod-api': { //正式生产 - target: 'http://192.168.202.34:30000', + //target: 'http://192.168.202.34:30000', //测试生产 - //target: 'http://192.168.202.20:9000', + target: 'http://192.168.202.20:9000', changeOrigin: true, // pathRewrite: { // '^/prod-ap': '',