fix 81456
This commit is contained in:
@@ -52,21 +52,16 @@
|
|||||||
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template v-slot:file="{text, record}">
|
<!--佐证材料-->
|
||||||
<a-tooltip overlay-class-name="tooltip-style">
|
<template v-slot:file="{text}">
|
||||||
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
|
<a-button class="table-text" v-if="!!text" type="primary" ghost @click="displayFile(text)">{{ $t('view') }}</a-button>
|
||||||
<div class="table-text can-click-table-text" v-if="text || text === 0" @click="handlePreview(record)">{{ text }}</div>
|
<div class="table-text" v-else>{{ global.emptyLine }}</div>
|
||||||
<div v-else class="table-text">{{ global.emptyLine }}</div>
|
|
||||||
</a-tooltip>
|
|
||||||
</template>
|
</template>
|
||||||
</j-table>
|
</j-table>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="images">
|
<!--佐证材料回显-->
|
||||||
<div class="image" v-viewer="{movable: false}">
|
<upload-file ref="fileDisplayModal" disabled />
|
||||||
<img v-show="image" :src="imageUrl" alt="">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</j-modal>
|
</j-modal>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -78,12 +73,12 @@ import Vue from 'vue'
|
|||||||
import { ACCESS_TOKEN } from '../../../../store/mutation-types'
|
import { ACCESS_TOKEN } from '../../../../store/mutation-types'
|
||||||
import { downloadFile, getFileAccessHttpUrl } from '../../../../api/manage'
|
import { downloadFile, getFileAccessHttpUrl } from '../../../../api/manage'
|
||||||
import { previewPdf } from '../../../../utils/previewPdf'
|
import { previewPdf } from '../../../../utils/previewPdf'
|
||||||
import { Base64 } from 'js-base64'
|
|
||||||
import { kkFilePreview } from '../../../../utils/kkFilePreview'
|
import { kkFilePreview } from '../../../../utils/kkFilePreview'
|
||||||
|
import UploadFile from '../../../../components/UploadFile'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'BasisDescriptionModal',
|
name: 'BasisDescriptionModal',
|
||||||
components: { JTable },
|
components: { UploadFile, JTable },
|
||||||
mixins: [JeroListMixin],
|
mixins: [JeroListMixin],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -126,7 +121,8 @@ export default {
|
|||||||
{
|
{
|
||||||
dataIndex: 'fileId',
|
dataIndex: 'fileId',
|
||||||
title: this.$t('projectLibrary.specialProjectLibrary.supportingMaterial'),
|
title: this.$t('projectLibrary.specialProjectLibrary.supportingMaterial'),
|
||||||
width: 120
|
width: 120,
|
||||||
|
scopedSlots: { customRender: 'file' }
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
image: false,
|
image: false,
|
||||||
@@ -201,6 +197,9 @@ export default {
|
|||||||
}
|
}
|
||||||
// 如果都不能预览就下载
|
// 如果都不能预览就下载
|
||||||
downloadFile(`/sys/common/download/${file.id}`, file.fileName)
|
downloadFile(`/sys/common/download/${file.id}`, file.fileName)
|
||||||
|
},
|
||||||
|
displayFile (text) {
|
||||||
|
this.$refs.fileDisplayModal.open(text)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user