From ceebfefe03f01f2a2978d5b1d491500e906fe6dd Mon Sep 17 00:00:00 2001 From: lxd <1004405501@qq.com> Date: Fri, 27 Dec 2024 17:25:47 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BF=9D=E5=AD=98=E5=92=8C?= =?UTF-8?q?=E4=B8=9A=E5=8A=A1=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/tblist/patientexamlist/index.ts | 2 +- src/views/ECG/ECGForm.vue | 10 +++++----- src/views/ECG/ECGhtml.vue | 19 +++++++++++++------ 3 files changed, 19 insertions(+), 12 deletions(-) diff --git a/src/api/tblist/patientexamlist/index.ts b/src/api/tblist/patientexamlist/index.ts index 49197e82..e39aba59 100644 --- a/src/api/tblist/patientexamlist/index.ts +++ b/src/api/tblist/patientexamlist/index.ts @@ -34,7 +34,7 @@ export interface PatientexamlistVO { billDoctorDepartment: string// 开单科室 送检科室 StudyInsta: string isFavourite: string //是否收藏 - pdfurl: String//pdf地址 + pdfurl: string//pdf地址 warning: String//是否有危急值 applyhighLevelname: String//申请上级机构医生 } diff --git a/src/views/ECG/ECGForm.vue b/src/views/ECG/ECGForm.vue index 4dc057ff..5d72b9d0 100644 --- a/src/views/ECG/ECGForm.vue +++ b/src/views/ECG/ECGForm.vue @@ -892,8 +892,8 @@ function Refresh() { //复制链接 function touchCopy () { // 调用 - if (rowinfo.value.pdfurl) { - toClipboard(rowinfo.value.pdfurl) + if (applyFormVO.value.pdfurl) { + toClipboard(applyFormVO.value.pdfurl) message.alertSuccess('复制成功') } else { message.alertError('请先保存后再进行复制') @@ -902,7 +902,7 @@ function touchCopy () { /** 申请后更新上级机构字段*/ const getuporghiorgid = async (id: number, orgId: string) => { try { - if (rowinfo.value.highLevelOrgId) { + if (applyFormVO.value.highLevelOrgId) { message.alertWarning('已提交申请') return } @@ -972,10 +972,10 @@ function FD() { } //分享点击 function shareclick() { - if (rowinfo.value.pdfurl) { + if (applyFormVO.value.diagDate) { isshare.value = false // 确保 DOM 已经渲染 - QRCode.toCanvas(qrcodeRef.value, rowinfo.value.pdfurl, function (error) { + QRCode.toCanvas(qrcodeRef.value, applyFormVO.value.pdfurl, function (error) { if (error) console.error(error) console.log('QR code generated!') }) diff --git a/src/views/ECG/ECGhtml.vue b/src/views/ECG/ECGhtml.vue index 37ded7a2..0d493895 100644 --- a/src/views/ECG/ECGhtml.vue +++ b/src/views/ECG/ECGhtml.vue @@ -211,7 +211,7 @@ onMounted(async () => { // topCanvas.value = document.getElementById('topCanvas'); }) -nextTick(() => { +nextTick(async () => { /* 计算宽度和高度*/ var canvasContainer = document.getElementById('canvas-container') var canvasContainer1 = document.getElementById('canvas-container1') @@ -255,7 +255,7 @@ nextTick(() => { leftCanvas.height = ahe - 118 heightoff.value=(ahe -118)/6 } - fetchData() + await fetchData() }) // 定义异步方法 @@ -456,11 +456,18 @@ function handleFileChange() { const json = JSON.parse(text.value) leads.forEach((lead, index) => { - const value = json[lead].trim() - const commaSeparatedValue = value.replace(/\s+/g, ',') - const numberArray = commaSeparatedValue.split(',').map(Number) - beatArray1.value.push(numberArray) + const value = json[lead] + + beatArray1.value.push(value) }) + // leads.forEach((lead, index) => { + // const value = json[lead]?json[lead].trim():"" + // if(!json[lead]) + // console.log("xxxxxxxx "+lead) + // const commaSeparatedValue = value.replace(/\s+/g, ',') + // const numberArray = commaSeparatedValue.split(',').map(Number) + // beatArray1.value.push(numberArray) + // }) beatArray2.value = beatArray1.value.slice() }