|
|
@ -1,4 +1,5 @@ |
|
|
<template> |
|
|
<template> |
|
|
|
|
|
<div> |
|
|
<!-- 移动 --> |
|
|
<!-- 移动 --> |
|
|
<el-dialog class="move-form" append-to-body :modal-append-to-body="false" :close-on-click-modal="false" :before-close="handleClose" :visible="moveVisible" title="移动" @opened="opened"> |
|
|
<el-dialog class="move-form" append-to-body :modal-append-to-body="false" :close-on-click-modal="false" :before-close="handleClose" :visible="moveVisible" title="移动" @opened="opened"> |
|
|
<span class="dialog-right-top" /> |
|
|
<span class="dialog-right-top" /> |
|
|
@ -83,6 +84,16 @@ |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
<MergeIntoDocument |
|
|
|
|
|
ref="mergeIntoDocument" |
|
|
|
|
|
:selected-category="selectedDocument" |
|
|
|
|
|
:selections="moveArc" |
|
|
|
|
|
:display-fields="displayFields" |
|
|
|
|
|
:business-type="10" |
|
|
|
|
|
:extra-params="moveFlowParams" |
|
|
|
|
|
@close-dialog="handleMoveFlowSuccess" |
|
|
|
|
|
/> |
|
|
|
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
|
<script> |
|
|
<script> |
|
|
@ -90,11 +101,13 @@ import { preLibraryCrud } from '../mixins/index' |
|
|
import { FetchMove } from '@/api/prearchiveLibrary/prearchiveLibrary' |
|
|
import { FetchMove } from '@/api/prearchiveLibrary/prearchiveLibrary' |
|
|
import { FetchMenuByFondsId } from '@/api/system/category/category' |
|
|
import { FetchMenuByFondsId } from '@/api/system/category/category' |
|
|
import { FetchInitCategoryViewTable, FetchInitCategoryView } from '@/api/collect/collect' |
|
|
import { FetchInitCategoryViewTable, FetchInitCategoryView } from '@/api/collect/collect' |
|
|
|
|
|
import { FetchReDocumentInitFlowByCategoryId } from '@/api/system/category/process' |
|
|
|
|
|
import MergeIntoDocument from './mergeIntoDocument.vue' |
|
|
// import { FetchInitSearchFonds } from '@/api/archiveUtilize/archiveUtilize' |
|
|
// import { FetchInitSearchFonds } from '@/api/archiveUtilize/archiveUtilize' |
|
|
import Vue from 'vue' |
|
|
import Vue from 'vue' |
|
|
export default { |
|
|
export default { |
|
|
name: 'MoveFile', |
|
|
name: 'MoveFile', |
|
|
components: { }, |
|
|
|
|
|
|
|
|
components: { MergeIntoDocument }, |
|
|
mixins: [preLibraryCrud], |
|
|
mixins: [preLibraryCrud], |
|
|
props: { |
|
|
props: { |
|
|
selectedDocument: { |
|
|
selectedDocument: { |
|
|
@ -102,6 +115,10 @@ export default { |
|
|
default: function() { |
|
|
default: function() { |
|
|
return {} |
|
|
return {} |
|
|
} |
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
displayFields: { |
|
|
|
|
|
type: Array, |
|
|
|
|
|
default: () => [] |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
data() { |
|
|
data() { |
|
|
@ -119,6 +136,7 @@ export default { |
|
|
tableDisplayFields: [], |
|
|
tableDisplayFields: [], |
|
|
selections: [], |
|
|
selections: [], |
|
|
moveArc: [], |
|
|
moveArc: [], |
|
|
|
|
|
moveFlowParams: {}, |
|
|
defaultProps: { children: 'children', label: 'cnName' }, |
|
|
defaultProps: { children: 'children', label: 'cnName' }, |
|
|
page: { |
|
|
page: { |
|
|
page: 1, |
|
|
page: 1, |
|
|
@ -284,6 +302,24 @@ export default { |
|
|
const archivesIds = this.moveArc.map(item => { |
|
|
const archivesIds = this.moveArc.map(item => { |
|
|
return item.id |
|
|
return item.id |
|
|
}) |
|
|
}) |
|
|
|
|
|
// 判断预归档移动审批流程是否开启 |
|
|
|
|
|
FetchReDocumentInitFlowByCategoryId({ 'documentId': null }).then((flowRes) => { |
|
|
|
|
|
const flowItem = flowRes && flowRes.length > 0 ? flowRes[0] : null |
|
|
|
|
|
if (flowItem && flowItem.status === 1) { |
|
|
|
|
|
// 审批流程开启,走流程提交 |
|
|
|
|
|
this.moveFlowParams = { |
|
|
|
|
|
'archivesIds': archivesIds, // 移动的预归档档案信息 |
|
|
|
|
|
'purposeCategoryId': this.selectedCategoryMove.id, // 目的门类(预归档用) |
|
|
|
|
|
'sourceDocumentId': this.selectedDocument.id, // 预归档门类id |
|
|
|
|
|
'archivalCategoryCode': this.selectedCategoryMove.code, |
|
|
|
|
|
'moveArchiveId': this.selections[0].id // 移动到的收集库档案id |
|
|
|
|
|
} |
|
|
|
|
|
this.archivesBtnLoading = false |
|
|
|
|
|
this.$nextTick(() => { |
|
|
|
|
|
this.$refs.mergeIntoDocument.archivesFillingVisible = true |
|
|
|
|
|
}) |
|
|
|
|
|
} else { |
|
|
|
|
|
// 审批流程未开启,直接移动 |
|
|
const params = { |
|
|
const params = { |
|
|
'archivesId': this.selections[0].id, // 移动到的收集库档案id |
|
|
'archivesId': this.selections[0].id, // 移动到的收集库档案id |
|
|
'archivesIds': archivesIds, // 移动的预归档档案信息 |
|
|
'archivesIds': archivesIds, // 移动的预归档档案信息 |
|
|
@ -303,6 +339,18 @@ export default { |
|
|
this.$emit('refresh') |
|
|
this.$emit('refresh') |
|
|
this.archivesBtnLoading = false |
|
|
this.archivesBtnLoading = false |
|
|
}) |
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}).catch(err => { |
|
|
|
|
|
console.log(err) |
|
|
|
|
|
this.archivesBtnLoading = false |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
// 预归档移动审批流程提交成功回调 |
|
|
|
|
|
handleMoveFlowSuccess() { |
|
|
|
|
|
this.moveVisible = false |
|
|
|
|
|
this.query.search = null |
|
|
|
|
|
this.selections = [] |
|
|
|
|
|
this.$emit('refresh') |
|
|
}, |
|
|
}, |
|
|
handleSizeChange(size) { |
|
|
handleSizeChange(size) { |
|
|
this.page.size = size |
|
|
this.page.size = size |
|
|
|