Browse Source

20241022预归档补充

master
xuhuajiao 4 months ago
parent
commit
64822ec2d5
  1. 10
      src/api/prearchiveLibrary/prearchiveLibrary.js
  2. 2
      src/views/archiveUtilize/archiveSearch/index.vue
  3. 3
      src/views/archivesManage/managementLibrary/module/uploadFile/index.vue
  4. 3
      src/views/collectReorganizi/collectionLibrary/module/uploadFile/index.vue
  5. 6
      src/views/components/archivesDetail/detail.vue
  6. 94
      src/views/components/archivesDetail/fourTestInfo/index.vue
  7. 1
      src/views/components/category/PreviewForm.vue
  8. 1
      src/views/prearchiveLibrary/index.vue
  9. 20
      src/views/prearchiveLibrary/module/detail.vue
  10. 31
      src/views/preview/index.vue

10
src/api/prearchiveLibrary/prearchiveLibrary.js

@ -109,4 +109,12 @@ export function FetchArchivesMetadata(params) {
})
}
export default { add, prearchEdit, del, FetchInitPreDocument, FetchInitDocumentsViewTable, FetchDoeditDocument, FetchBatchToFile, FetchMergeToFile, FetchMove, FetchArchivesDetails, FetchFileListByDocumentId, FetchArchivesMetadata }
export function FetchReDocumentBase64ByFileId(params) {
return request({
url: 'api/re-document/getBase64ByFileId',
method: 'get',
params
})
}
export default { add, prearchEdit, del, FetchInitPreDocument, FetchInitDocumentsViewTable, FetchDoeditDocument, FetchBatchToFile, FetchMergeToFile, FetchMove, FetchArchivesDetails, FetchFileListByDocumentId, FetchArchivesMetadata, FetchReDocumentBase64ByFileId }

2
src/views/archiveUtilize/archiveSearch/index.vue

@ -552,7 +552,7 @@ export default {
display: flex;
justify-content: flex-start;
flex-wrap: wrap;
height: 200px;
max-height: 200px;
overflow: hidden;
overflow-y: scroll;
span{

3
src/views/archivesManage/managementLibrary/module/uploadFile/index.vue

@ -123,6 +123,9 @@ export default {
'archiveNo': this.parentInfo.find(item => item.fieldName === 'archive_no').context
}})
window.open(routeData.href, '_blank')
if (localStorage.getItem('documentId')) {
localStorage.removeItem('documentId')
}
localStorage.setItem('fileParentInfo', JSON.stringify(this.parentInfo))
localStorage.setItem('fileTables', JSON.stringify(this.tableData))
localStorage.setItem('fileCurrent', JSON.stringify(row))

3
src/views/collectReorganizi/collectionLibrary/module/uploadFile/index.vue

@ -283,6 +283,9 @@ export default {
'archiveNo': this.parentInfo.find(item => item.fieldName === 'archive_no').context
}})
window.open(routeData.href, '_blank')
if (localStorage.getItem('documentId')) {
localStorage.removeItem('documentId')
}
localStorage.setItem('fileParentInfo', JSON.stringify(this.parentInfo))
localStorage.setItem('fileTables', JSON.stringify(this.tableData))
localStorage.setItem('fileCurrent', JSON.stringify(row))

6
src/views/components/archivesDetail/detail.vue

