From a1b487e3417efb1481c3ef5598dcc4894529f1d5 Mon Sep 17 00:00:00 2001 From: haoxuan <haoxuan> Date: 星期四, 18 四月 2024 16:42:04 +0800 Subject: [PATCH] 出入库明细打印的接口联调+根据公司的不同设置不同的打印宽度 --- src/views/overview/AddOverviewDialog.vue | 21 +++++++++++++-------- 1 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/views/overview/AddOverviewDialog.vue b/src/views/overview/AddOverviewDialog.vue index 7efbea8..462936e 100644 --- a/src/views/overview/AddOverviewDialog.vue +++ b/src/views/overview/AddOverviewDialog.vue @@ -1154,13 +1154,13 @@ }, saveParams() { let data = this.editConfig.infomation; - let companyID = 0; + let companyID = ''; let companyName = ""; - let contacterID = 0; + let contacterID = ''; let contacterName = ""; if (this.editConfig.title == "鏂板缓") { companyID = - Object.keys(this.companyObj).length == 0 ? 0 : this.companyObj.value; + Object.keys(this.companyObj).length == 0 ? '' : this.companyObj.value; companyName = Object.keys(this.companyObj).length == 0 ? "" @@ -1483,7 +1483,7 @@ productName: res.name, productId: res.id, auxiliaryUnit:adjunctUnit, - auxiliaryAmount:adjunctAmount, + auxiliaryAmount:Number(adjunctAmount), inputFloatAuxiliaryAmount:isValue, grossWeight:res.grossWeight, totalGrossWeight:res.grossWeight?Number(res.grossWeight)*1:'', @@ -1684,14 +1684,19 @@ console.log(res); if (res.code == 200) { console.log(this.editConfig.infomation.baseOperationType, "绫诲瀷"); + let name='' + if(res.data){ + name=res.data.name?res.data.name:'' + } let pdfParams = { - url: res.data, + url: res.data?res.data.url:'', baseOperationType: this.editConfig.infomation.baseOperationType || undefined, - cutAfterWidth: - this.editConfig.infomation.baseOperationType == 2 + // 1鏄槈鑱� + cutAfterWidth:name=='jialian'?52.6: + (this.editConfig.infomation.baseOperationType == 2 ? 50.8 - : 53.3, + : 53.3), }; var { href } = this.$router.resolve({ path: "/overview/previewExcel", -- Gitblit v1.8.0