zip文件预览默认图像
parent
a15e908e76
commit
8e5e2a0714
Binary file not shown.
After Width: | Height: | Size: 62 KiB |
|
@ -50,7 +50,7 @@
|
|||
:ref="`img${i}`"
|
||||
:key="item.Id"
|
||||
crossorigin="anonymous"
|
||||
:src="`${OSSclientConfig.basePath}${item.Path}`"
|
||||
:src="item.FileType&&item.FileType.indexOf('zip')>=0?zipImg:`${OSSclientConfig.basePath}${item.Path}`"
|
||||
:style="imgStyle"
|
||||
style="max-width:100%;max-height: 100%;"
|
||||
@load="handleImgLoad"
|
||||
|
@ -68,7 +68,7 @@
|
|||
|
||||
<script>
|
||||
import { on, off } from 'element-ui/src/utils/dom'
|
||||
import { rafThrottle, isFirefox } from 'element-ui/src/utils/util'
|
||||
import { rafThrottle, isFirefox } from 'element-ui/src/utils/util';
|
||||
|
||||
const mousewheelEventName = isFirefox() ? 'DOMMouseScroll' : 'mousewheel'
|
||||
|
||||
|
@ -102,6 +102,10 @@ export default {
|
|||
initialIndex: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
zipImg:{
|
||||
required:true,
|
||||
default:''
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -117,7 +121,7 @@ export default {
|
|||
offsetX: 0,
|
||||
offsetY: 0,
|
||||
enableTransition: false
|
||||
}
|
||||
},
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
:study-code="previewImage.studyCode"
|
||||
:body-part="previewImage.bodyPart"
|
||||
:modality="previewImage.modality"
|
||||
:zip-img='zipImg'
|
||||
/>
|
||||
</div>
|
||||
<div class="thumbnail-wrapper" style="z-index:999;background-color:#fff;">
|
||||
|
@ -42,7 +43,7 @@
|
|||
}"
|
||||
@click="selected(index)"
|
||||
>
|
||||
<img :title="item.FileName" crossorigin="anonymous" :src="`${OSSclientConfig.basePath + item.Path}`">
|
||||
<img :title="item.FileName" crossorigin="anonymous" :src="item.FileType&&item.FileType.indexOf('zip')>=0?zipImg:`${OSSclientConfig.basePath}${item.Path}`">
|
||||
<p v-if="item.FileName" class="item-date">
|
||||
{{ `${index+1}` }}
|
||||
</p>
|
||||
|
@ -62,7 +63,8 @@
|
|||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import ImageViewer from './image-viewer'
|
||||
import ImageViewer from './image-viewer';
|
||||
import zipImg from "@/assets/zip.png";
|
||||
export default {
|
||||
name: 'Preview',
|
||||
components: {
|
||||
|
@ -104,7 +106,8 @@ export default {
|
|||
previewVisible: true,
|
||||
translateX: 0,
|
||||
pageSize: 0, // 一页展示的图片数
|
||||
urlList: []
|
||||
urlList: [],
|
||||
zipImg
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
|
Loading…
Reference in New Issue