Browse Source

公共筛选/快速筛选/收集库

master
xuhuajiao 1 year ago
parent
commit
28af88d6fb
  1. 25
      src/api/system/dict.js
  2. 88
      src/assets/styles/archives-manage.scss
  3. 24
      src/views/archivesManage/managementLibrary/anjuan/tableList.vue
  4. 14
      src/views/archivesManage/managementLibrary/file/index.vue
  5. 20
      src/views/archivesManage/managementLibrary/index.vue
  6. 17
      src/views/archivesManage/managementLibrary/juannei/index.vue
  7. 13
      src/views/archivesManage/managementLibrary/mixins/index.js
  8. 27
      src/views/archivesManage/managementLibrary/module/collectHeader.vue
  9. 15
      src/views/archivesManage/managementLibrary/project/index.vue
  10. 19
      src/views/collectReorganizi/collectionLibrary/anjuan/tableList.vue
  11. 88
      src/views/collectReorganizi/collectionLibrary/index.vue
  12. 6
      src/views/collectReorganizi/collectionLibrary/juannei/index.vue
  13. 661
      src/views/collectReorganizi/collectionLibrary/module/collectHeader.vue
  14. 123
      src/views/collectReorganizi/collectionLibrary/module/fileNumberAdjustment/index.vue
  15. 9
      src/views/collectReorganizi/collectionLibrary/module/fileSeqAdjustment/index.vue
  16. 7
      src/views/collectReorganizi/collectionLibrary/project/index.vue
  17. 19
      src/views/components/BindingTagDlg.vue
  18. 158
      src/views/components/category/PreviewForm.vue
  19. 2
      src/views/components/category/SettingForm.vue
  20. 64
      src/views/system/archivesCategory/publicScreening/index.vue

25
src/api/system/dict.js

@ -1,12 +1,12 @@
import request from '@/utils/request'
// export function getDictsList(params) {
// return request({
// url: 'api/dictionary/initDictionaryList',
// method: 'get',
// params
// })
// }
export function FetchDictsList(params) {
return request({
url: 'api/dictionary/initDictionaryList',
method: 'get',
params
})
}
export function add(data) {
return request({
@ -48,4 +48,13 @@ export function FetchSonDictionaryList(params) {
})
}
export default { add, edit, del, FetchDictionaryTree, FetchSonDictionaryList }
// 快速筛选
export function FetchDictionaryTreeByCategoryId(params) {
return request({
url: 'api/dictionary/getDictionaryTreeByCategoryId',
method: 'get',
params
})
}
export default { add, edit, del, FetchDictsList, FetchDictionaryTree, FetchSonDictionaryList, FetchDictionaryTreeByCategoryId }

88
src/assets/styles/archives-manage.scss

@ -324,53 +324,74 @@
content: "";
position: absolute;
left: 15px;
top: 10px;
width: 1px;
height: 100%;
background-color: #3A99FD;
top: 32px;
width: 2px;
height: 45px;
// background-color: #0348F3;
border-left: 2px solid #0348F3;
opacity: 0.3;
z-index: 1;
}
&:last-child::before{
display: none;
}
&.step-active{
&::before{
opacity: 0.3;
}
}
&.step-loading{
&::before{
opacity: 1;
border-left: 2px dashed #0348F3;
}
}
}
.step-left-num{
position: relative;
display: block;
width: 30px;
height: 30px;
line-height: 30px;
line-height: 28px;
border-radius: 50%;
font-size: 16px;
text-align: center;
color: #fff;
border: 1px solid $mainColor;
background-color: $boxBg;
color: #0348F3;
border: 2px solid #0348F3;
// background-color: #0348F3;
opacity: 0.3;
z-index: 4;
&.step-active{
background-color: $mainColor;
color: #fff;
background-color:#0348F3;
opacity: 1;
}
&.step-loading{
color: #0348F3;
border: 2px solid #0348F3;
background-color: #fff;
&::before,
&::after{
content: "";
position: absolute;
left: 50%;
top: 50%;
width: 40px;
height: 40px;
border-radius: 50%;
border: 1px solid #13439E;
box-shadow: inset 0px 0px 8px 1px #13439E;
// width: 40px;
// height: 40px;
// border-radius: 50%;
// color: #0348F3;
// border: 2px solid #0348F3;
// background-color: #fff;
// box-shadow: inset 0px 0px 8px 1px #0348F3;
margin: -20px 0 0 -20px;
z-index: 1;
}
&::before{
animation: halo 2s linear 0.5s infinite;
}
&::after{
animation: halo 2s linear 1.5s infinite;
}
// &::before{
// animation: halo 2s linear 0.5s infinite;
// }
// &::after{
// animation: halo 2s linear 1.5s infinite;
// }
}
}
// 晕开效果
@ -405,26 +426,27 @@
flex: 1;
margin-left: 12px;
.step-title{
font-size: 16px;
line-height: 30px;
color: $mainColor;
color: #0348F3;
span{
padding-left: 10px;
font-weight: bold;
color: #fff;
// font-weight: bold;
color: #0C0E1E;
}
}
.step-tip{
padding: 0 10px;
height: 40px;
line-height: 40px;
color: #13439E;
background-color: #02255F;
color: #A6ADB6;
background-color: #EDEFF3;
border-radius: 4px;
&.tip-active{
color: $mainColor;
color: #545B65;
}
&.tip-error{
color: #EF3147;
color: #ED4A41;
}
}
}
@ -799,7 +821,7 @@
}
}
.head-search{
margin-right: 60px;
margin-right: 30px;
.el-button{
margin-left: 10px;
}
@ -920,4 +942,14 @@
padding: 0 20px 10px 20px;
text-align: right;
color: #545B65;
}
.drag-tip {
display: block;
padding-left: 20px;
padding-bottom: 10px;
font-style: normal;
font-weight: bold;
font-size: 12px;
}

24
src/views/archivesManage/managementLibrary/anjuan/tableList.vue

