Browse Source

预归档库

master
xuhuajiao 1 year ago
parent
commit
b04721f7f9
  1. 18
      .env.development
  2. 46
      src/views/prearchiveLibrary/index.vue
  3. 53
      src/views/prearchiveLibrary/module/batchFile.vue

18
.env.development

@ -3,16 +3,24 @@ ENV = 'development'
# 接口地址
#内网服务地址
VUE_APP_BASE_API = 'http://192.168.99.107:7077'
VUE_APP_WS_API = 'ws://192.168.99.107:7077'
VUE_APP_CAMERA_API = '192.168.99.107:3000'
# VUE_APP_BASE_API = 'http://192.168.99.107:7077'
# VUE_APP_WS_API = 'ws://192.168.99.107:7077'
# VUE_APP_CAMERA_API = '192.168.99.107:3000'
# VUE_APP_BASE_API = 'http://192.168.99.107:7070'
# VUE_APP_WS_API = 'ws://192.168.99.107:7071'
# VUE_APP_CAMERA_API = '192.168.99.107:3000'
# 许镇-本地服地址
# VUE_APP_BASE_API = 'http://192.168.99.84:7070'
# VUE_APP_WS_API = 'ws://192.168.99.84:7070'
# VUE_APP_BASE_API = 'http://192.168.99.67:11100'
# VUE_APP_WS_API = 'ws://192.168.99.67:11100'
VUE_APP_BASE_API = 'http://192.168.99.67:11100'
VUE_APP_WS_API = 'ws://192.168.99.67:11100'
# VUE_APP_BASE_API = 'http://192.168.99.107:11100'
# VUE_APP_WS_API = 'ws://192.168.99.107:11100'
# 是否启用 babel-plugin-dynamic-import-node插件
VUE_CLI_BABEL_TRANSPILE_MODULES = true

46
src/views/prearchiveLibrary/index.vue

