档案管理归档管理

main
mo 1 year ago
parent e8c53423bc
commit 766979a94d

@ -52,3 +52,13 @@ export function exportRecordExcel(query) {
responseType: 'blob' responseType: 'blob'
}) })
} }
// 生成编码
export function createCodeRule(data) {
return request({
url: '/archives/code-rule/create',
method: 'post',
data: data
})
}

@ -0,0 +1,54 @@
import request from '@/utils/request'
// 创建资产档案
export function createElectronicAssets(data) {
return request({
url: '/ea/electronic/create',
method: 'post',
data: data
})
}
// 更新资产档案
export function updateElectronicAssets(data) {
return request({
url: '/ea/electronic/update',
method: 'put',
data: data
})
}
// 删除资产档案
export function deleteElectronicAssets(id) {
return request({
url: '/ea/electronic/delete?id=' + id,
method: 'delete'
})
}
// 获得资产档案
export function getElectronicAssets(id) {
return request({
url: '/ea/electronic/get?id=' + id,
method: 'get'
})
}
// 获得资产档案分页
export function getElectronicAssetsPage(query) {
return request({
url: '/ea/electronic/page',
method: 'get',
params: query
})
}
// 导出资产档案 Excel
export function exportElectronicAssetsExcel(query) {
return request({
url: '/ea/electronic/export-excel',
method: 'get',
params: query,
responseType: 'blob'
})
}