@ -37,14 +37,15 @@
{{ scope.row[field.fieldName] }}
</template>
</el-table-column>
<el-table-column v-if="!isRecycle" label="实体" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<el-table-column v-if="!isRecycle && selectedCategory.arrangeType === 1" label="实体" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<!-- slot-scope="scope" -->
<template>
<span class="row-state row-physical state-active"></span>
<!-- <span :class="['row-state', 'row-physical', scope.row.tid ? 'state-active' : '' ]">{{ scope.row.tid ? '有': '无' }}</span> -->
</template>
</el-table-column>
<el-table-column v-if="!isRecycle" label="标签" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<el-table-column v-if="!isRecycle && selectedCategory.arrangeType === 1" label="标签" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<template>
<span class="row-state row-binding state-active">未绑</span>
<!-- 未绑 / 已绑 -->
@ -66,13 +67,14 @@
<!-- <span :class="['row-state', 'row-warehousing', (storageTxt[scope.$index] === '已入' )? 'state-active' : '' ]">{{ storageTxt[scope.$index] }}</span> -->
</template>
</el-table-column>
<el-table-column v-if="!isRecycle" label="借阅" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<el-table-column v-if="!isRecycle && selectedCategory.arrangeType === 1" label="借阅" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<template>
<span class="row-state row-lending state-active">已借</span>
<!-- is_borrow 4 已归还 / 为空 - 未加入待借列表 - 在库 / 2 待借阅在待借列表/借出确认列表 - 待借 / 1待登记 - 不可借- 表示 / 3 待归还 - 已借 -->
<!-- <span :class="['row-state', 'row-lending', (borrowTxt[scope.$index] === '已借' )? 'state-active' : '' ]">{{ borrowTxt[scope.$index] }}</span> -->
</template>
</el-table-column>
</el-table>
<!--分页组件-->
<el-pagination
@ -92,7 +94,7 @@
<script>
import { header, form } from '@crud/crud'
import { collectionLibraryCrud } from '../mixins/index'
import { manageLibraryCrud } from '../mixins/index'
import ArchivesInfo from '../module/archivesInfo/index'
import CollectHeader from '../module/collectHeader'
@ -105,7 +107,7 @@ export default {
mixins: [
header(),
form({}),
collectionLibraryCrud
manageLibraryCrud
],
props: {
isTitleType: {
@ -171,17 +173,6 @@ export default {
this.$parent.$parent.$emit('openJuannei', data)
}
},
// table
tableRowClassName({ row, rowIndex }) {
// console.log('', row, rowIndex)
let color = ''
this.selections.forEach(item => {
if (item.id === row.id) {
color = 'rowStyle'
}
})
return color
},
// table -
selectAll(val) {
this.selections = val
@ -225,6 +216,7 @@ export default {
//
handleCurrentChange(selection, row) {
console.log('触发单选', row)
console.log('selection', selection)
this.selections = selection
},
handleSizeChange(size) {

14
src/views/archivesManage/managementLibrary/file/index.vue

@ -68,7 +68,7 @@
</template>
<script>
import { collectionLibraryCrud } from '../mixins/index'
import { manageLibraryCrud } from '../mixins/index'
import { header, form } from '@crud/crud'
import CollectHeader from '../module/collectHeader.vue'
export default {
@ -77,7 +77,7 @@ export default {
mixins: [
header(),
form({}),
collectionLibraryCrud
manageLibraryCrud
],
props: {
selectedCategory: {
@ -114,16 +114,6 @@ export default {
rowKey(row) {
return row.id
},
// table
tableRowClassName({ row, rowIndex }) {
let color = ''
this.selections.forEach(item => {
if (item.id === row.id) {
color = 'rowStyle'
}
})
return color
},
// table -
selectAll(val) {
this.selections = val

20
src/views/archivesManage/managementLibrary/index.vue

@ -34,11 +34,11 @@
highlight-current
>
<span slot-scope="{ node, data }" class="custom-tree-node">
<span v-if="data.pid === null " class="iconClassify">
{{ data.name }}
<span v-if="data.childDictionarys !== null " class="iconClassify">
{{ data.dictionaryName }}
</span>
<span v-if="data.pid" class="iconClassify-child">
{{ data.name }}
<span v-else class="iconClassify-child">
{{ data.dictionaryName }}
</span>
</span>
</el-tree>
@ -62,8 +62,8 @@
<script>
import crudCategory from '@/api/category/category'
import { collectionLibraryCrud } from './mixins/index'
import { FetchArchivesClassTree } from '@/api/system/archivesClass'
import { manageLibraryCrud } from './mixins/index'
import { FetchDictionaryTreeByCategoryId } from '@/api/system/dict'
import CRUD, { presenter, header } from '@crud/crud'
import Project from './project/index'
import Anjuan from './anjuan/index'
@ -87,7 +87,7 @@ export default {
})
]
},
mixins: [presenter(), header(), collectionLibraryCrud],
mixins: [presenter(), header(), manageLibraryCrud],
props: {
isRecycle: {
type: Boolean,
@ -101,8 +101,8 @@ export default {
label: 'cnName'
},
defaultClassifyProps: {
children: 'childArchivesClass',
label: 'name'
children: 'childDictionarys',
label: 'dictionaryName'
},
sharedData: '',
selectedCategory: {},
@ -227,7 +227,7 @@ export default {
const params = {
'categoryId': categoryId
}
FetchArchivesClassTree(params).then((res) => {
FetchDictionaryTreeByCategoryId(params).then((res) => {
this.classifyTree = res
this.classifyLoading = false
}).catch(err => {

17
src/views/archivesManage/managementLibrary/juannei/index.vue

@ -43,6 +43,7 @@
{{ scope.row[field.fieldName] }}
</template>
</el-table-column>
<el-table-column v-if="!isRecycle" label="实体" width="88" align="center" :fixed="fixedStatusBar ? false : 'right' ">
<!-- slot-scope="scope" -->
<template>
@ -79,6 +80,7 @@
<!-- <span :class="['row-state', 'row-lending', (borrowTxt[scope.$index] === '已借' )? 'state-active' : '' ]">{{ borrowTxt[scope.$index] }}</span> -->
</template>
</el-table-column>
</el-table>
<!--分页组件-->
<el-pagination
@ -98,7 +100,7 @@
</template>
<script>
import { collectionLibraryCrud } from '../mixins/index'
import { manageLibraryCrud } from '../mixins/index'
import { header, form } from '@crud/crud'
import CollectHeader from '../module/collectHeader.vue'
import ArchivesInfo from '../module/archivesInfo/index'
@ -112,7 +114,7 @@ export default {
mixins: [
header(),
form({}),
collectionLibraryCrud
manageLibraryCrud
],
props: {
selectedCategory: {
@ -169,17 +171,6 @@ export default {
rowKey(row) {
return row.id
},
// table
tableRowClassName({ row, rowIndex }) {
// console.log('', row, rowIndex)
let color = ''
this.selections.forEach(item => {
if (item.id === row.id) {
color = 'rowStyle'
}
})
return color
},
// table -
selectAll(val) {
this.selections = val

13
src/views/archivesManage/managementLibrary/mixins/index.js

@ -1,7 +1,7 @@
// import qs from 'qs'
// import { exportFile } from '@/utils/index'
import { FetchInitCategoryViewTable, FetchInitCategoryView } from '@/api/collect/collect'
export const collectionLibraryCrud = {
export const manageLibraryCrud = {
// 组件共用属性
data() {
return {
@ -34,6 +34,17 @@ export const collectionLibraryCrud = {
// this.$emit('status-bar-checked-changed', this.fixedStatusBar)
// localStorage.setItem('statusBarFixedType', val)
// },
// table选中加上选中状态
tableRowClassName({ row, rowIndex }) {
// console.log('添加类名', row, rowIndex)
let color = ''
this.selections.forEach(item => {
if (item.id === row.id) {
color = 'rowStyle'
}
})
return color
},
handleSearch() {
this.getViewTableList()
},

27
src/views/archivesManage/managementLibrary/module/collectHeader.vue

@ -46,7 +46,7 @@
<span>整理</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType === 3" index="2-1">标签绑定</el-menu-item>
<el-menu-item v-if="isTitleType === 3" index="2-1" @click="bindingTag(selections)">标签绑定</el-menu-item>
<el-menu-item-group v-if="isTitleType === 3" class="collect-submenu-group submenu-tree">
<template slot="title">档案装盒</template>
<el-menu-item index="2-2">装盒</el-menu-item>
@ -95,6 +95,9 @@
</div>
</el-dialog>
<!-- 绑定标签 -->
<binding-tag-dlg ref="bindingTag" :binding-id="selections[0] && selections[0].id" :binding-type="1" binding-txt="档案" />
<!--删除对话框组件-->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="deleteVisible">
<div class="setting-dialog">
@ -162,16 +165,17 @@
</template>
<script>
import { collectionLibraryCrud } from '../mixins/index'
import { manageLibraryCrud } from '../mixins/index'
import { FetchInitCategoryInputFieldByPid } from '@/api/system/category/category'
import PreviewForm from '@/views/components/category/PreviewForm'
import Print from './print/index'
import BindingTagDlg from '@/views/components/BindingTagDlg'
// import { exportFile } from '@/utils/index'
import { mapGetters } from 'vuex'
export default {
name: 'CollectHeader',
components: { PreviewForm, Print },
mixins: [collectionLibraryCrud],
components: { PreviewForm, BindingTagDlg, Print },
mixins: [manageLibraryCrud],
props: {
selectedCategory: {
type: Object,
@ -198,6 +202,12 @@ export default {
isRecycle: {
type: Boolean,
default: false
},
selections: {
type: Array,
default: function() {
return []
}
}
},
data() {
@ -241,7 +251,6 @@ export default {
}
],
selectStatus: null,
activeMenuIndex: '1',
formVisible: false,
formTitle: '项目',
@ -397,6 +406,14 @@ export default {
handleDelConfirm() {
this.deleteVisible = false
},
//
bindingTag(data) {
if (data[0].tid) {
this.$refs.bindingTag.isBinding = true
this.$refs.bindingTag.tidCode = data[0].tid
}
this.$refs.bindingTag.bindingVisible = true
},
//
handleExport() {
this.exportVisible = true

15
src/views/archivesManage/managementLibrary/project/index.vue

@ -53,7 +53,7 @@
</template>
<script>
import { collectionLibraryCrud } from '../mixins/index'
import { manageLibraryCrud } from '../mixins/index'
import { header, form } from '@crud/crud'
import CollectHeader from '../module/collectHeader.vue'
import ArchivesInfo from '../module/archivesInfo/index'
@ -67,7 +67,7 @@ export default {
mixins: [
header(),
form({}),
collectionLibraryCrud
manageLibraryCrud
],
props: {
data: {
@ -117,17 +117,6 @@ export default {
rowKey(row) {
return row.id
},
// table
tableRowClassName({ row, rowIndex }) {
// console.log('', row, rowIndex)
let color = ''
this.selections.forEach(item => {
if (item.id === row.id) {
color = 'rowStyle'
}
})
return color
},
// table -
selectAll(val) {
this.selections = val

19
src/views/collectReorganizi/collectionLibrary/anjuan/tableList.vue

@ -58,6 +58,9 @@ import { header, form } from '@crud/crud'
import { collectionLibraryCrud } from '../mixins/index'
import ArchivesInfo from '../module/archivesInfo/index'
import CollectHeader from '../module/collectHeader.vue'
import tableData from '@/views/archivesManage/managementLibrary/anjuan/table.json'
import jsonData from '@/views/archivesManage/managementLibrary/anjuan/data.json'
export default {
name: 'Sorted',
components: { ArchivesInfo, CollectHeader },
@ -93,7 +96,8 @@ export default {
data() {
return {
categoryId: 'F0F59CC713C83AE4BAB99B',
arcId: '256E752BC0280618840600'
arcId: '256E752BC0280618840600',
title: '案卷'
}
},
watch: {
@ -105,11 +109,18 @@ export default {
this.doLayout()
},
activeIndex(newValue) {
if (newValue === 1) {
this.title = '文件'
} else {
this.title = '案卷'
}
this.selections = []
this.$refs.table.clearSelection()
}
},
created() {
this.tableDisplayFields = tableData.data
this.anjuanData = jsonData.data.list.content
},
mounted() {
@ -153,14 +164,18 @@ export default {
this.arcId = row.id
if (this.selectedCategory.arrangeType !== 1) {
this.title = '案卷'
this.$refs.archivesInfo.isHasFile = false
if (this.activeIndex === 1) {
this.title = '文件'
this.$refs.archivesInfo.detailTitle = '文件详情'
this.$refs.archivesInfo.isHasFile = true
} else {
this.title = '案卷'
this.$refs.archivesInfo.detailTitle = '案卷详情'
}
} else {
this.title = '文件'
this.$refs.archivesInfo.isHasFile = true
this.$refs.archivesInfo.detailTitle = '文件详情'
}
@ -175,7 +190,7 @@ export default {
clearTimeout(this.timer)
}
this.timer = setTimeout(() => {
this.openJuannei(row.archive_no)
this.openJuannei('所属' + this.title + row.archive_no)
}, 300)
this.selections = this.crud.selections
},

88
src/views/collectReorganizi/collectionLibrary/index.vue

@ -23,25 +23,41 @@
</el-tree>
</div>
<h3 class="arc-title arc-title-bottom">快速筛选</h3>
<el-tree
ref="classifyTree"
v-loading="classifyLoading"
class="arc-tree arc-tree-02"
:data="classifyTree"
:props="defaultClassifyProps"
node-key="id"
:expand-on-click-node="false"
highlight-current
>
<span slot-scope="{ node, data }" class="custom-tree-node">
<span v-if="data.pid === null " class="iconClassify">
{{ data.name }}
<div class="arc-tree arc-tree-02">
<el-tree
ref="classifyTree"
v-loading="classifyLoading"
:data="classifyTree"
:props="defaultClassifyProps"
node-key="id"
:expand-on-click-node="false"
highlight-current
>
<span slot-scope="{ node, data }" class="custom-tree-node">
<span v-if="data.childDictionarys !== null " class="iconClassify">
{{ data.dictionaryName }}
</span>
<span v-else class="iconClassify-child">
{{ data.dictionaryName }}
</span>
</span>
<span v-if="data.pid" class="iconClassify-child">
{{ data.name }}
</el-tree>
<el-tree
ref="fondsTree"
v-loading="classifyLoading"
:data="fondsTree"
:props="defaultFondsProps"
node-key="id"
:expand-on-click-node="false"
highlight-current
>
<span slot-scope="{ node, data }" class="custom-tree-node">
<span class="iconClassify">
{{ data.fondsName }}
</span>
</span>
</span>
</el-tree>
</el-tree>
</div>
</div>
</div>
</div>
@ -63,12 +79,13 @@
<script>
import crudCategory from '@/api/category/category'
import { collectionLibraryCrud } from './mixins/index'
import { FetchArchivesClassTree } from '@/api/system/archivesClass'
import { FetchDictionaryTreeByCategoryId } from '@/api/system/dict'
import CRUD, { presenter, header } from '@crud/crud'
import Project from './project/index'
import Anjuan from './anjuan/index'
import Juannei from './juannei/index'
import File from './file/index'
export default {
name: 'CollectionLibrary',
components: { Project, Anjuan, Juannei, File },
@ -101,12 +118,17 @@ export default {
label: 'cnName'
},
defaultClassifyProps: {
children: 'childArchivesClass',
label: 'name'
children: 'childDictionarys',
label: 'dictionaryName'
},
defaultFondsProps: {
children: 'children',
label: 'fondsName'
},
sharedData: '',
selectedCategory: {},
classifyTree: [],
fondsTree: [],
classifyLoading: false
}
},
@ -195,18 +217,19 @@ export default {
this.selectedCategory = val
if (this.selectedCategory.isType !== 1) {
this.getInitArchivesClass(val.id)
this.FetchDictionaryTreeByCategoryId(val.id)
} else {
this.classifyTree = []
this.fondsTree = []
}
this.$nextTick(() => {
if (this.selectedCategory.arrangeType === 3) {
this.$refs.projectEle.getCommonData(1)
// this.$refs.projectEle.getCommonData(1)
} else if (this.selectedCategory.arrangeType === 2) {
this.$refs.anjuanEle.$refs.ajContent.$refs.tableList.getCommonData(2)
// this.$refs.anjuanEle.$refs.ajContent.$refs.tableList.getCommonData(2)
} else if (this.selectedCategory.arrangeType === 1) {
this.$refs.anjuanEle.$refs.ajContent.$refs.tableList.getCommonData(3)
// this.$refs.anjuanEle.$refs.ajContent.$refs.tableList.getCommonData(3)
}
if (this.$refs.anjuanEle) {
this.$refs.anjuanEle.anjuanDrawer = false
@ -222,13 +245,14 @@ export default {
}
})
},
getInitArchivesClass(categoryId) {
FetchDictionaryTreeByCategoryId(categoryId) {
this.classifyLoading = true
const params = {
'categoryId': categoryId
}
FetchArchivesClassTree(params).then((res) => {
this.classifyTree = res
FetchDictionaryTreeByCategoryId(params).then((res) => {
this.classifyTree = res.dictionarys
this.fondsTree = res.fonds
this.classifyLoading = false
}).catch(err => {
console.log(err)
@ -236,7 +260,10 @@ export default {
},
handleOpenAnjuan(data) {
this.$refs.anjuanEle.anjuanDrawer = true
this.$refs.anjuanEle.$refs.ajContent.activeIndex = 0
this.activeIndex = 0
if (this.$refs.anjuanEle.$refs.ajContent) {
this.$refs.anjuanEle.$refs.ajContent.activeIndex = 0
}
this.$nextTick(() => {
this.$refs.anjuanEle.$refs.ajContent.test = data
})
@ -319,7 +346,6 @@ export default {
}
.arc-tree{
padding: 0 20px;
background-color: red;
}
.arc-tree-01{
height: 400px;
@ -331,9 +357,13 @@ export default {
}
.arc-tree-02{
margin: 20px 0;
height: calc(100vh - 720px);
overflow: hidden;
overflow-y: scroll;
.el-tree{
margin: 0;
}
}
::v-deep .el-tree-node__children .custom-tree-node{
font-size: 14px;

6
src/views/collectReorganizi/collectionLibrary/juannei/index.vue

@ -67,6 +67,8 @@ import { collectionLibraryCrud } from '../mixins/index'
import { header, form } from '@crud/crud'
import CollectHeader from '../module/collectHeader.vue'
import ArchivesInfo from '../module/archivesInfo/index'
import tableData from '@/views/archivesManage/managementLibrary/anjuan/table.json'
import jsonData from '@/views/archivesManage/managementLibrary/anjuan/data.json'
export default {
name: 'Juannei',
components: { CollectHeader, ArchivesInfo },
@ -104,6 +106,8 @@ export default {
}
},
created() {
this.tableDisplayFields = tableData.data
this.junneiData = jsonData.data.list.content
},
mounted() {
console.log('nei2', this.selectedCategory.arrangeType)
@ -157,7 +161,7 @@ export default {
clearTimeout(this.timer)
}
this.timer = setTimeout(() => {
this.openFile(row.archive_no)
this.openFile('所属卷内' + row.archive_no)
}, 300)
this.selections = this.crud.selections
},

661
src/views/collectReorganizi/collectionLibrary/module/collectHeader.vue

@ -1,278 +1,308 @@
<template>
<div class="collect-header">
<h4 :class="classType">{{ collectTitle }} <span v-if="isTitleType !== 2 && !(isTitleType === 3 && (selectedCategory.arrangeType === 1 || selectedCategory.arrangeType === 2) )"> > {{ test }}</span></h4>
<!-- :class="[!(isRecycle && (isTitleType === 2 || (isTitleType === 3 && selectedCategory.arrangeType !== 3))) ? 'head-search is-recycle':'head-search']" -->
<div v-if="isTitleType !== 6" class="head-search">
<!-- 搜索 -->
<el-input v-model="query.search" clearable size="small" :placeholder="placeholderType" prefix-icon="el-icon-search" style="width: 200px;" class="filter-item" />
<el-button class="filter-item filter-search" size="mini" type="success" icon="el-icon-search" @click="handleSearch">搜索</el-button>
<el-button class="filter-item filter-refresh" size="mini" type="warning" icon="el-icon-refresh-left">重置</el-button>
</div>
<div v-if="!isRecycle" class="collect-menu">
<el-menu
:default-active="activeMenuIndex"
mode="horizontal"
@select="handleSelect"
>
<el-submenu index="1">
<template slot="title">
<i class="iconfont icon-changgui" />
<span>常规</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 6" index="1-1" @click="handleForm('add')">新增</el-menu-item>
<el-menu-item v-if="isTitleType !== 6" index="1-2" @click="handleForm('edit')">编辑</el-menu-item>
<el-menu-item v-if="isTitleType !== 4" index="1-3" @click="toDelete">删除</el-menu-item>
<el-menu-item v-if="isTitleType === 4" index="1-4" @click="toMove">移出</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="(isTitleType === 3 && selectedCategory.arrangeType === 1) || isTitleType === 4 || isTitleType === 6 || (isTitleType === 3 && activeIndex === 1)" class="collect-submenu-group submenu-tree">
<template slot="title">原文上传</template>
<el-menu-item index="1-5" @click="fileUpload(0)">普通上传</el-menu-item>
<el-menu-item index="1-6" @click="fileUpload(1)">大文件上传</el-menu-item>
</el-menu-item-group>
</el-submenu>
<el-submenu v-if="isTitleType !== 6" index="2">
<template slot="title">
<i class="iconfont icon-zhengli" />
<span>整理</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 2" index="2-1" @click="handleBlukImport">批量导入</el-menu-item>
<!-- 项目 / 案卷 / 卷内 / 文件-->
<el-menu-item v-if="activeIndex !== 1 || (isTitleType === 3 && selectedCategory.arrangeType === 1 && activeIndex === 1)" index="2-2" @click="handleBlukEditing">批量修改</el-menu-item>
<el-menu-item v-if="isTitleType !== 2 && !(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1)" index="2-3" @click="handleAdjustment">档案调整</el-menu-item>
<el-menu-item v-if="isTitleType !== 2 && !(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1)" index="2-4" @click="handleFileNumberUpdate">档号更新</el-menu-item>
<!-- 案卷 -->
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1 " index="2-5" @click="handleFileNumberUpdate">卷内档号更新</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1 " index="2-12" @click="handleFileSeqAdjustment">卷内顺序调整</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1" index="2-6" @click="handleUncoil">拆卷</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1" index="2-7" @click="handleCombineFile">合卷</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && selectedCategory.arrangeType !== 1" index="2-8" @click="handleInsertFile">插件</el-menu-item>
<!-- 案卷 / 卷内 / 文件 -->
<el-menu-item v-if="isTitleType !== 2" index="2-9" @click="handleCollectMoveFile">移动</el-menu-item>
<!-- 案卷 -->
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0" index="2-10" @click="handleFiling">归档</el-menu-item>
<!-- 文件 -->
<el-menu-item v-if="(isTitleType === 3 && selectedCategory.arrangeType === 1) || (isTitleType === 3 && activeIndex === 1)" index="2-11" @click="handleReturn">退回预归档库</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="isTitleType === 3 && activeIndex === 1 && selectedCategory.arrangeType !== 1" class="collect-submenu-group submenu-tree">
<template slot="title">组卷</template>
<el-menu-item index="2-12" @click="handleQuickPaper">快速组卷</el-menu-item>
<el-menu-item index="2-13" @click="handlePaper">手工组卷</el-menu-item>
</el-menu-item-group>
</el-submenu>
<el-submenu index="3">
<template slot="title">
<i class="iconfont icon-gengduo" />
<span>更多</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 6" index="3-1" @click="handleExport">导出</el-menu-item>
<el-menu-item v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" index="3-2" @click="handlePrint">打印</el-menu-item>
<el-menu-item v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" index="3-3" @click="handleFourTest">四性检测</el-menu-item>
<el-menu-item v-if="isTitleType === 6" index="3-4" @click="handleOriginalDownload">下载</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" class="collect-submenu-group submenu-tree">
<template slot="title">电子文件目录</template>
<el-menu-item index="3-5" @click="handleCatalogDownload">目录下载</el-menu-item>
<el-menu-item index="3-6" @click="fileUpload(2)">目录上传</el-menu-item>
</el-menu-item-group>
</el-submenu>
</el-menu>
</div>
<div v-if="isRecycle && (isTitleType === 2 || (isTitleType === 3 && selectedCategory.arrangeType !== 3))" class="collect-menu">
<el-button class="filter-item" size="mini" type="success" @click="toRecover"><i class="iconfont icon-huifu" />恢复</el-button>
<el-button class="filter-item" size="mini" type="success" @click="toCompletelyDelete"><i class="iconfont icon-shanchu" />彻底删除</el-button>
</div>
<div>
<div class="collect-header">
<h4 :class="classType">{{ collectTitle }} </h4>
<!-- :class="[!(isRecycle && (isTitleType === 2 || (isTitleType === 3 && selectedCategory.arrangeType !== 3))) ? 'head-search is-recycle':'head-search']" -->
<div class="collect-filter">
<treeselect
v-if="selectedCategory.arrangeType === 3 && isTitleType !== 4 && isTitleType !== 6 && activeIndex !== 1"
v-model="query.projectClass"
:options="projectOptions"
style="width: 180px;"
flat
:multiple="false"
:normalizer="normalizerProject"
placeholder="请选择"
/>
<treeselect
v-if="isTitleType !== 6"
v-model="query.classify"
:options="classifyOptions"
style="width: 180px;"
flat
:multiple="false"
:normalizer="normalizer"
placeholder="请选择档案分类"
/>
</div>
<div v-if="isTitleType !== 6" class="head-search">
<!-- 搜索 -->
<el-input v-model="query.search" clearable size="small" :placeholder="placeholderType" prefix-icon="el-icon-search" style="width: 200px;" class="filter-item" />
<el-button class="filter-item filter-search" size="mini" type="success" icon="el-icon-search" @click="handleSearch">搜索</el-button>
<el-button class="filter-item filter-refresh" size="mini" type="warning" icon="el-icon-refresh-left">重置</el-button>
</div>
<div v-if="!isRecycle" class="collect-menu">
<el-menu
:default-active="activeMenuIndex"
mode="horizontal"
@select="handleSelect"
>
<el-submenu index="1">
<template slot="title">
<i class="iconfont icon-changgui" />
<span>常规</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 6" index="1-1" @click="handleForm('add')">新增</el-menu-item>
<el-menu-item v-if="isTitleType !== 6" index="1-2" @click="handleForm('edit')">编辑</el-menu-item>
<el-menu-item v-if="isTitleType !== 4" index="1-3" @click="toDelete">删除</el-menu-item>
<el-menu-item v-if="isTitleType === 4" index="1-4" @click="toMove">移出</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="(isTitleType === 3 && selectedCategory.arrangeType === 1) || isTitleType === 4 || isTitleType === 6 || (isTitleType === 3 && activeIndex === 1)" class="collect-submenu-group submenu-tree">
<template slot="title">原文上传</template>
<el-menu-item index="1-5" @click="fileUpload(0)">普通上传</el-menu-item>
<el-menu-item index="1-6" @click="fileUpload(1)">大文件上传</el-menu-item>
</el-menu-item-group>
</el-submenu>
<el-submenu v-if="isTitleType !== 6" index="2">
<template slot="title">
<i class="iconfont icon-zhengli" />
<span>整理</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 2" index="2-1" @click="handleBlukImport">批量导入</el-menu-item>
<!-- 项目 / 案卷 / 卷内 / 文件-->
<el-menu-item v-if="activeIndex !== 1 || (isTitleType === 3 && selectedCategory.arrangeType === 1 && activeIndex === 1)" index="2-2" @click="handleBlukEditing">批量修改</el-menu-item>
<el-menu-item v-if="(isTitleType === 3 && selectedCategory.arrangeType === 2) && activeIndex === 0" index="2-3" @click="handleAdjustment('anjuan')">案卷顺序调整</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1 " index="2-12" @click="handleJnSeqAdjustment">卷内顺序调整</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && selectedCategory.arrangeType === 1" index="2-3" @click="handleAdjustment('file')">文件顺序调整</el-menu-item>
<el-menu-item v-if="isTitleType !== 2 && !(isTitleType === 3 && (selectedCategory.arrangeType === 1|| selectedCategory.arrangeType === 2) && activeIndex === 1)" index="2-4" @click="handleFileNumberUpdate">档号更新</el-menu-item>
<!-- 案卷 -->
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1 " index="2-5" @click="handleFileNumberUpdate">卷内档号更新</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1" index="2-6" @click="handleUncoil">拆卷</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0 && selectedCategory.arrangeType !== 1" index="2-7" @click="handleCombineFile">合卷</el-menu-item>
<el-menu-item v-if="isTitleType === 3 && selectedCategory.arrangeType !== 1" index="2-8" @click="handleInsertFile">插件</el-menu-item>
<!-- 案卷 / 卷内 / 文件 -->
<el-menu-item v-if="isTitleType !== 2" index="2-9" @click="handleCollectMoveFile">移动</el-menu-item>
<!-- 案卷 -->
<el-menu-item v-if="isTitleType === 3 && activeIndex === 0" index="2-10" @click="handleFiling">归档</el-menu-item>
<!-- 文件 -->
<el-menu-item v-if="(isTitleType === 3 && selectedCategory.arrangeType === 1) || (isTitleType === 3 && activeIndex === 1)" index="2-11" @click="handleReturn">退回预归档库</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="isTitleType === 3 && activeIndex === 1 && selectedCategory.arrangeType !== 1" class="collect-submenu-group submenu-tree">
<template slot="title">组卷</template>
<el-menu-item index="2-12" @click="handleQuickPaper">快速组卷</el-menu-item>
<el-menu-item index="2-13" @click="handlePaper">手工组卷</el-menu-item>
</el-menu-item-group>
</el-submenu>
<el-submenu index="3">
<template slot="title">
<i class="iconfont icon-gengduo" />
<span>更多</span>
</template>
<el-menu-item-group class="collect-submenu-group">
<el-menu-item v-if="isTitleType !== 6" index="3-1" @click="handleExport">导出</el-menu-item>
<el-menu-item v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" index="3-2" @click="handlePrint">打印</el-menu-item>
<el-menu-item v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" index="3-3" @click="handleFourTest">四性检测</el-menu-item>
<el-menu-item v-if="isTitleType === 6" index="3-4" @click="handleOriginalDownload">下载</el-menu-item>
</el-menu-item-group>
<el-menu-item-group v-if="!(isTitleType === 3 && (selectedCategory.arrangeType === 3 || selectedCategory.arrangeType === 2) && activeIndex === 1) && (isTitleType !== 2 && isTitleType !== 6)" class="collect-submenu-group submenu-tree">
<template slot="title">电子文件目录</template>
<el-menu-item index="3-5" @click="handleCatalogDownload">目录下载</el-menu-item>
<el-menu-item index="3-6" @click="fileUpload(2)">目录上传</el-menu-item>
</el-menu-item-group>
</el-submenu>
</el-menu>
</div>
<!--新增 / 编辑 表单组件-->
<el-dialog class="preview-dialog" :modal-append-to-body="false" :close-on-click-modal="false" append-to-body :before-close="handleClose" :visible="formVisible" :title="formTitle">
<span class="dialog-right-top" />
<span class="dialog-left-bottom" />
<div class="setting-dialog">
<!-- form -->
<!-- @emitTableList="getTableList" -->
<PreviewForm v-if="formPreviewData.length" ref="previewForm" :is-has-code="true" :is-disabled="false" :form-preview-data.sync="formPreviewData" :selected-category="selectedCategory" :parents-id="parentsId" :arc-id="arcId" :is-des-form-type="isDesFormType" />
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="handlerArchivesSubmit">保存</el-button>
</div>
<div v-if="isRecycle && (isTitleType === 2 || (isTitleType === 3 && selectedCategory.arrangeType !== 3))" class="collect-menu">
<el-button class="filter-item" size="mini" type="success" @click="toRecover"><i class="iconfont icon-huifu" />恢复</el-button>
<el-button class="filter-item" size="mini" type="success" @click="toCompletelyDelete"><i class="iconfont icon-shanchu" />彻底删除</el-button>
</div>
</el-dialog>
<!--删除对话框组件-->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="deleteVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此删除将把会所选条目与其子集放入回收站</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="deleteVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleDelConfirm">确定</el-button>
<!--新增 / 编辑 表单组件-->
<el-dialog class="preview-dialog" :modal-append-to-body="false" :close-on-click-modal="false" append-to-body :before-close="handleClose" :visible="formVisible" :title="formTitle">
<span class="dialog-right-top" />
<span class="dialog-left-bottom" />
<div class="setting-dialog">
<!-- form -->
<!-- @emitTableList="getTableList" -->
<PreviewForm v-if="formPreviewData.length" ref="previewForm" :is-has-code="true" :is-disabled="false" :form-preview-data.sync="formPreviewData" :selected-category="selectedCategory" :parents-id="parentsId" :arc-id="arcId" :is-des-form-type="isDesFormType" />
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="handlerArchivesSubmit">保存</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!--卷内移出 组件-->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="moveVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此移出将把会所选条目返还到未整理列表</p>
<span>你是否还要继续?</span>
<!--删除对话框组件-->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="deleteVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此删除将把会所选条目与其子集放入回收站</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="deleteVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleDelConfirm">确定</el-button>
</div>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="moveVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleMoveConfirm">确定</el-button>
</el-dialog>
<!--卷内移出 组件-->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="moveVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此移出将把会所选条目返还到未整理列表</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="moveVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleMoveConfirm">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 原文上传 -->
<UploadOriginal ref="uploadOriginalRef" />
<!-- 批量导入 -->
<BlukImport ref="blukImportRef" />
<!-- 批量修改 -->
<BlukEditing ref="blukEditingRef" />
<!-- 档案调整 -->
<FileNumberAdjustment ref="fileNumberAdjustmentRef" :selected-category="selectedCategory" />
<!-- 原文上传 -->
<UploadOriginal ref="uploadOriginalRef" />
<!-- 批量导入 -->
<BlukImport ref="blukImportRef" />
<!-- 批量修改 -->
<BlukEditing ref="blukEditingRef" />
<!-- 档案调整 -->
<FileNumberAdjustment ref="fileNumberAdjustmentRef" :selected-category="selectedCategory" />
<!-- 档号更新 -->
<el-dialog class="tip-dialog" title="档号更新" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="updateVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将会自动重新生成档号</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="updateVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleUpdateConfirm">确定</el-button>
<!-- 档号更新 -->
<el-dialog class="tip-dialog" title="档号更新" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="updateVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将会自动重新生成档号</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="updateVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleUpdateConfirm">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 卷内顺序调整 -->
<FileSeqAdjustment ref="fileSeqAdjustmentRef" :selected-category="selectedCategory" />
<!-- 卷内顺序调整 -->
<FileSeqAdjustment ref="fileSeqAdjustmentRef" :selected-category="selectedCategory" />
<!-- 拆卷 -->
<el-dialog class="tip-dialog" title="拆卷" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="uncoilVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">拆卷之后对应的案卷数据将会自动删除</p>
<span>你是否还要继续?</span>
<!-- 拆卷 -->
<el-dialog class="tip-dialog" title="拆卷" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="uncoilVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">拆卷之后对应的案卷数据将会自动删除</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="uncoilVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleUncoilConfirm">确定</el-button>
</div>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="uncoilVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleUncoilConfirm">确定</el-button>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 合卷 -->
<CombineFile ref="combineFileRef" />
<!-- 插件 -->
<InsertFile ref="insertFileRef" />
<!-- 移动 -->
<CollectMoveFile ref="collectMoveFileRef" />
<!-- 合卷 -->
<CombineFile ref="combineFileRef" />
<!-- 插件 -->
<InsertFile ref="insertFileRef" />
<!-- 移动 -->
<CollectMoveFile ref="collectMoveFileRef" />
<!-- 归档 -->
<el-dialog class="tip-dialog" title="归档" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="filingVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将会把所选条目提交归档</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="filingVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleFilingConfirm">确定</el-button>
<!-- 归档 -->
<el-dialog class="tip-dialog" title="归档" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="filingVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将会把所选条目提交归档</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="filingVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleFilingConfirm">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 退回预归档库 -->
<el-dialog class="tip-dialog" title="退回预归档库" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="returnVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此移出将把会所选条目退回到预归档库</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="returnVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleReturnConfirm">确定</el-button>
<!-- 退回预归档库 -->
<el-dialog class="tip-dialog" title="退回预归档库" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="returnVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此移出将把会所选条目退回到预归档库</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="returnVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleReturnConfirm">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 导出 -->
<el-dialog class="tip-dialog" title="导出" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="exportVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将导出所选数据</p>
<span>你是否还要继续?</span>
<!-- 导出 -->
<el-dialog class="tip-dialog" title="导出" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="exportVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将导出所选数据</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="downloadVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleExportConfirm">确定</el-button>
</div>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="downloadVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleExportConfirm">确定</el-button>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 打印 -->
<Print ref="printRef" />
<!-- 四性检测 -->
<FourTest ref="fourTestRef" />
<!-- 打印 -->
<Print ref="printRef" />
<!-- 四性检测 -->
<FourTest ref="fourTestRef" />
<!-- 目录下载 -->
<el-dialog class="tip-dialog" title="目录下载" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="downloadVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将下载所选条目目录</p>
<span>你是否还要继续?</span>
<!-- 目录下载 -->
<el-dialog class="tip-dialog" title="目录下载" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="downloadVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此操作将下载所选条目目录</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="downloadVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleCatDownloadConfirm">确定</el-button>
</div>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="downloadVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleCatDownloadConfirm">确定</el-button>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 快速组卷 -->
<QuickPaper ref="quickPaperRef" />
<!-- 快速组卷 -->
<QuickPaper ref="quickPaperRef" />
<!-- 回收站 - 恢复 -->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="recoverVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此恢复将会把所选条目及其子集一并恢复</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="recoverVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleRecover">确定</el-button>
<!-- 回收站 - 恢复 -->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="recoverVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此恢复将会把所选条目及其子集一并恢复</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="recoverVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleRecover">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
<!-- 回收站 - 彻底删除 -->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="completelyDeleteVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此删除将把会所选条目与其子集彻底删除</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="completelyDeleteVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleCompletelyDelete">确定</el-button>
<!-- 回收站 - 彻底删除 -->
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="completelyDeleteVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">此删除将把会所选条目与其子集彻底删除</p>
<span>你是否还要继续?</span>
</div>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="completelyDeleteVisible = false">取消</el-button>
<el-button type="primary" @click.native="handleCompletelyDelete">确定</el-button>
</div>
</div>
</div>
</el-dialog>
</el-dialog>
</div>
<div style="height: 30px; line-height: 30px; padding: 0 20px;"> <span v-if="(isTitleType !== 2 && selectedCategory.arrangeType === 3 ) || ((isTitleType === 4 || isTitleType === 6) && selectedCategory.arrangeType === 2) || (isTitleType === 6 && selectedCategory.arrangeType === 1)">{{ test }}</span></div>
</div>
</template>
<script>
import { collectionLibraryCrud } from '../mixins/index'
import { FetchInitCategoryInputFieldByPid } from '@/api/system/category/category'
import { FetchArchivesClassTree } from '@/api/system/archivesClass'
import { FetchDictionaryTree } from '@/api/system/dict'
import Treeselect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
// import { LOAD_CHILDREN_OPTIONS } from '@riophae/vue-treeselect'
import PreviewForm from '@/views/components/category/PreviewForm'
import UploadOriginal from './uploadOriginal/index'
import BlukImport from './bulkImport/index'
@ -287,9 +317,10 @@ import FourTest from './fourTest/index'
import QuickPaper from './quickPaper/index'
// import { exportFile } from '@/utils/index'
import { mapGetters } from 'vuex'
export default {
name: 'CollectHeader',
components: { PreviewForm, UploadOriginal, BlukImport, BlukEditing, FileNumberAdjustment, FileSeqAdjustment, CombineFile, InsertFile, CollectMoveFile, Print, FourTest, QuickPaper },
components: { Treeselect, PreviewForm, UploadOriginal, BlukImport, BlukEditing, FileNumberAdjustment, FileSeqAdjustment, CombineFile, InsertFile, CollectMoveFile, Print, FourTest, QuickPaper },
mixins: [collectionLibraryCrud],
props: {
selectedCategory: {
@ -335,6 +366,12 @@ export default {
formVisible: false,
formTitle: '项目',
formPreviewData: [], // data
query: {
projectClass: null,
classify: null
},
projectOptions: [],
classifyOptions: [],
deleteVisible: false,
moveVisible: false,
updateVisible: false,
@ -346,7 +383,7 @@ export default {
recoverVisible: false,
completelyDeleteVisible: false,
parentsId: null, // id
isDesFormType: null //
isDesFormType: 'arcives' //
}
},
computed: {
@ -394,11 +431,92 @@ export default {
return '输入项目名称或编号'
}
},
watch: {
selectedCategory: function(newValue, oldValue) {
if (newValue && newValue.id) {
this.getInitArchivesClass()
this.getDictsList()
}
}
},
created() {
},
mounted() {
this.getInitArchivesClass()
this.getDictsList()
},
methods: {
getInitArchivesClass() {
this.classifyOptions = []
const params = {
'categoryId': this.selectedCategory.id
}
FetchArchivesClassTree(params).then((res) => {
this.classifyOptions = JSON.parse(JSON.stringify(res))
}).catch(err => {
console.log(err)
})
},
normalizer(node) {
if (node.childArchivesClass === null) {
delete node.childArchivesClass
}
return {
id: node.code,
label: node.name,
children: node.childArchivesClass
}
},
getDictsList() {
this.projectOptions = []
FetchDictionaryTree().then((res) => {
console.log(res)
const filterCodes = ['project_class']
let filteredItems = JSON.parse(JSON.stringify(res)).filter(item => filterCodes.includes(item.dictionaryCode))
filteredItems = this.addLevelToDictionaryList(filteredItems, 1)
if (this.selectedCategory.arrangeType === 3 && this.isTitleType === 3) {
this.projectOptions = filteredItems
console.log(this.projectOptions)
} else {
this.projectOptions = this.filterData(filteredItems, filteredItems[0].id)
}
}).catch(err => {
console.log(err)
})
},
//
filterData(data, targetId) {
return data.filter(item => {
if (item.id === targetId || item.dictionaryParents === targetId) {
if (item.childDictionarys && item.childDictionarys.length > 0) {
item.childDictionarys = this.filterData(item.childDictionarys, targetId)
}
return true
}
return false
})
},
// level 便
addLevelToDictionaryList(dictionaryList, level) {
dictionaryList.forEach(dictionary => {
dictionary.level = level
if (dictionary.childDictionarys) {
dictionary.childDictionarys = this.addLevelToDictionaryList(dictionary.childDictionarys, level + 1)
}
})
return dictionaryList
},
normalizerProject(node) {
if (node.childDictionarys && !node.childDictionarys.length) {
delete node.childDictionarys
}
return {
id: node.dictionaryCode,
label: node.dictionaryName,
children: node.childDictionarys,
isDisabled: this.isTitleType === 3 ? node.level !== 3 : node.level === 1
}
},
handleSelect(key, keyPath) {
console.log(key, keyPath)
},
@ -526,28 +644,26 @@ export default {
}
this.$refs.blukEditingRef.bulkEditingVisible = true
},
//
handleAdjustment() {
this.$refs.fileNumberAdjustmentRef.isType = this.isTitleType
if (this.selections.length === 0) {
this.$refs.fileNumberAdjustmentRef.adjustmentTipVisible = true
} else {
this.$refs.fileNumberAdjustmentRef.adjustmentVisible = true
}
},
//
handleFileNumberUpdate() {
if (this.selections.length === 0) {
this.$message('您还未勾选需要操作的条目,请先确认!')
// /
handleAdjustment(type) {
if (this.selections.length < 2) {
this.$message('请选择多个案卷后进行操作!')
return false
}
this.updateVisible = true
},
handleUpdateConfirm() {
this.updateVisible = false
if (type === 'anjuan') {
this.$refs.fileNumberAdjustmentRef.titleAdjustment = '案卷顺序调整'
} else {
this.$refs.fileNumberAdjustmentRef.titleAdjustment = '文件顺序调整'
}
this.$refs.fileNumberAdjustmentRef.adjustmentVisible = true
// if (this.selections.length === 0) {
// this.$refs.fileNumberAdjustmentRef.adjustmentTipVisible = true
// } else {
// this.$refs.fileNumberAdjustmentRef.adjustmentVisible = true
// }
},
//
handleFileSeqAdjustment() {
handleJnSeqAdjustment() {
if (this.selections.length === 0) {
this.$message('您还未勾选需要操作的条目,请先确认!')
return false
@ -558,6 +674,17 @@ export default {
}
this.$refs.fileSeqAdjustmentRef.adjustmentVisible = true
},
//
handleFileNumberUpdate() {
if (this.selections.length === 0) {
this.$message('您还未勾选需要操作的条目,请先确认!')
return false
}
this.updateVisible = true
},
handleUpdateConfirm() {
this.updateVisible = false
},
//
handleUncoil() {
if (this.selections.length === 0) {
@ -702,4 +829,18 @@ export default {
</script>
<style lang='scss' scoped>
.collect-filter{
display: flex;
// width: 360px;
height: 32px;
justify-content: flex-end;
::v-deep .vue-treeselect{
font-size: 12px;
margin-right: 10px !important;
.vue-treeselect__control{
height: 33px !important;
}
}
}
</style>

123
src/views/collectReorganizi/collectionLibrary/module/fileNumberAdjustment/index.vue

@ -1,7 +1,7 @@
<template>
<!-- 档号调整 -->
<!-- 文件顺序调整 -->
<div>
<el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="adjustmentTipVisible">
<!-- <el-dialog class="tip-dialog" title="提示" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="adjustmentTipVisible">
<div class="setting-dialog">
<div class="tip-content">
<p class="tipMsg">您未勾选条目否则直接选择所有条目</p>
@ -12,10 +12,10 @@
<el-button type="primary" @click.native="handleComfireAdjustment">确定</el-button>
</div>
</div>
</el-dialog>
</el-dialog> -->
<el-dialog class="adjust-dialog" title="档案调整" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="adjustmentVisible">
<el-form ref="form" :model="form" :rules="rules" label-width="110px">
<el-dialog class="adjust-dialog" :title="titleAdjustment" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :visible.sync="adjustmentVisible">
<!-- <el-form ref="form" :model="form" :rules="rules" label-width="110px">
<div style="display: flex; justify-content: flex-start;">
<el-form-item label="需要调整字段" prop="adjustFields">
<el-select v-model="form.adjustFields" placeholder="请选择" style="width: 225px;">
@ -28,7 +28,6 @@
</el-select>
</el-form-item>
<el-form-item label="起始值" prop="initialValue">
<!-- <el-input v-model="form.initialValue" style="width: 225px;" /> -->
<el-input-number
v-model.number="form.initialValue"
:min="0"
@ -51,7 +50,8 @@
</el-form-item>
<el-button class="adjust-submit" type="primary">调整</el-button>
</div>
</el-form>
</el-form> -->
<i class="drag-tip">提示请通过拖动鼠标来调整当前顺序</i>
<el-table :data="tableData" style="width: 100%">
<el-table-column prop="number" label="题名" width="120" />
<el-table-column prop="operator" label="档号" width="120" />
@ -90,44 +90,45 @@ export default {
},
data() {
return {
adjustmentTipVisible: false,
// adjustmentTipVisible: false,
adjustmentVisible: false,
form: {
adjustFields: '',
initialValue: undefined,
codeFields: '档号'
},
fieldsOptions: [
],
codeFieldsOptions: [
{
value: '1',
label: '档号'
}
],
rules: {
adjustFields: [
{ required: true, message: '请输入需调整的字段', trigger: 'change' }
],
initialValue: [
{ required: true, message: '请输入起始值', trigger: 'blur' }
]
},
// form: {
// adjustFields: '',
// initialValue: undefined,
// codeFields: ''
// },
// fieldsOptions: [
// ],
// codeFieldsOptions: [
// {
// value: '1',
// label: ''
// }
// ],
// rules: {
// adjustFields: [
// { required: true, message: '', trigger: 'change' }
// ],
// initialValue: [
// { required: true, message: '', trigger: 'blur' }
// ]
// },
titleAdjustment: '',
tableData: [],
page: {
page: 1,
size: 10,
total: 0
},
isType: 2
}
// isType: 2
}
},
watch: {
selectedCategory: function(newValue, oldValue) {
this.changeOptions(this.isType)
// this.changeOptions(this.isType)
},
isType(newVal) {
this.changeOptions(newVal)
// this.changeOptions(newVal)
}
},
created() {
@ -135,34 +136,34 @@ export default {
mounted() {
},
methods: {
changeOptions(value) {
if (value === 3) {
if (this.selectedCategory.isType === 5) {
this.fieldsOptions = [{
value: '目录号',
label: '目录号'
},
{
value: '件号',
label: '件号'
}]
} else {
this.fieldsOptions = [{
value: '案卷号',
label: '案卷号'
}]
}
} else if (value === 4) {
this.fieldsOptions = [{
value: '卷内顺序号',
label: '卷内顺序号'
},
{
value: '目录号',
label: '目录号'
}]
}
},
// changeOptions(value) {
// if (value === 3) {
// if (this.selectedCategory.isType === 5) {
// this.fieldsOptions = [{
// value: '',
// label: ''
// },
// {
// value: '',
// label: ''
// }]
// } else {
// this.fieldsOptions = [{
// value: '',
// label: ''
// }]
// }
// } else if (value === 4) {
// this.fieldsOptions = [{
// value: '',
// label: ''
// },
// {
// value: '',
// label: ''
// }]
// }
// },
handleComfireAdjustment() {
this.adjustmentTipVisible = false
this.adjustmentVisible = true

9
src/views/collectReorganizi/collectionLibrary/module/fileSeqAdjustment/index.vue

@ -17,7 +17,6 @@
<el-button type="primary" @click.native="handleSort">确定</el-button>
</div>
</div>
</el-dialog>
</div>
</template>
@ -140,12 +139,4 @@ export default {
flex: 1;
}
}
.drag-tip {
display: block;
padding-left: 20px;
padding-bottom: 10px;
font-style: normal;
font-weight: bold;
font-size: 12px;
}
</style>

7
src/views/collectReorganizi/collectionLibrary/project/index.vue

@ -59,6 +59,9 @@ import { collectionLibraryCrud } from '../mixins/index'
import { header, form } from '@crud/crud'
import CollectHeader from '../module/collectHeader.vue'
import ArchivesInfo from '../module/archivesInfo/index'
import tableData from '@/views/archivesManage/managementLibrary/anjuan/table.json'
import jsonData from '@/views/archivesManage/managementLibrary/anjuan/data.json'
export default {
name: 'Project',
components: { CollectHeader, ArchivesInfo },
@ -99,6 +102,8 @@ export default {
}
},
created() {
this.tableDisplayFields = tableData.data
this.projectData = jsonData.data.list.content
},
mounted() {
},
@ -147,7 +152,7 @@ export default {
clearTimeout(this.timer)
}
this.timer = setTimeout(() => {
this.openAnjuan(row.item_no)
this.openAnjuan('所属项目' + row.archive_no)
}, 300)
this.selections = this.crud.selections
},

19
src/views/components/BindingTagDlg.vue

@ -1,6 +1,6 @@
<template>
<div>
<el-dialog ref="bindingTagDialog" class="bindingDialog" :title="bindingTitle" :visible.sync="bindingVisible" :close-on-click-modal="false" :before-close="handleClose" @opened="opened">
<el-dialog ref="bindingTagDialog" class="bindingDialog" :title="bindingTitle" :visible.sync="bindingVisible" :close-on-click-modal="false" :modal-append-to-body="false" append-to-body :before-close="handleClose" @opened="opened">
<span class="dialog-right-top" />
<span class="dialog-left-bottom" />
<div class="setting-dialog">
@ -10,7 +10,7 @@
<el-input v-model="tidCode" placeholder="请输入内容" />
</div>
<div v-else class="binding-flow">
<div class="step-item">
<div class="step-item" :class="{ 'step-active': 1 <= step, 'step-loading': 2 === step }">
<!-- step-active 完成 step-loading 进行种 -->
<span class="step-left-num" :class="{ 'step-active': 1 <= step, 'step-loading': 1 === step }">1</span>
<div class="step-right-cont">
@ -20,11 +20,8 @@
<!-- err: 当前电脑未绑定读写器请到档案设备里进行绑定 -->
</div>
</div>
<div class="step-item">
<div class="step-item" :class="{ 'step-active': 2 <= step, 'step-loading': 3 === step }">
<span class="step-left-num" :class="{ 'step-active': 2 <= step, 'step-loading': 2 === step }">2</span>
<div class="pulse1" />
<div class="pulse2" />
<div class="pulse3" />
<div class="step-right-cont">
<p class="step-title">第二步<span>放入标签</span></p>
<p class="step-tip" :class="{ 'tip-error': 2 === errorStep, 'tip-active': 2 <= step }">{{ step2Message }}</p>
@ -33,7 +30,7 @@
<!-- err: 未读取到标签请重新放入 -->
</div>
</div>
<div class="step-item">
<div class="step-item" :class="{ 'step-active': 3 <= step, 'step-loading': 4 === step }">
<span class="step-left-num" :class="{ 'step-active': 3 <= step, 'step-loading': 3 === step }">3</span>
<div class="step-right-cont">
<p class="step-title">第三步<span>读取标签</span></p>
@ -43,7 +40,7 @@
<!-- err: 当前标签存在多个请取出多余的标签只保留一张 -->
</div>
</div>
<div class="step-item">
<div class="step-item" :class="{ 'step-active': 4 <= step, 'step-loading': 5 === step }">
<span class="step-left-num" :class="{ 'step-active': 4 <= step, 'step-loading': 4 === step }">4</span>
<div class="step-right-cont">
<p class="step-title">第四步<span>开始绑定</span></p>
@ -56,7 +53,7 @@
<!-- err: 绑定失败请拿走当前标签 -->
</div>
</div>
<div class="step-item">
<div class="step-item" :class="{ 'step-active': 5 === step }">
<span class="step-left-num" :class="{ 'step-active': 5 === step }">5</span>
<div class="step-right-cont">
<p class="step-title">第五步<span>绑定成功</span></p>
@ -117,7 +114,7 @@ export default {
bindingVisible: false, //
tidCode: '',
coverBindingVisible: false,
step: 1,
step: 3,
errorStep: 0,
step1Message: '连接中',
step2Message: '请放入标签',
@ -282,7 +279,7 @@ export default {
reject('获取mac地址失败')
} else {
const dev = await RFID.getDeviceIdByMac(mac)
if (!dev || dev === {} || !dev.deviceId) {
if (!dev || dev === JSON.stringify({}) || !dev.deviceId) {
this.step1Message = '当前电脑未绑定读写器,请到档案设备里进行绑定'
this.errorStep = 1
reject('当前电脑未绑定读写器,请到档案设备里进行绑定')

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

@ -31,7 +31,7 @@
:rows="item.isInputClass === 'textarea' ? 3 : ''"
:class="{'input-popover':(item.isInputClass === 'popover')}"
:style="{ width: item.editLength+'px'}"
:disabled="isDisabled"
:disabled="isDisabled || (item.fieldName === 'archival_category_code')"
:validate-event="!isDisabled"
@keyup.enter.native="isRepeatHandle(item)"
@input="autoAddZero(item.isFilling, item.fieldName, addOrUpdateForm[item.fieldName], item.fillingDigit)"
@ -257,7 +257,7 @@ export default {
delete node.childArchivesClass
}
return {
id: node.id,
id: node.name,
label: node.name,
children: node.childArchivesClass
}
@ -267,23 +267,11 @@ export default {
delete node.childMenus
}
return {
id: node.id,
id: node.fondsName,
label: node.fondsName,
children: node.childMenus
}
},
//
// getNode(tree, dicName) {
// for (let i = 0; i < tree.length; i++) {
// if (tree[i].dicName === dicName) {
// return tree[i]
// } else {
// if (tree[i].childMenus) {
// return this.getNode(tree[i].childMenus, dicName)
// }
// }
// }
// },
// vue-treeSelectunknown
getAutoNameUnknown(name) {
if (name.lastIndexOf('unknown') > -1) {
@ -307,6 +295,34 @@ export default {
})
return data
},
getFondsNode(list, fondsName) {
let data;
(list || []).map(item => {
if (item.fondsName === fondsName) {
data = [item]
} else {
const child = this.getFondsNode(item.childMenus, fondsName)
if (child) {
data = child
}
}
})
return data
},
getClassfiyNode(list, name) {
let data;
(list || []).map(item => {
if (item.name === name) {
data = [item]
} else {
const child = this.getClassfiyNode(item.childArchivesClass, name)
if (child) {
data = child
}
}
})
return data
},
//
handleAuto() {
let string = ''
@ -317,33 +333,58 @@ export default {
} else {
const fieldInfo = this.formPreviewData.find(element => element.fieldName === val.fieldName)
if (fieldInfo.isInputClass === 'select' || fieldInfo.isInputClass === 'popover') {
const params = {
'pid': fieldInfo.dictionaryId.id
if (fieldInfo.mateData === 3) {
await FetchSonDictionaryList({ 'pid': fieldInfo.dictionaryId.id }).then(res => {
const option = this.getNode(res, this.addOrUpdateForm[val.fieldName])
if (option) {
const obj = {}
obj.name = val.fieldName
obj.val = option[0].dictionaryCode + val.connector
obj.sequence = val.sequence
getAutoFiledVal.push(obj)
}
})
}
if (fieldInfo.mateData === 1) {
await FetchFondsAll().then(res => {
const option = this.getFondsNode(res, this.addOrUpdateForm[val.fieldName])
if (option) {
const obj = {}
obj.name = val.fieldName
obj.val = option[0].fondsNo + val.connector
obj.sequence = val.sequence
getAutoFiledVal.push(obj)
}
})
}
await FetchSonDictionaryList(params).then(res => {
const option = this.getNode(res, this.addOrUpdateForm[val.fieldName])
if (option) {
const obj = {}
obj.name = val.fieldName
obj.val = option[0].dictionaryCode + val.connector
obj.sequence = val.sequence
// string += '' + option[0].dicCode + val.connector
getAutoFiledVal.push(obj)
if (fieldInfo.mateData === 2) {
let categoryId
if (this.isDesFormType !== 'mergeFile' && this.isDesFormType !== 'arcives') {
categoryId = this.selectedCategory.pid
} else {
categoryId = this.selectedCategory.id
}
})
await FetchArchivesClassTree({ 'categoryId': categoryId }).then(res => {
const option = this.getClassfiyNode(res, this.addOrUpdateForm[val.fieldName])
if (option) {
const obj = {}
obj.name = val.name
obj.val = option[0].code + val.connector
obj.sequence = val.sequence
getAutoFiledVal.push(obj)
}
})
}
} else {
const obj = {}
obj.name = val.fieldName
obj.val = this.addOrUpdateForm[val.fieldName] + val.connector
obj.sequence = val.sequence
// string += '' + this.addOrUpdateForm[val.fieldName] + val.connector
getAutoFiledVal.push(obj)
}
}
//
getAutoFiledVal.sort(this.compare('sequence'))
string = getAutoFiledVal.map((item) => item.val).join('')
this.formPreviewData.map(item => {
if (item.isAutomatic) {
this.$set(this.addOrUpdateForm, item.fieldName, string)
@ -363,7 +404,7 @@ export default {
FetchNoFormatField(categoryId) {
getNoFormatField({ categoryId: categoryId }).then(res => {
this.autoMatic = res
// this.handleAuto()
this.handleAuto()
})
},
//
@ -495,6 +536,7 @@ export default {
if (this.isDesFormType !== 'prearchiveLibrary' && this.isDesFormType !== 'mergeFile') {
if (!item.isAutomatic) {
console.log('this.autoMatic', this.autoMatic)
const index = this.autoMatic.findIndex(i => item.fieldName === i.fieldName)
if (index !== -1) {
this.handleAuto()
@ -510,7 +552,13 @@ export default {
},
// tree - select
selectTree(val) {
this.addOrUpdateForm[this.treeCurrentFiled.fieldName] = val.dictionaryName
if (val.fondsNo) {
this.addOrUpdateForm[this.treeCurrentFiled.fieldName] = val.fondsName
} else if (val.code) {
this.addOrUpdateForm[this.treeCurrentFiled.fieldName] = val.name
} else {
this.addOrUpdateForm[this.treeCurrentFiled.fieldName] = val.dictionaryName
}
console.log('this.treeCurrentFiled.fieldName', this.treeCurrentFiled.fieldName)
console.log('val', val)
console.log('val.dictionaryName', val.dictionaryName)
@ -537,6 +585,7 @@ export default {
}
if (this.isDesFormType !== 'prearchiveLibrary' && this.isDesFormType !== 'mergeFile') {
const index = this.autoMatic.findIndex(i => this.treeCurrentFiled.fieldName === i.fieldName)
console.log('index', index)
if (index !== -1) {
this.handleAuto()
}
@ -563,9 +612,6 @@ export default {
this.popoverVisible = false
this.popoverClassifyVisible = false
this.popoverFondsVisible = false
// this.popoverTableData = []
// this.popoverTableDataClassify = []
// this.popoverTableDataFonds = []
if (this.isDesFormType !== 'prearchiveLibrary' && this.isDesFormType !== 'mergeFile') {
const index = this.autoMatic.findIndex(i => this.currentFieldName === i.fieldName)
@ -585,10 +631,31 @@ export default {
this.addOrUpdateForm[fieldName] = value.toString().padStart(fillingDigit, '0').slice(-1 * fillingDigit)
}
},
// pid
findNodeById(node, targetId) {
if (node.id === targetId) {
return node
}
if (node.children && node.children.length > 0) {
for (const child of node.children) {
const result = this.findNodeById(child, targetId)
if (result) {
return result
}
}
}
return null
},
//
editFormRow() {
this.rules = {}
console.log(this.formPreviewData)
// if (this.isDesFormType !== 'mergeFile' && this.isDesFormType !== 'arcives') {
// targetId = this.selectedCategory.pid
// } else {
// targetId = this.selectedCategory.id
// }
this.formPreviewData.map(item => {
if (item.isInputClass === 'select') {
this.$set(item, 'options', [])
@ -602,6 +669,21 @@ export default {
this.$set(this.addOrUpdateForm, item.fieldName, null) // unkonwn
}
}
if (item.fieldName === 'archival_category_code') {
let targetNode
if (this.isDesFormType !== 'mergeFile' && this.isDesFormType !== 'arcives') {
const targetId = this.selectedCategory.pid
targetNode = this.findNodeById(this.crud.data[0], targetId)
} else {
targetNode = this.selectedCategory
}
if (targetNode) {
this.$set(this.addOrUpdateForm, item.fieldName, targetNode.code)
} else {
this.$set(this.addOrUpdateForm, item.fieldName, '')
}
}
this.$set(this.rules, item.fieldName, [
{
required: !!item.isRequired,
@ -870,6 +952,10 @@ export default {
::v-deep .el-form-item--small .el-form-item__content {
line-height: 30px;
}
::v-deep .el-input.is-disabled .el-input__inner{
background-color: #f5f7fa;
color: #c0c4cc;
}
}
.preview-form-bottom{
padding: 20px 20px 0 20px;

2
src/views/components/category/SettingForm.vue

@ -169,7 +169,7 @@ export default {
const rules = {
fieldCnName: [
{ required: true, message: '请输入中文名称', trigger: 'blur' },
{ max: 7, message: '最大长度7个字符', trigger: 'blur' }
{ max: 10, message: '最大长度10个字符', trigger: 'blur' }
],
fieldName: [
{ required: true, message: '请选择字段标识', trigger: 'blur' },

64
src/views/system/archivesCategory/publicScreening/index.vue

@ -16,7 +16,7 @@
<el-form ref="form" inline :model="form" :rules="rules" size="small" label-width="90px">
<el-form-item label="筛选项" prop="fieldId">
<el-select v-model="form.fieldId" style="width: 580px;">
<el-option v-for="item in selectOptions" :key="item.id" :label="item.name" :value="item.id" />
<el-option v-for="item in selectOptions" :key="item.dictionaryId" :label="item.dictionaryName" :value="item.dictionaryId" />
</el-select>
</el-form-item>
</el-form>
@ -38,11 +38,11 @@
@selection-change="crud.selectionChangeHandler"
>
<el-table-column type="selection" width="55" />
<el-table-column :show-overflow-tooltip="true" prop="username" label="字段名称" />
<el-table-column prop="nickName" label="字段标识" />
<el-table-column prop="createTime" label="创建日期" width="200px">
<el-table-column :show-overflow-tooltip="true" prop="categoryId" label="字段名称" />
<el-table-column prop="fieldId" label="字段标识" />
<el-table-column prop="create_time" label="创建日期" width="200px">
<template slot-scope="scope">
<div>{{ scope.row.createTime | parseTime }}</div>
<div>{{ scope.row.create_time | parseTime }}</div>
</template>
</el-table-column>
</el-table>
@ -54,11 +54,12 @@
<script>
import crudFilter from '@/api/system/category/filter'
import { FetchInitArchivesClass } from '@/api/system/archivesClass'
// import { FetchInitArchivesClass } from '@/api/system/archivesClass'
import { FetchDictsList } from '@/api/system/dict'
import CRUD, { presenter, header, form } from '@crud/crud'
import pagination from '@crud/Pagination'
const defaultForm = { id: null, fieldId: null }
const defaultForm = { categoryId: null, fieldId: null }
export default {
name: 'PublicScreening',
@ -90,32 +91,23 @@ export default {
selectOptions: [],
needRefreshTree: false,
rules: {
dicName: [
{ required: true, message: '请输入字典名称', trigger: 'blur' }
],
dicCode: [
{ required: true, message: '请输入字典代码', trigger: 'blur' }
],
isTop: [
{ required: true, message: '请选择是否为顶级节点', trigger: 'change' }
],
sequence: [
{ required: true, message: '请输入序号', trigger: 'blur', type: 'number' }
fieldId: [
{ required: true, message: '请选择筛选项', trigger: 'change' }
]
}
}
},
created() {
this.getInitArchivesClass()
this.getDictsList()
},
methods: {
getInitArchivesClass() {
const params = {
'categoryId': this.selectedCategory.id
}
FetchInitArchivesClass(params).then((res) => {
getDictsList() {
FetchDictsList().then((res) => {
console.log(res)
this.selectOptions = res.content
//
const filterCodes = ['retention', 'security_class', 'doc_type', 'medium_type', 'organ_or_function']
const filteredItems = res.content.filter(item => filterCodes.includes(item.dictionaryCode))
this.selectOptions = filteredItems
}).catch(err => {
console.log(err)
})
@ -128,6 +120,7 @@ export default {
},
//
[CRUD.HOOK.beforeRefresh]() {
this.crud.query.categoryId = this.selectedCategory.id
},
[CRUD.HOOK.afterRefresh](crud) {
if (this.needRefreshTree) {
@ -135,16 +128,33 @@ export default {
this.$emit('treeRefresh', crud.data)
}
},
//
[CRUD.HOOK.afterValidateCU](crud) {
crud.form.categoryId = this.selectedCategory.id
console.log(crud.form)
return true
},
toDelete(datas) {
console.log(this.crud)
this.crud.delAllLoading = true
this.$confirm('此操作将删除当前所选字段' + '<span>你是否还要继续?</span>', '提示', {
confirmButtonText: '继续',
cancelButtonText: '取消',
type: 'warning',
dangerouslyUseHTMLString: true
}).then(() => {
this.crud.delAllLoading = true
this.crud.doDelete(datas)
const ids = []
datas.forEach(val => {
ids.push(val.id)
})
crudFilter.del(ids).then(() => {
this.crud.notify('删除成功', CRUD.NOTIFICATION_TYPE.SUCCESS)
this.crud.delAllLoading = false
this.crud.refresh()
}).catch(err => {
this.crud.delAllLoading = false
console.log(err)
})
}).catch(() => {
})
}

Loading…
Cancel
Save