[update] 全文检索增加跳转拆分详情的按钮
This commit is contained in:
@@ -18,7 +18,8 @@ module.exports = {
|
||||
standardGradeClassification: '标准等级分类',
|
||||
all: '全部',
|
||||
releaseDate: '发布日期',
|
||||
standardStatusSet: '标准状态设置'
|
||||
standardStatusSet: '标准状态设置',
|
||||
standardResolutionSheet: '标准分解单'
|
||||
},
|
||||
// 高级搜索
|
||||
advancedSearch: {
|
||||
|
||||
@@ -88,7 +88,11 @@
|
||||
<div v-show="judgeAbolish(item)" class="result-source-wrapper" >
|
||||
<p class="result-abolish">{{ StandardStatus.ABOLISH.text }}</p>
|
||||
</div>
|
||||
<p class="result-date">{{ $t('dashboard.generalSearch.releaseDate') }} {{ item.releaseDate || global.emptyLine }}</p>
|
||||
<p class="result-date">
|
||||
<!-- 2024-08-29周UAT变更,全文检索增加跳转拆分详情按钮 -->
|
||||
<a-button v-if="retrievalModeCurrent === '1'" class="result-split-btn" type="primary" ghost :disabled="!item.splitId" @click="toSplitDetail(item)">{{ $t('dashboard.generalSearch.standardResolutionSheet') }}</a-button>
|
||||
{{ $t('dashboard.generalSearch.releaseDate') }} {{ item.releaseDate || global.emptyLine }}
|
||||
</p>
|
||||
</div>
|
||||
<template v-if="retrievalModeCurrent === '1'">
|
||||
<!-- 全文检索 -->
|
||||
@@ -134,7 +138,7 @@ import {
|
||||
} from '@/api/dashboard'
|
||||
import { isHasPermission } from '@/utils/hasPermission'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { StandardStatus, EnterpriseStandardStatus } from '@/enums/commonEnums'
|
||||
import { StandardStatus, EnterpriseStandardStatus, SplitStandardSource } from '@/enums/commonEnums'
|
||||
import {
|
||||
getDomesticStandardFormModal,
|
||||
getDomesticStandardDetail,
|
||||
@@ -709,6 +713,41 @@ export default {
|
||||
} else {
|
||||
this.onSearch(1)
|
||||
}
|
||||
},
|
||||
// 验证企标权限
|
||||
checkEnterpriseStandardAuth (record, callback) {
|
||||
// 不是企标直接执行回调
|
||||
if (record.resourceType !== SplitStandardSource.ENTERPRISE.value) {
|
||||
callback && callback()
|
||||
return
|
||||
}
|
||||
// 企标需要校验权限
|
||||
this.loading = true
|
||||
// 判断是否有权限,没有权限不能进查看
|
||||
isCanLookDetail({ id: record.id }).then(res => {
|
||||
if (res.success) {
|
||||
if (res.result) {
|
||||
callback && callback()
|
||||
} else {
|
||||
this.$message.warn(this.$t('docTool.split.noPermission'))
|
||||
}
|
||||
} else {
|
||||
this.$message.warn(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
async toSplitDetail (record) {
|
||||
this.checkEnterpriseStandardAuth(record, () => {
|
||||
this.$openPageNewSheet({
|
||||
path: '/docTool/StandardSplitSheet',
|
||||
query: {
|
||||
id: record.splitId,
|
||||
searchValue: this.searchValue
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -890,7 +929,7 @@ export default {
|
||||
padding: 0 8px;
|
||||
}
|
||||
.result-date {
|
||||
min-width: 200px !important;
|
||||
min-width: 300px !important;
|
||||
font-size: 16px;
|
||||
font-family: PingFang SC-Regular, PingFang SC;
|
||||
font-weight: 400;
|
||||
@@ -899,6 +938,9 @@ export default {
|
||||
text-align: right;
|
||||
white-space: nowrap;
|
||||
flex: 1;
|
||||
.result-split-btn {
|
||||
margin-right: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.result-content-wrapper {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="split-content">
|
||||
<standard-resolution-sheet ref="resolutionSheet" :horizontal-overstep="true"/>
|
||||
<standard-resolution-sheet ref="resolutionSheet" :horizontal-overstep="true" :searchValue="$route.query.searchValue"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -15,7 +15,12 @@ export default {
|
||||
this.$nextTick(() => {
|
||||
this.$refs.resolutionSheet.queryParams = { id: this.$route.query.id }
|
||||
this.$refs.resolutionSheet.initClauseFieldList()
|
||||
this.$refs.resolutionSheet.initDetailInfo()
|
||||
const query = {}
|
||||
if (this.$route.query.searchValue) {
|
||||
this.$refs.resolutionSheet.queryParam.item_content = this.$route.query.searchValue
|
||||
query.item_content = this.$route.query.searchValue
|
||||
}
|
||||
this.$refs.resolutionSheet.initDetailInfo(query)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user