@ -109,7 +109,10 @@ export const DICT_TYPE = {
BS_SUPPLIER_TYPE: 'supplier_centre_state', BS_SUPPLIER_TYPE: 'supplier_centre_state',
// 采购进度(采购状态) // 采购进度(采购状态)
BS_PROCUREMENT_TYPE: 'supplier_procurement_state', BS_PROCUREMENT_TYPE: 'supplier_procurement_state',
// 档案类型
ARCHIVES_FILE_TYPE: 'archives_file_type',
// 归档状态
ARCHIVES_FILE_STATUS: 'archives_file_status',
} }
/** /**

@ -1,103 +1,55 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<!-- 搜索工作栏 --> <!-- 搜索工作栏 -->
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"> <el-form
<el-form-item label="业务实体id" prop="companyId"> :model="queryParams"
<el-input v-model="queryParams.companyId" placeholder="请输入业务实体id" clearable @keyup.enter.native="handleQuery"/> ref="queryForm"
</el-form-item> size="small"
<el-form-item label="业务实体" prop="company"> :inline="true"
<el-input v-model="queryParams.company" placeholder="请输入业务实体" clearable @keyup.enter.native="handleQuery"/> v-show="showSearch"
</el-form-item> label-width="88px"
<el-form-item label="归档频次" prop="frequency"> >
<el-input v-model="queryParams.frequency" placeholder="请输入归档频次" clearable @keyup.enter.native="handleQuery"/> <!-- <el-form-item label="会计年份" prop="year">
</el-form-item> <el-input
<el-form-item label="档案类型" prop="fileType"> v-model="queryParams.year"
<el-select v-model="queryParams.fileType" placeholder="请选择档案类型" clearable size="small"> placeholder="请输入会计年份"
<el-option label="请选择字典生成" value="" /> clearable
</el-select> @keyup.enter.native="handleQuery"
</el-form-item> />
<el-form-item label="会计年份" prop="year">
<el-input v-model="queryParams.year" placeholder="请输入会计年份" clearable @keyup.enter.native="handleQuery"/>
</el-form-item> </el-form-item>
<el-form-item label="会计月份" prop="period"> <el-form-item label="会计月份" prop="period">
<el-input v-model="queryParams.period" placeholder="请输入会计月份" clearable @keyup.enter.native="handleQuery"/> <el-input
</el-form-item> v-model="queryParams.period"
placeholder="请输入会计月份"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item> -->
<el-form-item label="起止凭证号" prop="vouNum"> <el-form-item label="起止凭证号" prop="vouNum">
<el-input v-model="queryParams.vouNum" placeholder="请输入起止凭证号" clearable @keyup.enter.native="handleQuery"/> <el-input
</el-form-item> v-model="queryParams.vouNum"
<el-form-item label="全宗号" prop="caseNum"> placeholder="请输入起止凭证号"
<el-input v-model="queryParams.caseNum" placeholder="请输入全宗号" clearable @keyup.enter.native="handleQuery"/> clearable
</el-form-item> @keyup.enter.native="handleQuery"
<el-form-item label="目录号" prop="catalogNum"> />
<el-input v-model="queryParams.catalogNum" placeholder="请输入目录号" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="案卷号" prop="filesNum">
<el-input v-model="queryParams.filesNum" placeholder="请输入案卷号" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="档案位置" prop="site">
<el-input v-model="queryParams.site" placeholder="请输入档案位置" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="关联号" prop="flowId">
<el-input v-model="queryParams.flowId" placeholder="请输入关联号" clearable @keyup.enter.native="handleQuery"/>
</el-form-item> </el-form-item>
<el-form-item label="创建日期" prop="createTime"> <el-form-item label="创建日期" prop="createTime">
<el-date-picker v-model="queryParams.createTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange" <el-date-picker
range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" /> v-model="queryParams.createTime"
</el-form-item> style="width: 240px"
<el-form-item label="状态" prop="status"> value-format="yyyy-MM-dd HH:mm:ss"
<el-select v-model="queryParams.status" placeholder="请选择状态" clearable size="small"> type="daterange"
<el-option label="请选择字典生成" value="" /> range-separator="-"
</el-select> start-placeholder="开始日期"
</el-form-item> end-placeholder="结束日期"
<el-form-item label="归档详情" prop="note"> :default-time="['00:00:00', '23:59:59']"
<el-input v-model="queryParams.note" placeholder="请输入归档详情" clearable @keyup.enter.native="handleQuery"/> />
</el-form-item>
<el-form-item label="归档状态" prop="fileStatus">
<el-select v-model="queryParams.fileStatus" placeholder="请选择归档状态" clearable size="small">
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="借阅状态" prop="borrowStatus">
<el-select v-model="queryParams.borrowStatus" placeholder="请选择借阅状态" clearable size="small">
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="鉴定状态" prop="identifyStatus">
<el-select v-model="queryParams.identifyStatus" placeholder="请选择鉴定状态" clearable size="small">
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="queryParams.remark" placeholder="请输入备注" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="归档时间" prop="recordTime">
<el-date-picker v-model="queryParams.recordTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"
range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="['00:00:00', '23:59:59']" />
</el-form-item>
<el-form-item label="所属部门id" prop="deptId">
<el-input v-model="queryParams.deptId" placeholder="请输入所属部门id" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="所属部门" prop="deptName">
<el-input v-model="queryParams.deptName" placeholder="请输入所属部门" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="预留字段1" prop="attr1">
<el-input v-model="queryParams.attr1" placeholder="请输入预留字段1" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="预留字段2" prop="attr2">
<el-input v-model="queryParams.attr2" placeholder="请输入预留字段2" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="预留字段3" prop="attr3">
<el-input v-model="queryParams.attr3" placeholder="请输入预留字段3" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="预留字段4" prop="attr4">
<el-input v-model="queryParams.attr4" placeholder="请输入预留字段4" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="用户id" prop="userId">
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery"/>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery"></el-button> <el-button type="primary" icon="el-icon-search" @click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" @click="resetQuery"></el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -105,23 +57,46 @@
<!-- 操作工具栏 --> <!-- 操作工具栏 -->
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" <el-button
v-hasPermi="['archives:record:create']">新增</el-button> type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['archives:record:create']"
>新增</el-button
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" <el-button
v-hasPermi="['archives:record:export']">导出</el-button> type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
:loading="exportLoading"
v-hasPermi="['archives:record:export']"
>导出</el-button
>
</el-col> </el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list"> <el-table v-loading="loading" :data="list">
<el-table-column label="主键" align="center" prop="id" />
<el-table-column label="业务实体id" align="center" prop="companyId" />
<el-table-column label="业务实体" align="center" prop="company" /> <el-table-column label="业务实体" align="center" prop="company" />
<el-table-column label="归档频次" align="center" prop="frequency" /> <el-table-column label="归档频次" align="center" prop="frequency" />
<el-table-column label="档案类型" align="center" prop="fileType" /> <el-table-column label="档案类型" align="center" prop="fileType">
<template v-slot="scope">
<dict-tag
:type="DICT_TYPE.ARCHIVES_FILE_TYPE"
:value="scope.row.fileType"
/>
</template>
</el-table-column>
<el-table-column label="会计年份" align="center" prop="year" /> <el-table-column label="会计年份" align="center" prop="year" />
<el-table-column label="会计月份" align="center" prop="period" /> <el-table-column label="会计月份" align="center" prop="period" />
<el-table-column label="起止凭证号" align="center" prop="vouNum" /> <el-table-column label="起止凭证号" align="center" prop="vouNum" />
@ -130,129 +105,263 @@
<el-table-column label="案卷号" align="center" prop="filesNum" /> <el-table-column label="案卷号" align="center" prop="filesNum" />
<el-table-column label="档案位置" align="center" prop="site" /> <el-table-column label="档案位置" align="center" prop="site" />
<el-table-column label="关联号" align="center" prop="flowId" /> <el-table-column label="关联号" align="center" prop="flowId" />
<el-table-column label="创建日期" align="center" prop="createTime" width="180"> <el-table-column
label="创建日期"
align="center"
prop="createTime"
width="160"
>
<template v-slot="scope"> <template v-slot="scope">
<span>{{ parseTime(scope.row.createTime) }}</span> <span>{{ parseTime(scope.row.createTime) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="状态" align="center" prop="status" /> <el-table-column label="状态" align="center" prop="status" />
<el-table-column label="归档详情" align="center" prop="note" /> <el-table-column label="归档详情" align="center" prop="note" />
<el-table-column label="归档状态" align="center" prop="fileStatus" /> <el-table-column label="归档状态" align="center" prop="fileStatus">
<template v-slot="scope">
<dict-tag
:type="DICT_TYPE.ARCHIVES_FILE_STATUS"
:value="scope.row.fileStatus"
/>
</template>
</el-table-column>
<el-table-column label="借阅状态" align="center" prop="borrowStatus" /> <el-table-column label="借阅状态" align="center" prop="borrowStatus" />
<el-table-column label="鉴定状态" align="center" prop="identifyStatus" /> <el-table-column label="鉴定状态" align="center" prop="identifyStatus" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="归档时间" align="center" prop="recordTime" /> <el-table-column label="归档时间" align="center" prop="recordTime" />
<el-table-column label="所属部门id" align="center" prop="deptId" />
<el-table-column label="所属部门" align="center" prop="deptName" /> <el-table-column label="所属部门" align="center" prop="deptName" />
<el-table-column label="预留字段1" align="center" prop="attr1" /> <el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="预留字段2" align="center" prop="attr2" /> <el-table-column
<el-table-column label="预留字段3" align="center" prop="attr3" /> label="操作"
<el-table-column label="预留字段4" align="center" prop="attr4" /> align="center"
<el-table-column label="用户id" align="center" prop="userId" /> width="120"
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> class-name="small-padding fixed-width"
>
<template v-slot="scope"> <template v-slot="scope">
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" <el-button
v-hasPermi="['archives:record:update']">修改</el-button> size="mini"
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" type="text"
v-hasPermi="['archives:record:delete']">删除</el-button> icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['archives:record:update']"
>修改</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['archives:record:delete']"
>删除</el-button
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<!-- 分页组件 --> <!-- 分页组件 -->
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" <pagination
@pagination="getList"/> v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNo"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 对话框(添加 / 修改) --> <!-- 对话框(添加 / 修改) -->
<el-dialog :title="title" :visible.sync="open" width="500px" v-dialogDrag append-to-body> <el-dialog
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> :title="title"
<el-form-item label="业务实体id" prop="companyId"> :visible.sync="open"
<el-input v-model="form.companyId" placeholder="请输入业务实体id" /> width="1000px"
</el-form-item> append-to-body
>
<el-form ref="form" :model="form" :rules="rules" label-width="98px">
<el-row>
<el-col :span="8">
<el-form-item label="业务实体" prop="company"> <el-form-item label="业务实体" prop="company">
<el-input v-model="form.company" placeholder="请输入业务实体" /> <el-cascader
v-model="companyArray"
:options="companyOptions"
:props="propName"
placeholder="请选择业务实体"
clearable
@change="handleChange"
/>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="归档频次" prop="frequency"> <el-form-item label="归档频次" prop="frequency">
<el-input v-model="form.frequency" placeholder="请输入归档频次" /> <el-input v-model="form.frequency" placeholder="请输入归档频次" />
</el-form-item> </el-form-item>
<el-form-item label="档案类型" prop="fileType"> </el-col>
<el-col :span="8">
<el-form-item label="档案类型" prop="company">
<el-select v-model="form.fileType" placeholder="请选择档案类型"> <el-select v-model="form.fileType" placeholder="请选择档案类型">
<el-option label="请选择字典生成" value="" /> <el-option
v-for="item in fileTypeOptions"
:key="item.id"
:value="item.value"
:label="item.label"
>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="会计年份" prop="year"> <el-form-item label="会计年份" prop="year">
<el-input v-model="form.year" placeholder="请输入会计年份" /> <el-date-picker
format="yyyy年"
v-model="form.year"
value-format="yyyy"
type="year"
placeholder="请选择会计年份"
>
</el-date-picker>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="会计月份" prop="period"> <el-form-item label="会计月份" prop="period">
<el-input v-model="form.period" placeholder="请输入会计月份" /> <el-date-picker
popper-class="due_month"
v-model="form.period"
format="M月"
value-format="M"
type="month"
placeholder="请选择会计月份"
>
</el-date-picker>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="起止凭证号" prop="vouNum"> <el-form-item label="起止凭证号" prop="vouNum">
<el-input v-model="form.vouNum" placeholder="请输入起止凭证号" /> <el-input v-model="form.vouNum" placeholder="请输入起止凭证号" />
</el-form-item> </el-form-item>
<el-form-item label="全宗号" prop="caseNum"> </el-col>
<el-input v-model="form.caseNum" placeholder="请输入全宗号" /> </el-row>
<el-row>
<el-col :span="8">
<el-form-item label="全宗号" prop="company">
<el-select
v-model="form.caseNum"
placeholder="请选择全宗号"
@change="changeCaseNum"
>
<el-option
v-for="item in caseNumOptions"
:key="item.id"
:value="item.value"
:label="item.label"
>
</el-option>
</el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="目录号" prop="catalogNum"> <el-form-item label="目录号" prop="catalogNum">
<el-input v-model="form.catalogNum" placeholder="请输入目录号" /> <el-select
v-model="form.catalogNum"
placeholder="请选择目录号"
@change="changeCatalogNum"
>
<el-option
v-for="item in catalogNumOptions"
:key="item.id"
:value="item.value"
:label="item.label"
>
</el-option>
</el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="案卷号" prop="filesNum"> <el-form-item label="案卷号" prop="filesNum">
<el-input v-model="form.filesNum" placeholder="请输入案卷号" /> <el-input v-model="form.filesNum" placeholder="请输入案卷号" />
</el-form-item> </el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="档案位置" prop="site"> <el-form-item label="档案位置" prop="site">
<el-input v-model="form.site" placeholder="请输入档案位置" /> <el-input v-model="form.site" placeholder="请输入档案位置" />
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="关联号" prop="flowId"> <el-form-item label="关联号" prop="flowId">
<el-input v-model="form.flowId" placeholder="请输入关联号" /> <el-input v-model="form.flowId" placeholder="请输入关联号" />
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="状态" prop="status"> <el-form-item label="状态" prop="status">
<el-radio-group v-model="form.status"> <el-radio-group v-model="form.status">
<el-radio label="1">请选择字典生成</el-radio> <el-radio label="1">请选择字典生成</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="归档详情" prop="note"> <el-form-item label="归档详情" prop="note">
<el-input v-model="form.note" placeholder="请输入归档详情" /> <el-input v-model="form.note" placeholder="请输入归档详情" />
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="归档状态" prop="fileStatus"> <el-form-item label="归档状态" prop="fileStatus">
<el-radio-group v-model="form.fileStatus"> <el-select v-model="form.fileStatus" placeholder="请选择归档状态">
<el-radio label="1">请选择字典生成</el-radio> <el-option
</el-radio-group> v-for="item in fileStatusOptions"
:key="item.id"
:value="item.value"
:label="item.label"
>
</el-option>
</el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="借阅状态" prop="borrowStatus"> <el-form-item label="借阅状态" prop="borrowStatus">
<el-radio-group v-model="form.borrowStatus"> <el-radio-group v-model="form.borrowStatus">
<el-radio label="1">请选择字典生成</el-radio> <el-radio label="1">请选择字典生成</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="鉴定状态" prop="identifyStatus"> <el-form-item label="鉴定状态" prop="identifyStatus">
<el-radio-group v-model="form.identifyStatus"> <el-radio-group v-model="form.identifyStatus">
<el-radio label="1">请选择字典生成</el-radio> <el-radio label="1">请选择字典生成</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="备注" prop="remark"> <el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" /> <el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item> </el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="归档时间" prop="recordTime"> <el-form-item label="归档时间" prop="recordTime">
<el-date-picker clearable v-model="form.recordTime" type="date" value-format="timestamp" placeholder="选择归档时间" /> <el-date-picker
</el-form-item> clearable
<el-form-item label="所属部门id" prop="deptId"> v-model="form.recordTime"
<el-input v-model="form.deptId" placeholder="请输入所属部门id" /> type="date"
value-format="yyyy-MM-dd"
placeholder="选择归档时间"
/>
</el-form-item> </el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="所属部门" prop="deptName"> <el-form-item label="所属部门" prop="deptName">
<el-input v-model="form.deptName" placeholder="请输入所属部门" /> <el-input v-model="form.deptName" placeholder="请输入所属部门" />
</el-form-item> </el-form-item>
<el-form-item label="预留字段1" prop="attr1"> </el-col>
<el-input v-model="form.attr1" placeholder="请输入预留字段1" /> <el-col :span="8">
</el-form-item>
<el-form-item label="预留字段2" prop="attr2">
<el-input v-model="form.attr2" placeholder="请输入预留字段2" />
</el-form-item>
<el-form-item label="预留字段3" prop="attr3">
<el-input v-model="form.attr3" placeholder="请输入预留字段3" />
</el-form-item>
<el-form-item label="预留字段4" prop="attr4">
<el-input v-model="form.attr4" placeholder="请输入预留字段4" />
</el-form-item>
<el-form-item label="用户id" prop="userId"> <el-form-item label="用户id" prop="userId">
<el-input v-model="form.userId" placeholder="请输入用户id" /> <el-input v-model="form.userId" placeholder="请输入用户id" />
</el-form-item> </el-form-item>
</el-col>
</el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button> <el-button type="primary" @click="submitForm"> </el-button>
@ -263,14 +372,31 @@
</template> </template>
<script> <script>
import { createRecord, updateRecord, deleteRecord, getRecord, getRecordPage, exportRecordExcel } from "@/api/archives/record"; import {
createRecord,
updateRecord,
deleteRecord,
getRecord,
getRecordPage,
exportRecordExcel,
createCodeRule,
} from "@/api/archives/record";
import { listDept } from "@/api/system/dept";
import { listData } from "@/api/system/dict/data";
export default { export default {
name: "Record", name: "Record",
components: { components: {},
},
data() { data() {
return { return {
propName: {
checkStrictly: true,
label: "name",
value: "id",
multiple: false,
},
companyOptions: [], //
companyArray: [], //
// //
loading: true, loading: true,
// //
@ -319,25 +445,94 @@ export default {
}, },
// //
form: {}, form: {},
Fileform: {},
// //
rules: { rules: {},
} fileTypeOptions: [], //
fileStatusOptions: [], //
catalogNumOptions: [], //
caseNumOptions: [], //
}; };
}, },
created() { created() {
this.getList(); this.getList();
this.getCompanyList();
this.handleInitList();
}, },
methods: { methods: {
/** 查询列表 */ /** 查询列表 */
getList() { getList() {
this.loading = true; this.loading = true;
// //
getRecordPage(this.queryParams).then(response => { getRecordPage(this.queryParams).then((response) => {
this.list = response.data.list; this.list = response.data.list;
this.total = response.data.total; this.total = response.data.total;
this.loading = false; this.loading = false;
}); });
}, },
//
getCompanyList() {
listDept().then((response) => {
this.companyOptions = this.handleTree(response.data, "id", "parentId");
console.log(this.companyOptions);
});
},
handleChange(value) {
console.log(value, value[value.length - 1]);
this.form.companyId = value[value.length - 1]; //id
},
//
handleInitList() {
//
listData({
pageNo: 1,
pageSize: 100,
dictType: "archives_file_type",
}).then((res) => {
this.fileTypeOptions = res.data.list || [];
});
//
listData({
pageNo: 1,
pageSize: 100,
dictType: "archives_case_num",
}).then((res) => {
this.caseNumOptions = res.data.list || [];
});
//
listData({
pageNo: 1,
pageSize: 100,
dictType: "archives_catalog_num",
}).then((res) => {
this.catalogNumOptions = res.data.list || [];
});
//
listData({
pageNo: 1,
pageSize: 100,
dictType: "archives_file_status",
}).then((res) => {
this.fileStatusOptions = res.data.list || [];
});
},
changeCaseNum(val) {
this.Fileform.catalogNum = val;
if (this.Fileform.catalogNum != null && this.Fileform.caseNum != null) {
this.creatFilesNum();
}
},
changeCatalogNum(val) {
this.Fileform.caseNum = val;
if (this.Fileform.catalogNum != null && this.Fileform.caseNum != null) {
this.creatFilesNum();
}
},
creatFilesNum() {
createCodeRule(this.Fileform).then((response) => {
this.form.filesNum = response.data;
});
},
/** 取消按钮 */ /** 取消按钮 */
cancel() { cancel() {
this.open = false; this.open = false;
@ -374,6 +569,11 @@ export default {
attr4: undefined, attr4: undefined,
userId: undefined, userId: undefined,
}; };
this.Fileform = {
catalogNum: null,
caseNum: null,
};
this.companyArray = [];
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
@ -396,7 +596,7 @@ export default {
handleUpdate(row) { handleUpdate(row) {
this.reset(); this.reset();
const id = row.id; const id = row.id;
getRecord(id).then(response => { getRecord(id).then((response) => {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改归档"; this.title = "修改归档";
@ -404,13 +604,13 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate((valid) => {
if (!valid) { if (!valid) {
return; return;
} }
// //
if (this.form.id != null) { if (this.form.id != null) {
updateRecord(this.form).then(response => { updateRecord(this.form).then((response) => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.getList(); this.getList();
@ -418,7 +618,7 @@ export default {
return; return;
} }
// //
createRecord(this.form).then(response => { createRecord(this.form).then((response) => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.getList(); this.getList();
@ -428,12 +628,16 @@ export default {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const id = row.id; const id = row.id;
this.$modal.confirm('是否确认删除归档编号为"' + id + '"的数据项?').then(function() { this.$modal
.confirm('是否确认删除归档编号为"' + id + '"的数据项?')
.then(function () {
return deleteRecord(id); return deleteRecord(id);
}).then(() => { })
.then(() => {
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
}).catch(() => {}); })
.catch(() => {});
}, },
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
@ -441,14 +645,24 @@ export default {
let params = { ...this.queryParams }; let params = { ...this.queryParams };
params.pageNo = undefined; params.pageNo = undefined;
params.pageSize = undefined; params.pageSize = undefined;
this.$modal.confirm('是否确认导出所有归档数据项?').then(() => { this.$modal
.confirm("是否确认导出所有归档数据项?")
.then(() => {
this.exportLoading = true; this.exportLoading = true;
return exportRecordExcel(params); return exportRecordExcel(params);
}).then(response => { })
this.$download.excel(response, '归档.xls'); .then((response) => {
this.$download.excel(response, "归档.xls");
this.exportLoading = false; this.exportLoading = false;
}).catch(() => {}); })
} .catch(() => {});
} },
},
}; };
</script> </script>
<style lang="scss">
.due_month .el-date-picker__header {
display: none;
}
</style>

@ -0,0 +1,667 @@
<template>
<div class="app-container">
<!-- 搜索工作栏 -->
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="98px"
>
<el-form-item label="业务实体名称" prop="company">
<el-input
v-model="queryParams.company"
placeholder="请输入业务实体名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="部门名称" prop="deptName">
<el-input
v-model="queryParams.deptName"
placeholder="请输入部门名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="资产名称" prop="assetName">
<el-input
v-model="queryParams.assetName"
placeholder="请输入资产名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="资产类型" prop="assetType">
<el-select
v-model="queryParams.assetType"
placeholder="请选择资产类型"
clearable
size="small"
>
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="购买日期" prop="purchaseDate">
<el-date-picker
v-model="queryParams.purchaseDate"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
/>
</el-form-item>
<el-form-item label="报废日期" prop="disposalDate">
<el-date-picker
v-model="queryParams.disposalDate"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
/>
</el-form-item>
<el-form-item label="资产状态" prop="assetStatus">
<el-select
v-model="queryParams.assetStatus"
placeholder="请选择资产状态"
clearable
size="small"
>
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="购买渠道" prop="purchaseChannel">
<el-input
v-model="queryParams.purchaseChannel"
placeholder="请输入购买渠道"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="年度" prop="year">
<el-input
v-model="queryParams.year"
placeholder="请输入年度"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="月份" prop="period">
<el-input
v-model="queryParams.period"
placeholder="请输入月份"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="借阅状态" prop="borrowStatus">
<el-select
v-model="queryParams.borrowStatus"
placeholder="请选择借阅状态"
clearable
size="small"
>
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="纸档位置" prop="position">
<el-input
v-model="queryParams.position"
placeholder="请输入纸档位置"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="归档状态" prop="fileStatus">
<el-select
v-model="queryParams.fileStatus"
placeholder="请选择归档状态"
clearable
size="small"
>
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
<el-form-item label="创建日期" prop="createTime">
<el-date-picker
v-model="queryParams.createTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
/>
</el-form-item>
<el-form-item label="制单人" prop="createBy">
<el-input
v-model="queryParams.createBy"
placeholder="请输入制单人"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery"
>搜索</el-button
>
<el-button icon="el-icon-refresh" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<!-- 操作工具栏 -->
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['ea:electronic:create']"
>新增</el-button
>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
:loading="exportLoading"
v-hasPermi="['ea:electronic:export']"
>导出</el-button
>
</el-col>
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row>
<!-- 列表 -->
<el-table v-loading="loading" :data="list">
<!-- <el-table-column label="资产档案id" align="center" prop="id" />
<el-table-column label="业务实体id" align="center" prop="companyId" /> -->
<el-table-column label="业务实体名称" align="center" prop="company" />
<!-- <el-table-column label="部门id" align="center" prop="deptId" /> -->
<el-table-column label="部门名称" align="center" prop="deptName" />
<el-table-column label="资产编号" align="center" prop="assetCode" />
<el-table-column label="资产名称" align="center" prop="assetName" />
<el-table-column
label="资产描述"
align="center"
prop="assetDescription"
/>
<el-table-column label="资产类型" align="center" prop="assetType" />
<el-table-column
label="购买日期"
align="center"
prop="purchaseDate"
width="180"
>
<template v-slot="scope">
<span>{{ parseTime(scope.row.purchaseDate) }}</span>
</template>
</el-table-column>
<el-table-column
label="报废日期"
align="center"
prop="disposalDate"
width="180"
>
<template v-slot="scope">
<span>{{ parseTime(scope.row.disposalDate) }}</span>
</template>
</el-table-column>
<el-table-column label="资产状态" align="center" prop="assetStatus" />
<el-table-column label="资产价格" align="center" prop="purchasePrice" />
<el-table-column label="资产数量" align="center" prop="assetQuantity" />
<el-table-column label="购买渠道" align="center" prop="purchaseChannel" />
<el-table-column label="文件来源" align="center" prop="source" />
<el-table-column label="年度" align="center" prop="year" />
<el-table-column label="月份" align="center" prop="period" />
<el-table-column label="借阅状态" align="center" prop="borrowStatus" />
<el-table-column label="纸档位置" align="center" prop="position" />
<el-table-column label="完整性" align="center" prop="cherks" />
<!-- <el-table-column label="归档id" align="center" prop="recordId" /> -->
<el-table-column label="归档状态" align="center" prop="fileStatus" />
<el-table-column
label="创建日期"
align="center"
prop="createTime"
width="180"
>
<template v-slot="scope">
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
<el-table-column label="制单人" align="center" prop="createBy" />
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template v-slot="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['ea:electronic:update']"
>修改</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['ea:electronic:delete']"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<!-- 分页组件 -->
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNo"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 对话框(添加 / 修改) -->
<el-dialog
:title="title"
:visible.sync="open"
width="1000px"
append-to-body
>
<el-form ref="form" :model="form" :rules="rules" label-width="98px">
<!-- <el-form-item label="业务实体id" prop="companyId">
<el-input v-model="form.companyId" placeholder="请输入业务实体id" />
</el-form-item> -->
<el-row>
<el-col :span="8">
<el-form-item label="业务实体名称" prop="company">
<el-input
v-model="form.company"
placeholder="请输入业务实体名称"
/>
</el-form-item>
</el-col>
<!-- <el-form-item label="部门id" prop="deptId">
<el-input v-model="form.deptId" placeholder="请输入部门id" />
</el-form-item> -->
<el-col :span="8">
<el-form-item label="部门名称" prop="deptName">
<el-input v-model="form.deptName" placeholder="请输入部门名称" />
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="资产编号" prop="assetCode">
<el-input v-model="form.assetCode" placeholder="请输入资产编号" />
</el-form-item>
</el-col>
</el-row>
<el-form-item label="资产名称" prop="assetName">
<el-input v-model="form.assetName" placeholder="请输入资产名称" />
</el-form-item>
<el-form-item label="资产描述">
<editor v-model="form.assetDescription" :min-height="192" />
</el-form-item>
<el-row>
<el-col :span="8">
<el-form-item label="资产类型" prop="assetType">
<el-select v-model="form.assetType" placeholder="请选择资产类型">
<el-option label="请选择字典生成" value="" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="购买日期" prop="purchaseDate">
<el-date-picker
clearable
v-model="form.purchaseDate"
type="date"
value-format="yyyy-MM-dd "
placeholder="选择购买日期"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="报废日期" prop="disposalDate">
<el-date-picker
clearable
v-model="form.disposalDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择报废日期"
/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="资产状态" prop="assetStatus">
<el-input
v-model="form.assetStatus"
placeholder="请输入资产状态"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="资产价格" prop="purchasePrice">
<el-input
v-model="form.purchasePrice"
placeholder="请输入资产价格"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="资产数量" prop="assetQuantity">
<el-input
v-model="form.assetQuantity"
placeholder="请输入资产数量"
/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="购买渠道" prop="purchaseChannel">
<el-input
v-model="form.purchaseChannel"
placeholder="请输入购买渠道"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="文件来源" prop="source">
<el-input v-model="form.source" placeholder="请输入文件来源" />
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="年度" prop="year">
<el-date-picker
format="yyyy年"
v-model="form.year"
value-format="yyyy"
type="year"
placeholder="请选择会计年份"
>
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="月份" prop="period">
<el-date-picker
popper-class="due_month"
v-model="form.period"
format="M月"
value-format="M"
type="month"
placeholder="请选择会计月份"
>
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="借阅状态" prop="borrowStatus">
<el-input
v-model="form.borrowStatus"
placeholder="请输入借阅状态"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="纸档位置" prop="position">
<el-input v-model="form.position" placeholder="请输入纸档位置" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="完整性" prop="cherks">
<el-input v-model="form.cherks" placeholder="请输入完整性" />
</el-form-item>
</el-col>
<!-- <el-form-item label="归档id" prop="recordId">
<el-input v-model="form.recordId" placeholder="请输入归档id" />
</el-form-item> -->
<el-col :span="8">
<el-form-item label="归档状态" prop="fileStatus">
<el-input
v-model="form.fileStatus"
placeholder="请输入归档状态"
/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="制单人" prop="createBy">
<el-input v-model="form.createBy" placeholder="请输入制单人" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import {
createElectronicAssets,
updateElectronicAssets,
deleteElectronicAssets,
getElectronicAssets,
getElectronicAssetsPage,
exportElectronicAssetsExcel,
} from "@/api/ea/electronicAssets/assetFile";
import Editor from "@/components/Editor";
export default {
name: "ElectronicAssets",
components: {
Editor,
},
data() {
return {
//
loading: true,
//
exportLoading: false,
//
showSearch: true,
//
total: 0,
//
list: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNo: 1,
pageSize: 10,
companyId: null,
company: null,
deptId: null,
deptName: null,
assetCode: null,
assetName: null,
assetDescription: null,
assetType: null,
purchaseDate: [],
disposalDate: [],
assetStatus: null,
purchasePrice: null,
assetQuantity: null,
purchaseChannel: null,
source: null,
year: null,
period: null,
borrowStatus: null,
position: null,
cherks: null,
recordId: null,
fileStatus: null,
createTime: [],
createBy: null,
},
//
form: {},
//
rules: {},
};
},
created() {
this.getList();
},
methods: {
/** 查询列表 */
getList() {
this.loading = true;
//
getElectronicAssetsPage(this.queryParams).then((response) => {
this.list = response.data.list;
this.total = response.data.total;
this.loading = false;
});
},
/** 取消按钮 */
cancel() {
this.open = false;
this.reset();
},
/** 表单重置 */
reset() {
this.form = {
id: undefined,
companyId: undefined,
company: undefined,
deptId: undefined,
deptName: undefined,
assetCode: undefined,
assetName: undefined,
assetDescription: undefined,
assetType: undefined,
purchaseDate: undefined,
disposalDate: undefined,
assetStatus: undefined,
purchasePrice: undefined,
assetQuantity: undefined,
purchaseChannel: undefined,
source: undefined,
year: undefined,
period: undefined,
borrowStatus: undefined,
position: undefined,
cherks: undefined,
recordId: undefined,
fileStatus: undefined,
createBy: undefined,
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNo = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加资产档案";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id;
getElectronicAssets(id).then((response) => {
this.form = response.data;
this.open = true;
this.title = "修改资产档案";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate((valid) => {
if (!valid) {
return;
}
//
if (this.form.id != null) {
updateElectronicAssets(this.form).then((response) => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
return;
}
//
createElectronicAssets(this.form).then((response) => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
});
},
/** 删除按钮操作 */
handleDelete(row) {
const id = row.id;
this.$modal
.confirm('是否确认删除资产档案编号为"' + id + '"的数据项?')
.then(function () {
return deleteElectronicAssets(id);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
//
let params = { ...this.queryParams };
params.pageNo = undefined;
params.pageSize = undefined;
this.$modal
.confirm("是否确认导出所有资产档案数据项?")
.then(() => {
this.exportLoading = true;
return exportElectronicAssetsExcel(params);
})
.then((response) => {
this.$download.excel(response, "资产档案.xls");
this.exportLoading = false;
})
.catch(() => {});
},
},
};
</script>
Loading…
Cancel
Save