客户新增需求,添加图片全文识别单、双面功能

master
hshansha 8 months ago
parent 346c064c43
commit 2296d6ddad

@ -29,7 +29,7 @@
## 在线体验
- admin/huawei12#$/Huawei12#$ sysAdmin/123456
- admin/huawei12#$Huawei12#$ sysAdmin/123456
#影源扫描仪 授权码V4tMKPYgFtW8vQr4C0s4/g==
测试临时码D+1WT4eWDqLseG5433yq9w==

@ -2,6 +2,7 @@
<configuration>
<!-- 日志存放路径 -->
<property name="log.path" value="/home/ruoyi/logs" />
<!--腾讯云用 <property name="log.path" value="/www/wwwroot/dangan/" />-->
<!-- 日志输出格式 -->
<!--<property name="log.pattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n" />-->
<property name="log.pattern" value="%d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n" />

@ -0,0 +1,98 @@
package com.da.dangan.controller;
import com.da.common.annotation.Log;
import com.da.common.core.controller.BaseController;
import com.da.common.core.domain.AjaxResult;
import com.da.common.core.page.TableDataInfo;
import com.da.common.enums.BusinessType;
import com.da.common.utils.poi.ExcelUtil;
import com.da.dangan.domain.DaQuanwen;
import com.da.dangan.service.IDaQuanwenService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
/**
* Controller
*
* @author ruoyi
* @date 2025-04-25
*/
@RestController
@RequestMapping("/dangan/quanwen")
public class DaQuanwenController extends BaseController
{
@Autowired
private IDaQuanwenService daQuanwenService;
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:list')")
@GetMapping("/list")
public TableDataInfo list(DaQuanwen daQuanwen)
{
startPage();
List<DaQuanwen> list = daQuanwenService.selectDaQuanwenList(daQuanwen);
return getDataTable(list);
}
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:export')")
@Log(title = "全文识别", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, DaQuanwen daQuanwen)
{
List<DaQuanwen> list = daQuanwenService.selectDaQuanwenList(daQuanwen);
ExcelUtil<DaQuanwen> util = new ExcelUtil<DaQuanwen>(DaQuanwen.class);
util.exportExcel(response, list, "全文识别数据");
}
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id)
{
return success(daQuanwenService.selectDaQuanwenById(id));
}
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:add')")
@Log(title = "全文识别", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody DaQuanwen daQuanwen)
{
return toAjax(daQuanwenService.insertDaQuanwen(daQuanwen));
}
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:edit')")
@Log(title = "全文识别", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody DaQuanwen daQuanwen)
{
return toAjax(daQuanwenService.updateDaQuanwen(daQuanwen));
}
/**
*
*/
@PreAuthorize("@ss.hasPermi('dangan:quanwen:remove')")
@Log(title = "全文识别", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(daQuanwenService.deleteDaQuanwenByIds(ids));
}
}

