非dicom影像图片上传后文件数量预览按钮位置对齐
continuous-integration/drone/push Build is passing Details

uat_us
DESKTOP-6C3NK6N\WXS 2024-09-18 11:48:37 +08:00
parent 86dde0a9e8
commit 3dddbafd04
1 changed files with 50 additions and 43 deletions

View File

@ -68,14 +68,38 @@
/> />
<el-table-column :label="$t('common:action:action')" width="120"> <el-table-column :label="$t('common:action:action')" width="120">
<template slot-scope="files"> <template slot-scope="files">
<!-- 预览 --> <div style="display: flex">
<viewer <!-- 预览 -->
v-if="files.row.type !== 'MP4'" <viewer
:ref="files.row.FullFilePath" v-if="files.row.type !== 'MP4'"
style="margin:0 10px;" :ref="files.row.FullFilePath"
:images="[`${OSSclientConfig.basePath}${files.row.FullFilePath}`]" style="margin: 0 10px"
> :images="[
`${OSSclientConfig.basePath}${files.row.FullFilePath}`,
]"
>
<el-button
icon="el-icon-view"
circle
:title="$t('trials:uploadNonDicoms:action:preview')"
size="small"
:disabled="
files.row.FileType &&
files.row.FileType.indexOf('zip') >= 0
"
@click.native.prevent="handlePreviewImg(files.row)"
>
</el-button>
<img
v-show="false"
crossorigin="anonymous"
:src="`${OSSclientConfig.basePath}${files.row.FullFilePath}`"
alt="Image"
/>
</viewer>
<el-button <el-button
v-if="files.row.type === 'MP4'"
icon="el-icon-view" icon="el-icon-view"
circle circle
:title="$t('trials:uploadNonDicoms:action:preview')" :title="$t('trials:uploadNonDicoms:action:preview')"
@ -84,42 +108,25 @@
files.row.FileType && files.row.FileType &&
files.row.FileType.indexOf('zip') >= 0 files.row.FileType.indexOf('zip') >= 0
" "
@click.native.prevent="handlePreviewImg(files.row)"> @click.native.prevent="handleLookVideo(scope.row)"
</el-button> />
<img <!-- 删除 -->
v-show="false" <el-button
crossorigin="anonymous" v-if="allowAddOrEdit"
:src="`${OSSclientConfig.basePath}${files.row.FullFilePath}`" v-hasPermi="[
alt="Image" 'trials:trials-panel:visit:crc-upload:delete',
> ]"
</viewer> icon="el-icon-delete"
circle
<el-button :title="$t('trials:uploadNonDicoms:action:delete')"
v-if="files.row.type === 'MP4'" size="small"
icon="el-icon-view" @click.native.prevent="
circle files.row.type === 'MP4'
:title="$t('trials:uploadNonDicoms:action:preview')" ? hadnleDeleteVideo(scope.row)
size="small" : handleDeleteFile(files.row.Id)
:disabled=" "
files.row.FileType && />
files.row.FileType.indexOf('zip') >= 0 </div>
"
@click.native.prevent="handleLookVideo(scope.row)"
/>
<!-- 删除 -->
<el-button
v-if="allowAddOrEdit"
v-hasPermi="['trials:trials-panel:visit:crc-upload:delete']"
icon="el-icon-delete"
circle
:title="$t('trials:uploadNonDicoms:action:delete')"
size="small"
@click.native.prevent="
files.row.type === 'MP4'
? hadnleDeleteVideo(scope.row)
: handleDeleteFile(files.row.Id)
"
/>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>