剩余模块:生产退料
This commit is contained in:
parent
a59dd54c27
commit
63a44af1d8
@ -198,7 +198,7 @@
|
|||||||
const str = JSON.stringify(obj);
|
const str = JSON.stringify(obj);
|
||||||
console.log(item);
|
console.log(item);
|
||||||
temporaryScanDraftSave({
|
temporaryScanDraftSave({
|
||||||
FVHUBFormId: "SAL_DELIVERYNOTICE", //数据类型
|
FVHUBFormId: "SAL_OUTSTOCK", //数据类型
|
||||||
FVHUBFBillNo: state.FBillNo, //单据编号
|
FVHUBFBillNo: state.FBillNo, //单据编号
|
||||||
FVHUBScanNumber: state.queryString, //条码
|
FVHUBScanNumber: state.queryString, //条码
|
||||||
FVHUBMaterialNumber: item.articlesStr, //物料编码
|
FVHUBMaterialNumber: item.articlesStr, //物料编码
|
||||||
@ -234,7 +234,7 @@
|
|||||||
}
|
}
|
||||||
const scanRecordFun = () => {
|
const scanRecordFun = () => {
|
||||||
toPages('/pages/records/index', {
|
toPages('/pages/records/index', {
|
||||||
FormId: 'SAL_DELIVERYNOTICE',
|
FormId: 'SAL_OUTSTOCK',
|
||||||
FbillNo: state.FBillNo
|
FbillNo: state.FBillNo
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -250,7 +250,7 @@
|
|||||||
let ids : any = []
|
let ids : any = []
|
||||||
let ScanEntry : any = []
|
let ScanEntry : any = []
|
||||||
let param = {
|
let param = {
|
||||||
FormId: 'SAL_DELIVERYNOTICE',
|
FormId: 'SAL_OUTSTOCK',
|
||||||
UserId: uni.getStorageSync('userInfo').Context.UserId,
|
UserId: uni.getStorageSync('userInfo').Context.UserId,
|
||||||
FbillNo: state.FBillNo
|
FbillNo: state.FBillNo
|
||||||
};
|
};
|
||||||
@ -273,7 +273,7 @@
|
|||||||
})
|
})
|
||||||
//推送数据
|
//推送数据
|
||||||
SAL_OUTSTOCKCheck({
|
SAL_OUTSTOCKCheck({
|
||||||
Ids: ids,
|
Ids: state.materialId,
|
||||||
EntryIds: EntryIds.toString(),
|
EntryIds: EntryIds.toString(),
|
||||||
}).then((res : any) => {
|
}).then((res : any) => {
|
||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
|
@ -153,31 +153,37 @@
|
|||||||
command.setSize(100, 50)
|
command.setSize(100, 50)
|
||||||
command.setGap(2)
|
command.setGap(2)
|
||||||
command.setCls()
|
command.setCls()
|
||||||
command.setQR(15, 15, "L", 3, "A", item.FBarCode)
|
command.setQR(30, 100, "L", 7, "A", item.FBarCode)
|
||||||
command.setText(120, 15, "TSS24.BF2", 1, 1, `Date:${item.FDate.split('T')[0]}`)
|
command.setText(280, 40, "TSS24.BF2", 1, 1, `Supplier Name:${item.FSupplierId}`)
|
||||||
command.setText(120, 40, "TSS24.BF2", 1, 1, `MO#:${item.FSrcBillNo}`)
|
command.setText(280, 80, "TSS24.BF2", 1, 1, `P/N:${item.FMaterialId}`)
|
||||||
command.setText(120, 65, "TSS24.BF2", 1, 1, `P/N:${item.FMaterialId}`)
|
command.setText(280, 120, "TSS24.BF2", 1, 1, `Qty:${item.FQty}`)
|
||||||
command.setText(120, 90, "TSS24.BF2", 1, 1, `SN#:${item.FSno}`)
|
command.setText(280, 160, "TSS24.BF2", 1, 1, `Batch No:${item.FLot}`)
|
||||||
|
command.setText(280, 200, "TSS24.BF2", 1, 1, `Supplier Lot No:${item.FSupplierLot}`)
|
||||||
|
command.setText(280, 240, "TSS24.BF2", 1, 1, `PO:${state.pageData.PO}`)
|
||||||
|
command.setText(280, 280, "TSS24.BF2", 1, 1, `Delivery Date:${state.pageData.Date}`)
|
||||||
|
command.setText(280, 320, "TSS24.BF2", 1, 1, `GRN #:${state.pageData.FBillCode}`)
|
||||||
command.setPagePrint()
|
command.setPagePrint()
|
||||||
state.sendData = command.getData();
|
state.sendData = command.getData();
|
||||||
}
|
}
|
||||||
const sendHexStr = () => {
|
const sendHexStr = () => {
|
||||||
let arr = []
|
let arr = []
|
||||||
let data1 = {
|
let data1 = {
|
||||||
FBarCodeRule: "171064",
|
FBarCodeRule: "01",
|
||||||
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.FQty) - Number(state.pageData.splitQty)}`,
|
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.FQty) - Number(state.pageData.splitQty)}`,
|
||||||
FBillCode:state.pageData.FBillCode,
|
FBillCode:state.pageData.FBillCode,
|
||||||
FMaterialId: state.pageData.FMaterialId,
|
FMaterialId: state.pageData.FMaterialId,
|
||||||
FSupplierLot: state.pageData.FSupplierId,
|
FSupplierLot: state.pageData.FSupplierLot,
|
||||||
FQty: Number(state.pageData.FQty) - Number(state.pageData.splitQty)
|
FLot: state.pageData.FLotText,
|
||||||
|
FQty: (Number(state.pageData.FQty) - Number(state.pageData.splitQty)) + ''
|
||||||
}
|
}
|
||||||
let data2 = {
|
let data2 = {
|
||||||
FBarCodeRule: "171064",
|
FBarCodeRule: "01",
|
||||||
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.splitQty)}`,
|
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.splitQty)}`,
|
||||||
FBillCode:state.pageData.FBillCode,
|
FBillCode:state.pageData.FBillCode,
|
||||||
FMaterialId: state.pageData.FMaterialId,
|
FMaterialId: state.pageData.FMaterialId,
|
||||||
FSupplierLot: state.pageData.FSupplierId,
|
FSupplierLot: state.pageData.FSupplierLot,
|
||||||
FQty: Number(state.pageData.splitQty)
|
FLot: state.pageData.FLotText,
|
||||||
|
FQty: Number(state.pageData.splitQty) + ''
|
||||||
}
|
}
|
||||||
arr = [data1,data2]
|
arr = [data1,data2]
|
||||||
UHIK_BD_BarCodeMainFileSave({
|
UHIK_BD_BarCodeMainFileSave({
|
||||||
@ -185,40 +191,19 @@
|
|||||||
Items: arr
|
Items: arr
|
||||||
},true).then((res : any) => {
|
},true).then((res : any) => {
|
||||||
console.log(res);
|
console.log(res);
|
||||||
// if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
// let i : number = 0;
|
|
||||||
// state.timer = setInterval(() => {
|
setTimeout(()=>{
|
||||||
// if (state.printState === '0') {
|
createLabel(arr[0])
|
||||||
// createLabel(state.prontList[i])
|
initPrint()
|
||||||
// initPrint()
|
},2000)
|
||||||
// i++;
|
setTimeout(()=>{
|
||||||
// }
|
createLabel(arr[1])
|
||||||
// if (state.prontList.length == i) {
|
initPrint()
|
||||||
// clearInterval(state.timer);
|
},4000)
|
||||||
// state.timer = null;
|
} else {
|
||||||
// state.printState = '0';
|
uni.$u.toast(res.msg)
|
||||||
// }
|
}
|
||||||
// }, 2000);
|
|
||||||
// } else {
|
|
||||||
// let str = JSON.stringify(res)
|
|
||||||
// if(str.indexOf('违反字段唯一性要求') !== -1 || str.indexOf('is already been used') !== -1){
|
|
||||||
// let i : number = 0;
|
|
||||||
// state.timer = setInterval(() => {
|
|
||||||
// if (state.printState === '0') {
|
|
||||||
// createLabel(state.prontList[i])
|
|
||||||
// initPrint()
|
|
||||||
// i++;
|
|
||||||
// }
|
|
||||||
// if (state.prontList.length == i) {
|
|
||||||
// clearInterval(state.timer);
|
|
||||||
// state.timer = null;
|
|
||||||
// state.printState = '0';
|
|
||||||
// }
|
|
||||||
// }, 2000);
|
|
||||||
// } else {
|
|
||||||
// uni.$u.toast(t('index.cjbqsb'))
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
58
unpackage/dist/dev/app-plus/app-service.js
vendored
58
unpackage/dist/dev/app-plus/app-service.js
vendored
@ -13942,38 +13942,56 @@ ${codeFrame}` : message2);
|
|||||||
command.setSize(100, 50);
|
command.setSize(100, 50);
|
||||||
command.setGap(2);
|
command.setGap(2);
|
||||||
command.setCls();
|
command.setCls();
|
||||||
command.setQR(15, 15, "L", 3, "A", item.FBarCode);
|
command.setQR(30, 100, "L", 7, "A", item.FBarCode);
|
||||||
command.setText(120, 15, "TSS24.BF2", 1, 1, `Date:${item.FDate.split("T")[0]}`);
|
command.setText(280, 40, "TSS24.BF2", 1, 1, `Supplier Name:${item.FSupplierId}`);
|
||||||
command.setText(120, 40, "TSS24.BF2", 1, 1, `MO#:${item.FSrcBillNo}`);
|
command.setText(280, 80, "TSS24.BF2", 1, 1, `P/N:${item.FMaterialId}`);
|
||||||
command.setText(120, 65, "TSS24.BF2", 1, 1, `P/N:${item.FMaterialId}`);
|
command.setText(280, 120, "TSS24.BF2", 1, 1, `Qty:${item.FQty}`);
|
||||||
command.setText(120, 90, "TSS24.BF2", 1, 1, `SN#:${item.FSno}`);
|
command.setText(280, 160, "TSS24.BF2", 1, 1, `Batch No:${item.FLot}`);
|
||||||
|
command.setText(280, 200, "TSS24.BF2", 1, 1, `Supplier Lot No:${item.FSupplierLot}`);
|
||||||
|
command.setText(280, 240, "TSS24.BF2", 1, 1, `PO:${state.pageData.PO}`);
|
||||||
|
command.setText(280, 280, "TSS24.BF2", 1, 1, `Delivery Date:${state.pageData.Date}`);
|
||||||
|
command.setText(280, 320, "TSS24.BF2", 1, 1, `GRN #:${state.pageData.FBillCode}`);
|
||||||
command.setPagePrint();
|
command.setPagePrint();
|
||||||
state.sendData = command.getData();
|
state.sendData = command.getData();
|
||||||
};
|
};
|
||||||
const sendHexStr = () => {
|
const sendHexStr = () => {
|
||||||
let arr = [];
|
let arr = [];
|
||||||
let data1 = {
|
let data1 = {
|
||||||
FBarCodeRule: "171064",
|
FBarCodeRule: "01",
|
||||||
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.FQty) - Number(state.pageData.splitQty)}`,
|
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.FQty) - Number(state.pageData.splitQty)}`,
|
||||||
FBillCode: state.pageData.FBillCode,
|
FBillCode: state.pageData.FBillCode,
|
||||||
FMaterialId: state.pageData.FMaterialId,
|
FMaterialId: state.pageData.FMaterialId,
|
||||||
FSupplierLot: state.pageData.FSupplierId,
|
FSupplierLot: state.pageData.FSupplierLot,
|
||||||
FQty: Number(state.pageData.FQty) - Number(state.pageData.splitQty)
|
FLot: state.pageData.FLotText,
|
||||||
|
FQty: Number(state.pageData.FQty) - Number(state.pageData.splitQty) + ""
|
||||||
};
|
};
|
||||||
let data2 = {
|
let data2 = {
|
||||||
FBarCodeRule: "171064",
|
FBarCodeRule: "01",
|
||||||
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.splitQty)}`,
|
FBarCode: `${state.pageData.FBillCode}*${state.pageData.FMaterialId}*${state.pageData.FLotText}*${Number(state.pageData.splitQty)}`,
|
||||||
FBillCode: state.pageData.FBillCode,
|
FBillCode: state.pageData.FBillCode,
|
||||||
FMaterialId: state.pageData.FMaterialId,
|
FMaterialId: state.pageData.FMaterialId,
|
||||||
FSupplierLot: state.pageData.FSupplierId,
|
FSupplierLot: state.pageData.FSupplierLot,
|
||||||
FQty: Number(state.pageData.splitQty)
|
FLot: state.pageData.FLotText,
|
||||||
|
FQty: Number(state.pageData.splitQty) + ""
|
||||||
};
|
};
|
||||||
arr = [data1, data2];
|
arr = [data1, data2];
|
||||||
UHIK_BD_BarCodeMainFileSave({
|
UHIK_BD_BarCodeMainFileSave({
|
||||||
Key: "qwe123!@#",
|
Key: "qwe123!@#",
|
||||||
Items: arr
|
Items: arr
|
||||||
}, true).then((res2) => {
|
}, true).then((res2) => {
|
||||||
formatAppLog("log", "at pages/split/print.vue:187", res2);
|
formatAppLog("log", "at pages/split/print.vue:193", res2);
|
||||||
|
if (res2.code == 200) {
|
||||||
|
setTimeout(() => {
|
||||||
|
createLabel(arr[0]);
|
||||||
|
initPrint();
|
||||||
|
}, 2e3);
|
||||||
|
setTimeout(() => {
|
||||||
|
createLabel(arr[1]);
|
||||||
|
initPrint();
|
||||||
|
}, 4e3);
|
||||||
|
} else {
|
||||||
|
uni.$u.toast(res2.msg);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
const initPrint = () => {
|
const initPrint = () => {
|
||||||
@ -13997,16 +14015,16 @@ ${codeFrame}` : message2);
|
|||||||
return resArr;
|
return resArr;
|
||||||
}
|
}
|
||||||
var sendloop = splitString(hexStr, 250);
|
var sendloop = splitString(hexStr, 250);
|
||||||
formatAppLog("log", "at pages/split/print.vue:249", sendloop.length);
|
formatAppLog("log", "at pages/split/print.vue:234", sendloop.length);
|
||||||
function realWriteData(sendloop2, i2) {
|
function realWriteData(sendloop2, i2) {
|
||||||
var data2 = sendloop2[i2];
|
var data2 = sendloop2[i2];
|
||||||
if (typeof data2 == "undefined") {
|
if (typeof data2 == "undefined") {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
formatAppLog("log", "at pages/split/print.vue:255", "第【" + i2 + "】次写数据" + data2);
|
formatAppLog("log", "at pages/split/print.vue:240", "第【" + i2 + "】次写数据" + data2);
|
||||||
blueModule.sendHexStr(data2, (result) => {
|
blueModule.sendHexStr(data2, (result) => {
|
||||||
formatAppLog("log", "at pages/split/print.vue:258", "发送结果");
|
formatAppLog("log", "at pages/split/print.vue:243", "发送结果");
|
||||||
formatAppLog("log", "at pages/split/print.vue:259", result);
|
formatAppLog("log", "at pages/split/print.vue:244", result);
|
||||||
if (!result.success) {
|
if (!result.success) {
|
||||||
uni.$u.toast(t("index.ljydk"));
|
uni.$u.toast(t("index.ljydk"));
|
||||||
uni.setStorageSync("printInfo", {});
|
uni.setStorageSync("printInfo", {});
|
||||||
@ -31260,7 +31278,7 @@ This will fail in production if not fixed.`);
|
|||||||
const str = JSON.stringify(obj);
|
const str = JSON.stringify(obj);
|
||||||
formatAppLog("log", "at pages/BatchOutOftock/material.vue:199", item);
|
formatAppLog("log", "at pages/BatchOutOftock/material.vue:199", item);
|
||||||
temporaryScanDraftSave({
|
temporaryScanDraftSave({
|
||||||
FVHUBFormId: "SAL_DELIVERYNOTICE",
|
FVHUBFormId: "SAL_OUTSTOCK",
|
||||||
//数据类型
|
//数据类型
|
||||||
FVHUBFBillNo: state.FBillNo,
|
FVHUBFBillNo: state.FBillNo,
|
||||||
//单据编号
|
//单据编号
|
||||||
@ -31302,7 +31320,7 @@ This will fail in production if not fixed.`);
|
|||||||
};
|
};
|
||||||
const scanRecordFun = () => {
|
const scanRecordFun = () => {
|
||||||
toPages("/pages/records/index", {
|
toPages("/pages/records/index", {
|
||||||
FormId: "SAL_DELIVERYNOTICE",
|
FormId: "SAL_OUTSTOCK",
|
||||||
FbillNo: state.FBillNo
|
FbillNo: state.FBillNo
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
@ -31318,7 +31336,7 @@ This will fail in production if not fixed.`);
|
|||||||
let ids = [];
|
let ids = [];
|
||||||
let ScanEntry = [];
|
let ScanEntry = [];
|
||||||
let param = {
|
let param = {
|
||||||
FormId: "SAL_DELIVERYNOTICE",
|
FormId: "SAL_OUTSTOCK",
|
||||||
UserId: uni.getStorageSync("userInfo").Context.UserId,
|
UserId: uni.getStorageSync("userInfo").Context.UserId,
|
||||||
FbillNo: state.FBillNo
|
FbillNo: state.FBillNo
|
||||||
};
|
};
|
||||||
@ -31339,7 +31357,7 @@ This will fail in production if not fixed.`);
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
SAL_OUTSTOCKCheck({
|
SAL_OUTSTOCKCheck({
|
||||||
Ids: ids,
|
Ids: state.materialId,
|
||||||
EntryIds: EntryIds.toString()
|
EntryIds: EntryIds.toString()
|
||||||
}).then((res3) => {
|
}).then((res3) => {
|
||||||
if (res3.code === 200) {
|
if (res3.code === 200) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user