@ -44,7 +44,7 @@
<template v-slot:rightButtonGroup>
<div>
<el-button size="mini" :disabled="crud.selections.length === 0" @click="handleBatch"><i class="iconfont icon-piliangchengjian" />批量成件</el-button>
<el-button size="mini" :disabled="crud.selections.length === 0" @click="mergeVisible = true"><i class="iconfont icon-hebingchengjian" />合并成件</el-button>
<el-button size="mini" :disabled="crud.selections.length === 0" @click="handelMerge"><i class="iconfont icon-hebingchengjian" />合并成件</el-button>
<el-button size="mini" :disabled="crud.selections.length === 0" @click="handleMove"><i class="iconfont icon-yidong" />移动</el-button>
</div>
</template>
@ -100,12 +100,16 @@
<span class="dialog-left-bottom" />
<div class="setting-dialog">
<el-form ref="form" :inline="true" :model="form" :rules="rules" size="small" label-width="80px">
<el-form-item label="档案门类" prop="target">
<el-form-item label="档案门类" prop="categoryId">
<treeselect
v-model="form.target"
:options="targetOptions"
v-model="form.categoryId"
:options="categoryTree"
style="width: 400px;"
:normalizer="normalizer"
flat
:multiple="false"
placeholder="请选择档案门类"
@select="handleSelectCategory"
/>
</el-form-item>
</el-form>
@ -123,6 +127,7 @@
<script>
import CRUD, { presenter, header } from '@crud/crud'
import { FetchCategoryMenu } from '@/api/system/category/category'
import rrOperation from '@crud/RR.operation'
import crudOperation from '@crud/CRUD.operation'
import pagination from '@crud/Pagination'
@ -172,7 +177,7 @@ export default {
table: [],
deleteVisible: false,
mergeVisible: false,
targetOptions: [],
categoryTree: [],
form: {},
loadSource: [],
rules: {
@ -189,6 +194,14 @@ export default {
this.table = tableJson
},
methods: {
filterData(data) {
return data.filter(node => {
if (node.children && node.children.length > 0) {
node.children = this.filterData(node.children) //
}
return node.isType !== 3 // isType3
})
},
//
findNode(tree, func) {
for (const node of tree) {
@ -322,6 +335,29 @@ export default {
handleBatch() {
this.$refs.batchForm.batchVisible = true
},
handelMerge() {
this.mergeVisible = true
this.getCategoryDataTree()
},
getCategoryDataTree() {
FetchCategoryMenu().then(res => {
this.categoryTree = this.filterData(res)
})
},
handleSelectCategory(val) {
// this.selectedCategoryName = val.cnName
},
normalizer(node) {
if (node.children && !node.children.length) {
delete node.children
}
return {
id: node.id,
label: node.cnName,
children: node.children,
isDisabled: node.isType !== 2
}
},
handleClose(done) {
this.mergeVisible = false
done()

53
src/views/prearchiveLibrary/module/batchFile.vue

@ -17,7 +17,7 @@
</el-select>
</el-form-item>
<el-form-item label="归档范围" prop="scope">
<el-input v-model="form.scope" type="text">
<el-input v-model="form.scope" type="text" readonly>
<i slot="suffix" class="el-input__icon iconfont icon-sousuo" @click="selectScope" />
</el-input>
</el-form-item>
@ -57,31 +57,35 @@
<div class="corres-field-list corres-field-middle">
<div class="corres-field-title">
<p>源分类文件库-文件表</p>
<span>文件库分类A</span>
<span>{{ form.documentName }}</span>
</div>
<div class="field-list">
<div v-for="(item, index) in selectStatus" :key="index" class="field-item">
<el-select :key="index" v-model="item.value">
<el-select v-if="item.mode" :key="index" v-model="item.value" @change="selectChange(index)">
<el-option value="">请选择</el-option>
<el-option
v-for="v in selectOptions"
:key="v.value"
:label="v.label"
:value="v.value"
v-for="v in options"
:key="v.id"
:label="v.fieldCnName"
:value="v.fieldCnName"
/>
</el-select>
<div v-if="!item.mode" class="field-state"><span :class=" item.isType === 1 ? 'is-select' : 'is-hide'">{{ item.isType === 1 ? '显示': '隐藏' }}</span></div>
<p v-if="!item.mode" @click="textMode(index)">
{{ item.value }}
</p>
<div v-if="!item.mode" class="field-state"><span :class="item.isDisplay ? 'is-select' : 'is-hide'">{{ item.isDisplay ? '显示': '隐藏' }}</span></div>
</div>
</div>
</div>
<div class="corres-field-list corres-field-right">
<div class="corres-field-title">
<p>目标门类整理库/管理库-文件表</p>
<span>文书档案文件</span>
<span>{{ selectedCategoryName }}</span>
</div>
<div class="field-list">
<div v-for="(item,index) in targetData" :key="index" class="field-item">
<p>{{ item.label }}</p>
<div class="field-state"><span :class=" item.isType === 1 ? 'is-select' : 'is-hide'">{{ item.isType === 1 ? '显示': '隐藏' }}</span></div>
<p>{{ item.fieldCnName }}</p>
<div class="field-state"><span :class=" item.isDisplay ? 'is-select' : 'is-hide'">{{ item.isDisplay ? '显示': '隐藏' }}</span></div>
</div>
</div>
</div>
@ -129,19 +133,13 @@ export default {
{ required: true, message: '请选择档案门类', trigger: 'change' }
]
},
fiedOption: [
{ label: '字段值', value: '字段值', isType: 1 },
{ label: '默认值', value: '默认值', isType: 2 }
],
fiedOption: [],
fiedType: null,
selectStatus: [],
selectOptions: [
{ label: '字段A', value: '字段A', isType: 1 },
{ label: '字段B', value: '字段B', isType: 1 },
{ label: '字段C', value: '字段C', isType: 0 },
{ label: '字段D', value: '字段D', isType: 1 }
],
targetData: []
selectOptions: [],
targetData: [],
leftLoading: false,
rightLoading: false
}
},
created() {
@ -168,6 +166,7 @@ export default {
FetchInitFieldMate({ 'id': id }).then((res) => {
console.log(res)
this.form.documentName = res.documentName
this.selectedCategoryName = res.categoryName
this.form.categoryId = res.fieldMateDetails[0].pid.categoryId.pid
}).catch(err => {
console.log(err)
@ -213,6 +212,16 @@ export default {
console.log('val', val)
}
},
selectChange(index) {
this.options.forEach((item) => {
if (item.fieldCnName === this.selectStatus[index].value) {
this.selectStatus.splice(index, 1, { mode: false, value: this.selectStatus[index].value, field: item, isDisplay: item.isDisplay })
}
})
},
textMode(index) {
this.selectStatus.splice(index, 1, { mode: true, value: this.selectStatus[index].value, field: null, isDisplay: this.selectStatus[index].isDisplay })
},
handleClose(done) {
this.batchVisible = false
done()

Loading…
Cancel
Save