ecg图片pdf

This commit is contained in:
旺仔 2025-01-08 16:21:27 +08:00
parent dbacfdaa16
commit 7e936d62ef
2 changed files with 19 additions and 1 deletions

View File

@ -101,6 +101,10 @@ export const EcganalysisparasApi = {
SaveEcgPdf: async (data: EcganalysisparasVO) => { SaveEcgPdf: async (data: EcganalysisparasVO) => {
return await request.put({ url: `/tblist/ecganalysisparas/SaveEcgPdf`, data }) return await request.put({ url: `/tblist/ecganalysisparas/SaveEcgPdf`, data })
}, },
// 调用打印服务生成pdf(图片数据)
SaveEcgPdf_image: async (data: any) => {
return await request.post({ url: `/tblist/ecganalysisparas/SaveEcgPdf_image`, data })
},
getDoctorBydoctorID: async (doctorID: any) => { getDoctorBydoctorID: async (doctorID: any) => {
return await request.get({ url: `/doctor/getBydoctorID?doctorID=` + doctorID }) return await request.get({ url: `/doctor/getBydoctorID?doctorID=` + doctorID })
}, },

View File

@ -911,6 +911,17 @@ const save = async () => {
) )
) { ) {
await EcganalysisparasApi.SaveEcgPdf(saveFormVO.value) await EcganalysisparasApi.SaveEcgPdf(saveFormVO.value)
} else {
await EcganalysisparasApi.SaveEcgPdf_image({
type: '2',
filepath: queryParams.value.ecgJsonDataFilePath,
regid: id.value,
examid: rowinfo.value.examId,
orgid: orgid.value,
diagContent: queryParams.value.doctorDiagResult,
doctorId: Profilevo.value.doctorID,
doctorName: Profilevo.value.doctorname
})
} }
// //
await getPatientexamlist(keyid.value) await getPatientexamlist(keyid.value)
@ -987,6 +998,8 @@ function print() {
isdiagshow.value = false isdiagshow.value = false
if (applyFormVO.value && applyFormVO.value.reportstatus != '已审核') { if (applyFormVO.value && applyFormVO.value.reportstatus != '已审核') {
message.alertError('请审核后再进行打印') message.alertError('请审核后再进行打印')
} else if (!applyFormVO.value.pdfurl) {
message.alertError('未获取到相关数据')
} else { } else {
//isprintimage.value = true //isprintimage.value = true
isdiagshow.value = true isdiagshow.value = true
@ -994,7 +1007,7 @@ function print() {
setTimeout(async () => { setTimeout(async () => {
if (applyFormVO.value.pdfurl) { if (applyFormVO.value.pdfurl) {
imagebase64_new.value = applyFormVO.value.pdfurl.trim() imagebase64_new.value = applyFormVO.value.pdfurl.trim()
} else { } else if (false) {
let doctorEcgDiagInfo: any = null let doctorEcgDiagInfo: any = null
if (queryParams.value && queryParams.value.doctorId) { if (queryParams.value && queryParams.value.doctorId) {
doctorEcgDiagInfo = await EcganalysisparasApi.getDoctorBydoctorID( doctorEcgDiagInfo = await EcganalysisparasApi.getDoctorBydoctorID(
@ -1036,6 +1049,7 @@ function print() {
doctorName: queryParams.value.doctorName, doctorName: queryParams.value.doctorName,
image: doctorEcgDiagInfo ? doctorEcgDiagInfo.esignatureUrl : '', image: doctorEcgDiagInfo ? doctorEcgDiagInfo.esignatureUrl : '',
filepath: queryParams.value.ecgJsonDataFilePath, filepath: queryParams.value.ecgJsonDataFilePath,
orgid: orgid.value,
orgname: rowinfo.value.orgName orgname: rowinfo.value.orgName
}) })
if (mapRes && mapRes.code == '200') { if (mapRes && mapRes.code == '200') {