档案检索,档案采集、档案目录,档案上传记录

master
wanglei 2 years ago
parent e49e32ec2a
commit 282c7954aa

@ -229,59 +229,12 @@
</el-dialog>
<!-- 上传记录 -->
<el-dialog title="上传记录" :visible.sync="scjl.open" width="1000px" append-to-body top="6vh">
<el-tabs v-model="scjl.recognize" @tab-click="scjlActiveClick">
<el-tab-pane label="未识别" name="0">
<div v-if="scjl.list.length>0" style="display:flex;justify-content: space-between;margin:10px;">
<el-checkbox v-model="scjl.checkAll" @change="handleCheckAllChange"></el-checkbox>
<el-button icon="el-icon-full-screen" type="primary" @click="OCRRecognition">OCR</el-button>
</div>
<div class="wsb">
<el-checkbox v-for="item in scjl.list" :label="item.picName" :key="item.id" v-model="item.checked" @change="handleCheckChange(item)">
<div class="list">
<el-image
style="width: 120px; height: 120px"
:src="item.picUrl"
:preview-src-list="[item.picUrl]">
</el-image>
<p>{{ item.picName }}</p>
<p>{{ item.muPath }}</p>
<p>{{ item.wlsjPath }}</p>
</div>
</el-checkbox>
</div>
<el-empty :image-size="240" v-if="scjl.list.length===0"></el-empty>
</el-tab-pane>
<el-tab-pane label="已识别" name="1">
<div class="ysb">
<div class="list" v-for="item in scjl.list" :label="item.picName" :key="item.id">
<el-image
style="width: 120px; height: 120px"
:src="item.picUrl"
:preview-src-list="[item.picUrl]">
</el-image>
<p>{{ item.picName }}</p>
<p>{{ item.muPath }}</p>
<p>{{ item.wlsjPath }}</p>
</div>
</div>
<el-empty :image-size="240" v-if="scjl.list.length===0"></el-empty>
</el-tab-pane>
</el-tabs>
</el-dialog>
</div>
</template>
<script>
import { listCatalog, getCatalog, delCatalog, addCatalog, updateCatalog } from "@/api/dangan/catalog";
import { listPictureRecard } from "@/api/dangan/pictureRecard";
import { listAreaSort } from "@/api/dangan/areaSort";
import { collectRecongnize } from "@/api/dangan/collection";
import Treeselect from "@riophae/vue-treeselect";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
@ -347,16 +300,7 @@ export default {
areaType: 2,
pid: null,
}
},
//
scjl:{
open: false,
checkAll: false,
list: [],
// ID
muId: null,
recognize: '0'
},
}
};
},
created() {
@ -489,6 +433,10 @@ export default {
handleDACJ(row){
this.$router.push("/collection?id=" + row.id);
},
//
handleSCJL(row){
this.$router.push("/pictureRecard?muId=" + row.id);
},
//
selectPid(){
this.form.ywType = undefined;
@ -537,74 +485,16 @@ export default {
this.form.muName = row.muName;
this.xzcsq.open = false;
},
//
handleSCJL(row){
this.scjl.list = [];
this.scjl.open = true;
this.scjl.muId = row.id;
this.scjl.recognize = '0';
this.getPictureRecard();
},
//
getPictureRecard(){
listPictureRecard({
pageNum: 1,
pageSize: 1000000000,
muId: this.scjl.muId,
recognize: this.scjl.recognize,
}).then(response => {
this.scjl.list = response.rows;
});
},
//
scjlActiveClick(tab){
this.scjl.recognize = tab.name;
this.scjl.list = [];
this.getPictureRecard();
},
//
handleCheckAllChange(val) {
this.scjl.list.forEach(item =>{
item['checked']= val
})
this.scjl.list = [...this.scjl.list]
},
//
handleCheckChange(val) {
let checkAll = true
this.scjl.list.forEach(item=>{
if(!item['checked']){
checkAll = false
}
})
this.scjl.list = [...this.scjl.list]
this.scjl.checkAll = checkAll
},
// OCR
OCRRecognition(){
let arr = [];
this.scjl.list.forEach(item => {
if(item.checked){
arr.push(item)
}
})
if(arr.length>0){
collectRecongnize(arr).then(response => {
this.scjl.list = [];
this.$modal.msgSuccess("操作成功");
this.getPictureRecard();
});
//
handleDAXX(row){
if(row.ywType==='0'|| row.ywType==='1'|| row.ywType==='2'){
this.$router.push("/dangan/czrkdj?muId=" + row.id);
}else {
this.$alert(`请先选择需要识别的档案`, `提示`, {
this.$alert(`暂无相关页面!`, `提示`, {
type: 'warning'
});
}
},
//
handleDAXX(row){
this.$router.push("/dangan/czrkdj?muId=" + row.id);
},
}
};
</script>

@ -44,8 +44,8 @@
<div v-if="pictureRecard.length>0">
<div style="margin-bottom: 20px;">
<el-checkbox v-model="isYiZu">[OCR2]</el-checkbox>
<el-checkbox v-model="isSuangMian"></el-checkbox>
<el-checkbox v-model="isYiZu">[OCR2]</el-checkbox>
<el-checkbox v-model="isSuangMian"></el-checkbox>
</div>
<el-checkbox v-model="checkAll" @change="handleCheckAllChange"></el-checkbox>

@ -1,18 +1,26 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="图片名称" prop="picName">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="档案目录ID" prop="muId">
<el-input
v-model="queryParams.picName"
placeholder="请输入图片名称"
v-model="queryParams.muId"
placeholder="请输入档案目录ID"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="档案目录路径" prop="muPath">
<el-input
v-model="queryParams.muPath"
placeholder="请输入档案目录路径"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="图片路径" prop="picUrl">
<el-form-item label="图片名称" prop="picName">
<el-input
v-model="queryParams.picUrl"
placeholder="请输入图片路径"
v-model="queryParams.picName"
placeholder="请输入图片名称"
clearable
@keyup.enter.native="handleQuery"
/>
@ -33,30 +41,22 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="档案目录ID" prop="muId">
<el-input
v-model="queryParams.muId"
placeholder="请输入档案目录ID"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="档案目录路径" prop="muPath">
<el-input
v-model="queryParams.muPath"
placeholder="请输入档案目录路径"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="是否已经识别" prop="recognize">
<el-input
<el-select
v-model="queryParams.recognize"
placeholder="请输入是否已经识别"
placeholder="是否已经识别"
clearable
@keyup.enter.native="handleQuery"
style="width:100%"
>
<el-option
v-for="dict in dict.type.recognize"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
@ -64,28 +64,7 @@
</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="['dangan:pictureRecard:add']"
>新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['dangan:pictureRecard:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-col :span="2">
<el-button
type="danger"
plain
@ -96,39 +75,33 @@
v-hasPermi="['dangan:pictureRecard:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['dangan:pictureRecard:export']"
>导出</el-button>
<el-col :span="22" style="display: flex; align-items: center; justify-content: end">
<el-checkbox v-model="isSuangMian" style="margin-right: 10px;"></el-checkbox>
<el-button icon="el-icon-full-screen" type="primary" @click="OCRRecognition">OCR</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="pictureRecardList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="上传时间" align="center" prop="createTime" />
<el-table-column label="图片名称" align="center" prop="picName" />
<el-table-column label="图片路径" align="center" prop="picUrl" />
<el-table v-loading="loading" :data="pictureRecardList" @selection-change="handleSelectionChange" border>
<el-table-column type="selection" width="50" align="center" fixed/>
<el-table-column label="档案目录ID" align="center" prop="muId" fixed min-width="50"/>
<el-table-column label="档案目录路径" align="center" prop="muPath" fixed min-width="100" show-overflow-tooltip/>
<el-table-column label="物理书架ID" align="center" prop="wlsjId" />
<el-table-column label="物理书架路径" align="center" prop="wlsjPath" />
<el-table-column label="档案目录ID" align="center" prop="muId" />
<el-table-column label="档案目录路径" align="center" prop="muPath" />
<el-table-column label="是否已经识别" align="center" prop="recognize" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="物理书架路径" align="center" prop="wlsjPath" min-width="100" show-overflow-tooltip/>
<el-table-column label="是否已经识别" align="center" prop="recognize" >
<template slot-scope="scope">
<dict-tag :options="dict.type.recognize" :value="scope.row.recognize"/>
</template>
</el-table-column>
<el-table-column label="上传时间" align="center" prop="createTime" />
<el-table-column label="图片名称" align="center" prop="picName" min-width="100" show-overflow-tooltip/>
<el-table-column label="图片路径" align="center" prop="picUrl">
<template slot-scope="scope">
<image-preview :src="scope.row.picUrl" :width="50" :height="50"/>
</template>
</el-table-column>
<!-- <el-table-column label="备注" align="center" prop="remark" />-->
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['dangan:pictureRecard:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
@ -148,47 +121,21 @@
@pagination="getList"
/>
<!-- 添加或修改档案图片信息记录对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="图片名称" prop="picName">
<el-input v-model="form.picName" placeholder="请输入图片名称" />
</el-form-item>
<el-form-item label="图片路径" prop="picUrl">
<el-input v-model="form.picUrl" placeholder="请输入图片路径" />
</el-form-item>
<el-form-item label="物理书架ID" prop="wlsjId">
<el-input v-model="form.wlsjId" placeholder="请输入物理书架ID" />
</el-form-item>
<el-form-item label="物理书架路径" prop="wlsjPath">
<el-input v-model="form.wlsjPath" placeholder="请输入物理书架路径" />
</el-form-item>
<el-form-item label="档案目录ID" prop="muId">
<el-input v-model="form.muId" placeholder="请输入档案目录ID" />
</el-form-item>
<el-form-item label="档案目录路径" prop="muPath">
<el-input v-model="form.muPath" placeholder="请输入档案目录路径" />
</el-form-item>
<el-form-item label="是否已经识别" prop="recognize">
<el-input v-model="form.recognize" placeholder="请输入是否已经识别" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
<div class="myProgress" v-show="openProgress">
<el-progress type="circle" :percentage="percentage"></el-progress>
<div style="margin-top:20px;">拼命识别中...</div>
</div>
</el-dialog>
</div>
</template>
<script>
import { listPictureRecard, getPictureRecard, delPictureRecard, addPictureRecard, updatePictureRecard } from "@/api/dangan/pictureRecard";
import { listPictureRecard, delPictureRecard } from "@/api/dangan/pictureRecard";
import { collectRecongnize, collectProgress, collectRecongnizeZu } from "@/api/dangan/collection";
export default {
name: "PictureRecard",
dicts: ['recognize'],
data() {
return {
//
@ -205,10 +152,6 @@ export default {
total: 0,
//
pictureRecardList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
@ -221,20 +164,16 @@ export default {
muPath: null,
recognize: null,
},
//
form: {},
//
rules: {
picName: [
{ required: true, message: "图片名称不能为空", trigger: "blur" }
],
picUrl: [
{ required: true, message: "图片路径不能为空", trigger: "blur" }
],
}
percentage: 0,
openProgress: false,
//
isSuangMian: false,
//
selectionList: []
};
},
created() {
this.queryParams.muId = this.$route.query.muId || undefined
this.getList();
},
methods: {
@ -247,30 +186,6 @@ export default {
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
picName: null,
picUrl: null,
wlsjId: null,
wlsjPath: null,
muId: null,
muPath: null,
recognize: null,
remark: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
@ -283,46 +198,11 @@ export default {
},
//
handleSelectionChange(selection) {
this.selectionList = selection;
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加档案图片信息记录";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids
getPictureRecard(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改档案图片信息记录";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.id != null) {
updatePictureRecard(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addPictureRecard(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
@ -333,12 +213,51 @@ export default {
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('dangan/pictureRecard/export', {
...this.queryParams
}, `pictureRecard_${new Date().getTime()}.xlsx`)
// OCR
OCRRecognition(){
let arr = [];
let singeOrDouble = 0
if(this.isSuangMian){
singeOrDouble = 1
}
this.selectionList.forEach(item => {
item.singeOrDouble = singeOrDouble
arr.push(item);
})
if(arr.length>0){
collectRecongnize(arr).then(response => {
this.selectionList = [];
this.$modal.msgSuccess("操作成功");
this.getList();
});
}else {
this.$alert(`请先选择需要识别的档案!`, `提示`, {
type: 'warning'
});
}
},
/** 查询目录列表 */
getProgress() {
collectProgress().then(response => {
this.percentage = response*100;
});
},
}
};
</script>
<style lang="scss">
.myProgress{
position: absolute;
top:0;
left:0;
width: 100%;
height: 100%;
background: rgba(255,255,255,0.8);
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
font-size: 20px;
}
</style>

@ -6,12 +6,9 @@
<el-button style="height:50px;font-size: 14px;" type="primary" icon="el-icon-search" @click="handleQuery"></el-button>
</div>
<el-checkbox-group v-model="checkList">
<el-checkbox :label="0">常住人口登记表</el-checkbox>
<el-checkbox :label="1">出生登记</el-checkbox>
<el-checkbox :label="2">户口迁移</el-checkbox>
<el-checkbox :label="3">变更更正</el-checkbox>
<el-checkbox :label="4">编码表</el-checkbox>
<el-checkbox :label="5">其它</el-checkbox>
<el-checkbox v-for="dict in dict.type.yw_type"
:key="dict.value"
:label="dict.value">{{ dict.label }}</el-checkbox>
</el-checkbox-group>
</div>
@ -323,6 +320,7 @@ import { listCzrkdj } from "@/api/dangan/czrkdj";
export default {
name: "Retrieval",
dicts: ['yw_type'],
data() {
return {
//
@ -398,7 +396,7 @@ export default {
},
methods: {
handleQuery(){
if(this.checkList.indexOf(0) !== -1){
if(this.checkList.indexOf('0') !== -1){
this.czrkdj.open = true
this.czrkdj.qParams.name = this.keyword
this.czrkdjQuery();
@ -408,7 +406,7 @@ export default {
this.czrkdj.total = 0;
}
if(this.checkList.indexOf(1) !== -1){
if(this.checkList.indexOf('1') !== -1){
this.csdj.open = true
this.csdj.qParams.name = this.keyword
// this.csdjQuery();
@ -418,7 +416,7 @@ export default {
this.csdj.total = 0;
}
if(this.checkList.indexOf(2) !== -1){
if(this.checkList.indexOf('2') !== -1){
this.hkqy.open = true
this.hkqy.qParams.name = this.keyword
// this.hkqyQuery();
@ -428,7 +426,7 @@ export default {
this.hkqy.total = 0;
}
if(this.checkList.indexOf(3) !== -1){
if(this.checkList.indexOf('3') !== -1){
this.bggz.open = true
this.bggz.qParams.name = this.keyword
// this.bggzQuery();
@ -438,7 +436,7 @@ export default {
this.bggz.total = 0;
}
if(this.checkList.indexOf(4) !== -1){
if(this.checkList.indexOf('4') !== -1){
this.bmb.open = true
this.bmb.qParams.name = this.keyword
// this.bmbQuery();
@ -448,7 +446,7 @@ export default {
this.bmb.total = 0;
}
if(this.checkList.indexOf(5) !== -1){
if(this.checkList.indexOf('5') !== -1){
this.qt.open = true
this.qt.qParams.name = this.keyword
// this.qtQuery();
@ -528,6 +526,10 @@ export default {
height: 20px;
}
::v-deep .el-checkbox{
margin-bottom: 15px;
}
::v-deep .el-checkbox__inner::after {
height: 10px;
left: 7px;

@ -6,12 +6,9 @@
<el-button style="height:50px;font-size: 14px;" type="primary" icon="el-icon-search" @click="handleQuery"></el-button>
</div>
<el-checkbox-group v-model="checkList">
<el-checkbox :label="0">常住人口登记表</el-checkbox>
<el-checkbox :label="1">出生登记</el-checkbox>
<el-checkbox :label="2">户口迁移</el-checkbox>
<el-checkbox :label="3">变更更正</el-checkbox>
<el-checkbox :label="4">编码表</el-checkbox>
<el-checkbox :label="5">其它</el-checkbox>
<el-checkbox v-for="dict in dict.type.yw_type"
:key="dict.value"
:label="dict.value">{{ dict.label }}</el-checkbox>
</el-checkbox-group>
</div>
@ -323,6 +320,7 @@ import { listCzrkdj } from "@/api/dangan/czrkdj";
export default {
name: "Retrieval",
dicts: ['yw_type'],
data() {
return {
//
@ -398,7 +396,7 @@ export default {
},
methods: {
handleQuery(){
if(this.checkList.indexOf(0) !== -1){
if(this.checkList.indexOf('0') !== -1){
this.czrkdj.open = true
this.czrkdj.qParams.name = this.keyword
this.czrkdjQuery();
@ -408,7 +406,7 @@ export default {
this.czrkdj.total = 0;
}
if(this.checkList.indexOf(1) !== -1){
if(this.checkList.indexOf('1') !== -1){
this.csdj.open = true
this.csdj.qParams.name = this.keyword
// this.csdjQuery();
@ -418,7 +416,7 @@ export default {
this.csdj.total = 0;
}
if(this.checkList.indexOf(2) !== -1){
if(this.checkList.indexOf('2') !== -1){
this.hkqy.open = true
this.hkqy.qParams.name = this.keyword
// this.hkqyQuery();
@ -428,7 +426,7 @@ export default {
this.hkqy.total = 0;
}
if(this.checkList.indexOf(3) !== -1){
if(this.checkList.indexOf('3') !== -1){
this.bggz.open = true
this.bggz.qParams.name = this.keyword
// this.bggzQuery();
@ -438,7 +436,7 @@ export default {
this.bggz.total = 0;
}
if(this.checkList.indexOf(4) !== -1){
if(this.checkList.indexOf('4') !== -1){
this.bmb.open = true
this.bmb.qParams.name = this.keyword
// this.bmbQuery();
@ -448,7 +446,7 @@ export default {
this.bmb.total = 0;
}
if(this.checkList.indexOf(5) !== -1){
if(this.checkList.indexOf('5') !== -1){
this.qt.open = true
this.qt.qParams.name = this.keyword
// this.qtQuery();
@ -528,6 +526,10 @@ export default {
height: 20px;
}
::v-deep .el-checkbox{
margin-bottom: 15px;
}
::v-deep .el-checkbox__inner::after {
height: 10px;
left: 7px;

Loading…
Cancel
Save