fix:筛选对应物料号的仓库列表

master
zhoulei 4 years ago
parent ac069c80cc
commit 152dbaa65b

@ -104,6 +104,7 @@ import { BasePage } from '@/components/base/page';
import jPicker from '@/components/J-Picker/jPicker.vue';
import { session } from '@/store/modules/session';
import model from './model';
import LocationDetail from './model.location';
@Component({
components: {
jPicker,
@ -126,8 +127,7 @@ export default class dnReceiptDom extends BasePage {
//
receiptAmount: any = '';
//
Location: any = [];
newLocation: any = [];
Location: LocationDetail[] = [];
//
LocationList: any = [];
//
@ -144,8 +144,9 @@ export default class dnReceiptDom extends BasePage {
}
//
//
async initLocation() {
async initLocation(condition): Promise<LocationDetail[]> {
//
let list: Array<LocationDetail> = [];
let means: any = JSON.parse(localStorage.getItem('__GWMS_APP_STATE_DATA__') as any);
let sendSpot = JSON.parse(localStorage.getItem('sendSpot') as any);
let content = {
@ -155,15 +156,16 @@ export default class dnReceiptDom extends BasePage {
workArea: session.workareaCode,
};
let res: any = await this.model.queryByFactoryCodeAndWorkAreaCode(content);
res.forEach((item: any) => {
console.log('res is:', res);
res.forEach((item: LocationDetail) => {
if (item.sendSpot === condition.sendSpot) {
let pickerName: any = {};
pickerName.label = item.locationCode;
pickerName.value = item.locationCode + '(' + item.sendSpot + ')';
pickerName.sendSpot = item.sendSpot;
this.Location.push(pickerName);
console.log('this.Locaton', this.Location);
list.push(pickerName);
}
});
return list;
}
//
async query() {
@ -174,8 +176,6 @@ export default class dnReceiptDom extends BasePage {
});
return;
}
//
this.initLocation();
await this.model.queryOrderInInfo(this.form.documentNo);
if (model.code == '1') {
uni.showToast({
@ -235,13 +235,11 @@ export default class dnReceiptDom extends BasePage {
});
}
// receiptAmount requestAmount
materialChoice(e: any) {
async materialChoice(e: any) {
//
this.every = { ...e.pickerName };
console.log('this.every', this.every);
//guoshuang SAP
this.newLocation = this.Location.filter((item: any) => item.sendSpot === this.every.sendSpot);
console.log('newLoction', this.newLocation);
//
this.Location = await this.initLocation(this.every);
}
//
LocationChoice(e: any) {

@ -0,0 +1,107 @@
/*
* @Author: zhou lei
* @Date: 2021-12-24 12:02:31
* @LastEditTime: 2021-12-24 14:33:54
* @LastEditors: zhou lei
* @Description:
* @FilePath: /wms_haiwai_app/src/pages/raw/ingoods/dnReceipt/model.location.ts
* :910592680@qq.com 18669792120
*/
/**
*
* @export
* @interface LocationDetail
*/
export default interface LocationDetail {
factoryCode?: string;
cosmoType?: null;
sapFactoryCode?: null;
user?: null;
loginName?: null;
sign?: null;
page?: number;
rows?: number;
schema?: null;
lastModifiedBy?: null;
gmtCreate?: null;
createdBy?: null;
createdByName?: null;
warehouseCode?: string;
warehouseName?: null;
warehouseType?: string;
workareaCode?: null;
createdDate?: null;
createdDateStr?: null;
createdDateMax?: null;
createdDateMaxStr?: null;
createdDateMin?: null;
createdDateMinStr?: null;
lastUpdBy?: null;
lastUpdByName?: null;
lastUpdDate?: null;
lastUpdDateStr?: null;
lastUpdDateMax?: null;
lastUpdDateMin?: null;
activeFlag?: string;
userDefined1?: null;
userDefined2?: null;
userDefined3?: null;
userDefined4?: null;
userDefined5?: null;
userDefined6?: null;
userDefined7?: null;
userDefined8?: null;
userDefined9?: null;
userDefined10?: null;
remark?: null;
createBy?: null;
gmtCreateMin?: null;
gmtCreateStr?: null;
gmtCreateMax?: null;
gmtModified?: null;
gmtModifiedStr?: null;
gmtModifiedMax?: null;
gmtModifiedMin?: null;
locationId?: null;
locationCode?: string;
shelfOrder?: null;
sendSpot?: string;
sendSpotDesc1?: string;
checkOrder?: null;
pickOrder?: null;
locationUse?: null;
pickFlag?: null;
isOpenKnFlag?: null;
locationType?: null;
locationAttr?: null;
turnDemand?: null;
stockEnv?: null;
regionCode?: string;
areaCode?: string;
checkCode?: null;
workArea?: string;
port1?: null;
port2?: null;
port3?: null;
volumeLimit?: null;
weightLimit?: null;
boxLimit?: null;
qtyLimit?: null;
palletLimit?: null;
length?: null;
width?: null;
height?: null;
xcoordinate?: null;
ycoordinate?: null;
zcoordinate?: null;
xpixels?: null;
ypixels?: null;
zpixels?: null;
locRow?: null;
layerNum?: null;
locColumn?: null;
bord?: null;
productMix?: null;
batchMix?: null;
ignoreId?: null;
}

@ -3,8 +3,7 @@ import store from '@/store';
import http from '@/utils/request';
import { url } from '@/utils/url';
import { session } from '@/store/modules/session';
import httpjson from '@/utils/location';
import LocationDetail from './model.location';
class OrderInInfo {
checked?: boolean;
dnNo?: string;
@ -225,15 +224,22 @@ export class ReceiptModule extends VuexModule {
});
return kw;
}
/**
*
*
* @param {*} content
* @returns
* @memberof ReceiptModule
*/
@Action({ commit: 'updateCheckedOrderInInfoListKw' })
async queryByFactoryCodeAndWorkAreaCode(content: any) {
let res = await http.post('wmspda/fg/queryByFactoryCodeAndWorkAreaCode', content);
const res = await http.post<LocationDetail>('wmspda/fg/queryByFactoryCodeAndWorkAreaCode', content);
return res;
}
//查询DN/海外DN收货明细
@Action({ commit: 'updateCheckedOrderInInfoListKw' })
async querydetaildlist(content: any) {
let res: any = await http.post('/wmspda/material/getDnRecSn', content);
const res: any = await http.post('/wmspda/material/getDnRecSn', content);
console.log('明细》》》》》》》》》', res.list);
this.DNdetailedList = res.list;
return res;

Loading…
Cancel
Save