修改法规清单的更新log 历史版本

This commit is contained in:
qq787203167
2022-04-20 14:25:03 +08:00
parent 522cf1c6d9
commit 0b0f401e6a
5 changed files with 173 additions and 10 deletions
+4
View File
@@ -687,4 +687,8 @@ module.exports = {
verificationComplianceConfirmationDeadline:'Verification compliance confirmation deadline',
pleaseEnterTheCorrectWebAddress:'Please enter the correct web address',
updateTime:'update Time',
comment:'comment',
historicalVersion:'Historical version',
versionName:'Version name',
finalizationTime:'Finalization time',
}
+4
View File
@@ -691,4 +691,8 @@ module.exports = {
verificationComplianceConfirmationDeadline:'验证符合性确认截止时间',
pleaseEnterTheCorrectWebAddress:'请输入正确的网址',
updateTime:'更新时间',
comment:'评论',
historicalVersion:'历史版本',
versionName:'版本名称',
finalizationTime:'定版时间',
}
@@ -9,6 +9,20 @@
{{this.title}}
</span>
</div>
<div class="Virtual-detail-text-right" v-if="textTitle === '法规清单'">
<div class="operator-text">
<a-icon type="message"/>
{{$t('comment')}}
</div>
<div class="operator-text" @click="historicalVersionClick">
<a-icon type="clock-circle"/>
{{$t('historicalVersion')}}
</div>
<div class="operator-text" @click="UpdateLogClick">
<a-icon type="reload"/>
{{$t('UpdateLog')}}
</div>
</div>
</div>
<div style="padding: 67px 0 0 0;background: #ffffff;height:100%">
<div class="detail-content" style="height: 100%">
@@ -43,6 +57,8 @@
</div>
</div>
</div>
<updateLog :url="url" ref="updateLogRef"/>
<historicalVersionList :url="url" ref="historicalVersionListRef"/>
</div>
</template>
@@ -52,6 +68,8 @@
import ProjectDetailsName from '../components/ProjectDetails'
import TaskParameterCollection from '../components/TaskParameterCollection'
import nonConformance from '../components/nonConformance'
import updateLog from '@/components/UpdateLog/index'
import historicalVersionList from '../components/historicalVersionList'
export default {
name: 'ProjectDetails',
@@ -60,12 +78,18 @@
listOfRegulations,
ProjectDetailsName,
TaskParameterCollection,
nonConformance
nonConformance,
updateLog,
historicalVersionList
},
data() {
return {
title: this.$t('projectDetails'),
textTitle: '项目详情'
textTitle: '项目详情',
url: {
logList: '',
historicalVersionUrl: ''
}
}
},
mounted() {
@@ -90,6 +114,12 @@
}
let text = document.getElementsByClassName('Virtual-detail-left-text')
text[num].classList.add('Virtual-detail-left-text-color')
},
UpdateLogClick() {
this.$refs.updateLogRef.getList()
},
historicalVersionClick() {
this.$refs.historicalVersionListRef.getList()
}
}
}
@@ -161,4 +191,8 @@
background: #eff1f3;
border-radius: 4px;
}
.Virtual-detail-text-right {
}
</style>
@@ -0,0 +1,123 @@
<template>
<a-modal
:title="$t('historicalVersion')"
:width="900"
:visible="visible"
:confirm-loading="confirmLoading"
:maskClosable="false"
@ok="handleOk"
@cancel="handleCancel"
>
<a-table
class="table"
:columns="columns"
:pagination="false"
:scroll="{y: 400}"
:data-source="dataSource"
:loading="loading"
>
<span slot="operation" slot-scope="text,record">
<a @click="seeClick(record)">{{$t('See')}}</a>
</span>
</a-table>
<div class="page" v-if="dataSource.length > 0">
<a-pagination
:show-total="total => $t('total')+`${total}`+$t('strip')"
show-quick-jumper
show-size-changer
:page-size.sync="pageSize "
:total="total"
@change="onChange"
@showSizeChange="SizeChange"
/>
</div>
</a-modal>
</template>
<script>
import { getAction, postAction, } from '@/api/manage'
export default {
name: 'historicalVersionList',
props:['url'],
data(){
return{
visible:false,
confirmLoading:false,
dataSource:[],
loading:false,
pageNo: 1,
pageSize: 10,
total: 0,
columns: [
{
title: this.$t('versionName'),
dataIndex: 'versionName',
align: 'center',
ellipsis: true,
},
{
title: this.$t('finalizationTime'),
dataIndex: 'finalizationTime',
align: 'center',
ellipsis: true,
width: 180
},
{
title: this.$t('operation'),
align: 'center',
width: 80,
scopedSlots: { customRender: 'operation' }
}
]
}
},
mounted() {
},
methods:{
getList(){
this.visible = true
this.pageNo = 1
this.historicalList()
},
handleOk() {
this.visible = false
},
handleCancel() {
this.visible = false
},
onChange(page, pageSize) {
this.pageNo = page
this.historicalList()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.historicalList()
},
historicalList(){
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
documentId: this.$route.query.id
}
this.loading = true
getAction(this.url.historicalVersionUrl, query).then((res) => {
if (res.success) {
this.dataSource = res.result.records
this.total = res.result.total
this.loading = false
} else {
this.loading = false
}
})
},
seeClick(item){
},
}
}
</script>
<style scoped>
</style>
@@ -256,14 +256,6 @@
data() {
return {
columns: [
{
title: 'WVTA ID',
align: 'center',
dataIndex: 'wvtaId',
width: 100,
ellipsis: true,
fixed: 'left'
},
{
title: this.$t('standard'),
align: 'center',
@@ -329,6 +321,12 @@
ellipsis: true,
dataIndex: 'implementTime'
},
{
title: 'WVTA ID',
align: 'center',
dataIndex: 'wvtaId',
ellipsis: true
},
{
title: this.$t('certificationType'),
align: 'center',