多组织仓位
This commit is contained in:
@@ -312,7 +312,7 @@ export default {
|
|||||||
remarkIndex: null, //修改的是那个明细的备注
|
remarkIndex: null, //修改的是那个明细的备注
|
||||||
itremake: '', // 明细盘亏备注
|
itremake: '', // 明细盘亏备注
|
||||||
choseBoxId: '', // 当前箱的箱id
|
choseBoxId: '', // 当前箱的箱id
|
||||||
subStockCode: null, // 当前箱的仓位code
|
// subStockCode: null, // 当前箱的仓位code
|
||||||
subStockCode: '', //仓位code
|
subStockCode: '', //仓位code
|
||||||
old_SubStockCode: '', //老仓位code,由箱号携带出来
|
old_SubStockCode: '', //老仓位code,由箱号携带出来
|
||||||
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
||||||
@@ -407,13 +407,11 @@ export default {
|
|||||||
},
|
},
|
||||||
//仓库change事件
|
//仓库change事件
|
||||||
ckchange(e) {
|
ckchange(e) {
|
||||||
console.log(1232323);
|
|
||||||
this.xhDisabled = !e.name;
|
this.xhDisabled = !e.name;
|
||||||
this.focusInput = '';
|
this.focusInput = '';
|
||||||
this.warehouseName = e.name;
|
this.warehouseName = e.name;
|
||||||
this.warehouseCode = e.code;
|
this.warehouseCode = e.code;
|
||||||
this.orgCode = e.erpOrgCode;
|
this.orgCode = e.erpOrgCode;
|
||||||
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.focusInput = 'box';
|
this.focusInput = 'box';
|
||||||
}, 300);
|
}, 300);
|
||||||
@@ -521,7 +519,7 @@ export default {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let formData = [];
|
let formData = [];
|
||||||
|
|
||||||
this.dataList.forEach((it) => {
|
this.dataList.forEach((it) => {
|
||||||
formData.push({
|
formData.push({
|
||||||
boxId: this.choseBoxId,
|
boxId: this.choseBoxId,
|
||||||
@@ -534,15 +532,17 @@ export default {
|
|||||||
remark: it.remark,
|
remark: it.remark,
|
||||||
stockCode: this.warehouseCode,
|
stockCode: this.warehouseCode,
|
||||||
BoxBillNo: this.xhNo,
|
BoxBillNo: this.xhNo,
|
||||||
old_SubStockCode: it.old_SubStockCode ? it.old_SubStockCode : this.subStockCode
|
old_SubStockCode: it.old_SubStockCode ? it.old_SubStockCode : this.subStockCode,
|
||||||
|
twoSerialNumbers:it.twoSerialNumbers ? it.twoSerialNumbers.filter(Boolean):[]
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
console.log('提交數據', formData);
|
console.log('提交數據', formData);
|
||||||
|
|
||||||
// 节流
|
// 节流
|
||||||
if (this.requestStatus) {
|
if (this.requestStatus) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.requestStatus = true;
|
this.requestStatus = true;
|
||||||
this.qrpdshow = false;
|
this.qrpdshow = false;
|
||||||
this.$api.post('/TakeStock/Save', formData).then((res) => {
|
this.$api.post('/TakeStock/Save', formData).then((res) => {
|
||||||
@@ -715,6 +715,11 @@ export default {
|
|||||||
this.dataList[findindx].itxlhList.push(res.data.serialNumber);
|
this.dataList[findindx].itxlhList.push(res.data.serialNumber);
|
||||||
// 缓存当前扫描数据
|
// 缓存当前扫描数据
|
||||||
this.xlhStrlist.push(res.data.serialNumber);
|
this.xlhStrlist.push(res.data.serialNumber);
|
||||||
|
//缓存2件装序列号
|
||||||
|
if(res.data.isTwo==2) {
|
||||||
|
this.dataList[findindx].twoSerialNumbers.push(res.data.twoSerialNumber);
|
||||||
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
|
}
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '获取成功',
|
title: '获取成功',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -753,7 +758,8 @@ export default {
|
|||||||
old_SubStockCode: res.data.subStockCode,
|
old_SubStockCode: res.data.subStockCode,
|
||||||
pdNum: this.xlhOrggType == 'ggxh' ? 0 : this.xlhOrggType == 'xlh' ? 1 : 0,
|
pdNum: this.xlhOrggType == 'ggxh' ? 0 : this.xlhOrggType == 'xlh' ? 1 : 0,
|
||||||
serialNumbers: [],
|
serialNumbers: [],
|
||||||
itxlhList: []
|
itxlhList: [],
|
||||||
|
twoSerialNumbers:[],
|
||||||
});
|
});
|
||||||
if (this.xlhOrggType == 'xlh') {
|
if (this.xlhOrggType == 'xlh') {
|
||||||
this.xlhGgxNum = 1;
|
this.xlhGgxNum = 1;
|
||||||
@@ -762,6 +768,7 @@ export default {
|
|||||||
this.xlhStrlist.push(res.data.serialNumber);
|
this.xlhStrlist.push(res.data.serialNumber);
|
||||||
//缓存2件装序列号
|
//缓存2件装序列号
|
||||||
if(res.data.isTwo==2) {
|
if(res.data.isTwo==2) {
|
||||||
|
this.dataList[this.dataList.length - 1].twoSerialNumbers.push(res.data.twoSerialNumber);
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -837,16 +844,8 @@ export default {
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//没有仓位就不添加明细数据
|
|
||||||
// if(!if()res.data.subStockCode) {
|
|
||||||
// return
|
|
||||||
// }if()
|
|
||||||
//明细数据
|
|
||||||
// if(!res.data.subStockCode) {
|
|
||||||
// retrun
|
|
||||||
// }
|
|
||||||
this.dataList = [];
|
this.dataList = [];
|
||||||
|
|
||||||
res.data.details.forEach((obj) => {
|
res.data.details.forEach((obj) => {
|
||||||
if (obj.qty > 0 && res.data.subStockCode) {
|
if (obj.qty > 0 && res.data.subStockCode) {
|
||||||
this.dataList.push({
|
this.dataList.push({
|
||||||
@@ -857,7 +856,9 @@ export default {
|
|||||||
subStockCode: res.data.subStockCode,
|
subStockCode: res.data.subStockCode,
|
||||||
remark: '',
|
remark: '',
|
||||||
erpSubStockCode: null,
|
erpSubStockCode: null,
|
||||||
old_SubStockCode: res.data.subStockCode
|
old_SubStockCode: res.data.subStockCode,
|
||||||
|
twoSerialNumbers:res.data.twoSerialNumbers ? res.data.twoSerialNumbers: []
|
||||||
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Binary file not shown.
@@ -337,6 +337,7 @@ export default {
|
|||||||
this.dqNumTag = '';
|
this.dqNumTag = '';
|
||||||
this.xlhOrggStrlist = [];
|
this.xlhOrggStrlist = [];
|
||||||
this.twoData=[]
|
this.twoData=[]
|
||||||
|
this.confirmParams=[]
|
||||||
this.MbNoTag = false;
|
this.MbNoTag = false;
|
||||||
this.YyNoTag = false;
|
this.YyNoTag = false;
|
||||||
this.xlhOrggTag = false;
|
this.xlhOrggTag = false;
|
||||||
@@ -375,11 +376,13 @@ export default {
|
|||||||
qty: obj.serialNumber ? 1 : obj.qty, //如归是序列号默认为1,如果是规格型号取用户输入的值
|
qty: obj.serialNumber ? 1 : obj.qty, //如归是序列号默认为1,如果是规格型号取用户输入的值
|
||||||
srcBoxId: obj.boxId,
|
srcBoxId: obj.boxId,
|
||||||
serialNumber: obj.serialNumber,
|
serialNumber: obj.serialNumber,
|
||||||
serialNumbers: []
|
twoSerialNumber:obj.twoSerialNumber,
|
||||||
|
serialNumbers: [],
|
||||||
|
twoSerialNumbers:[],
|
||||||
});
|
});
|
||||||
return acc;
|
return acc;
|
||||||
}, {});
|
}, {});
|
||||||
|
let srcBoxId =null
|
||||||
const result = Object.values(groupedBySrcBoxId).map((group) => {
|
const result = Object.values(groupedBySrcBoxId).map((group) => {
|
||||||
return group.reduce((acc, obj) => {
|
return group.reduce((acc, obj) => {
|
||||||
const existing = acc.find((item) => item.materialNumber === obj.materialNumber);
|
const existing = acc.find((item) => item.materialNumber === obj.materialNumber);
|
||||||
@@ -387,29 +390,41 @@ export default {
|
|||||||
if (obj.serialNumber) {
|
if (obj.serialNumber) {
|
||||||
existing.qty += obj.qty;
|
existing.qty += obj.qty;
|
||||||
existing.serialNumbers.push(obj.serialNumber);
|
existing.serialNumbers.push(obj.serialNumber);
|
||||||
|
|
||||||
}
|
}
|
||||||
// existing.qty += obj.qty;
|
if(obj.twoSerialNumber) {
|
||||||
// existing.serialNumbers.push(obj.serialNumber);
|
existing.twoSerialNumbers.push(obj.twoSerialNumber)
|
||||||
|
console.log(existing,'=existing=')
|
||||||
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
let twoSerialNumbers = []
|
||||||
|
if(obj.twoSerialNumber) {
|
||||||
|
twoSerialNumbers.push(obj.twoSerialNumber)
|
||||||
|
}
|
||||||
acc.push({
|
acc.push({
|
||||||
materialNumber: obj.materialNumber,
|
materialNumber: obj.materialNumber,
|
||||||
qty: obj.qty,
|
qty: obj.qty,
|
||||||
serialNumbers: obj.serialNumber ? [obj.serialNumber] : [],
|
serialNumbers: obj.serialNumber ? [obj.serialNumber] : [],
|
||||||
srcBoxId: obj.srcBoxId
|
// srcBoxId: obj.srcBoxId,
|
||||||
|
twoSerialNumbers:twoSerialNumbers,
|
||||||
});
|
});
|
||||||
|
srcBoxId = obj.srcBoxId
|
||||||
}
|
}
|
||||||
return acc;
|
return acc;
|
||||||
}, []);
|
}, []);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
console.log()
|
||||||
let params = [];
|
let params = [];
|
||||||
let length = result.length;
|
let length = result.length;
|
||||||
for (let i = 0; i < length; i++) {
|
for (let i = 0; i < length; i++) {
|
||||||
let obj = {
|
let obj = {
|
||||||
destBoxBillNo: this.boxMbNo,
|
destBoxBillNo: this.boxMbNo,
|
||||||
srcBoxId: this.YyboxId ? this.YyboxId : result[i][0].srcBoxId,
|
srcBoxId: this.YyboxId ? this.YyboxId : srcBoxId,
|
||||||
destBoxId: this.MbBoxId ? this.MbBoxId : 0,
|
destBoxId: this.MbBoxId ? this.MbBoxId : 0,
|
||||||
subStockCode: cwcode ? cwcode : this.subStockCode ? this.subStockCode : 0, //目标箱仓位或重新上架选择仓位
|
subStockCode: cwcode ? cwcode : this.subStockCode ? this.subStockCode : 0, //目标箱仓位或重新上架选择仓位
|
||||||
details: result[i]
|
details: result[i],
|
||||||
};
|
};
|
||||||
params.push(obj);
|
params.push(obj);
|
||||||
}
|
}
|
||||||
@@ -419,8 +434,8 @@ export default {
|
|||||||
if (this.requestStatus) {
|
if (this.requestStatus) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
console.log('提交的數據',params)
|
this.requestStatus = true;
|
||||||
this.requestStatus = true;
|
console.log(params,'=params=')
|
||||||
this.$api.post('/ChangeBoxRecord/Save', params).then((res) => {
|
this.$api.post('/ChangeBoxRecord/Save', params).then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -633,7 +648,7 @@ export default {
|
|||||||
specifications: this.itData.specifications,
|
specifications: this.itData.specifications,
|
||||||
materialNumber: this.itData.materialNumber,
|
materialNumber: this.itData.materialNumber,
|
||||||
qty: this.dqNum,
|
qty: this.dqNum,
|
||||||
srcBoxId: this.itData.boxId
|
srcBoxId: this.itData.boxId,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -834,13 +849,15 @@ export default {
|
|||||||
specifications: res.data.specifications,
|
specifications: res.data.specifications,
|
||||||
materialNumber: res.data.materialNumber,
|
materialNumber: res.data.materialNumber,
|
||||||
qty: 1,
|
qty: 1,
|
||||||
srcBoxId: res.data.boxId
|
srcBoxId: res.data.boxId,
|
||||||
|
twoSerialNumber:res.data.twoSerialNumber ? res.data.twoSerialNumber: ''
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
//数量默认为1
|
//数量默认为1
|
||||||
this.focusInput = 'xlhggxh';
|
this.focusInput = 'xlhggxh';
|
||||||
this.setSMinputxlhOrggxh();
|
this.setSMinputxlhOrggxh();
|
||||||
this.xlhOrggStrlist.push(this.xlhOrggType == 'xlh' ? res.data.serialNumber : res.data.specifications);
|
this.xlhOrggStrlist.push(this.xlhOrggType == 'xlh' ? res.data.serialNumber : res.data.specifications);
|
||||||
|
this.confirmParams.push(res.data);
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '设置成功',
|
title: '设置成功',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
@@ -858,7 +875,7 @@ export default {
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.xlhOrggStrlist.includes(this.xlhOrggxhVal) || this.twoData.includes(this.xlhVal)) {
|
if (this.xlhOrggStrlist.includes(this.xlhOrggxhVal) || this.twoData.includes(this.xlhOrggxhVal)) {
|
||||||
this.setSMinputxlhOrggxh();
|
this.setSMinputxlhOrggxh();
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '该序列号/格型号已扫描',
|
title: '该序列号/格型号已扫描',
|
||||||
@@ -880,7 +897,6 @@ export default {
|
|||||||
this.xlhggxhData = res;
|
this.xlhggxhData = res;
|
||||||
this.useGGXH = res.data.specifications;
|
this.useGGXH = res.data.specifications;
|
||||||
this.entGGXH = res.data.specifications;
|
this.entGGXH = res.data.specifications;
|
||||||
this.confirmParams.push(res.data);
|
|
||||||
// 明细添加,如果该序列号对应的规格型号不存在,就明细填加一条,如果存在就数量加一(booleacz 这个是判断规格型号)
|
// 明细添加,如果该序列号对应的规格型号不存在,就明细填加一条,如果存在就数量加一(booleacz 这个是判断规格型号)
|
||||||
this.booleacz = this.dataList.some((obj) => obj.specifications === res.data.specifications);
|
this.booleacz = this.dataList.some((obj) => obj.specifications === res.data.specifications);
|
||||||
// 判断扫码的是个序列号还是规格型号
|
// 判断扫码的是个序列号还是规格型号
|
||||||
@@ -895,6 +911,10 @@ export default {
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
//缓存2件装序列号
|
||||||
|
if(res.data.isTwo==2 ) {
|
||||||
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
|
}
|
||||||
if (this.xlhOrggType == 'xlh') {
|
if (this.xlhOrggType == 'xlh') {
|
||||||
let xlhyyitlist = [];
|
let xlhyyitlist = [];
|
||||||
this.yyMXlist.forEach((it) => {
|
this.yyMXlist.forEach((it) => {
|
||||||
@@ -902,6 +922,7 @@ export default {
|
|||||||
xlhyyitlist = it.serialNumbers;
|
xlhyyitlist = it.serialNumbers;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
/*
|
/*
|
||||||
原箱号有值,序列号=激活、激活且非冻结、非激活且非冻结=扫描成功,
|
原箱号有值,序列号=激活、激活且非冻结、非激活且非冻结=扫描成功,
|
||||||
原箱号没有值,序列号=非激活且非冻结、激活且冻结=扫描成功
|
原箱号没有值,序列号=非激活且非冻结、激活且冻结=扫描成功
|
||||||
@@ -991,13 +1012,15 @@ export default {
|
|||||||
this.dqNum = null;
|
this.dqNum = null;
|
||||||
this.focusInput = 'dqNum';
|
this.focusInput = 'dqNum';
|
||||||
this.xlhOrggStrlist.push(this.xlhOrggType == 'xlh' ? res.data.serialNumber : res.data.specifications);
|
this.xlhOrggStrlist.push(this.xlhOrggType == 'xlh' ? res.data.serialNumber : res.data.specifications);
|
||||||
|
this.confirmParams.push(res.data);
|
||||||
//缓存2件装序列号
|
//缓存2件装序列号
|
||||||
if(res.data.isTwo==2 && this.xlhOrggType == 'xlh') {
|
// if(res.data.isTwo==2 && this.xlhOrggType == 'xlh') {
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
// this.twoData.push(res.data.twoSerialNumber)
|
||||||
}
|
// console.log(this.twoData,'=this.twoData=')
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
this.focusInput = this.xlhOrggType == 'ggxh' ? 'dqNum' : 'xlhggxh';
|
this.focusInput = this.xlhOrggType == 'ggxh' ? 'dqNum' : 'xlhggxh';
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
this.setSMinputxlhOrggxh();
|
this.setSMinputxlhOrggxh();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -269,7 +269,6 @@ export default {
|
|||||||
subStockCode: this.cwcode,
|
subStockCode: this.cwcode,
|
||||||
details: []
|
details: []
|
||||||
};
|
};
|
||||||
console.log(this.dataList, '=this.dataList=');
|
|
||||||
this.dataList.forEach((it) => {
|
this.dataList.forEach((it) => {
|
||||||
if (it.details && it.details.length > 0) {
|
if (it.details && it.details.length > 0) {
|
||||||
it.details.forEach((k) => {
|
it.details.forEach((k) => {
|
||||||
@@ -280,16 +279,19 @@ export default {
|
|||||||
qty: k.qty,
|
qty: k.qty,
|
||||||
subStockCode: k.subStockCode,
|
subStockCode: k.subStockCode,
|
||||||
serialNumbers: k.itxlhlist,
|
serialNumbers: k.itxlhlist,
|
||||||
remark: k.remark
|
remark: k.remark,
|
||||||
|
twoSerialNumbers:k.twoSerialNumbers.filter(Boolean)
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
console.log('入库回退下架1', this.dataList, formdata);
|
// console.log('入库回退下架1', this.dataList, formdata);
|
||||||
|
// formData.details.twoSerialNumbers = formData?.details?.twoSerialNumbers?.length && formData?.details?.twoSerialNumbers.filter(Boolean);
|
||||||
if (this.requestStatus) {
|
if (this.requestStatus) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
this.requestStatus = true;
|
this.requestStatus = true;
|
||||||
|
|
||||||
this.$api.post('/BackRecord/OffShelf', formdata).then((res) => {
|
this.$api.post('/BackRecord/OffShelf', formdata).then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -474,6 +476,7 @@ export default {
|
|||||||
it.subStockCode = res.data.subStockCode;
|
it.subStockCode = res.data.subStockCode;
|
||||||
it.boxId = it.boxId;
|
it.boxId = it.boxId;
|
||||||
it.remark = '';
|
it.remark = '';
|
||||||
|
it.twoSerialNumbers = it.twoSerialNumbers ? it.twoSerialNumbers : []
|
||||||
});
|
});
|
||||||
this.dataList = [res.data].concat(this.dataList);
|
this.dataList = [res.data].concat(this.dataList);
|
||||||
|
|
||||||
@@ -608,8 +611,11 @@ export default {
|
|||||||
this.xlhVal = res.data.serialNumber;
|
this.xlhVal = res.data.serialNumber;
|
||||||
// 缓存序列号
|
// 缓存序列号
|
||||||
this.xlhstrList.push(res.data.serialNumber);
|
this.xlhstrList.push(res.data.serialNumber);
|
||||||
|
|
||||||
|
console.log(this.dataList,'=this.dataList=')
|
||||||
//缓存2件装序列号
|
//缓存2件装序列号
|
||||||
if(res.data.isTwo==2) {
|
if(res.data.isTwo==2) {
|
||||||
|
this.dataList[indexobj.objectIndex].details[indexobj.detailIndex].twoSerialNumbers.push(res.data.twoSerialNumber);
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
}
|
}
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
|
|||||||
@@ -408,7 +408,8 @@ export default {
|
|||||||
materialNumber: k.materialNumber,
|
materialNumber: k.materialNumber,
|
||||||
qty: parseInt(k.qty ? k.qty : 0),
|
qty: parseInt(k.qty ? k.qty : 0),
|
||||||
serialNumbers: k.itxlhlist,
|
serialNumbers: k.itxlhlist,
|
||||||
remark: k.remark
|
remark: k.remark,
|
||||||
|
twoSerialNumbers:k.twoSerialNumbers ? k.twoSerialNumbers.filter(Boolean): []
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -418,7 +419,10 @@ export default {
|
|||||||
if (this.requestStatus) {
|
if (this.requestStatus) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.requestStatus = true;
|
this.requestStatus = true;
|
||||||
|
|
||||||
|
// formData.details.twoSerialNumbers = formData?.details?.twoSerialNumbers?.length && formData?.details?.twoSerialNumbers?.filter(Boolean);
|
||||||
this.$api.post('/BackRecord/OnShelf', formdata).then((res) => {
|
this.$api.post('/BackRecord/OnShelf', formdata).then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -699,6 +703,7 @@ export default {
|
|||||||
this.xlhstrList.push(res.data.serialNumber);
|
this.xlhstrList.push(res.data.serialNumber);
|
||||||
if(res.data.isTwo==2) {
|
if(res.data.isTwo==2) {
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
|
this.dataList[0].details[findindx].twoSerialNumbers.push(res.data.twoSerialNumber);
|
||||||
}
|
}
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '获取成功',
|
title: '获取成功',
|
||||||
@@ -746,7 +751,8 @@ export default {
|
|||||||
materialNumber: res.data.materialNumber,
|
materialNumber: res.data.materialNumber,
|
||||||
specifications: res.data.specifications,
|
specifications: res.data.specifications,
|
||||||
materialName: res.data.materialName,
|
materialName: res.data.materialName,
|
||||||
remark: ''
|
remark: '',
|
||||||
|
twoSerialNumbers:[]
|
||||||
};
|
};
|
||||||
if (this.xlhOrggType == 'xlh') {
|
if (this.xlhOrggType == 'xlh') {
|
||||||
this.dqBoxInfo.details = [];
|
this.dqBoxInfo.details = [];
|
||||||
@@ -767,7 +773,9 @@ export default {
|
|||||||
materialNumber: res.data.materialNumber,
|
materialNumber: res.data.materialNumber,
|
||||||
specifications: res.data.specifications,
|
specifications: res.data.specifications,
|
||||||
materialName: res.data.materialName,
|
materialName: res.data.materialName,
|
||||||
remark: ''
|
remark: '',
|
||||||
|
twoSerialNumbers:[]
|
||||||
|
|
||||||
});
|
});
|
||||||
this.itIndx = this.dataList[0].details.length - 1;
|
this.itIndx = this.dataList[0].details.length - 1;
|
||||||
}
|
}
|
||||||
@@ -784,7 +792,9 @@ export default {
|
|||||||
materialNumber: res.data.materialNumber,
|
materialNumber: res.data.materialNumber,
|
||||||
specifications: res.data.specifications,
|
specifications: res.data.specifications,
|
||||||
materialName: res.data.materialName,
|
materialName: res.data.materialName,
|
||||||
remark: ''
|
remark: '',
|
||||||
|
twoSerialNumbers:[]
|
||||||
|
|
||||||
};
|
};
|
||||||
this.itIndx = this.dataList[0].details.length;
|
this.itIndx = this.dataList[0].details.length;
|
||||||
}
|
}
|
||||||
@@ -796,6 +806,7 @@ export default {
|
|||||||
//缓存2件装序列号
|
//缓存2件装序列号
|
||||||
if(res.data.isTwo==2) {
|
if(res.data.isTwo==2) {
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
|
this.dataList[0].details[this.itIndx].twoSerialNumbers.push(res.data.twoSerialNumber);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.xlhOrggType == 'ggxh') {
|
if (this.xlhOrggType == 'ggxh') {
|
||||||
@@ -883,6 +894,8 @@ export default {
|
|||||||
.then((res) => {
|
.then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
if (res.data !== null) {
|
if (res.data !== null) {
|
||||||
|
console.log(this.cwcode,'=this.cwcode=')
|
||||||
|
console.log(res.data.subStockCode ,'=res.data.subStockCode =')
|
||||||
if (this.htfsType == '按产品回退' && this.cwcode !== res.data.subStockCode && res.data.subStockCode) {
|
if (this.htfsType == '按产品回退' && this.cwcode !== res.data.subStockCode && res.data.subStockCode) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '请扫描对应仓位内的箱号',
|
title: '请扫描对应仓位内的箱号',
|
||||||
@@ -1024,7 +1037,6 @@ export default {
|
|||||||
this.dataList[indexobj.objectIndex].details[indexobj.detailIndex].itxlhlist.push(this.xlhVal);
|
this.dataList[indexobj.objectIndex].details[indexobj.detailIndex].itxlhlist.push(this.xlhVal);
|
||||||
} else {
|
} else {
|
||||||
const indexsh = this.dataList.findIndex((obj) => obj.boxBillNo === res.data.boxBillNo);
|
const indexsh = this.dataList.findIndex((obj) => obj.boxBillNo === res.data.boxBillNo);
|
||||||
console.log(12, indexsh);
|
|
||||||
if (indexsh !== -1) {
|
if (indexsh !== -1) {
|
||||||
const shwlidindex = this.dataList[indexsh].details.findIndex((obj) => obj.materialNumber === res.data.materialNumber);
|
const shwlidindex = this.dataList[indexsh].details.findIndex((obj) => obj.materialNumber === res.data.materialNumber);
|
||||||
console.log(13, shwlidindex, this.dataList[indexsh].details);
|
console.log(13, shwlidindex, this.dataList[indexsh].details);
|
||||||
|
|||||||
@@ -33,20 +33,24 @@
|
|||||||
<!-- 無聊 -->
|
<!-- 無聊 -->
|
||||||
<view class="item" :class="{ itembg2: !warehouseName }" :style="{ 'pointer-events': !warehouseName ? 'none' : '' }">
|
<view class="item" :class="{ itembg2: !warehouseName }" :style="{ 'pointer-events': !warehouseName ? 'none' : '' }">
|
||||||
<view class="" style="display: flex;padding: 10rpx 0; margin:0 40rpx;border-bottom: 1rpx solid #E3E5E8; box-sizing: border-box;">
|
<view class="" style="display: flex;padding: 10rpx 0; margin:0 40rpx;border-bottom: 1rpx solid #E3E5E8; box-sizing: border-box;">
|
||||||
<view style="border-right: 1rpx solid #E3E5E8;padding-right: 16rpx;">
|
<!-- border-right: 1rpx solid #E3E5E8; -->
|
||||||
|
<view style="width:130rpx;flex:3;border-right: 1rpx solid #E3E5E8;">
|
||||||
<uni-data-select
|
<uni-data-select
|
||||||
v-model="selectValue"
|
v-model="selectValue"
|
||||||
:localdata="options"
|
:localdata="options"
|
||||||
@change="hanldeSelectChange"
|
@change="hanldeSelectChange"
|
||||||
:clear="false"
|
:clear="false"
|
||||||
|
style=""
|
||||||
></uni-data-select>
|
></uni-data-select>
|
||||||
</view>
|
</view>
|
||||||
<view style="display: flex; align-items: center;justify-content: center;">
|
<!-- <view style="width: 1rpx; height:50rpx;background-color:#E3E5E8 ;">
|
||||||
<u-input :focus="focusTag==='box'" @clear="handleClear" border="bottom" :style="{width: inputWidth}" style="font-size: 14px; height:32rpx;"clearable v-model="inputVal" @confirm="handleInputConfirm()"
|
|
||||||
|
</view> -->
|
||||||
|
<view style="display: flex; align-items: center;justify-content: center;flex:10">
|
||||||
|
<u-input :focus="focusTag==='box'" @clear="handleClear" border="bottom" style="font-size: 14px; height:32rpx;"clearable v-model="inputVal" @confirm="handleInputConfirm()"
|
||||||
></u-input>
|
></u-input>
|
||||||
</view>
|
</view>
|
||||||
<view style="display: flex;align-items: center;"@click="scanImg('box')">
|
<view style="display: flex;align-items: center;flex: 2;justify-content: center;"@click="scanImg('box')">
|
||||||
<image src="../../static/img/smico.png" class="searchico" style="margin-left:0;"></image>
|
<image src="../../static/img/smico.png" class="searchico" style="margin-left:0;"></image>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@@ -193,7 +197,7 @@
|
|||||||
warehouseList:[],//仓库列表数据
|
warehouseList:[],//仓库列表数据
|
||||||
inputVal:'',//input输入值
|
inputVal:'',//input输入值
|
||||||
timer:null,
|
timer:null,
|
||||||
inputWidth:"470rpx",
|
inputWidth:0,
|
||||||
timer1:null,
|
timer1:null,
|
||||||
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
||||||
scanTracker: {
|
scanTracker: {
|
||||||
@@ -207,11 +211,12 @@
|
|||||||
this.getElHeight(".sh_gdInfo",1)
|
this.getElHeight(".sh_gdInfo",1)
|
||||||
this.getElHeight(".mianheade",2)
|
this.getElHeight(".mianheade",2)
|
||||||
/* #ifdef H5 */
|
/* #ifdef H5 */
|
||||||
this.inputWidth = '470rpx'
|
this.inputWidth = '450rpx'
|
||||||
/*#endif*/
|
/*#endif*/
|
||||||
/*#ifdef APP-PLUS*/
|
/*#ifdef APP-PLUS*/
|
||||||
this.inputWidth = '422rpx'
|
this.inputWidth = '402rpx'
|
||||||
/*#endif*/
|
/*#endif*/
|
||||||
|
console.log(this.inputWidth,'=this.inputWidth')
|
||||||
|
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
|||||||
@@ -464,7 +464,6 @@ export default {
|
|||||||
this.YiJiannum = 0;
|
this.YiJiannum = 0;
|
||||||
this.YingJianum = 0;
|
this.YingJianum = 0;
|
||||||
}
|
}
|
||||||
console.log(n,'===========n===========')
|
|
||||||
//根据出库单号检索
|
//根据出库单号检索
|
||||||
this.pageNo = 1;
|
this.pageNo = 1;
|
||||||
this.ckSelectlist = [];
|
this.ckSelectlist = [];
|
||||||
@@ -701,7 +700,6 @@ export default {
|
|||||||
},
|
},
|
||||||
// 一键清除出库单号
|
// 一键清除出库单号
|
||||||
clearnFn(val) {
|
clearnFn(val) {
|
||||||
console.log('一键清除出库单号', val);
|
|
||||||
if (val == 'ckdhselect') {
|
if (val == 'ckdhselect') {
|
||||||
// this.warehouseName = '';
|
// this.warehouseName = '';
|
||||||
// this.warehouseCode = '';
|
// this.warehouseCode = '';
|
||||||
@@ -802,7 +800,7 @@ export default {
|
|||||||
icon: 'none',
|
icon: 'none',
|
||||||
duration: 2000
|
duration: 2000
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let formData = {};
|
let formData = {};
|
||||||
formData.taskId = this.fid;
|
formData.taskId = this.fid;
|
||||||
@@ -852,10 +850,12 @@ export default {
|
|||||||
materialNumber: item.materialNumber,
|
materialNumber: item.materialNumber,
|
||||||
boxId: item.boxId,
|
boxId: item.boxId,
|
||||||
serialNumbers: [],
|
serialNumbers: [],
|
||||||
|
twoSerialNumbers:[],
|
||||||
qty: 0
|
qty: 0
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
mergedArray[key].serialNumbers.push(item.serialNumbers);
|
mergedArray[key].serialNumbers.push(item.serialNumbers);
|
||||||
|
mergedArray[key].twoSerialNumbers.push(item.twoSerialNumbers);
|
||||||
mergedArray[key].qty += item.qty;
|
mergedArray[key].qty += item.qty;
|
||||||
});
|
});
|
||||||
const result = Object.values(mergedArray);
|
const result = Object.values(mergedArray);
|
||||||
@@ -864,9 +864,11 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
thedetails = boxdetails;
|
thedetails = boxdetails;
|
||||||
}
|
}
|
||||||
// 过滤为0的数据
|
// 过滤为0的数
|
||||||
formData.details = [];
|
formData.details = [];
|
||||||
formData.details = thedetails.filter((it) => {
|
formData.details = thedetails.filter((it) => {
|
||||||
|
//去掉空值
|
||||||
|
it.twoSerialNumbers = it?.twoSerialNumbers?.filter(Boolean)
|
||||||
return it.qty && it.qty > 0;
|
return it.qty && it.qty > 0;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -875,6 +877,7 @@ export default {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
this.requestStatus = true;
|
this.requestStatus = true;
|
||||||
|
|
||||||
this.$api.post('/OutStock/Save', formData).then((res) => {
|
this.$api.post('/OutStock/Save', formData).then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -1112,8 +1115,6 @@ export default {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let boxwlIds = res.data.details.filter((item) => item.qty > 0).map((item) => item.materialNumber);
|
let boxwlIds = res.data.details.filter((item) => item.qty > 0).map((item) => item.materialNumber);
|
||||||
console.log(boxwlIds,'=boxwlIds=')
|
|
||||||
console.log(this.dataList,'=this.dataList=')
|
|
||||||
let datawlds = this.dataList.map((it) => {
|
let datawlds = this.dataList.map((it) => {
|
||||||
return it.materialNumber;
|
return it.materialNumber;
|
||||||
});
|
});
|
||||||
@@ -1371,6 +1372,7 @@ export default {
|
|||||||
// 扫描序列号数据处理
|
// 扫描序列号数据处理
|
||||||
setxlhdata(res) {
|
setxlhdata(res) {
|
||||||
let thindx = this.dataList.findIndex((it) => it.materialNumber == res.data.materialNumber);
|
let thindx = this.dataList.findIndex((it) => it.materialNumber == res.data.materialNumber);
|
||||||
|
|
||||||
// 如果这个序列存在明细信息就缓存
|
// 如果这个序列存在明细信息就缓存
|
||||||
if (!this.dataList[thindx].itxlhlist && this.dataList[thindx].itxlhlist.length == 0) {
|
if (!this.dataList[thindx].itxlhlist && this.dataList[thindx].itxlhlist.length == 0) {
|
||||||
this.dqYJnum = 0;
|
this.dqYJnum = 0;
|
||||||
@@ -1382,7 +1384,8 @@ export default {
|
|||||||
qty: 1,
|
qty: 1,
|
||||||
boxId: this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxId : res.data.boxId,
|
boxId: this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxId : res.data.boxId,
|
||||||
subStockCode: this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxsubStock : res.data.subStockCode,
|
subStockCode: this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxsubStock : res.data.subStockCode,
|
||||||
serialNumbers: res.data.serialNumber
|
serialNumbers: res.data.serialNumber,
|
||||||
|
twoSerialNumbers:res.data.twoSerialNumber
|
||||||
});
|
});
|
||||||
this.dataList[thindx].itxlhlist.push(this.xlhVal);
|
this.dataList[thindx].itxlhlist.push(this.xlhVal);
|
||||||
this.dataList[thindx].boxitNo = this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxName : res.data.boxBillNo;
|
this.dataList[thindx].boxitNo = this.isOldOps && this.isOldboxInfo.boxsubStock ? this.isOldboxInfo.boxName : res.data.boxBillNo;
|
||||||
@@ -1653,7 +1656,6 @@ export default {
|
|||||||
},
|
},
|
||||||
//根据出库单号获取对应的下拉数据
|
//根据出库单号获取对应的下拉数据
|
||||||
getCKselectlist(val) {
|
getCKselectlist(val) {
|
||||||
console.log('1232323')
|
|
||||||
// if (!val) return
|
// if (!val) return
|
||||||
clearTimeout(this.timer);
|
clearTimeout(this.timer);
|
||||||
this.pagingSet = false;
|
this.pagingSet = false;
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<view class="mianheade mianheade2" @click="goback()">
|
<view class="mianheade mianheade2" @click="goback()">
|
||||||
<image src="../../static/img/n_baiback.png" class="blacBackico"></image>
|
<image src="../../static/img/n_baiback.png" class="blacBackico"></image>
|
||||||
<!-- /生产 -->
|
<!-- /生产 -->
|
||||||
<text class="pagetitle">采购上架入库</text>
|
<text class="pagetitle">采购/生产上架入库</text>
|
||||||
</view>
|
</view>
|
||||||
<!-- 固定内容-->
|
<!-- 固定内容-->
|
||||||
<view class="sh_gdInfo">
|
<view class="sh_gdInfo">
|
||||||
@@ -231,6 +231,7 @@ export default {
|
|||||||
qktkTitle: '确定清空已收货数量?',
|
qktkTitle: '确定清空已收货数量?',
|
||||||
qktkContent: '清空后页面数据将不保存',
|
qktkContent: '清空后页面数据将不保存',
|
||||||
fid: '', // 来源单号
|
fid: '', // 来源单号
|
||||||
|
instockType:null,
|
||||||
orgCode: '', // 组织编码
|
orgCode: '', // 组织编码
|
||||||
dqboxNO: '', //用来是否保存当前输入箱号的值
|
dqboxNO: '', //用来是否保存当前输入箱号的值
|
||||||
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
APPdevice: uni.getStorageSync('devicePixelRatio'), // 缓存设备的像素比用来区分普通安卓normalAnroid还是pda
|
||||||
@@ -254,10 +255,10 @@ export default {
|
|||||||
if (!n) {
|
if (!n) {
|
||||||
this.cwselectList = [];
|
this.cwselectList = [];
|
||||||
this.subStockCode = null;
|
this.subStockCode = null;
|
||||||
this.orgCode = null;
|
// this.orgCode = null;
|
||||||
} else {
|
} else {
|
||||||
this.subStockCode = null;
|
this.subStockCode = null;
|
||||||
this.orgCode = null;
|
// this.orgCode = null;
|
||||||
this.getcwList(n);
|
this.getcwList(n);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -273,6 +274,7 @@ export default {
|
|||||||
this.$refs.wselect1.inputData = '';
|
this.$refs.wselect1.inputData = '';
|
||||||
this.cwselectList = [];
|
this.cwselectList = [];
|
||||||
this.daiboxstrList = [];
|
this.daiboxstrList = [];
|
||||||
|
this.orgCode="";
|
||||||
this.krcwInfo = {
|
this.krcwInfo = {
|
||||||
materialSubStocks: [],
|
materialSubStocks: [],
|
||||||
materialNumber: '',
|
materialNumber: '',
|
||||||
@@ -361,12 +363,11 @@ export default {
|
|||||||
if (!val) return;
|
if (!val) return;
|
||||||
clearTimeout(this.timer);
|
clearTimeout(this.timer);
|
||||||
this.timer = setTimeout(() => {
|
this.timer = setTimeout(() => {
|
||||||
this.$api.get('/InStockTask/GetSourceOrder/' + val).then((res) => {
|
this.$api.get('/InStockTask/GetSourceOrder/' + val +"&").then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
this.lyselectList = [];
|
this.lyselectList = [];
|
||||||
this.lyselectList = res.data && res.data.length>0? res.data.filter(element => element.waitSlefQty > 0):[]
|
this.lyselectList = res.data && res.data.length>0? res.data.filter(element => element.waitSlefQty > 0):[]
|
||||||
|
|
||||||
console.log(this.focusInput);
|
|
||||||
if (this.lyselectList && this.lyselectList.length == 1) {
|
if (this.lyselectList && this.lyselectList.length == 1) {
|
||||||
this.lyOrderNo = this.lyselectList[0].sourceBillNo;
|
this.lyOrderNo = this.lyselectList[0].sourceBillNo;
|
||||||
this.$refs.wselectlydd.filterList = res.data;
|
this.$refs.wselectlydd.filterList = res.data;
|
||||||
@@ -383,6 +384,7 @@ export default {
|
|||||||
this.$refs.wselectlydd.optionsShow = false;
|
this.$refs.wselectlydd.optionsShow = false;
|
||||||
this.$refs.wselectlydd.isShow = false;
|
this.$refs.wselectlydd.isShow = false;
|
||||||
}
|
}
|
||||||
|
// console.log(this.instockType,'=this.instockType=')
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}, 1000);
|
}, 1000);
|
||||||
@@ -392,13 +394,18 @@ export default {
|
|||||||
if (!this.lyOrderNo) {
|
if (!this.lyOrderNo) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
console.log(1111111111111,'=============')
|
||||||
|
// console.log(e,'===============>>>')
|
||||||
this.setItemdata(e);
|
this.setItemdata(e);
|
||||||
},
|
},
|
||||||
// 选中的来源订单号相关物料
|
// 选中的来源订单号相关物料
|
||||||
setItemdata(e) {
|
setItemdata(e) {
|
||||||
|
console.log(e,'==============e==============')
|
||||||
this.lyorderId = e.id;
|
this.lyorderId = e.id;
|
||||||
this.detailsId = e.detailsId;
|
this.detailsId = e.detailsId;
|
||||||
this.customerCode = e.customerCode;
|
this.customerCode = e.customerCode;
|
||||||
|
this.instockType = e.instockType;
|
||||||
|
this.orgCode =e.orgCode;
|
||||||
// 仓库名称
|
// 仓库名称
|
||||||
this.warehouseName = e.stockName;
|
this.warehouseName = e.stockName;
|
||||||
this.warehouseCode = e.stockCode;
|
this.warehouseCode = e.stockCode;
|
||||||
@@ -461,6 +468,7 @@ export default {
|
|||||||
orgCode: this.orgCode,
|
orgCode: this.orgCode,
|
||||||
stockCode: this.warehouseCode,
|
stockCode: this.warehouseCode,
|
||||||
subStockCode: this.subStockCode,
|
subStockCode: this.subStockCode,
|
||||||
|
instockType:this.instockType,
|
||||||
details: thedetails
|
details: thedetails
|
||||||
})
|
})
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
@@ -565,7 +573,8 @@ export default {
|
|||||||
this.$api
|
this.$api
|
||||||
.get('/SysConfig/GetSubUcStockByName', {
|
.get('/SysConfig/GetSubUcStockByName', {
|
||||||
name: val,
|
name: val,
|
||||||
stockCode: this.warehouseCode
|
stockCode: this.warehouseCode,
|
||||||
|
orgCode:this.orgCode,
|
||||||
})
|
})
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
@@ -581,8 +590,10 @@ export default {
|
|||||||
},
|
},
|
||||||
// 仓位下拉选择
|
// 仓位下拉选择
|
||||||
cwchange(e, type) {
|
cwchange(e, type) {
|
||||||
|
console.log(e,'=====================>')
|
||||||
|
console.log(this.instockType,'===============>')
|
||||||
this.subStockCode = e.code;
|
this.subStockCode = e.code;
|
||||||
this.orgCode = e.erpOrgCode;
|
// this.orgCode = e.erpOrgCode;
|
||||||
},
|
},
|
||||||
// 輸入失去焦點
|
// 輸入失去焦點
|
||||||
inputblur(val, type) {
|
inputblur(val, type) {
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="item" @click="otherPage(2)">
|
<view class="item" @click="otherPage(2)">
|
||||||
<image src="../../static/img/rk_fcgsjico.png" class="rkico"></image>
|
<image src="../../static/img/rk_fcgsjico.png" class="rkico"></image>
|
||||||
<text class="t1">采购上架</text>
|
<text class="t1">采购/生产上架</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="item" @click="otherPage(3)">
|
<view class="item" @click="otherPage(3)">
|
||||||
<image src="../../static/img/rk_cgsjico.png" class="rkico"></image>
|
<image src="../../static/img/rk_cgsjico.png" class="rkico"></image>
|
||||||
|
|||||||
@@ -419,17 +419,17 @@ export default {
|
|||||||
}
|
}
|
||||||
let dataForm = {};
|
let dataForm = {};
|
||||||
let details = [];
|
let details = [];
|
||||||
console.log(this.dataList);
|
console.log(this.dataList,);
|
||||||
details = this.dataList.map((it) => {
|
details = this.dataList.map((it) => {
|
||||||
return {
|
return {
|
||||||
qty: it.qty,
|
qty: it.qty,
|
||||||
supplierId: it.supplierId,
|
supplierId: it.supplierId,
|
||||||
materialNumber: it.materialNumber,
|
materialNumber: it.materialNumber,
|
||||||
serialNumbers: it.xlhList, //序列号集
|
serialNumbers: it.xlhList, //序列号集
|
||||||
erpDetailId: it.erpDetailId
|
erpDetailId: it.erpDetailId,
|
||||||
|
twoSerialNumbers:it.twoSerialNumbers ? it.twoSerialNumbers.filter(Boolean):[]
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
console.log('提交数据1', this.dataList, dataForm);
|
|
||||||
if (this.sjfsType == '按产品上架') {
|
if (this.sjfsType == '按产品上架') {
|
||||||
this.boxs[0].details = details;
|
this.boxs[0].details = details;
|
||||||
}
|
}
|
||||||
@@ -441,7 +441,7 @@ export default {
|
|||||||
subStockCode: this.subStockCode,
|
subStockCode: this.subStockCode,
|
||||||
boxs: this.boxs
|
boxs: this.boxs
|
||||||
};
|
};
|
||||||
console.log('dataForm', dataForm);
|
console.log('提交数据===dataForm===', dataForm);
|
||||||
// 节流
|
// 节流
|
||||||
if (this.requestStatus) {
|
if (this.requestStatus) {
|
||||||
return false;
|
return false;
|
||||||
@@ -480,6 +480,7 @@ export default {
|
|||||||
this.dataList.forEach((it) => {
|
this.dataList.forEach((it) => {
|
||||||
it.qty = 0;
|
it.qty = 0;
|
||||||
it.xlhList = [];
|
it.xlhList = [];
|
||||||
|
it.twoSerialNumbers=[]
|
||||||
});
|
});
|
||||||
this.qktkshow = false;
|
this.qktkshow = false;
|
||||||
this.focusInput = '';
|
this.focusInput = '';
|
||||||
@@ -783,10 +784,6 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.focusInput = '';
|
this.focusInput = '';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
console.log('序列號', this.xlhVal);
|
|
||||||
this.$api
|
this.$api
|
||||||
.get('/SysConfig/GetMaterial', {
|
.get('/SysConfig/GetMaterial', {
|
||||||
serialNumber: this.xlhVal,
|
serialNumber: this.xlhVal,
|
||||||
@@ -844,13 +841,16 @@ export default {
|
|||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.dataList = this.$util.scanAndAllocate(this.dataList, res.data.materialNumber, res.data.serialNumber);
|
//18LC-628W3Y CTN00094835
|
||||||
|
console.log('走到了这里')
|
||||||
|
this.dataList = this.$util.scanAndAllocate(this.dataList, res.data.materialNumber, res.data.serialNumber,res.data.twoSerialNumber);
|
||||||
// 缓存序列号
|
// 缓存序列号
|
||||||
this.xlhstrList.push(res.data.serialNumber);
|
this.xlhstrList.push(res.data.serialNumber);
|
||||||
//缓存2件装序列号
|
//缓存2件装序列号
|
||||||
if(res.data.isTwo==2) {
|
if(res.data.isTwo==2) {
|
||||||
this.twoData.push(res.data.twoSerialNumber)
|
this.twoData.push(res.data.twoSerialNumber)
|
||||||
}
|
}
|
||||||
|
|
||||||
//保留当前输入的数据
|
//保留当前输入的数据
|
||||||
this.dqboxXlh = res.data.serialNumber;
|
this.dqboxXlh = res.data.serialNumber;
|
||||||
this.xlhVal = res.data.serialNumber;
|
this.xlhVal = res.data.serialNumber;
|
||||||
@@ -874,6 +874,7 @@ export default {
|
|||||||
list.forEach((it) => {
|
list.forEach((it) => {
|
||||||
it.qty = 0;
|
it.qty = 0;
|
||||||
it.xlhList = [];
|
it.xlhList = [];
|
||||||
|
it.twoSerialNumbers=[]
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
console.log('根据序列号的时候明细数据结构', list);
|
console.log('根据序列号的时候明细数据结构', list);
|
||||||
@@ -895,8 +896,8 @@ export default {
|
|||||||
let objArray = [];
|
let objArray = [];
|
||||||
objArray = list;
|
objArray = list;
|
||||||
let newObjArray = objArray.map((obj) => {
|
let newObjArray = objArray.map((obj) => {
|
||||||
obj.zQty = JSON.parse(JSON.stringify(obj.qty)); // 修改 name 属性,这里是在姓名后加上 ' Smith'
|
obj.zQty = JSON.parse(JSON.stringify(obj.qty));
|
||||||
obj.qty = 0; // 添加 age 属性,这里设定年龄为 30
|
obj.qty = 0;
|
||||||
return obj;
|
return obj;
|
||||||
});
|
});
|
||||||
return objArray;
|
return objArray;
|
||||||
@@ -919,15 +920,6 @@ export default {
|
|||||||
this.heights.body = this.heights.body - 36;
|
this.heights.body = this.heights.body - 36;
|
||||||
this.heights = this.$util.setlistHeight('.sh_gdInfo', '.footbts');
|
this.heights = this.$util.setlistHeight('.sh_gdInfo', '.footbts');
|
||||||
}, 200);
|
}, 200);
|
||||||
// if(this.cwNum && this.cwselectList.length && !this.subStockCode){
|
|
||||||
// this.cwselectList.forEach((item)=>{
|
|
||||||
// if(item.name === this.cwNum) {
|
|
||||||
// this.subStockCode = item.code
|
|
||||||
// console.log(this.subStockCode,'=走到这里来了=')
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
|
|
||||||
this.$forceUpdate();
|
this.$forceUpdate();
|
||||||
},
|
},
|
||||||
// 获取仓位下拉数据
|
// 获取仓位下拉数据
|
||||||
@@ -942,14 +934,6 @@ export default {
|
|||||||
.then((res) => {
|
.then((res) => {
|
||||||
if (res.status == 200) {
|
if (res.status == 200) {
|
||||||
this.cwselectList = res.data;
|
this.cwselectList = res.data;
|
||||||
//&& this.cwselectList.length == 1
|
|
||||||
// if (this.cwselectList && this.cwselectList.length == 1) {
|
|
||||||
// this.cwNum = this.cwselectList[0].name;
|
|
||||||
// this.cwchange(this.cwselectList[0]);
|
|
||||||
// this.$refs.wselect1.optionsShow = false;
|
|
||||||
// this.$refs.wselect1.isShow = false;
|
|
||||||
// }
|
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,5 @@
|
|||||||
const BaseApi = 'https://api.wms.test.f2b211.com/api' //测试
|
//const BaseApi = 'https://api.wms.test.f2b211.com/api' //测试
|
||||||
//const BaseApi = 'https://wmsapi.f2b211.com/api' // 正式
|
const BaseApi = 'https://wmsapi.f2b211.com/api' // 正式
|
||||||
export {
|
export {
|
||||||
BaseApi
|
BaseApi
|
||||||
}
|
}
|
||||||
@@ -215,10 +215,14 @@ function subtractQty(mxArray, boxArray) {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
//按照产品分配序列号
|
//按照产品分配序列号
|
||||||
function scanAndAllocate(arr, materialNumber, serialNumber) {
|
function scanAndAllocate(arr, materialNumber, serialNumber,twoSerialNumber) {
|
||||||
|
console.log(twoSerialNumber,'=twoSerialNumber=')
|
||||||
// 遍历数组,按顺序分配序列号
|
// 遍历数组,按顺序分配序列号
|
||||||
for (const item of arr) {
|
for (const item of arr) {
|
||||||
if (item.materialNumber === materialNumber) {
|
if (item.materialNumber === materialNumber) {
|
||||||
|
if(twoSerialNumber) {
|
||||||
|
item.twoSerialNumbers.push(twoSerialNumber)
|
||||||
|
}
|
||||||
if (item.xlhList.length == 0) {
|
if (item.xlhList.length == 0) {
|
||||||
item.xlhList.push(serialNumber)
|
item.xlhList.push(serialNumber)
|
||||||
item.qty = item.xlhList.length
|
item.qty = item.xlhList.length
|
||||||
@@ -233,6 +237,7 @@ function scanAndAllocate(arr, materialNumber, serialNumber) {
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return arr
|
return arr
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
## 1.0.10(2025-04-14)
|
||||||
|
- 修复 清除按钮不展示问题
|
||||||
|
## 1.0.9(2025-03-26)
|
||||||
|
- 优化 默认背景为白色与整体组件保持风格统一
|
||||||
## 1.0.8(2024-03-28)
|
## 1.0.8(2024-03-28)
|
||||||
- 修复 在vue2下:style动态绑定导致编译失败的bug
|
- 修复 在vue2下:style动态绑定导致编译失败的bug
|
||||||
## 1.0.7(2024-01-20)
|
## 1.0.7(2024-01-20)
|
||||||
|
|||||||
@@ -6,10 +6,10 @@
|
|||||||
<view class="uni-select__input-box" @click="toggleSelector">
|
<view class="uni-select__input-box" @click="toggleSelector">
|
||||||
<view v-if="current" class="uni-select__input-text">{{textShow}}</view>
|
<view v-if="current" class="uni-select__input-text">{{textShow}}</view>
|
||||||
<view v-else class="uni-select__input-text uni-select__input-placeholder">{{typePlaceholder}}</view>
|
<view v-else class="uni-select__input-text uni-select__input-placeholder">{{typePlaceholder}}</view>
|
||||||
<view v-if="current && clear && !disabled" @click.stop="clearVal">
|
<view key="clear-button" v-if="current && clear && !disabled" @click.stop="clearVal">
|
||||||
<uni-icons type="clear" color="#c0c4cc" size="24" />
|
<uni-icons type="clear" color="#c0c4cc" size="24" />
|
||||||
</view>
|
</view>
|
||||||
<view v-else>
|
<view key="arrow-button" v-else>
|
||||||
<uni-icons :type="showSelector? 'top' : 'bottom'" size="14" color="#999" />
|
<uni-icons :type="showSelector? 'top' : 'bottom'" size="14" color="#999" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -143,9 +143,6 @@
|
|||||||
textShow() {
|
textShow() {
|
||||||
// 长文本显示
|
// 长文本显示
|
||||||
let text = this.current;
|
let text = this.current;
|
||||||
if (text.length > 10) {
|
|
||||||
return text.slice(0, 25) + '...';
|
|
||||||
}
|
|
||||||
return text;
|
return text;
|
||||||
},
|
},
|
||||||
getOffsetByPlacement() {
|
getOffsetByPlacement() {
|
||||||
@@ -244,6 +241,7 @@
|
|||||||
|
|
||||||
clearVal() {
|
clearVal() {
|
||||||
this.emit('')
|
this.emit('')
|
||||||
|
this.current = ''
|
||||||
if (this.collection) {
|
if (this.collection) {
|
||||||
this.removeCache()
|
this.removeCache()
|
||||||
}
|
}
|
||||||
@@ -352,6 +350,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.uni-stat-box {
|
.uni-stat-box {
|
||||||
|
background-color: #fff;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
@@ -405,6 +404,7 @@
|
|||||||
|
|
||||||
.uni-select__input-box {
|
.uni-select__input-box {
|
||||||
height: 35px;
|
height: 35px;
|
||||||
|
width: 0px;
|
||||||
position: relative;
|
position: relative;
|
||||||
/* #ifndef APP-NVUE */
|
/* #ifndef APP-NVUE */
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -433,6 +433,9 @@
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
left: 0;
|
left: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
min-width: 200rpx;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: nowrap;
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
border: 1px solid #EBEEF5;
|
border: 1px solid #EBEEF5;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"id": "uni-data-select",
|
"id": "uni-data-select",
|
||||||
"displayName": "uni-data-select 下拉框选择器",
|
"displayName": "uni-data-select 下拉框选择器",
|
||||||
"version": "1.0.8",
|
"version": "1.0.10",
|
||||||
"description": "通过数据驱动的下拉框选择器",
|
"description": "通过数据驱动的下拉框选择器",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"uni-ui",
|
"uni-ui",
|
||||||
@@ -48,8 +48,10 @@
|
|||||||
},
|
},
|
||||||
"client": {
|
"client": {
|
||||||
"App": {
|
"App": {
|
||||||
"app-vue": "u",
|
"app-vue": "y",
|
||||||
"app-nvue": "n"
|
"app-nvue": "n",
|
||||||
|
"app-harmony": "u",
|
||||||
|
"app-uvue": "u"
|
||||||
},
|
},
|
||||||
"H5-mobile": {
|
"H5-mobile": {
|
||||||
"Safari": "y",
|
"Safari": "y",
|
||||||
|
|||||||
Reference in New Issue
Block a user