@ -17,6 +17,10 @@ public class DaCzrkdj extends BaseEntity {
/** id */
private Long id;
/** 全文识别内容 */
@Excel(name = "全文识别内容")
private String allInfo;
/** 任务id */
@Excel(name = "任务id")
private Long taskId;
@ -263,6 +267,14 @@ public class DaCzrkdj extends BaseEntity {
*/
private String flag;
public String getAllInfo() {
return allInfo;
}
public void setAllInfo(String allInfo) {
this.allInfo = allInfo;
}
public String getNameP() {
return nameP;
}
@ -809,6 +821,7 @@ public class DaCzrkdj extends BaseEntity {
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("allInfo", getAllInfo())
.append("taskId", getTaskId())
.append("ywType", getYwType())
.append("muId", getMuId())

@ -0,0 +1,238 @@
package com.da.dangan.domain;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.da.common.annotation.Excel;
import com.da.common.core.domain.BaseEntity;
/**
* da_quanwen
*
* @author ruoyi
* @date 2025-04-25
*/
public class DaQuanwen extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** id */
private Long id;
/** 全文识别内容 */
@Excel(name = "全文识别内容")
private String allInfo;
/** 任务id */
@Excel(name = "任务id")
private Long taskId;
/** 业务类型(字典) */
@Excel(name = "业务类型(字典)")
private String ywType;
/** 目录id */
@Excel(name = "目录id")
private Long muId;
/** 档案目录路径 */
@Excel(name = "档案目录路径")
private String muPath;
/** 识别图片id */
@Excel(name = "识别图片id")
private String picIds;
/** 识别图片 */
@Excel(name = "识别图片")
private String pictures;
/** 相关图片id */
@Excel(name = "相关图片id")
private String allPicIds;
/** 相关图片 */
@Excel(name = "相关图片")
private String allPics;
/** 是否纠错(字典0否1是) */
@Excel(name = "是否纠错(字典0否1是)")
private String errorCorrect;
/** 审核状态(字典) */
@Excel(name = "审核状态(字典)")
private String auditStatus;
/** 审核人 */
@Excel(name = "审核人")
private String auditName;
/** 审核结果 */
@Excel(name = "审核结果")
private String auditResult;
/** 审核原由 */
@Excel(name = "审核原由")
private String auditReason;
public void setId(Long id)
{
this.id = id;
}
public Long getId()
{
return id;
}
public void setAllInfo(String allInfo)
{
this.allInfo = allInfo;
}
public String getAllInfo()
{
return allInfo;
}
public void setTaskId(Long taskId)
{
this.taskId = taskId;
}
public Long getTaskId()
{
return taskId;
}
public void setYwType(String ywType)
{
this.ywType = ywType;
}
public String getYwType()
{
return ywType;
}
public void setMuId(Long muId)
{
this.muId = muId;
}
public Long getMuId()
{
return muId;
}
public void setMuPath(String muPath)
{
this.muPath = muPath;
}
public String getMuPath()
{
return muPath;
}
public void setPicIds(String picIds)
{
this.picIds = picIds;
}
public String getPicIds()
{
return picIds;
}
public void setPictures(String pictures)
{
this.pictures = pictures;
}
public String getPictures()
{
return pictures;
}
public void setAllPicIds(String allPicIds)
{
this.allPicIds = allPicIds;
}
public String getAllPicIds()
{
return allPicIds;
}
public void setAllPics(String allPics)
{
this.allPics = allPics;
}
public String getAllPics()
{
return allPics;
}
public void setErrorCorrect(String errorCorrect)
{
this.errorCorrect = errorCorrect;
}
public String getErrorCorrect()
{
return errorCorrect;
}
public void setAuditStatus(String auditStatus)
{
this.auditStatus = auditStatus;
}
public String getAuditStatus()
{
return auditStatus;
}
public void setAuditName(String auditName)
{
this.auditName = auditName;
}
public String getAuditName()
{
return auditName;
}
public void setAuditResult(String auditResult)
{
this.auditResult = auditResult;
}
public String getAuditResult()
{
return auditResult;
}
public void setAuditReason(String auditReason)
{
this.auditReason = auditReason;
}
public String getAuditReason()
{
return auditReason;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("allInfo", getAllInfo())
.append("taskId", getTaskId())
.append("ywType", getYwType())
.append("muId", getMuId())
.append("muPath", getMuPath())
.append("picIds", getPicIds())
.append("pictures", getPictures())
.append("allPicIds", getAllPicIds())
.append("allPics", getAllPics())
.append("errorCorrect", getErrorCorrect())
.append("auditStatus", getAuditStatus())
.append("auditName", getAuditName())
.append("auditResult", getAuditResult())
.append("auditReason", getAuditReason())
.append("remark", getRemark())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
}

@ -0,0 +1,27 @@
package com.da.dangan.domain.vo;
import com.da.dangan.domain.DaQuanwen;
import java.util.List;
public class QwDatas {
private static final long serialVersionUID = 1L;
private List<Long> Picid;
private List<DaQuanwen> info;
public List<Long> getPicid() {
return Picid;
}
public void setPicid(List<Long> picid) {
Picid = picid;
}
public List<DaQuanwen> getInfo() {
return info;
}
public void setInfo(List<DaQuanwen> info) {
this.info = info;
}
}

@ -0,0 +1,62 @@
package com.da.dangan.mapper;
import com.da.dangan.domain.DaQuanwen;
import java.util.List;
/**
* Mapper
*
* @author ruoyi
* @date 2025-04-25
*/
public interface DaQuanwenMapper
{
/**
*
*
* @param id
* @return
*/
public DaQuanwen selectDaQuanwenById(Long id);
/**
*
*
* @param daQuanwen
* @return
*/
public List<DaQuanwen> selectDaQuanwenList(DaQuanwen daQuanwen);
/**
*
*
* @param daQuanwen
* @return
*/
public int insertDaQuanwen(DaQuanwen daQuanwen);
/**
*
*
* @param daQuanwen
* @return
*/
public int updateDaQuanwen(DaQuanwen daQuanwen);
/**
*
*
* @param id
* @return
*/
public int deleteDaQuanwenById(Long id);
/**
*
*
* @param ids
* @return
*/
public int deleteDaQuanwenByIds(Long[] ids);
}

@ -0,0 +1,62 @@
package com.da.dangan.service;
import com.da.dangan.domain.DaQuanwen;
import java.util.List;
/**
* Service
*
* @author ruoyi
* @date 2025-04-25
*/
public interface IDaQuanwenService
{
/**
*
*
* @param id
* @return
*/
public DaQuanwen selectDaQuanwenById(Long id);
/**
*
*
* @param daQuanwen
* @return
*/
public List<DaQuanwen> selectDaQuanwenList(DaQuanwen daQuanwen);
/**
*
*
* @param daQuanwen
* @return
*/
public int insertDaQuanwen(DaQuanwen daQuanwen);
/**
*
*
* @param daQuanwen
* @return
*/
public int updateDaQuanwen(DaQuanwen daQuanwen);
/**
*
*
* @param ids
* @return
*/
public int deleteDaQuanwenByIds(Long[] ids);
/**
*
*
* @param id
* @return
*/
public int deleteDaQuanwenById(Long id);
}

@ -0,0 +1,97 @@
package com.da.dangan.service.impl;
import com.da.common.utils.DateUtils;
import com.da.dangan.domain.DaQuanwen;
import com.da.dangan.mapper.DaQuanwenMapper;
import com.da.dangan.service.IDaQuanwenService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
/**
* Service
*
* @author ruoyi
* @date 2025-04-25
*/
@Service
public class DaQuanwenServiceImpl implements IDaQuanwenService
{
@Resource
private DaQuanwenMapper daQuanwenMapper;
/**
*
*
* @param id
* @return
*/
@Override
public DaQuanwen selectDaQuanwenById(Long id)
{
return daQuanwenMapper.selectDaQuanwenById(id);
}
/**
*
*
* @param daQuanwen
* @return
*/
@Override
public List<DaQuanwen> selectDaQuanwenList(DaQuanwen daQuanwen)
{
return daQuanwenMapper.selectDaQuanwenList(daQuanwen);
}
/**
*
*
* @param daQuanwen
* @return
*/
@Override
public int insertDaQuanwen(DaQuanwen daQuanwen)
{
daQuanwen.setCreateTime(DateUtils.getNowDate());
return daQuanwenMapper.insertDaQuanwen(daQuanwen);
}
/**
*
*
* @param daQuanwen
* @return
*/
@Override
public int updateDaQuanwen(DaQuanwen daQuanwen)
{
daQuanwen.setUpdateTime(DateUtils.getNowDate());
return daQuanwenMapper.updateDaQuanwen(daQuanwen);
}
/**
*
*
* @param ids
* @return
*/
@Override
public int deleteDaQuanwenByIds(Long[] ids)
{
return daQuanwenMapper.deleteDaQuanwenByIds(ids);
}
/**
*
*
* @param id
* @return
*/
@Override
public int deleteDaQuanwenById(Long id)
{
return daQuanwenMapper.deleteDaQuanwenById(id);
}
}

@ -33,6 +33,8 @@ import java.util.stream.Stream;
*/
@Component("timeTask")
public class TimeTask {
@Autowired
private IDaQuanwenService daQuanwenService;
@Autowired
private IDaTaskService daTaskService;
@Autowired
@ -146,6 +148,8 @@ public class TimeTask {
case "option3": //常住人口登记表2
//break;
case "option9": //常住人口登记表3
//break;
case "option11": //常住人口登记表1——全文识别的情况 字段all_info存储所有是被信息
//获取常住人口信息集合
List<CzrkDatas> czrkDatas = JSONArray.parseArray(datas, CzrkDatas.class);
for (CzrkDatas czrkData : czrkDatas) {
@ -356,6 +360,41 @@ public class TimeTask {
}
}
break;
case "option12":
//获取准迁证信息集合
List<QwDatas> qwDatas = JSONArray.parseArray(datas, QwDatas.class);
for (QwDatas qwData : qwDatas) {
List<Long> picids = qwData.getPicid();
String picIds = StringUtils.join(picids, ",");//逗号分割
//根据picIds查找对应的图片记录
List<DaPicturesRecard> picRecards = daPicturesRecardService.selectDaPicturesRecardByIds(picids.toArray(new Long[picids.size()]));
List<String> picUrls = picRecards.stream()
.map(DaPicturesRecard::getPicUrl).collect(Collectors.toList());
String pictures = StringUtils.join(picUrls, ",");//逗号分割
List<DaQuanwen> info = qwData.getInfo();
if (info != null && info.size() > 0) {
for (DaQuanwen qw : info) {
//判断返回结果是否都是字符串 "无"
/*if(CallThirdInterface.allFieldsEqualTo(zqz,"无")){
continue;
}*/
qw.setAllPicIds(picIds);
qw.setAllPics(pictures);
qw.setPicIds(picIds);
qw.setPictures(pictures);
//其他字段存储
qw.setYwType(ywType);
qw.setMuId(muId);
qw.setMuPath(muPath);
qw.setAuditStatus("0");
qw.setErrorCorrect("0");
qw.setTaskId(datask.getId());
daQuanwenService.insertDaQuanwen(qw);
}
}
}
break;
}
}
} else { //=3或者其他值第三方服务崩溃或者其他异常---任务丢失

@ -5,6 +5,7 @@
<mapper namespace="com.da.dangan.mapper.DaCzrkdjMapper">
<resultMap type="DaCzrkdj" id="DaCzrkdjResult">
<result property="id" column="id"/>
<result property="allInfo" column="all_info" />
<result property="taskId" column="task_id"/>
<result property="ywType" column="yw_type"/>
<result property="muId" column="mu_id"/>
@ -67,7 +68,7 @@
</resultMap>
<sql id="selectDaCzrkdjVo">
select id, task_id, yw_type, mu_id, mu_path, relation, name, other_name, used_name, sex, jhr1, jhgx1, jhr2, jhgx2, gmcszqfrq, birthday, address, yj, nation, zjxy, whcd, hyzk, zyjfwcs, bxsqtzz, gmzdhhmqfjgjrq, hsyhdqlbxshsdjhk, hsybxshcqlhsdjhk, hshyqwhd, zxhkrq, zxhkyy, hkdjsxbgjznrsjjblrz1, hkdjsxbgjznrsjjblrz2, jiguan, xzz, hz_name, hb, djrq, byzk, height, blood, zy, sl_reason, sljmsfzqm, qfyj, yxrq, card_id, pic_ids, pictures, all_pic_ids, all_pics, error_correct, audit_status, audit_name, audit_result, audit_reason, remark, create_by, create_time, update_by, update_time from da_czrkdj
select id, all_info, task_id, yw_type, mu_id, mu_path, relation, name, other_name, used_name, sex, jhr1, jhgx1, jhr2, jhgx2, gmcszqfrq, birthday, address, yj, nation, zjxy, whcd, hyzk, zyjfwcs, bxsqtzz, gmzdhhmqfjgjrq, hsyhdqlbxshsdjhk, hsybxshcqlhsdjhk, hshyqwhd, zxhkrq, zxhkyy, hkdjsxbgjznrsjjblrz1, hkdjsxbgjznrsjjblrz2, jiguan, xzz, hz_name, hb, djrq, byzk, height, blood, zy, sl_reason, sljmsfzqm, qfyj, yxrq, card_id, pic_ids, pictures, all_pic_ids, all_pics, error_correct, audit_status, audit_name, audit_result, audit_reason, remark, create_by, create_time, update_by, update_time from da_czrkdj
</sql>
<select id="selectDaCzrkdjList" parameterType="DaCzrkdj" resultMap="DaCzrkdjResult">
@ -247,6 +248,7 @@
<insert id="insertDaCzrkdj" parameterType="DaCzrkdj" useGeneratedKeys="true" keyProperty="id">
insert into da_czrkdj
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="allInfo != null">all_info,</if>
<if test="taskId != null">task_id,</if>
<if test="ywType != null">yw_type,</if>
<if test="muId != null">mu_id,</if>
@ -308,6 +310,7 @@
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="allInfo != null">#{allInfo},</if>
<if test="taskId != null">#{taskId},</if>
<if test="ywType != null">#{ywType},</if>
<if test="muId != null">#{muId},</if>
@ -374,6 +377,7 @@
<update id="updateDaCzrkdj" parameterType="DaCzrkdj">
update da_czrkdj
<trim prefix="SET" suffixOverrides=",">
<if test="allInfo != null">all_info = #{allInfo},</if>
<if test="taskId != null">task_id = #{taskId},</if>
<if test="ywType != null">yw_type = #{ywType},</if>
<if test="muId != null">mu_id = #{muId},</if>

@ -0,0 +1,141 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.da.dangan.mapper.DaQuanwenMapper">
<resultMap type="DaQuanwen" id="DaQuanwenResult">
<result property="id" column="id" />
<result property="allInfo" column="all_info" />
<result property="taskId" column="task_id" />
<result property="ywType" column="yw_type" />
<result property="muId" column="mu_id" />
<result property="muPath" column="mu_path" />
<result property="picIds" column="pic_ids" />
<result property="pictures" column="pictures" />
<result property="allPicIds" column="all_pic_ids" />
<result property="allPics" column="all_pics" />
<result property="errorCorrect" column="error_correct" />
<result property="auditStatus" column="audit_status" />
<result property="auditName" column="audit_name" />
<result property="auditResult" column="audit_result" />
<result property="auditReason" column="audit_reason" />
<result property="remark" column="remark" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectDaQuanwenVo">
select id, all_info, task_id, yw_type, mu_id, mu_path, pic_ids, pictures, all_pic_ids, all_pics, error_correct, audit_status, audit_name, audit_result, audit_reason, remark, create_by, create_time, update_by, update_time from da_quanwen
</sql>
<select id="selectDaQuanwenList" parameterType="DaQuanwen" resultMap="DaQuanwenResult">
<include refid="selectDaQuanwenVo"/>
<where>
<if test="allInfo != null and allInfo != ''"> and all_info = #{allInfo}</if>
<if test="taskId != null "> and task_id = #{taskId}</if>
<if test="ywType != null and ywType != ''"> and yw_type = #{ywType}</if>
<if test="muId != null "> and mu_id = #{muId}</if>
<if test="muPath != null and muPath != ''"> and mu_path = #{muPath}</if>
<if test="picIds != null and picIds != ''"> and pic_ids = #{picIds}</if>
<if test="pictures != null and pictures != ''"> and pictures = #{pictures}</if>
<if test="allPicIds != null and allPicIds != ''"> and all_pic_ids = #{allPicIds}</if>
<if test="allPics != null and allPics != ''"> and all_pics = #{allPics}</if>
<if test="errorCorrect != null and errorCorrect != ''"> and error_correct = #{errorCorrect}</if>
<if test="auditStatus != null and auditStatus != ''"> and audit_status = #{auditStatus}</if>
<if test="auditName != null and auditName != ''"> and audit_name like concat('%', #{auditName}, '%')</if>
<if test="auditResult != null and auditResult != ''"> and audit_result = #{auditResult}</if>
<if test="auditReason != null and auditReason != ''"> and audit_reason = #{auditReason}</if>
</where>
</select>
<select id="selectDaQuanwenById" parameterType="Long" resultMap="DaQuanwenResult">
<include refid="selectDaQuanwenVo"/>
where id = #{id}
</select>
<insert id="insertDaQuanwen" parameterType="DaQuanwen" useGeneratedKeys="true" keyProperty="id">
insert into da_quanwen
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="allInfo != null">all_info,</if>
<if test="taskId != null">task_id,</if>
<if test="ywType != null and ywType != ''">yw_type,</if>
<if test="muId != null">mu_id,</if>
<if test="muPath != null">mu_path,</if>
<if test="picIds != null">pic_ids,</if>
<if test="pictures != null">pictures,</if>
<if test="allPicIds != null">all_pic_ids,</if>
<if test="allPics != null">all_pics,</if>
<if test="errorCorrect != null">error_correct,</if>
<if test="auditStatus != null">audit_status,</if>
<if test="auditName != null">audit_name,</if>
<if test="auditResult != null">audit_result,</if>
<if test="auditReason != null">audit_reason,</if>
<if test="remark != null">remark,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="allInfo != null">#{allInfo},</if>
<if test="taskId != null">#{taskId},</if>
<if test="ywType != null and ywType != ''">#{ywType},</if>
<if test="muId != null">#{muId},</if>
<if test="muPath != null">#{muPath},</if>
<if test="picIds != null">#{picIds},</if>
<if test="pictures != null">#{pictures},</if>
<if test="allPicIds != null">#{allPicIds},</if>
<if test="allPics != null">#{allPics},</if>
<if test="errorCorrect != null">#{errorCorrect},</if>
<if test="auditStatus != null">#{auditStatus},</if>
<if test="auditName != null">#{auditName},</if>
<if test="auditResult != null">#{auditResult},</if>
<if test="auditReason != null">#{auditReason},</if>
<if test="remark != null">#{remark},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateDaQuanwen" parameterType="DaQuanwen">
update da_quanwen
<trim prefix="SET" suffixOverrides=",">
<if test="allInfo != null">all_info = #{allInfo},</if>
<if test="taskId != null">task_id = #{taskId},</if>
<if test="ywType != null and ywType != ''">yw_type = #{ywType},</if>
<if test="muId != null">mu_id = #{muId},</if>
<if test="muPath != null">mu_path = #{muPath},</if>
<if test="picIds != null">pic_ids = #{picIds},</if>
<if test="pictures != null">pictures = #{pictures},</if>
<if test="allPicIds != null">all_pic_ids = #{allPicIds},</if>
<if test="allPics != null">all_pics = #{allPics},</if>
<if test="errorCorrect != null">error_correct = #{errorCorrect},</if>
<if test="auditStatus != null">audit_status = #{auditStatus},</if>
<if test="auditName != null">audit_name = #{auditName},</if>
<if test="auditResult != null">audit_result = #{auditResult},</if>
<if test="auditReason != null">audit_reason = #{auditReason},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteDaQuanwenById" parameterType="Long">
delete from da_quanwen where id = #{id}
</delete>
<delete id="deleteDaQuanwenByIds" parameterType="String">
delete from da_quanwen where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询全文识别列表
export function listQuanwen(query) {
return request({
url: '/dangan/quanwen/list',
method: 'get',
params: query
})
}
// 查询全文识别详细
export function getQuanwen(id) {
return request({
url: '/dangan/quanwen/' + id,
method: 'get'
})
}
// 新增全文识别
export function addQuanwen(data) {
return request({
url: '/dangan/quanwen',
method: 'post',
data: data
})
}
// 修改全文识别
export function updateQuanwen(data) {
return request({
url: '/dangan/quanwen',
method: 'put',
data: data
})
}
// 删除全文识别
export function delQuanwen(id) {
return request({
url: '/dangan/quanwen/' + id,
method: 'delete'
})
}

@ -0,0 +1,396 @@
<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="任务id" prop="taskId">
<el-input
v-model="queryParams.taskId"
placeholder="请输入任务id"
clearable
@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="识别图片id" prop="picIds">
<el-input
v-model="queryParams.picIds"
placeholder="请输入识别图片id"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="相关图片id" prop="allPicIds">
<el-input
v-model="queryParams.allPicIds"
placeholder="请输入相关图片id"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="是否纠错(字典0否1是)" prop="errorCorrect">
<el-input
v-model="queryParams.errorCorrect"
placeholder="请输入是否纠错(字典0否1是)"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="审核人" prop="auditName">
<el-input
v-model="queryParams.auditName"
placeholder="请输入审核人"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="审核结果" prop="auditResult">
<el-input
v-model="queryParams.auditResult"
placeholder="请输入审核结果"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="审核原由" prop="auditReason">
<el-input
v-model="queryParams.auditReason"
placeholder="请输入审核原由"
clearable
@keyup.enter.native="handleQuery"
/>
</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>
</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="['dangan:quanwen: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:quanwen:edit']"
>修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['dangan:quanwen: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:quanwen:export']"
>导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="quanwenList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="id" align="center" prop="id" />
<el-table-column label="全文识别内容" align="center" prop="allInfo" />
<el-table-column label="任务id" align="center" prop="taskId" />
<el-table-column label="业务类型(字典)" align="center" prop="ywType" />
<el-table-column label="目录id" align="center" prop="muId" />
<el-table-column label="档案目录路径" align="center" prop="muPath" />
<el-table-column label="识别图片id" align="center" prop="picIds" />
<el-table-column label="识别图片" align="center" prop="pictures" />
<el-table-column label="相关图片id" align="center" prop="allPicIds" />
<el-table-column label="相关图片" align="center" prop="allPics" />
<el-table-column label="是否纠错(字典0否1是)" align="center" prop="errorCorrect" />
<el-table-column label="审核状态(字典)" align="center" prop="auditStatus" />
<el-table-column label="审核人" align="center" prop="auditName" />
<el-table-column label="审核结果" align="center" prop="auditResult" />
<el-table-column label="审核原由" align="center" prop="auditReason" />
<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:quanwen:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['dangan:quanwen:remove']"
>删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@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="allInfo">
<el-input v-model="form.allInfo" type="textarea" placeholder="请输入内容" />
</el-form-item>
<el-form-item label="任务id" prop="taskId">
<el-input v-model="form.taskId" placeholder="请输入任务id" />
</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="识别图片id" prop="picIds">
<el-input v-model="form.picIds" placeholder="请输入识别图片id" />
</el-form-item>
<el-form-item label="识别图片" prop="pictures">
<el-input v-model="form.pictures" type="textarea" placeholder="请输入内容" />
</el-form-item>
<el-form-item label="相关图片id" prop="allPicIds">
<el-input v-model="form.allPicIds" placeholder="请输入相关图片id" />
</el-form-item>
<el-form-item label="相关图片" prop="allPics">
<el-input v-model="form.allPics" type="textarea" placeholder="请输入内容" />
</el-form-item>
<el-form-item label="是否纠错(字典0否1是)" prop="errorCorrect">
<el-input v-model="form.errorCorrect" placeholder="请输入是否纠错(字典0否1是)" />
</el-form-item>
<el-form-item label="审核人" prop="auditName">
<el-input v-model="form.auditName" placeholder="请输入审核人" />
</el-form-item>
<el-form-item label="审核结果" prop="auditResult">
<el-input v-model="form.auditResult" placeholder="请输入审核结果" />
</el-form-item>
<el-form-item label="审核原由" prop="auditReason">
<el-input v-model="form.auditReason" 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>
</el-dialog>
</div>
</template>
<script>
import { listQuanwen, getQuanwen, delQuanwen, addQuanwen, updateQuanwen } from "@/api/dangan/quanwen";
export default {
name: "Quanwen",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
quanwenList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
allInfo: null,
taskId: null,
ywType: null,
muId: null,
muPath: null,
picIds: null,
pictures: null,
allPicIds: null,
allPics: null,
errorCorrect: null,
auditStatus: null,
auditName: null,
auditResult: null,
auditReason: null,
},
//
form: {},
//
rules: {
ywType: [
{ required: true, message: "业务类型(字典)不能为空", trigger: "change" }
],
muId: [
{ required: true, message: "目录id不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询全文识别列表 */
getList() {
this.loading = true;
listQuanwen(this.queryParams).then(response => {
this.quanwenList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
allInfo: null,
taskId: null,
ywType: null,
muId: null,
muPath: null,
picIds: null,
pictures: null,
allPicIds: null,
allPics: null,
errorCorrect: null,
auditStatus: null,
auditName: null,
auditResult: null,
auditReason: null,
remark: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(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
getQuanwen(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) {
updateQuanwen(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addQuanwen(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除全文识别编号为"' + ids + '"的数据项?').then(function() {
return delQuanwen(ids);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download('dangan/quanwen/export', {
...this.queryParams
}, `quanwen_${new Date().getTime()}.xlsx`)
}
}
};
</script>
Loading…
Cancel
Save