15 changed files with 667 additions and 140 deletions
-
38src/api/collect/collect.js
-
4src/main.js
-
25src/views/archiveUtilize/archiveEditing/module/onlineEditing.vue
-
2src/views/collectReorganizi/collectionLibrary/anjuan/tableList.vue
-
6src/views/collectReorganizi/collectionLibrary/index.vue
-
2src/views/collectReorganizi/collectionLibrary/juannei/index.vue
-
1src/views/collectReorganizi/collectionLibrary/mixins/index.js
-
191src/views/collectReorganizi/collectionLibrary/module/archivesFilling/index.vue
-
28src/views/collectReorganizi/collectionLibrary/module/archivesInfo/index.vue
-
152src/views/collectReorganizi/collectionLibrary/module/collectHeader.vue
-
9src/views/collectReorganizi/collectionLibrary/module/fourTest/index.vue
-
4src/views/collectReorganizi/collectionLibrary/project/index.vue
-
3src/views/collectReorganizi/recycled/index.vue
-
110src/views/components/archivesDetail/project.vue
-
232src/views/components/archivesListModule/index.vue
@ -0,0 +1,191 @@ |
|||||
|
<template> |
||||
|
<!-- 归档审批 --> |
||||
|
<el-dialog class="detail-dialog" :visible.sync="archivesFillingVisible" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body title="流程详情" :before-close="handleCloseDialog" @opened="opened"> |
||||
|
<div class="setting-dialog"> |
||||
|
<div style="padding-top: 20px;"> |
||||
|
<el-form ref="form" :model="form" inline :rules="rules" label-width="80px"> |
||||
|
<el-row> |
||||
|
<el-form-item label="标题" prop="title"> |
||||
|
<el-input v-model="form.title" style="width: 572px;" /> |
||||
|
</el-form-item> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-form-item label="全宗" prop="fondsNo"> |
||||
|
<el-input v-model="form.fondsNo" disabled /> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请人" prop="applicant"> |
||||
|
<el-input v-model="form.applicant" disabled /> |
||||
|
</el-form-item> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-form-item label="备注" prop="remarks"> |
||||
|
<el-input v-model="form.remarks" type="textarea" :rows="3" style="width: 572px;" /> |
||||
|
</el-form-item> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
<div class="detail-tab tab-content"> |
||||
|
<ul class="tab-nav"> |
||||
|
<li :class="{'active-tab-nav': activeIndex == 0 }" @click="changeActiveTab(0)">档案列表</li> |
||||
|
<!-- <li :class="{'active-tab-nav': activeIndex == 1 }" @click="changeActiveTab(1)">任务列表</li> |
||||
|
<li :class="{'active-tab-nav': activeIndex == 2 }" @click="changeActiveTab(2)">流程图</li> --> |
||||
|
</ul> |
||||
|
<div v-if="activeIndex == 0" class="double-click-btn"><i class="iconfont icon-zhuyi-lan" /><span>双击列表数据查看详情</span></div> |
||||
|
<!-- <component :is="comName" class="component-cont" /> --> |
||||
|
<ArchivesListModule v-if="activeIndex == 0" ref="archivesListModule" :selected-category="selectedCategory" :collect-level="collectLevel" :selections="selections" /> |
||||
|
</div> |
||||
|
<div slot="footer" class="dialog-footer"> |
||||
|
<el-button type="primary" @click="handleComfired">确定</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</el-dialog> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { FetchFondsDetail } from '@/api/system/fonds' |
||||
|
import { mapGetters } from 'vuex' |
||||
|
import { FetchBusinessFlowTitle, FetchBecomeDocument } from '@/api/collect/collect' |
||||
|
import ArchivesListModule from '@/views/components/archivesListModule/index' |
||||
|
export default { |
||||
|
name: 'ArchivesFilling', |
||||
|
components: { ArchivesListModule }, |
||||
|
props: { |
||||
|
selectedCategory: { |
||||
|
type: Object, |
||||
|
default: function() { |
||||
|
return {} |
||||
|
} |
||||
|
}, |
||||
|
collectLevel: { |
||||
|
type: Number, |
||||
|
default: function() { |
||||
|
return null |
||||
|
} |
||||
|
}, |
||||
|
selections: { |
||||
|
type: Array, |
||||
|
default: () => [] |
||||
|
} |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
archivesFillingVisible: false, |
||||
|
activeIndex: 0, |
||||
|
form: { |
||||
|
title: null, |
||||
|
username: null, |
||||
|
fondsNo: null, |
||||
|
remarks: null |
||||
|
}, |
||||
|
rules: { |
||||
|
title: [ |
||||
|
{ required: true, message: '标题不可为空', trigger: 'blur' } |
||||
|
] |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
computed: { |
||||
|
// comName: function() { |
||||
|
// if (this.activeIndex === 0) { |
||||
|
// return 'ArchivesListModule' |
||||
|
// } else if (this.activeIndex === 1) { |
||||
|
// return '' |
||||
|
// } else if (this.activeIndex === 2) { |
||||
|
// return '' |
||||
|
// } |
||||
|
// return 'ArchivesListModule' |
||||
|
// } |
||||
|
...mapGetters([ |
||||
|
'user', |
||||
|
'baseApi' |
||||
|
]) |
||||
|
}, |
||||
|
mounted() { |
||||
|
}, |
||||
|
methods: { |
||||
|
getFondsDetail() { |
||||
|
FetchFondsDetail({ id: this.user.fonds.id }).then((res) => { |
||||
|
this.form.fondsNo = res.fondsNo |
||||
|
if (res.fondsNo) { |
||||
|
this.getBusinessFlowTitle() |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
console.log(err) |
||||
|
}) |
||||
|
}, |
||||
|
getBusinessFlowTitle() { |
||||
|
const params = { |
||||
|
'username': this.user.username, |
||||
|
'fondsNo': this.form.fondsNo |
||||
|
} |
||||
|
FetchBusinessFlowTitle(params).then((res) => { |
||||
|
if (res.code !== 500) { |
||||
|
console.log(res) |
||||
|
this.form.title = res |
||||
|
} else { |
||||
|
this.$message.error('失败') |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
console.log(err) |
||||
|
}) |
||||
|
}, |
||||
|
handleComfired() { |
||||
|
this.$refs.form.validate((valid) => { |
||||
|
if (valid) { |
||||
|
const archivesIds = [] |
||||
|
this.selections.forEach(val => { |
||||
|
archivesIds.push(val.id) |
||||
|
}) |
||||
|
const params = { |
||||
|
'title': this.form.title, |
||||
|
'applicant': this.user.username, |
||||
|
'fondsNo': this.form.fondsNo, |
||||
|
'remarks': this.form.remarks, |
||||
|
'archivesIds': archivesIds, |
||||
|
'categoryId': this.selectedCategory.id, |
||||
|
'categoryLevel': this.collectLevel |
||||
|
} |
||||
|
FetchBecomeDocument(params).then((res) => { |
||||
|
if (res.code !== 500) { |
||||
|
this.$message.success('归档操作提交成功') |
||||
|
this.archivesFillingVisible = false |
||||
|
this.handleSearch(this.collectLevel) |
||||
|
} else { |
||||
|
const message = JSON.parse(res.message) |
||||
|
this.$message.error(message.fail.join(',') + '归档操作提交失败') |
||||
|
} |
||||
|
}).catch(err => { |
||||
|
console.log(err) |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
changeActiveTab(data) { |
||||
|
this.activeIndex = data |
||||
|
if (this.activeIndex === 0) { |
||||
|
console.log(this.$refs.archivesListModule) |
||||
|
} |
||||
|
}, |
||||
|
opened() { |
||||
|
if (this.activeIndex === 0) { |
||||
|
this.form.applicant = this.user.username |
||||
|
this.getFondsDetail() |
||||
|
this.$refs.archivesListModule.getViewTable() |
||||
|
} |
||||
|
}, |
||||
|
handleCloseDialog() { |
||||
|
// this.form = {} |
||||
|
this.archivesFillingVisible = false |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style lang='scss' scoped> |
||||
|
|
||||
|
.detail-dialog{ |
||||
|
.detail-tab .tab-nav{ |
||||
|
margin: 0 0 18px 0; |
||||
|
} |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,232 @@ |
|||||
|
<template> |
||||
|
<div> |
||||
|
<el-table |
||||
|
ref="table" |
||||
|
v-loading="tableLoading" |
||||
|
class="archives-table" |
||||
|
:data="tableData" |
||||
|
height="calc(100vh - 600px)" |
||||
|
highlight-current-row |
||||
|
style="width: 100%;" |
||||
|
:row-key="rowKey" |
||||
|
@cell-dblclick="tableDoubleClick" |
||||
|
> |
||||
|
<el-table-column type="index" label="序号" width="55" align="center" /> |
||||
|
<el-table-column :label="selectedCategory.arrangeType === 1 ? '原文':'卷内'" prop="child" width="55" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.child === '' ? 0 : scope.row.child }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column v-for="field in tableDisplayFields" :key="field.id" :label="field.fieldCnName" :align="field.displayformatType" :width="field.displayLength" show-overflow-tooltip> |
||||
|
<template slot="header"> |
||||
|
<el-tooltip |
||||
|
class="item" |
||||
|
effect="dark" |
||||
|
:content="field.fieldCnName" |
||||
|
placement="top-start" |
||||
|
> |
||||
|
<span>{{ field.fieldCnName }}</span> |
||||
|
</el-tooltip> |
||||
|
</template> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row[field.fieldName] }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<!-- 档案详情 --> |
||||
|
<ArchivesInfo ref="archivesInfo" :selected-category="selectedCategory" :arc-id="arcId" /> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import ArchivesInfo from '@/views/collectReorganizi/collectionLibrary/module/archivesInfo/index' |
||||
|
import { FetchInitCategoryViewTable, FetchInitCategoryView } from '@/api/collect/collect' |
||||
|
export default { |
||||
|
name: 'ArchivesListModule', |
||||
|
components: { ArchivesInfo }, |
||||
|
props: { |
||||
|
selectedCategory: { |
||||
|
type: Object, |
||||
|
default: function() { |
||||
|
return {} |
||||
|
} |
||||
|
}, |
||||
|
collectLevel: { |
||||
|
type: Number, |
||||
|
default: function() { |
||||
|
return null |
||||
|
} |
||||
|
}, |
||||
|
selections: { |
||||
|
type: Array, |
||||
|
default: () => [] |
||||
|
}, |
||||
|
isTitleType: { |
||||
|
type: Number, |
||||
|
default: 2 |
||||
|
} |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
tableLoading: false, |
||||
|
tableDisplayFields: [], |
||||
|
tableData: [], |
||||
|
arrySort: [], |
||||
|
arcId: null, |
||||
|
isDetail: false, |
||||
|
parentId: null, |
||||
|
setType: null, |
||||
|
rowType: null, |
||||
|
collectLevelList: null |
||||
|
} |
||||
|
}, |
||||
|
watch: { |
||||
|
isTitleType: function(newValue, oldValue) { |
||||
|
console.log('newValue222', newValue) |
||||
|
} |
||||
|
}, |
||||
|
mounted() { |
||||
|
}, |
||||
|
methods: { |
||||
|
rowKey(row) { |
||||
|
return row.id |
||||
|
}, |
||||
|
// table - 双击查看详情 |
||||
|
tableDoubleClick(row) { |
||||
|
console.log(row.id) |
||||
|
this.arcId = row.id |
||||
|
this.$nextTick(() => { |
||||
|
if (this.selectedCategory.arrangeType === 3) { |
||||
|
console.log('dddddddd', localStorage.getItem('collectLevelList')) |
||||
|
console.log('collectLevelList', this.collectLevelList) |
||||
|
localStorage.setItem('collectLevelList', this.collectLevelList) |
||||
|
// 项目 |
||||
|
this.isDetail = true |
||||
|
if (localStorage.getItem('collectLevelList') === '2') { |
||||
|
this.$refs.archivesInfo.isHasFile = false |
||||
|
this.$refs.archivesInfo.detailTitle = '案卷详情' |
||||
|
this.$refs.archivesInfo.isHasModuleFile = true |
||||
|
this.$refs.archivesInfo.parentId = row.id |
||||
|
this.$refs.archivesInfo.getDetial(2, row.id) |
||||
|
} else if (localStorage.getItem('collectLevelList') === '3') { |
||||
|
this.$refs.archivesInfo.isHasFile = true |
||||
|
this.$refs.archivesInfo.isFourTest = true |
||||
|
this.$refs.archivesInfo.detailTitle = '卷内详情' |
||||
|
this.$refs.archivesInfo.parentId = row.id |
||||
|
this.$refs.archivesInfo.getDetial(3, row.id) |
||||
|
} else { |
||||
|
console.log('111') |
||||
|
} |
||||
|
} else if (this.selectedCategory.arrangeType === 2) { |
||||
|
// 案卷 |
||||
|
this.$refs.archivesInfo.isHasFile = true |
||||
|
this.$refs.archivesInfo.isFourTest = true |
||||
|
this.$refs.archivesInfo.detailTitle = '卷内详情' |
||||
|
this.$refs.archivesInfo.parentId = row.id |
||||
|
this.$refs.archivesInfo.getDetial(3, row.id) |
||||
|
} else { |
||||
|
// 文件 |
||||
|
this.$refs.archivesInfo.isHasFile = true |
||||
|
this.$refs.archivesInfo.isHasModuleFile = false |
||||
|
this.$refs.archivesInfo.detailTitle = '文件详情' |
||||
|
this.$refs.archivesInfo.parentId = row.id |
||||
|
this.$refs.archivesInfo.getDetial(3, row.id) |
||||
|
} |
||||
|
|
||||
|
this.$refs.archivesInfo.isFourTest = true |
||||
|
this.$refs.archivesInfo.archivesInfoVisible = true |
||||
|
this.$refs.archivesInfo.archivesTabIndex = 0 |
||||
|
}) |
||||
|
}, |
||||
|
getViewTable() { |
||||
|
this.tableData = [] |
||||
|
this.tableLoading = true |
||||
|
let params |
||||
|
let collectLevel |
||||
|
if (this.isDetail) { |
||||
|
if (this.selectedCategory.arrangeType === 3) { |
||||
|
console.log('ttt', localStorage.getItem('collectLevelList')) |
||||
|
console.log('ggg', this.collectLevelList) |
||||
|
if (localStorage.getItem('collectLevelList') === '2') { |
||||
|
collectLevel = 3 |
||||
|
} else if (localStorage.getItem('collectLevelList') === '3') { |
||||
|
collectLevel = 4 |
||||
|
} else { |
||||
|
collectLevel = 2 |
||||
|
} |
||||
|
console.log(collectLevel) |
||||
|
} else if (this.selectedCategory.arrangeType === 2) { |
||||
|
collectLevel = 3 |
||||
|
} else { |
||||
|
collectLevel = 4 |
||||
|
} |
||||
|
params = { |
||||
|
categoryId: this.selectedCategory.id, |
||||
|
categoryLevel: collectLevel |
||||
|
} |
||||
|
} else { |
||||
|
params = { |
||||
|
categoryId: this.selectedCategory.id, |
||||
|
categoryLevel: this.collectLevel |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
FetchInitCategoryViewTable(params).then((res) => { |
||||
|
if (res) { |
||||
|
this.arrySort = [] |
||||
|
this.tableDisplayFields = res |
||||
|
const orderSortArry = this.tableDisplayFields.filter(item => item.displayOrder).sort((a, b) => a.displayOrder - b.displayOrder) |
||||
|
orderSortArry.forEach(item => { |
||||
|
if (item.displayOrderBy) { |
||||
|
this.arrySort.push(item.fieldName + ',' + item.displayOrderBy) |
||||
|
} |
||||
|
}) |
||||
|
if (this.isDetail) { |
||||
|
this.getViewTableList() |
||||
|
} else { |
||||
|
this.tableData = this.selections |
||||
|
this.tableLoading = false |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
getViewTableList() { |
||||
|
let collectLevel |
||||
|
if (this.selectedCategory.arrangeType === 3) { |
||||
|
console.log('rrr', localStorage.getItem('collectLevelList')) |
||||
|
if (localStorage.getItem('collectLevelList') === '2') { |
||||
|
collectLevel = 3 |
||||
|
} else if (localStorage.getItem('collectLevelList') === '3') { |
||||
|
collectLevel = 4 |
||||
|
} else { |
||||
|
collectLevel = 2 |
||||
|
} |
||||
|
} else if (this.selectedCategory.arrangeType === 2) { |
||||
|
collectLevel = 3 |
||||
|
} else { |
||||
|
collectLevel = 4 |
||||
|
} |
||||
|
const params = { |
||||
|
'parentId': this.parentId, |
||||
|
'categoryId': this.selectedCategory.id, |
||||
|
'categoryLevel': collectLevel, |
||||
|
'page': 0, |
||||
|
'size': 100, |
||||
|
'sort': this.arrySort |
||||
|
} |
||||
|
FetchInitCategoryView(params).then((res) => { |
||||
|
if (res.code !== 500) { |
||||
|
this.tableData = res.list.content |
||||
|
this.collectLevelList = res.categoryLevel |
||||
|
} |
||||
|
this.tableLoading = false |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style lang='scss' scoped> |
||||
|
@import "~@/assets/styles/collect-reorganizi.scss"; |
||||
|
|
||||
|
</style> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue