质量检验不合格数量处理

master
guoshuang 10 months ago
parent 97f255f2c4
commit 19d5b99955

@ -143,7 +143,7 @@ export default class LoginPage extends BasePage {
} }
///****************** ///******************
version = '0.0.96'; // version = '0.0.96'; //
//version = '0.0.7'; // //version = '0.0.9'; //
//*************** false true **************** //*************** false true ****************
//isTest = true; //isTest = true;

@ -812,7 +812,29 @@ export default class PurchaseWHSRM extends BasePage {
item.checkType = this.selectList.value; item.checkType = this.selectList.value;
item.orderCode = this.clickitem.orderNo; item.orderCode = this.clickitem.orderNo;
item.files = []; item.files = [];
let defectObj = {};
if (item.defectNames != null) {
item.defectNames.split(',').forEach((item) => {
let [key, value] = item.split(':');
defectObj[key.trim()] = parseFloat(value.trim());
});
// console.log(defectObj, '');
// console.log(this.defectCodelist, '');
let olddefectCodelist = [];
olddefectCodelist = JSON.parse(JSON.stringify(this.defectCodelist));
// console.log(olddefectCodelist, 'old');
olddefectCodelist.forEach((item) => {
if (Object.prototype.hasOwnProperty.call(defectObj, item.label)) {
// console.log('', defectObj[item.label]);
item.numberall = defectObj[item.label];
}
});
item.babtype = olddefectCodelist;
} else {
item.babtype = this.defectCodelist; item.babtype = this.defectCodelist;
}
//this.defectCodelist;
item.defectlabel = null; item.defectlabel = null;
}); });
//this.determine(); //this.determine();
@ -865,6 +887,7 @@ export default class PurchaseWHSRM extends BasePage {
// await this.model.getpalletLocation(params); //23 // await this.model.getpalletLocation(params); //23
} }
async selectbabTypelist(babtypelist, index) { async selectbabTypelist(babtypelist, index) {
//console.log('9990000',babtypelist, index);
this.detaillistceshi[index].babtype = babtypelist; this.detaillistceshi[index].babtype = babtypelist;
let defectCode = []; let defectCode = [];
let defectQuality = []; let defectQuality = [];
@ -894,10 +917,12 @@ export default class PurchaseWHSRM extends BasePage {
} }
}); });
} }
//console.log(mergedObject, '');
const array3 = Object.keys(mergedObject).map((defectCode) => ({ const array3 = Object.keys(mergedObject).map((defectCode) => ({
defectCode, defectCode,
value: mergedObject[defectCode], value: mergedObject[defectCode],
})); }));
//console.log(array3, '');
for (let index = 0; index < array3.length; index++) { for (let index = 0; index < array3.length; index++) {
this.detaillistdefects.forEach((item) => { this.detaillistdefects.forEach((item) => {
@ -1000,6 +1025,7 @@ export default class PurchaseWHSRM extends BasePage {
} }
focustype(item, value, index) { focustype(item, value, index) {
//console.log('',item,value,index);
this.isfocus = false; this.isfocus = false;
this.$nextTick(() => { this.$nextTick(() => {
this.isfocus = true; this.isfocus = true;
@ -1147,13 +1173,13 @@ export default class PurchaseWHSRM extends BasePage {
}); });
return; return;
} }
if (this.selectdisqualificationType.value === null || this.selectdisqualificationType.value === '') { // if (this.selectdisqualificationType.value === null || this.selectdisqualificationType.value === '') {
(this.$refs.uToast as any).show({ // (this.$refs.uToast as any).show({
title: '不良分类不能为空', // title: '',
type: 'default', // type: 'default',
}); // });
return; // return;
} // }
} }
} }
//oa //oa

@ -175,7 +175,7 @@ export default class BatchOfflineStorage extends BasePage {
async query() { async query() {
if (this.orderNo == '' || this.orderNo.length == 0) { if (this.orderNo == '' || this.orderNo.length == 0) {
(this.$refs.uToast as any).show({ (this.$refs.uToast as any).show({
title: '请扫描标志码', title: '请扫描标志码',
// url: '/pages/user/index' // url: '/pages/user/index'
}); });
return; return;
@ -187,7 +187,7 @@ export default class BatchOfflineStorage extends BasePage {
let chongfuscan = this.list.some((item) => item.pallet === this.orderNoItemList.pallet); let chongfuscan = this.list.some((item) => item.pallet === this.orderNoItemList.pallet);
if (chongfuscan) { if (chongfuscan) {
(this.$refs.uToast as any).show({ (this.$refs.uToast as any).show({
title: '重复扫描标志卡', title: '请勿重复扫描标志卡',
// url: '/pages/user/index' // url: '/pages/user/index'
}); });
return; return;

Loading…
Cancel
Save