@ -38,7 +38,7 @@
</code>
</pre>
</div>
<FourTestInfo v-if="archivesTabIndex===3" />
<FourTestInfo v-show="archivesTabIndex===3" ref="fourTestInfoRefs" />
<HandleInfo v-if="archivesTabIndex===4" />
<ArchivesListModule v-show="archivesTabIndex===5" ref="archivesListModuleRef" :selected-category="selectedCategory" :category-id="categoryId" :is-title-type="isTitleType" :is-collect="false" />
</div>
@ -137,6 +137,10 @@ export default {
this.archivesTabIndex = index
if (this.archivesTabIndex === 2) {
this.setXml()
} else if (this.archivesTabIndex === 3) {
console.log(this.$refs.fourTestInfoRefs)
this.$refs.fourTestInfoRefs.currentArcId = this.arcId
this.$refs.fourTestInfoRefs.getFourCheckRecord(this.arcId)
} else if (this.archivesTabIndex === 5) {
if (this.isTitleType === 2) {
this.$refs.archivesListModuleRef.detailLevel = 2

94
src/views/components/archivesDetail/fourTestInfo/index.vue

@ -1,16 +1,17 @@
<template>
<!--四性检测-档案详情内-->
<div class="fourTest-container">
<el-table :data="tableData" style="min-width: 100%" height="calc(100vh - 440px)">
<el-table-column prop="admin" label="检测人" min-width="60" />
<el-table-column prop="createTime" label="检测时间" min-width="180">
<div class="double-click-btn"><i class="iconfont icon-zhuyi-lan" /><span>双击列表数据查看报告详情</span></div>
<el-table :data="tableData" style="min-width: 100%" height="calc(100vh - 440px)" @cell-dblclick="tableDoubleClick">
<el-table-column prop="create_by" label="检测人" min-width="80" />
<el-table-column prop="create_time" label="检测时间" min-width="150">
<template slot-scope="scope">
<div>{{ scope.row.createTime | parseTime }}</div>
<div>{{ scope.row.create_time | parseTime }}</div>
</template>
</el-table-column>
<el-table-column prop="truth" label="真实性" align="center">
<el-table-column prop="authenticity" label="真实性" align="center">
<template slot-scope="scope">
<span v-if="scope.row.truth===1" class="four-icon iconfont icon-zhengque" />
<span v-if="scope.row.authenticity===1" class="four-icon iconfont icon-zhengque" />
<span v-else class="four-icon iconfont icon-cuowu" />
</template>
</el-table-column>
@ -20,9 +21,9 @@
<span v-else class="four-icon iconfont icon-cuowu" />
</template>
</el-table-column>
<el-table-column prop="availability" label="可用性" align="center">
<el-table-column prop="usability" label="可用性" align="center">
<template slot-scope="scope">
<span v-if="scope.row.availability===1" class="four-icon iconfont icon-zhengque" />
<span v-if="scope.row.usability===1" class="four-icon iconfont icon-zhengque" />
<span v-else class="four-icon iconfont icon-cuowu" />
</template>
</el-table-column>
@ -32,14 +33,15 @@
<span v-else class="four-icon iconfont icon-cuowu" />
</template>
</el-table-column>
<el-table-column prop="createDate" label="检测结果" min-width="220">
<el-table-column label="检测结果" min-width="250">
<template slot-scope="scope">
<div>共检测{{ scope.row.totalNum }}<span class="testSuccess">通过{{ scope.row.successNum }}</span><span class="testError">未通过{{ scope.row.errorNum }}</span></div>
<div>共检测{{ scope.row.checkNum }}<span class="testSuccess">通过{{ scope.row.passNum }}</span><span class="testError">未通过{{ scope.row.failNum }}</span></div>
</template>
</el-table-column>
</el-table>
<!--分页组件-->
<el-pagination
v-if="tableData.length !== 0"
:current-page="page.page"
:total="page.total"
:page-size="page.size"
@ -52,45 +54,17 @@
</template>
<script>
const data = [
{
'id': '005E76FEC5A2AAB368CA1F',
'admin': 'admin',
'archive_no': 'YXK-2022-JJ-001 ',
'maintitle': '文书档案001',
'createTime': 1660706815000,
'truth': 0,
'integrity': 1,
'availability': 0,
'safety': 0,
'totalNum': 5,
'successNum': 1,
'errorNum': 0
},
{
'id': '005E76FEC5A2AAB368CA1F2',
'admin': 'admin',
'archive_no': 'YXK-2022-JJ-002 ',
'maintitle': '文书档案001',
'createTime': 1660706815000,
'truth': 0,
'integrity': 1,
'availability': 1,
'safety': 0,
'totalNum': 5,
'successNum': 1,
'errorNum': 0
}
]
import { FetchFourCheckRecord } from '@/api/collect/collect'
export default {
name: 'FourTestInfo',
components: { },
mixins: [],
data() {
return {
tableData: [{}, {}],
currentArcId: null,
tableData: [],
page: {
page: 1,
page: 0,
size: 10,
total: 0
}
@ -100,15 +74,40 @@ export default {
},
mounted() {
this.tableData = data
},
methods: {
getFourCheckRecord(arcId) {
const params = {
'archivesId': arcId,
'page': this.page.page,
'size': this.page.size
}
FetchFourCheckRecord(params).then(data => {
if (data.content && data.content.length !== 0) {
this.tableData = data.content
this.page.total = data.totalElements
} else {
this.tableData = []
this.page.total = 0
}
})
},
handleSizeChange(size) {
this.page.size = size
this.page.page = 1
this.page.page = 0
this.getFourCheckRecord(this.currentArcId)
},
handleCurrentPage(val) {
this.page.page = val
this.getFourCheckRecord(this.currentArcId)
},
tableDoubleClick(row) {
const routeData = this.$router.resolve({
path: '/fourTestReport',
query: {}
})
localStorage.setItem('fourTestStorage', JSON.stringify(row))
window.open(routeData.href, '_blank')
}
}
}
@ -116,4 +115,11 @@ export default {
<style lang='scss' scoped>
@import "~@/assets/styles/collect-reorganizi.scss";
.double-click-btn{
position: static;
right: 0;
top: 0;
justify-content: flex-end;
margin: -6px 0 4px 0;
}
</style>

1
src/views/components/category/PreviewForm.vue

@ -789,7 +789,6 @@ export default {
'jsonString': JSON.stringify(this.addOrUpdateForm),
'fileJsonString': this.fileJsonString
}
console.log(params)
prearchEdit(params).then(res => {
if (res) {
this.$message({ message: res.message, type: 'success', offset: 8 })

1
src/views/prearchiveLibrary/index.vue

@ -312,6 +312,7 @@ export default {
console.log('tableDoubleClick', row)
this.$refs.archivesInfo.archivesInfoVisible = true
this.$refs.archivesInfo.archivesTabIndex = 0
this.$refs.archivesInfo.parentInfo = row
this.$refs.archivesInfo.getDetial(row.id)
},
//

20
src/views/prearchiveLibrary/module/detail.vue

@ -71,10 +71,9 @@
</template>
</el-table-column>
<el-table-column label="操作" min-width="80" align="center">
<!-- slot-scope="scope" -->
<template>
<template slot-scope="scope">
<div class="handle-btn">
<el-button class="iconfont icon-sulan" @click="toPreview" />
<el-button class="iconfont icon-sulan" @click="toPreview(scope.row)" />
<!-- <el-button class="iconfont icon-xiazai" />
<el-button class="iconfont icon-dayin" /> -->
</div>
@ -132,7 +131,8 @@ export default {
selections: [],
tableData: [],
showCoverVisible: false,
previewSrc: '' // src
previewSrc: '', // src
parentInfo: null
}
},
computed: {
@ -145,9 +145,17 @@ export default {
mounted() {
},
methods: {
toPreview() {
const routeData = this.$router.resolve({ path: '/preview' })
toPreview(row) {
const routeData = this.$router.resolve({
path: '/preview',
query: {
'archiveNo': this.parentInfo.maintitle
}})
window.open(routeData.href, '_blank')
localStorage.setItem('documentId', JSON.stringify(this.selectedDocument.id))
localStorage.setItem('fileParentInfo', JSON.stringify(this.parentInfo))
localStorage.setItem('fileTables', JSON.stringify(this.tableData))
localStorage.setItem('fileCurrent', JSON.stringify(row))
},
getFileSize(fileSize) {
const fileSizeInKB = (fileSize / 1024).toFixed(2) + 'kB'

31
src/views/preview/index.vue

@ -37,9 +37,9 @@
<div v-loading="loading" element-loading-text="文件加载中" class="content-right">
<div class="preview-info">
<ul>
<li>创建时间{{ fileCurrent.create_time }}</li>
<li>大小{{ getFileSize(fileCurrent.file_size) }}</li>
<li>尺寸{{ (!fileCurrent.file_dpi || fileCurrent.file_dpi === 'null') ? '-' : fileCurrent.file_dpi }}</li>
<li>创建时间{{ fileCurrent && fileCurrent.create_time }}</li>
<li>大小{{ getFileSize(fileCurrent && fileCurrent.file_size) }}</li>
<li>尺寸{{ (!(fileCurrent && fileCurrent.file_dpi) || (fileCurrent && fileCurrent.file_dpi === 'null')) ? '-' : fileCurrent.file_dpi }}</li>
</ul>
<div class="preview-btn">
<el-button class="iconfont icon-xiazai" @click="downloadFile(fileCurrent)">下载</el-button>
@ -54,6 +54,7 @@
</template>
<script>
import { FetchReDocumentBase64ByFileId } from '@/api/prearchiveLibrary/prearchiveLibrary'
import { FetchBase64ByFileId } from '@/api/archivesManage/library'
import { getExtend, readBuffer, render } from '@/components/util'
import { parse } from 'qs'
@ -114,7 +115,8 @@ export default {
toFile: null,
fileCurrent: null,
fileParentInfo: null,
pdfsArray: []
pdfsArray: [],
documentId: null
}
},
computed: {
@ -141,6 +143,9 @@ export default {
if (this.$route.query.archiveNo) {
this.parentArchiveNo = this.$route.query.archiveNo
}
if (localStorage.getItem('documentId')) {
this.documentId = JSON.parse(localStorage.getItem('documentId'))
}
if (localStorage.getItem('fileParentInfo')) {
this.fileParentInfo = JSON.parse(localStorage.getItem('fileTables'))
}
@ -148,7 +153,6 @@ export default {
if (localStorage.getItem('fileTables')) {
this.allFileTables = JSON.parse(localStorage.getItem('fileTables'))
}
if (localStorage.getItem('fileCurrent')) {
this.fileCurrent = JSON.parse(localStorage.getItem('fileCurrent'))
}
@ -175,10 +179,26 @@ export default {
},
getBase64ByFileId() {
this.loading = true
if (this.documentId) {
const params = {
'fileId': this.fileCurrent.id,
'documentId': this.documentId
}
FetchReDocumentBase64ByFileId(params).then(res => {
var base64String = res
var fileName = this.fileCurrent && this.fileCurrent.file_name
var mimeType = this.fileCurrent && this.fileCurrent.file_type
this.toFile = this.base64ToFile(base64String, fileName, mimeType)
if (this.toFile) {
this.handleChange()
}
})
} else {
const params = {
'fileId': this.fileCurrent ? this.fileCurrent.id : this.allFileTables[0].id
}
FetchBase64ByFileId(params).then(res => {
console.log('res', res)
var base64String = res
var fileName = this.fileCurrent && this.fileCurrent.file_name
var mimeType = this.fileCurrent && this.fileCurrent.file_type
@ -187,6 +207,7 @@ export default {
this.handleChange()
}
})
}
},
base64ToFile(base64String, fileName, mimeType) {
var byteCharacters = atob(base64String)

Loading…
Cancel
Save