匿名化文件夹支持选择内置文件
Showing
3 changed files
with
48 additions
and
10 deletions
| ... | @@ -379,3 +379,9 @@ export const downDicomPath = (taskExecGuid) => request({ | ... | @@ -379,3 +379,9 @@ export const downDicomPath = (taskExecGuid) => request({ |
| 379 | method: 'get', | 379 | method: 'get', |
| 380 | responseType: 'blob' | 380 | responseType: 'blob' |
| 381 | }) | 381 | }) |
| 382 | |||
| 383 | /** 获取内置的文件夹路径 */ | ||
| 384 | export const getInnerFolderPath = () => request({ | ||
| 385 | url: `${import.meta.env.VITE_APP_DIGITAL_CONTRACT_URL}/anon-task/get-dicom-path`, | ||
| 386 | method: 'get' | ||
| 387 | }) | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
| ... | @@ -55,11 +55,19 @@ | ... | @@ -55,11 +55,19 @@ |
| 55 | class="mr8" @click=uploadFolder>上传文件</el-button> | 55 | class="mr8" @click=uploadFolder>上传文件</el-button> |
| 56 | <Dialog ref="dialogRef" :dialog-info="uploadFileDialogInfo" @btnClick="dialogBtnClick"> | 56 | <Dialog ref="dialogRef" :dialog-info="uploadFileDialogInfo" @btnClick="dialogBtnClick"> |
| 57 | <template #extra-content> | 57 | <template #extra-content> |
| 58 | <div class="folder-main-content" v-loading="uploadFileDialogInfo.contentLoading"> | 58 | <div class="radio-main"> |
| 59 | <span>是否选择内置文件夹路径:</span> | ||
| 60 | <el-radio-group v-model="isBuiltInPath"> | ||
| 61 | <el-radio :value="true">是</el-radio> | ||
| 62 | <el-radio :value="false">否</el-radio> | ||
| 63 | </el-radio-group> | ||
| 64 | </div> | ||
| 65 | <div v-show="!isBuiltInPath" class="folder-main-content" v-loading="uploadFileDialogInfo.contentLoading"> | ||
| 59 | <Tree ref="treeInfoRef" :treeInfo="folderTreeInfo" @nodeClick="nodeClick" key="path" | 66 | <Tree ref="treeInfoRef" :treeInfo="folderTreeInfo" @nodeClick="nodeClick" key="path" |
| 60 | @loadNode="loadFolderTreeNode" /> | 67 | @loadNode="loadFolderTreeNode" /> |
| 61 | </div> | 68 | </div> |
| 62 | <div class="folder-foot">{{ '当前选中文件夹路径:' + (dialogOpenSelectNode.path || '--') }}</div> | 69 | <div v-show="!isBuiltInPath" class="folder-foot">{{ '当前选中文件夹路径:' + (dialogOpenSelectNode.path || '--') }}</div> |
| 70 | <div v-show="isBuiltInPath" class="builtIn-folder-foot">{{ '内置文件夹路径:' + (builtInPath || '--') }}</div> | ||
| 63 | </template> | 71 | </template> |
| 64 | </Dialog> | 72 | </Dialog> |
| 65 | <div v-show="clickSelectNode.path && dicomStatisticsData.state" class="folder-foot">{{ '当前提取文件夹路径:' + | 73 | <div v-show="clickSelectNode.path && dicomStatisticsData.state" class="folder-foot">{{ '当前提取文件夹路径:' + |
| ... | @@ -234,7 +242,8 @@ import { | ... | @@ -234,7 +242,8 @@ import { |
| 234 | scanFolder, | 242 | scanFolder, |
| 235 | getDicomMeta, | 243 | getDicomMeta, |
| 236 | getDicomStatistics, | 244 | getDicomStatistics, |
| 237 | retryDicom | 245 | retryDicom, |
| 246 | getInnerFolderPath | ||
| 238 | } from '@/api/modules/dataAnonymization'; | 247 | } from '@/api/modules/dataAnonymization'; |
| 239 | import { | 248 | import { |
| 240 | parseAndDecodeUrl, | 249 | parseAndDecodeUrl, |
| ... | @@ -990,6 +999,11 @@ const uploadFileChange = (file) => { | ... | @@ -990,6 +999,11 @@ const uploadFileChange = (file) => { |
| 990 | 999 | ||
| 991 | /*** ----------------------- 解析扫描文件 ------------------------------ */ | 1000 | /*** ----------------------- 解析扫描文件 ------------------------------ */ |
| 992 | 1001 | ||
| 1002 | /** 是否选择内置文件夹路径 */ | ||
| 1003 | const isBuiltInPath = ref(false); | ||
| 1004 | |||
| 1005 | const builtInPath = ref(''); | ||
| 1006 | |||
| 993 | /** 上传选择文件夹对话框 */ | 1007 | /** 上传选择文件夹对话框 */ |
| 994 | const uploadFileDialogInfo = ref({ | 1008 | const uploadFileDialogInfo = ref({ |
| 995 | visible: false, | 1009 | visible: false, |
| ... | @@ -1057,7 +1071,7 @@ const refreshFolderResult = () => { | ... | @@ -1057,7 +1071,7 @@ const refreshFolderResult = () => { |
| 1057 | const dialogBtnClick = (btn) => { | 1071 | const dialogBtnClick = (btn) => { |
| 1058 | if (btn.value == 'submit') { | 1072 | if (btn.value == 'submit') { |
| 1059 | clickSelectNode.value = dialogOpenSelectNode.value; | 1073 | clickSelectNode.value = dialogOpenSelectNode.value; |
| 1060 | if (!clickSelectNode.value.path) { | 1074 | if (!isBuiltInPath.value && !clickSelectNode.value.path) { |
| 1061 | proxy.$ElMessage.error('请先选择文件夹'); | 1075 | proxy.$ElMessage.error('请先选择文件夹'); |
| 1062 | return; | 1076 | return; |
| 1063 | } | 1077 | } |
| ... | @@ -1068,7 +1082,7 @@ const dialogBtnClick = (btn) => { | ... | @@ -1068,7 +1082,7 @@ const dialogBtnClick = (btn) => { |
| 1068 | saveParams.coverageArea = []; | 1082 | saveParams.coverageArea = []; |
| 1069 | } | 1083 | } |
| 1070 | saveParams.filePath = { | 1084 | saveParams.filePath = { |
| 1071 | url: clickSelectNode.value.path | 1085 | url: isBuiltInPath.value ? builtInPath.value : clickSelectNode.value.path |
| 1072 | }; | 1086 | }; |
| 1073 | saveParams.samplingRate = null; | 1087 | saveParams.samplingRate = null; |
| 1074 | if (taskGuid.value) { | 1088 | if (taskGuid.value) { |
| ... | @@ -1182,6 +1196,15 @@ const uploadFolder = () => { | ... | @@ -1182,6 +1196,15 @@ const uploadFolder = () => { |
| 1182 | clickSelectNode.value = {}; | 1196 | clickSelectNode.value = {}; |
| 1183 | dialogOpenSelectNode.value = {}; | 1197 | dialogOpenSelectNode.value = {}; |
| 1184 | uploadFileDialogInfo.value.visible = true; | 1198 | uploadFileDialogInfo.value.visible = true; |
| 1199 | if (!builtInPath.value) { | ||
| 1200 | getInnerFolderPath().then((res: any) => { | ||
| 1201 | if (res?.code == proxy.$passCode) { | ||
| 1202 | builtInPath.value = res.data || ''; | ||
| 1203 | } else { | ||
| 1204 | ElMessage.error(res.msg); | ||
| 1205 | } | ||
| 1206 | }) | ||
| 1207 | } | ||
| 1185 | folderTreeInfo.value.loading = true; | 1208 | folderTreeInfo.value.loading = true; |
| 1186 | scanFolder().then((res: any) => { | 1209 | scanFolder().then((res: any) => { |
| 1187 | folderTreeInfo.value.loading = false; | 1210 | folderTreeInfo.value.loading = false; |
| ... | @@ -2414,8 +2437,8 @@ onUnmounted(() => { | ... | @@ -2414,8 +2437,8 @@ onUnmounted(() => { |
| 2414 | } | 2437 | } |
| 2415 | 2438 | ||
| 2416 | .folder-main-content { | 2439 | .folder-main-content { |
| 2417 | height: 450px; | 2440 | height: 420px; |
| 2418 | padding: 8px 16px; | 2441 | padding: 0px 16px 8px; |
| 2419 | 2442 | ||
| 2420 | :deep(.tree_panel) { | 2443 | :deep(.tree_panel) { |
| 2421 | height: 100%; | 2444 | height: 100%; |
| ... | @@ -2426,8 +2449,17 @@ onUnmounted(() => { | ... | @@ -2426,8 +2449,17 @@ onUnmounted(() => { |
| 2426 | } | 2449 | } |
| 2427 | } | 2450 | } |
| 2428 | 2451 | ||
| 2452 | .radio-main { | ||
| 2453 | padding: 8px 24px 0px; | ||
| 2454 | } | ||
| 2455 | |||
| 2429 | .folder-foot { | 2456 | .folder-foot { |
| 2430 | padding: 0px 16px 8px; | 2457 | padding: 0px 24px 8px; |
| 2458 | line-height: 21px; | ||
| 2459 | } | ||
| 2460 | |||
| 2461 | .builtIn-folder-foot { | ||
| 2462 | padding: 8px 24px; | ||
| 2431 | line-height: 21px; | 2463 | line-height: 21px; |
| 2432 | } | 2464 | } |
| 2433 | 2465 | ... | ... |
| ... | @@ -1652,7 +1652,7 @@ onActivated(() => { | ... | @@ -1652,7 +1652,7 @@ onActivated(() => { |
| 1652 | <span class="item_label">创建时间:</span> | 1652 | <span class="item_label">创建时间:</span> |
| 1653 | <span class="item_value">{{ detailInfo.createTime || '--' }}</span> | 1653 | <span class="item_value">{{ detailInfo.createTime || '--' }}</span> |
| 1654 | </div> | 1654 | </div> |
| 1655 | <div class="list_item" style=" width: 55%;"> | 1655 | <!-- <div class="list_item" style=" width: 55%;"> |
| 1656 | <span class="item_label">有效期:</span> | 1656 | <span class="item_label">有效期:</span> |
| 1657 | <span class="item_value">{{ !detailInfo.signatureTime ? '--' : (detailInfo.signatureTime + '至' + | 1657 | <span class="item_value">{{ !detailInfo.signatureTime ? '--' : (detailInfo.signatureTime + '至' + |
| 1658 | detailInfo.endTime) }}</span> | 1658 | detailInfo.endTime) }}</span> |
| ... | @@ -1660,7 +1660,7 @@ onActivated(() => { | ... | @@ -1660,7 +1660,7 @@ onActivated(() => { |
| 1660 | <div class="list_item" style=" width: 45%;"> | 1660 | <div class="list_item" style=" width: 45%;"> |
| 1661 | <span class="item_label">签署时间:</span> | 1661 | <span class="item_label">签署时间:</span> |
| 1662 | <span class="item_value">{{ detailInfo.signatureTime || '--' }}</span> | 1662 | <span class="item_value">{{ detailInfo.signatureTime || '--' }}</span> |
| 1663 | </div> | 1663 | </div> --> |
| 1664 | </div> | 1664 | </div> |
| 1665 | </div> | 1665 | </div> |
| 1666 | <div class="empty-div"></div> | 1666 | <div class="empty-div"></div> | ... | ... |
-
Please register or sign in to post a comment