修改匿名化报告
Showing
4 changed files
with
18 additions
and
3 deletions
| ... | @@ -352,6 +352,13 @@ export const htmlToWord = (params) => request({ | ... | @@ -352,6 +352,13 @@ export const htmlToWord = (params) => request({ |
| 352 | responseType: 'blob' | 352 | responseType: 'blob' |
| 353 | }) | 353 | }) |
| 354 | 354 | ||
| 355 | export const downloadAnonReport = (params) => request({ | ||
| 356 | url: `${import.meta.env.VITE_APP_ANONYMIZATION_BASEURL}/anon-task/download`, | ||
| 357 | method: 'postJsonD', | ||
| 358 | data: params, | ||
| 359 | responseType: 'blob' | ||
| 360 | }) | ||
| 361 | |||
| 355 | export const scanFolder = (dirPath = '') => request({ | 362 | export const scanFolder = (dirPath = '') => request({ |
| 356 | url: `${import.meta.env.VITE_APP_DIGITAL_CONTRACT_URL}/anon-task/directory/scan?dirPath=${dirPath}`, | 363 | url: `${import.meta.env.VITE_APP_DIGITAL_CONTRACT_URL}/anon-task/directory/scan?dirPath=${dirPath}`, |
| 357 | method: 'get' | 364 | method: 'get' | ... | ... |
| ... | @@ -4,6 +4,7 @@ | ... | @@ -4,6 +4,7 @@ |
| 4 | 4 | ||
| 5 | <script lang="ts" setup name="anonResultReportView"> | 5 | <script lang="ts" setup name="anonResultReportView"> |
| 6 | import { | 6 | import { |
| 7 | downloadAnonReport, | ||
| 7 | getAnonAnalyzePageData, | 8 | getAnonAnalyzePageData, |
| 8 | getAnonAnalyzeResult, | 9 | getAnonAnalyzeResult, |
| 9 | getAnonTaskDetail, | 10 | getAnonTaskDetail, |
| ... | @@ -15,11 +16,14 @@ import anonResultAnalysis from './components/anonResultAnalysis.vue'; | ... | @@ -15,11 +16,14 @@ import anonResultAnalysis from './components/anonResultAnalysis.vue'; |
| 15 | import { commonPageConfig } from '@/utils/enum'; | 16 | import { commonPageConfig } from '@/utils/enum'; |
| 16 | import { calcColumnWidth } from '@/utils'; | 17 | import { calcColumnWidth } from '@/utils'; |
| 17 | import html2canvas from 'html2canvas'; | 18 | import html2canvas from 'html2canvas'; |
| 19 | import useUserStore from "@/store/modules/user"; | ||
| 18 | 20 | ||
| 19 | const route = useRoute(); | 21 | const route = useRoute(); |
| 20 | const router = useRouter(); | 22 | const router = useRouter(); |
| 21 | const fullPath = route.fullPath; | 23 | const fullPath = route.fullPath; |
| 22 | const taskGuid = ref(route.query.guid); | 24 | const taskGuid = ref(route.query.guid); |
| 25 | const userStore = useUserStore(); | ||
| 26 | const userData = JSON.parse(userStore.userData) | ||
| 23 | const { proxy } = getCurrentInstance() as any; | 27 | const { proxy } = getCurrentInstance() as any; |
| 24 | const resultDataLoading = ref(false); | 28 | const resultDataLoading = ref(false); |
| 25 | 29 | ||
| ... | @@ -202,7 +206,7 @@ const downloadWord = () => { | ... | @@ -202,7 +206,7 @@ const downloadWord = () => { |
| 202 | resultDataLoading.value = true; | 206 | resultDataLoading.value = true; |
| 203 | loadingText.value = '报告正在下载中,请勿关闭浏览器...'; | 207 | loadingText.value = '报告正在下载中,请勿关闭浏览器...'; |
| 204 | downPromise.value = convertHtml2Img(report, dom).then(() => { | 208 | downPromise.value = convertHtml2Img(report, dom).then(() => { |
| 205 | htmlToWord({ html: encodeURIComponent(`<div>${getHTML(dom.innerHTML)}</div>`) }).then((res: any) => { | 209 | downloadAnonReport({ taskGuid: taskGuid.value, title: `${analysisResultInfo.value.tenantName}持有的“${oldAnonTaskValueInfo.value.taskName}”`, evaluationDate: analysisResultInfo.value.execTime, deIdentProcessorName: userData.tenantName, html: encodeURIComponent(`<div>${getHTML(dom.innerHTML)}</div>`) }).then((res: any) => { |
| 206 | downPromise.value = null | 210 | downPromise.value = null |
| 207 | loadingText.value = ''; | 211 | loadingText.value = ''; |
| 208 | resultDataLoading.value = false; | 212 | resultDataLoading.value = false; | ... | ... |
| ... | @@ -245,7 +245,8 @@ import { | ... | @@ -245,7 +245,8 @@ import { |
| 245 | getDicomMeta, | 245 | getDicomMeta, |
| 246 | getDicomStatistics, | 246 | getDicomStatistics, |
| 247 | retryDicom, | 247 | retryDicom, |
| 248 | getInnerFolderPath | 248 | getInnerFolderPath, |
| 249 | downloadAnonReport, | ||
| 249 | } from '@/api/modules/dataAnonymization'; | 250 | } from '@/api/modules/dataAnonymization'; |
| 250 | import { | 251 | import { |
| 251 | parseAndDecodeUrl, | 252 | parseAndDecodeUrl, |
| ... | @@ -276,6 +277,7 @@ import html2canvas from 'html2canvas'; | ... | @@ -276,6 +277,7 @@ import html2canvas from 'html2canvas'; |
| 276 | const anonymizationStore = useDataAnonymizationStore(); | 277 | const anonymizationStore = useDataAnonymizationStore(); |
| 277 | const { proxy } = getCurrentInstance() as any; | 278 | const { proxy } = getCurrentInstance() as any; |
| 278 | const userStore = useUserStore(); | 279 | const userStore = useUserStore(); |
| 280 | const userData = JSON.parse(userStore.userData) | ||
| 279 | const route = useRoute(); | 281 | const route = useRoute(); |
| 280 | const router = useRouter(); | 282 | const router = useRouter(); |
| 281 | const fullPath = route.fullPath; | 283 | const fullPath = route.fullPath; |
| ... | @@ -1261,6 +1263,7 @@ const dialogBtnClick = (btn) => { | ... | @@ -1261,6 +1263,7 @@ const dialogBtnClick = (btn) => { |
| 1261 | if (taskGuid.value) { | 1263 | if (taskGuid.value) { |
| 1262 | saveParams.guid = taskGuid.value; | 1264 | saveParams.guid = taskGuid.value; |
| 1263 | } | 1265 | } |
| 1266 | saveParams.dataSharingTypeName = saveParams.dataSharingTypeCode && dataSharingTypeList.value.find(d => d.value == saveParams.dataSharingTypeCode)?.label; | ||
| 1264 | dicomStatisticsData.value = {}; | 1267 | dicomStatisticsData.value = {}; |
| 1265 | folderFileTableInfo.value.data = []; | 1268 | folderFileTableInfo.value.data = []; |
| 1266 | if (!taskGuid.value) { //保存 | 1269 | if (!taskGuid.value) { //保存 |
| ... | @@ -2232,7 +2235,8 @@ const downloadWord = () => { | ... | @@ -2232,7 +2235,8 @@ const downloadWord = () => { |
| 2232 | loadingText.value = '报告正在下载中,请勿关闭浏览器...'; | 2235 | loadingText.value = '报告正在下载中,请勿关闭浏览器...'; |
| 2233 | downloadLoading.value = true; | 2236 | downloadLoading.value = true; |
| 2234 | downPromise.value = convertHtml2Img(report, dom).then(() => { | 2237 | downPromise.value = convertHtml2Img(report, dom).then(() => { |
| 2235 | htmlToWord({ html: encodeURIComponent(`<div>${getHTML(dom.innerHTML)}</div>`) }).then((res: any) => { | 2238 | downloadAnonReport({ taskGuid: oldAnonTaskValueInfo.value.guid, title: `${analysisResultInfo.value.tenantName}持有的“${oldAnonTaskValueInfo.value.taskName}”`, evaluationDate: analysisResultInfo.value.execTime, |
| 2239 | deIdentProcessorName: userData.tenantName, html: encodeURIComponent(`<div>${getHTML(dom.innerHTML)}</div>`) }).then((res: any) => { | ||
| 2236 | downPromise.value = null | 2240 | downPromise.value = null |
| 2237 | loadingText.value = ''; | 2241 | loadingText.value = ''; |
| 2238 | downloadLoading.value = false; | 2242 | downloadLoading.value = false; | ... | ... |
This diff is collapsed.
Click to expand it.
-
Please register or sign in to post a comment