[update] 外标详情增加授权部门查看全部
This commit is contained in:
@@ -59,7 +59,7 @@
|
||||
<!-- 需要显示查看全部按钮 -->
|
||||
<a-button v-else-if="showViewAllField.includes(formItem.dbFieldName) &&
|
||||
(detailData[formItem.dbFieldName + '_dictText'] || detailData[formItem.dbFieldName])"
|
||||
type="primary" ghost @click="viewAll('auth_dept')">
|
||||
type="primary" ghost @click="viewAll(formItem.dbFieldName)">
|
||||
{{ $t('enterpriseStandardLibrary.standard.viewAll')}}
|
||||
</a-button>
|
||||
<span v-else-if="detailData[formItem.dbFieldName + '_dictText']">{{ detailData[formItem.dbFieldName + '_dictText'] }}</span>
|
||||
|
||||
@@ -36,12 +36,7 @@
|
||||
</div>
|
||||
</template>
|
||||
<!--文件需要显示预览-->
|
||||
<span v-else-if="!fileField.includes(formItem.dbFieldName)">
|
||||
{{
|
||||
detailData[needDictFieldList.includes(formItem.fieldShowType) ? formItem.dbFieldName + '_dictText' : formItem.dbFieldName] || global.emptyLine
|
||||
}}
|
||||
</span>
|
||||
<div class="file-box" v-else>
|
||||
<div class="file-box" v-else-if="fileField.includes(formItem.dbFieldName)">
|
||||
<template v-if="detailData[formItem.dbFieldName + 'List'] && detailData[formItem.dbFieldName + 'List'].length > 0">
|
||||
<div class="detail-page-process-manuscript-file"
|
||||
v-for="file in detailData[formItem.dbFieldName + 'List']"
|
||||
@@ -69,6 +64,17 @@
|
||||
</template>
|
||||
<span v-else>{{ global.emptyLine }}</span>
|
||||
</div>
|
||||
<!-- 需要显示查看全部按钮 -->
|
||||
<a-button v-else-if="showViewAllField.includes(formItem.dbFieldName) &&
|
||||
(detailData[formItem.dbFieldName + '_dictText'] || detailData[formItem.dbFieldName])"
|
||||
type="primary" ghost @click="viewAll(formItem.dbFieldName)">
|
||||
{{ $t('enterpriseStandardLibrary.standard.viewAll')}}
|
||||
</a-button>
|
||||
<span v-else>
|
||||
{{
|
||||
detailData[needDictFieldList.includes(formItem.fieldShowType) ? formItem.dbFieldName + '_dictText' : formItem.dbFieldName] || global.emptyLine
|
||||
}}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 过程稿件特殊处理-->
|
||||
@@ -124,6 +130,8 @@
|
||||
<user-select-modal ref="userSelectModal" type="checkbox" @change="continueShare" />
|
||||
<!-- 标准分解单-->
|
||||
<standard-resolution-sheet-modal ref="standardResolutionSheetModal" />
|
||||
<!-- 查看全部弹框 -->
|
||||
<text-content-modal ref="textContentModal"></text-content-modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -150,6 +158,7 @@ import { previewPdf } from '../../../utils/previewPdf.js'
|
||||
import { Base64 } from 'js-base64'
|
||||
import { kkFilePreview } from '../../../utils/kkFilePreview'
|
||||
import { previewFileCurrentWindowByFileId, queryStandardInfoByStandardNumber } from '../../../utils/util'
|
||||
import TextContentModal from '../../enterpriseStandardLibrary/standard/detail/module/TextContentModal'
|
||||
|
||||
// 国内标准权限
|
||||
const DomesticStandardPermission = {
|
||||
@@ -192,7 +201,7 @@ const FILE_TYPE_IMGS = ['jpg', 'jpeg', 'png', 'raw']
|
||||
|
||||
export default {
|
||||
name: 'StandardDetailPage',
|
||||
components: { UpdateRecordModal, SubmitQuestionModal, UserSelectModal, StandardResolutionSheetModal },
|
||||
components: { UpdateRecordModal, SubmitQuestionModal, UserSelectModal, StandardResolutionSheetModal, TextContentModal },
|
||||
data () {
|
||||
return {
|
||||
loading: false,
|
||||
@@ -207,7 +216,8 @@ export default {
|
||||
image: false,
|
||||
imageUrl: null,
|
||||
// 标准字段,需要跳转标准详情
|
||||
standardFields: ['substitute_standard_number', 'replaced_by_standard_number', 'reference_standard', 'referenced_standard', 'adopt_the_international_standard_number', 'associated_foreign_standards']
|
||||
standardFields: ['substitute_standard_number', 'replaced_by_standard_number', 'reference_standard', 'referenced_standard', 'adopt_the_international_standard_number', 'associated_foreign_standards'],
|
||||
showViewAllField: ['auth_dept'] // 需要显示展示查看全部按钮的字段
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -386,6 +396,11 @@ export default {
|
||||
previewStandardResolutionSheet (id) {
|
||||
this.$refs.standardResolutionSheetModal.open(id)
|
||||
},
|
||||
// 查看全部
|
||||
viewAll (fieldName) {
|
||||
const data = this.detailData[fieldName + '_dictText'] || this.detailData[fieldName]
|
||||
this.$refs.textContentModal.open(data)
|
||||
},
|
||||
handlePreview (file) {
|
||||
if (!file || !file.url) {
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user