Compare commits

...

3 Commits

Author SHA1 Message Date
wangxiaoshuang 8e554bbeb8 Merge branch 'main' of https://gitea.frp.extimaging.com/XCKJ/irc_web
continuous-integration/drone/push Build is passing Details
2024-06-19 16:50:08 +08:00
wangxiaoshuang 8e5e2a0714 zip文件预览默认图像 2024-06-19 16:49:43 +08:00
wangxiaoshuang a15e908e76 时间格式处理 2024-06-19 16:49:26 +08:00
4 changed files with 15 additions and 8 deletions

BIN
src/assets/zip.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

View File

@ -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: {

View File

@ -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: {

View File

@ -237,11 +237,11 @@ export default {
var dateTime
if (this.clinicalTrialForm.StartTime) {
dateTime = new Date(this.clinicalTrialForm.StartTime)
this.clinicalTrialForm.StartTime = moment(new Date(dateTime.setDate(dateTime.getDate()+1))).format('YYYY')
this.clinicalTrialForm.StartTime = moment(new Date(dateTime.setDate(dateTime.getDate()+1))).format('YYYY') + "-01"
}
if (this.clinicalTrialForm.EndTime) {
dateTime = new Date(this.clinicalTrialForm.EndTime)
this.clinicalTrialForm.EndTime = moment(new Date(dateTime.setDate(dateTime.getDate()+1))).format("YYYY")
this.clinicalTrialForm.EndTime = moment(new Date(dateTime.setDate(dateTime.getDate()+1))).format("YYYY") + "-01"
}
addOrUpdateTrialExperience(this.clinicalTrialForm).then(res => {
this.isDisabled = false