Browse Source

档案管理bug修复

master
xuhuajiao 3 years ago
parent
commit
39da013769
  1. 52
      src/views/archivesManage/archivesList/index.vue
  2. 131
      src/views/archivesManage/archivesList/mixins/archives.js
  3. 2
      src/views/components/echarts/lendAcross.vue

52
src/views/archivesManage/archivesList/index.vue

@ -39,7 +39,7 @@
/>
<!-- 案卷 -->
<archivesAnjuan
v-if="selectedCategory.isType === 2 || selectedCategory.isType === 3 || selectedCategory.isType === 5"
v-if="( selectedCategory.isType === 2 && selectedCategory.children.length !==0 ) || selectedCategory.isType === 3 || selectedCategory.isType === 5"
ref="anjuan"
:selected-category="selectedCategory"
:is-project="isProject"
@ -52,7 +52,7 @@
/>
<!-- 卷内 -->
<archivesJuannei
v-if="selectedCategory.isType === 2 || selectedCategory.isType === 3 || selectedCategory.isType === 4"
v-if="( selectedCategory.isType === 2 && selectedCategory.children.length !==0 && this.selectedCategory.children[0].children.length !==0 ) || ( selectedCategory.isType === 3 && selectedCategory.children.length !==0 ) || selectedCategory.isType === 4"
ref="file"
:is-anjuan="isAnjuan"
:anjuan-selection="anjuanSelection"
@ -251,7 +251,9 @@ export default {
this.$nextTick(() => {
if (this.$refs.anjuan) {
this.$refs.anjuan.anjuanData = []
this.$refs.file.junneiData = []
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
}
})
} else if (selectData && selectData.length === 1) {
@ -259,7 +261,9 @@ export default {
this.$nextTick(() => {
if (this.$refs.anjuan) {
this.$refs.anjuan.getTableList()
this.$refs.file.junneiData = []
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
}
})
} else {
@ -267,7 +271,9 @@ export default {
this.$nextTick(() => {
if (this.$refs.anjuan) {
this.$refs.anjuan.getTableList()
this.$refs.file.junneiData = []
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
}
})
}
@ -380,12 +386,20 @@ export default {
handleTableList() {
if (this.selectedCategory.isType === 2) {
this.$nextTick(() => {
this.$refs.anjuan.anjuanData = []
this.$refs.file.junneiData = []
if (this.$refs.anjuan) {
this.$refs.anjuan.anjuanData = []
}
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
this.$refs.project.getTableDisplayFields(0)
if (this.selectedCategory.children.length !== 0) {
this.$refs.anjuan.getTableDisplayFields(1)
this.$refs.file.getTableDisplayFields(2)
if (this.$refs.anjuan) {
this.$refs.anjuan.getTableDisplayFields(1)
}
if (this.$refs.file) {
this.$refs.file.getTableDisplayFields(2)
}
}
setTimeout(() => {
this.$refs.project.getTableList()
@ -396,11 +410,17 @@ export default {
})
} else if (this.selectedCategory.isType === 3) {
this.$nextTick(() => {
this.$refs.anjuan.anjuanData = []
this.$refs.file.junneiData = []
if (this.$refs.anjuan) {
this.$refs.anjuan.anjuanData = []
}
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
this.$refs.anjuan.getTableDisplayFields(1)
if (this.selectedCategory.children.length !== 0) {
this.$refs.file.getTableDisplayFields(2)
if (this.$refs.file) {
this.$refs.file.getTableDisplayFields(2)
}
}
setTimeout(() => {
this.$refs.anjuan.getTableList()
@ -411,7 +431,9 @@ export default {
})
} else if (this.selectedCategory.isType === 4) {
this.$nextTick(() => {
this.$refs.file.junneiData = []
if (this.$refs.file) {
this.$refs.file.junneiData = []
}
this.$refs.file.getTableDisplayFields(2)
setTimeout(() => {
this.$refs.file.getTableList()
@ -422,7 +444,9 @@ export default {
})
} else if (this.selectedCategory.isType === 5) {
this.$nextTick(() => {
this.$refs.anjuan.anjuanData = []
if (this.$refs.anjuan) {
this.$refs.anjuan.anjuanData = []
}
this.$refs.anjuan.getTableDisplayFields(1)
setTimeout(() => {
this.$refs.anjuan.getTableList()

131
src/views/archivesManage/archivesList/mixins/archives.js

@ -91,6 +91,7 @@ export const archivesCrud = {
this.categoryId = this.selectedCategory.id
}
}
this.getTableDisplayFieldsLoading = true
this.selections = []
FetchTableDisplayFields({ categoryId: this.categoryId }).then(data => {
@ -122,75 +123,77 @@ export const archivesCrud = {
this.parentsId = null
}
}
this.selections = []
this.page.page = isNaN(page - 1) ? 0 : page - 1
this.formVisible = false
this.getTableDisplayFieldsLoading = true
const params = {
'categoryId': this.categoryId,
'parentsId': this.parentsId,
'isdel': this.recycleMain.isdel,
'page': this.page.page,
'size': this.page.size,
'sort': this.arrySort,
'queryType': this.query.queryType,
'queryTitle': this.query.queryTitle,
'itemNo': this.query.itemNo,
'archiveCtgNo': this.query.archiveCtgNo,
'responsibleby': this.query.responsibleby,
'archiveNo': this.query.archiveNo,
'archiveYear': this.smartQuery.archiveYear,
'department': this.smartQuery.department,
'retention': this.smartQuery.retention,
'securityClass': this.smartQuery.securityClass,
'organizationMatter': this.smartQuery.organizationMatter
}
FetchInitArchivesView(params).then(data => {
this.getTableDisplayFieldsLoading = false
if (data) {
this[name] = data.list.content
this.yearGroup = data.yearGroup
this.page.total = data.list.totalElements
if (this.categoryId !== null) { // 防止项目下无案卷门类情况
this.selections = []
this.page.page = isNaN(page - 1) ? 0 : page - 1
this.formVisible = false
this.getTableDisplayFieldsLoading = true
const params = {
'categoryId': this.categoryId,
'parentsId': this.parentsId,
'isdel': this.recycleMain.isdel,
'page': this.page.page,
'size': this.page.size,
'sort': this.arrySort,
'queryType': this.query.queryType,
'queryTitle': this.query.queryTitle,
'itemNo': this.query.itemNo,
'archiveCtgNo': this.query.archiveCtgNo,
'responsibleby': this.query.responsibleby,
'archiveNo': this.query.archiveNo,
'archiveYear': this.smartQuery.archiveYear,
'department': this.smartQuery.department,
'retention': this.smartQuery.retention,
'securityClass': this.smartQuery.securityClass,
'organizationMatter': this.smartQuery.organizationMatter
}
FetchInitArchivesView(params).then(data => {
this.getTableDisplayFieldsLoading = false
if (data) {
this[name] = data.list.content
this.yearGroup = data.yearGroup
this.page.total = data.list.totalElements
if (name === 'anjuanData' || name === 'junneiData') {
this[name].forEach((item, index) => {
if (name === 'anjuanData' || name === 'junneiData') {
this[name].forEach((item, index) => {
// 入库状态
if (item.is_storage === 0) {
this.storageTxt[index] = '未入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
if (item.is_storage === 0) {
this.storageTxt[index] = '未入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
}
} else if (item.is_storage === 1) {
this.storageTxt[index] = '待入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
}
} else if (item.is_storage === 2) {
this.storageTxt[index] = '已入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '在库'
}
} else if (item.is_storage === 3) {
this.storageTxt[index] = '待出'
} else if (item.is_storage === '') {
this.storageTxt[index] = '未入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
}
}
} else if (item.is_storage === 1) {
this.storageTxt[index] = '待入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
}
} else if (item.is_storage === 2) {
this.storageTxt[index] = '已入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '在库'
}
} else if (item.is_storage === 3) {
this.storageTxt[index] = '待出'
} else if (item.is_storage === '') {
this.storageTxt[index] = '未入'
if (item.is_borrow === '') {
this.borrowTxt[index] = '-'
}
}
// 借阅状态
if (item.is_borrow === 1) {
this.borrowTxt[index] = '待借'
} else if (item.is_borrow === 2) {
this.borrowTxt[index] = '待借'
} else if (item.is_borrow === 3) {
this.borrowTxt[index] = '已借'
}
})
// 借阅状态
if (item.is_borrow === 1) {
this.borrowTxt[index] = '待借'
} else if (item.is_borrow === 2) {
this.borrowTxt[index] = '待借'
} else if (item.is_borrow === 3) {
this.borrowTxt[index] = '已借'
}
})
}
}
}
})
})
}
},
// 著录界面-form/详情-api
handleForm(type, title) {

2
src/views/components/echarts/lendAcross.vue

@ -111,14 +111,12 @@ export default {
// return colorList[params.dataIndex]
// }
color: function(params) {
console.log(params)
var colorList = [
['#5FA2E2', '#1C54EE'],
['#84DFC0', '#0D9D81'],
['#FBCE9B', '#FF801E'],
['#FF7A7D', '#FF3438']
]
var colorItem = colorList[params.dataIndex]
return new echarts.graphic.LinearGradient(0, 0, 1, 0, [{
offset: 0,

Loading…
Cancel
Save