按照客户数据调整库表结构,修改业务代码

main
252535409 2 years ago
parent b553cfc4aa
commit 0ed0392f9a

@ -0,0 +1,171 @@
package org.jeecg.modules.ai.controller;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.ai.entity.YsDirectoryMaterialRelation;
import org.jeecg.modules.ai.service.IYsDirectoryMaterialRelationService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
import org.jeecg.common.system.base.controller.JeecgController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import org.springframework.web.servlet.ModelAndView;
import com.alibaba.fastjson.JSON;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.jeecg.common.aspect.annotation.AutoLog;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Api(tags="预审事项和预审材料关系表")
@RestController
@RequestMapping("/ai/ysDirectoryMaterialRelation")
@Slf4j
public class YsDirectoryMaterialRelationController extends JeecgController<YsDirectoryMaterialRelation, IYsDirectoryMaterialRelationService> {
@Autowired
private IYsDirectoryMaterialRelationService ysDirectoryMaterialRelationService;
/**
*
*
* @param ysDirectoryMaterialRelation
* @param pageNo
* @param pageSize
* @param req
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-分页列表查询")
@ApiOperation(value="预审事项和预审材料关系表-分页列表查询", notes="预审事项和预审材料关系表-分页列表查询")
@GetMapping(value = "/list")
public Result<?> queryPageList(YsDirectoryMaterialRelation ysDirectoryMaterialRelation,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
QueryWrapper<YsDirectoryMaterialRelation> queryWrapper = QueryGenerator.initQueryWrapper(ysDirectoryMaterialRelation, req.getParameterMap());
Page<YsDirectoryMaterialRelation> page = new Page<YsDirectoryMaterialRelation>(pageNo, pageSize);
IPage<YsDirectoryMaterialRelation> pageList = ysDirectoryMaterialRelationService.page(page, queryWrapper);
return Result.OK(pageList);
}
/**
*
*
* @param ysDirectoryMaterialRelation
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-添加")
@ApiOperation(value="预审事项和预审材料关系表-添加", notes="预审事项和预审材料关系表-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody YsDirectoryMaterialRelation ysDirectoryMaterialRelation) {
ysDirectoryMaterialRelationService.save(ysDirectoryMaterialRelation);
return Result.OK("添加成功!");
}
/**
*
*
* @param ysDirectoryMaterialRelation
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-编辑")
@ApiOperation(value="预审事项和预审材料关系表-编辑", notes="预审事项和预审材料关系表-编辑")
@PutMapping(value = "/edit")
public Result<?> edit(@RequestBody YsDirectoryMaterialRelation ysDirectoryMaterialRelation) {
ysDirectoryMaterialRelationService.updateById(ysDirectoryMaterialRelation);
return Result.OK("编辑成功!");
}
/**
* id
*
* @param id
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-通过id删除")
@ApiOperation(value="预审事项和预审材料关系表-通过id删除", notes="预审事项和预审材料关系表-通过id删除")
@DeleteMapping(value = "/delete")
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
ysDirectoryMaterialRelationService.removeById(id);
return Result.OK("删除成功!");
}
/**
*
*
* @param ids
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-批量删除")
@ApiOperation(value="预审事项和预审材料关系表-批量删除", notes="预审事项和预审材料关系表-批量删除")
@DeleteMapping(value = "/deleteBatch")
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
this.ysDirectoryMaterialRelationService.removeByIds(Arrays.asList(ids.split(",")));
return Result.OK("批量删除成功!");
}
/**
* id
*
* @param id
* @return
*/
@AutoLog(value = "预审事项和预审材料关系表-通过id查询")
@ApiOperation(value="预审事项和预审材料关系表-通过id查询", notes="预审事项和预审材料关系表-通过id查询")
@GetMapping(value = "/queryById")
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
YsDirectoryMaterialRelation ysDirectoryMaterialRelation = ysDirectoryMaterialRelationService.getById(id);
if(ysDirectoryMaterialRelation==null) {
return Result.error("未找到对应数据");
}
return Result.OK(ysDirectoryMaterialRelation);
}
/**
* excel
*
* @param request
* @param ysDirectoryMaterialRelation
*/
@RequestMapping(value = "/exportXls")
public ModelAndView exportXls(HttpServletRequest request, YsDirectoryMaterialRelation ysDirectoryMaterialRelation) {
return super.exportXls(request, ysDirectoryMaterialRelation, YsDirectoryMaterialRelation.class, "预审事项和预审材料关系表");
}
/**
* excel
*
* @param request
* @param response
* @return
*/
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
return super.importExcel(request, response, YsDirectoryMaterialRelation.class);
}
}

@ -0,0 +1,171 @@
package org.jeecg.modules.ai.controller;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLDecoder;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.util.oConvertUtils;
import org.jeecg.modules.ai.entity.YsEventType;
import org.jeecg.modules.ai.service.IYsEventTypeService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.extern.slf4j.Slf4j;
import org.jeecgframework.poi.excel.ExcelImportUtil;
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.ImportParams;
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
import org.jeecg.common.system.base.controller.JeecgController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import org.springframework.web.servlet.ModelAndView;
import com.alibaba.fastjson.JSON;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.jeecg.common.aspect.annotation.AutoLog;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Api(tags="预审事项类型字典表")
@RestController
@RequestMapping("/ai/ysEventType")
@Slf4j
public class YsEventTypeController extends JeecgController<YsEventType, IYsEventTypeService> {
@Autowired
private IYsEventTypeService ysEventTypeService;
/**
*
*
* @param ysEventType
* @param pageNo
* @param pageSize
* @param req
* @return
*/
@AutoLog(value = "预审事项类型字典表-分页列表查询")
@ApiOperation(value="预审事项类型字典表-分页列表查询", notes="预审事项类型字典表-分页列表查询")
@GetMapping(value = "/list")
public Result<?> queryPageList(YsEventType ysEventType,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) {
QueryWrapper<YsEventType> queryWrapper = QueryGenerator.initQueryWrapper(ysEventType, req.getParameterMap());
Page<YsEventType> page = new Page<YsEventType>(pageNo, pageSize);
IPage<YsEventType> pageList = ysEventTypeService.page(page, queryWrapper);
return Result.OK(pageList);
}
/**
*
*
* @param ysEventType
* @return
*/
@AutoLog(value = "预审事项类型字典表-添加")
@ApiOperation(value="预审事项类型字典表-添加", notes="预审事项类型字典表-添加")
@PostMapping(value = "/add")
public Result<?> add(@RequestBody YsEventType ysEventType) {
ysEventTypeService.save(ysEventType);
return Result.OK("添加成功!");
}
/**
*
*
* @param ysEventType
* @return
*/
@AutoLog(value = "预审事项类型字典表-编辑")
@ApiOperation(value="预审事项类型字典表-编辑", notes="预审事项类型字典表-编辑")
@PutMapping(value = "/edit")
public Result<?> edit(@RequestBody YsEventType ysEventType) {
ysEventTypeService.updateById(ysEventType);
return Result.OK("编辑成功!");
}
/**
* id
*
* @param id
* @return
*/
@AutoLog(value = "预审事项类型字典表-通过id删除")
@ApiOperation(value="预审事项类型字典表-通过id删除", notes="预审事项类型字典表-通过id删除")
@DeleteMapping(value = "/delete")
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
ysEventTypeService.removeById(id);
return Result.OK("删除成功!");
}
/**
*
*
* @param ids
* @return
*/
@AutoLog(value = "预审事项类型字典表-批量删除")
@ApiOperation(value="预审事项类型字典表-批量删除", notes="预审事项类型字典表-批量删除")
@DeleteMapping(value = "/deleteBatch")
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
this.ysEventTypeService.removeByIds(Arrays.asList(ids.split(",")));
return Result.OK("批量删除成功!");
}
/**
* id
*
* @param id
* @return
*/
@AutoLog(value = "预审事项类型字典表-通过id查询")
@ApiOperation(value="预审事项类型字典表-通过id查询", notes="预审事项类型字典表-通过id查询")
@GetMapping(value = "/queryById")
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
YsEventType ysEventType = ysEventTypeService.getById(id);
if(ysEventType==null) {
return Result.error("未找到对应数据");
}
return Result.OK(ysEventType);
}
/**
* excel
*
* @param request
* @param ysEventType
*/
@RequestMapping(value = "/exportXls")
public ModelAndView exportXls(HttpServletRequest request, YsEventType ysEventType) {
return super.exportXls(request, ysEventType, YsEventType.class, "预审事项类型字典表");
}
/**
* excel
*
* @param request
* @param response
* @return
*/
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
return super.importExcel(request, response, YsEventType.class);
}
}

@ -105,7 +105,7 @@ public class YsDirectory implements Serializable {
/**事件类型,来源字典表*/
@Excel(name = "事件类型,来源字典表", width = 15)
@ApiModelProperty(value = "事件类型,来源字典表")
private java.lang.Integer evtentType;
private java.lang.Integer eventType;
/**权利来源*/
@Excel(name = "权利来源", width = 15)
@ApiModelProperty(value = "权利来源")

@ -0,0 +1,46 @@
package org.jeecg.modules.ai.entity;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Data
@TableName("ys_directory_material_relation")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="ys_directory_material_relation对象", description="预审事项和预审材料关系表")
public class YsDirectoryMaterialRelation implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private java.lang.String id;
/**预审事项编码*/
@Excel(name = "预审事项编码", width = 15)
@ApiModelProperty(value = "预审事项编码")
private java.lang.String eventCode;
/**预审材料编码*/
@Excel(name = "预审材料编码", width = 15)
@ApiModelProperty(value = "预审材料编码")
private java.lang.String materialCode;
}

@ -0,0 +1,42 @@
package org.jeecg.modules.ai.entity;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
import java.util.Date;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.jeecg.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Data
@TableName("ys_event_type")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="ys_event_type对象", description="预审事项类型字典表")
public class YsEventType implements Serializable {
private static final long serialVersionUID = 1L;
/**主键*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键")
private java.lang.String id;
/**类型名称*/
@Excel(name = "类型名称", width = 15)
@ApiModelProperty(value = "类型名称")
private java.lang.String name;
}

@ -0,0 +1,18 @@
package org.jeecg.modules.ai.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.ai.entity.YsDirectoryMaterialRelation;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
public interface YsDirectoryMaterialRelationMapper extends BaseMapper<YsDirectoryMaterialRelation> {
}

@ -0,0 +1,18 @@
package org.jeecg.modules.ai.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.ai.entity.YsEventType;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
public interface YsEventTypeMapper extends BaseMapper<YsEventType> {
}

@ -14,11 +14,12 @@
<result column="author_status" property="authorStatus" jdbcType="INTEGER"/>
<result column="del_flag" property="delFlag" jdbcType="INTEGER"/>
<result column="processing_type" property="processingType" jdbcType="INTEGER"/>
<result column="event_type_name" property="eventTypeName" jdbcType="VARCHAR"/>
</resultMap>
<sql id="preexaminationmatters_column_body">
a.id,a.display_name,a.event_code,b.del_flag,a.author_status,c.depart_name,a.processing_type,
b.valid_status,a.report_template_url,a.print_template_url
b.valid_status,a.report_template_url,a.print_template_url,d.name as event_type_name
</sql>
<sql id="preexaminationmatters_select_body">
@ -28,7 +29,7 @@
<if test="query.orgCode != null and query.orgCode != ''"> and a.sys_org_code = #{query.orgCode,jdbcType=VARCHAR} </if>
<if test="query.eventCode != null and query.eventCode != ''"> and a.event_code = #{query.eventCode,jdbcType=VARCHAR} </if>
<if test="query.processingType != null"> and a.processing_type = #{query.processingType,jdbcType=INTEGER} </if>
<if test="query.eventType != null"> and b.event_type = #{query.eventType,jdbcType=INTEGER} </if>
<if test="query.eventTypeName != null and query.eventTypeName != ''" > and d.name = #{query.eventTypeName,jdbcType=INTEGER} </if>
<if test="query.delFlag != null"> and a.del_flag = #{query.delFlag,jdbcType=INTEGER} </if>
<if test="query.authorStatus != null"> and a.author_status = #{query.authorStatus,jdbcType=INTEGER} </if>
</where>
@ -39,6 +40,7 @@
from pre_examination_matters a
left join ys_directory b on a.event_code = b.event_code
left join sys_depart c on b.sys_org_code = c.depart_code
left join ys_event_type d on a.processing_type = d.id
<include refid="preexaminationmatters_select_body" />
</select>

@ -6,7 +6,7 @@
<result column="id" property="id" jdbcType="VARCHAR"/>
<result column="material_code" property="materialCode" jdbcType="VARCHAR"/>
<result column="material_name" property="materialName" jdbcType="VARCHAR"/>
<result column="material_type" property="materialType" jdbcType="VARCHAR"/>
<result column="upload_material_type" property="materialType" jdbcType="VARCHAR"/>
<result column="depart_name" property="departName" jdbcType="VARCHAR"/>
<result column="material_url" property="materialUrl" jdbcType="VARCHAR"/>
<result column="event_code" property="eventCode" jdbcType="VARCHAR"/>
@ -14,11 +14,11 @@
</resultMap>
<sql id="prereviewmaterial_column_body">
a.id,b.material_name,b.material_type,a.material_code,a.valid_status,c.depart_name,b.material_url,a.event_code
a.id,b.material_name,b.upload_material_type,c.depart_name,a.material_code,a.valid_status,b.material_url,d.event_code
</sql>
<sql id="prereviewmaterial_column_body_bycode">
a.id,b.material_name,b.material_type,a.material_code,a.valid_status,b.material_url,a.event_code
a.id,b.material_name,b.upload_material_type,a.material_code,a.valid_status,b.material_url,d.event_code
</sql>
<sql id="prereviewmaterial_select_body">
@ -28,22 +28,26 @@
<if test="query.orgCode != null and query.orgCode != ''"> and a.sys_org_code like CONCAT('%', #{query.orgCode}, '%') </if>
<if test="query.materialType != null"> and b.material_type = #{query.materialType,jdbcType=INTEGER} </if>
<if test="query.validStatus != null"> and a.valid_status = #{query.validStatus,jdbcType=INTEGER} </if>
<if test="query.eventCode != null"> and a.event_code = #{query.eventCode,jdbcType=INTEGER} </if>
<if test="query.eventCode != null"> and d.event_code = #{query.eventCode,jdbcType=INTEGER} </if>
</where>
</sql>
<select id="getPreReviewMaterialList" resultMap="baseResultMap" >
select <include refid="prereviewmaterial_column_body" />
from pre_review_material a
left join ys_directory_material_relation d on a.material_code = d.material_code
left join ys_directory_material b on a.material_code = b.material_code
left join sys_depart c on a.sys_org_code = c.depart_code
left join ys_directory e on d.event_code = e.event_code
left join sys_depart c on e.sys_org_code = c.depart_code
<include refid="prereviewmaterial_select_body" />
group by a.material_code
</select>
<select id="getPreReviewMaterialByCode" resultMap="baseResultMap" >
select <include refid="prereviewmaterial_column_body_bycode" />
from pre_review_material a
left join ys_directory_material b on a.material_code = b.material_code
left join ys_directory_material_relation d on a.material_code = d.material_code
where a.material_code = #{materialCode,jdbcType=VARCHAR}
</select>
</mapper>

@ -11,7 +11,7 @@
</resultMap>
<sql id="prereviewrecordsdetail_column_body">
a.id,b.material_name,a.review_result,a.materia_url,a.create_time,a.material_code
a.id,b.material_name,d.review_result,a.materia_url,a.create_time,a.material_code
</sql>
<sql id="prereviewrecordsdetail_select_body">
@ -19,7 +19,7 @@
<if test="query.reviewRecordsId != null and query.reviewRecordsId != ''"> and a.review_records_id = #{query.reviewRecordsId,jdbcType=VARCHAR} </if>
<if test="query.eventCode != null and query.eventCode != ''"> and a.event_code = #{query.eventCode,jdbcType=VARCHAR} </if>
<if test="query.userId != null and query.userId != ''"> and c.user_id = #{query.userId,jdbcType=VARCHAR} </if>
<if test="query.reviewResult != null and query.reviewResult != ''"> and a.review_result = #{query.reviewResult,jdbcType=VARCHAR} </if>
<if test="query.reviewResult != null and query.reviewResult != ''"> and d.review_result = #{query.reviewResult,jdbcType=VARCHAR} </if>
</where>
</sql>
@ -28,6 +28,7 @@
from pre_review_records_detail a
left join ys_directory_material b on a.material_code = b.material_code
left join pre_review_records c on a.review_records_id = c.id
left join pre_review_records_detail_template d on a.id = d.record_detail_id
<include refid="prereviewrecordsdetail_select_body" />
</select>
</mapper>

@ -8,14 +8,14 @@
<result column="event_code" property="eventCode" jdbcType="VARCHAR"/>
<result column="depart_name" property="departName" jdbcType="VARCHAR"/>
<result column="valid_status" property="validStatus" jdbcType="VARCHAR"/>
<result column="evtent_type" property="evtentType" jdbcType="INTEGER"/>
<result column="event_type" property="eventType" jdbcType="INTEGER"/>
<result column="del_flag" property="delFlag" jdbcType="INTEGER"/>
<result column="source_of_rights" property="sourceOfRights" jdbcType="INTEGER"/>
</resultMap>
<sql id="ysdirectory_column_body">
a.id,a.event_name,a.event_code,a.del_flag,a.evtent_type,b.depart_name,a.source_of_rights,
a.valid_status
a.id,a.event_name,a.event_code,a.del_flag,a.event_type,b.depart_name,a.source_of_rights,
a.valid_status,c.name as eventTypeName
</sql>
<sql id="ysdirectory_select_body">
@ -24,6 +24,7 @@
<if test="query.orgCode != null and query.orgCode != ''"> and a.sys_org_code = #{query.orgCode,jdbcType=VARCHAR} </if>
<if test="query.orgId != null and query.orgId != ''"> and b.id = #{query.orgId,jdbcType=VARCHAR} </if>
<if test="query.eventType != null"> and b.event_type = #{query.eventType,jdbcType=INTEGER} </if>
<if test="query.eventTypeName != null and query.eventTypeName != ''"> and c.name = #{query.eventTypeName,jdbcType=VARCHAR} </if>
<if test="query.delFlag != null"> and a.del_flag = #{query.delFlag,jdbcType=INTEGER} </if>
<if test="query.validStatus != null"> and a.valid_status = #{query.validStatus,jdbcType=INTEGER} </if>
</where>
@ -33,6 +34,7 @@
select <include refid="ysdirectory_column_body" />
from ys_directory a
left join sys_depart b on a.sys_org_code = b.depart_code
left join ys_event_type c on a.event_type = c.id
<include refid="ysdirectory_select_body" />
</select>

@ -0,0 +1,5 @@
<?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="org.jeecg.modules.ai.mapper.YsDirectoryMaterialRelationMapper">
</mapper>

@ -0,0 +1,5 @@
<?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="org.jeecg.modules.ai.mapper.YsEventTypeMapper">
</mapper>

@ -8,6 +8,7 @@ public class PreExaminationMattersQuery {
private String ids;
private String displayName;
private String eventTypeName;
private String departName;
private String orgCode;
private String eventCode;

@ -5,6 +5,7 @@ import lombok.Data;
@Data
public class YsDirectoryQuery {
private String eventTypeName;
private String eventName;
private String orgCode;
private String orgId;

@ -0,0 +1,15 @@
package org.jeecg.modules.ai.service;
import org.jeecg.modules.ai.entity.YsDirectoryMaterialRelation;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
public interface IYsDirectoryMaterialRelationService extends IService<YsDirectoryMaterialRelation> {
}

@ -0,0 +1,15 @@
package org.jeecg.modules.ai.service;
import org.jeecg.modules.ai.entity.YsEventType;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
public interface IYsEventTypeService extends IService<YsEventType> {
}

@ -82,7 +82,7 @@ public class PreExaminationMattersServiceImpl extends ServiceImpl<PreExamination
preExaminationMatters.setSysOrgCode(ysDirectory.getSysOrgCode());
preExaminationMatters.setCreateTime(new Date());
preExaminationMatters.setCreateBy(user.getUsername());
preExaminationMatters.setProcessingType(ysDirectory.getEvtentType());
preExaminationMatters.setProcessingType(ysDirectory.getEventType());
preExaminationMattersMapper.insert(preExaminationMatters);
}
});

@ -80,7 +80,7 @@ public class PreReviewMaterialServiceImpl extends ServiceImpl<PreReviewMaterialM
List<YsDirectoryMaterial> listYsDirectoryMaterial = iYsDirectoryMaterialService.listByIds(idsList);
listYsDirectoryMaterial.stream().forEach(ysDirectoryMaterial -> {
YsDirectory ysDirectory = ysDirectoryMapper.selectById(ysDirectoryMaterial.getDirId());
// YsDirectory ysDirectory = ysDirectoryMapper.selectById(ysDirectoryMaterial.getDirId());
//查询是否已经存在
LambdaQueryWrapper<PreReviewMaterial> queryPreReviewMaterial = new LambdaQueryWrapper<>();
@ -90,7 +90,7 @@ public class PreReviewMaterialServiceImpl extends ServiceImpl<PreReviewMaterialM
PreReviewMaterial preReviewMaterial = new PreReviewMaterial();
preReviewMaterial.setMaterialCode(ysDirectoryMaterial.getMaterialCode());
preReviewMaterial.setSysOrgCode(ysDirectoryMaterial.getSysOrgCode());
preReviewMaterial.setEventCode(ysDirectory.getEventCode());
// preReviewMaterial.setEventCode(ysDirectory.getEventCode());
preReviewMaterialMapper.insert(preReviewMaterial);
}

@ -172,7 +172,7 @@ public class PreReviewRecordsServiceImpl extends ServiceImpl<PreReviewRecordsMap
PreReviewRecords preReviewRecordsUp = new PreReviewRecords();
if(preReviewRecords.getId()!=null) {
//发送完成短信
String result = new SendSmsUtil().sendSms("", "", "", "");
// String result = new SendSmsUtil().sendSms("", "", "", "");
}
preReviewRecordsUp.setId(preReviewRecords.getId());
preReviewRecordsUp.setValidStatus(1);

@ -0,0 +1,19 @@
package org.jeecg.modules.ai.service.impl;
import org.jeecg.modules.ai.entity.YsDirectoryMaterialRelation;
import org.jeecg.modules.ai.mapper.YsDirectoryMaterialRelationMapper;
import org.jeecg.modules.ai.service.IYsDirectoryMaterialRelationService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Service
public class YsDirectoryMaterialRelationServiceImpl extends ServiceImpl<YsDirectoryMaterialRelationMapper, YsDirectoryMaterialRelation> implements IYsDirectoryMaterialRelationService {
}

@ -40,9 +40,9 @@ public class YsDirectoryMaterialServiceImpl extends ServiceImpl<YsDirectoryMater
queryWrapper.eq(YsDirectoryMaterial::getMaterialCode, materialCode);
YsDirectoryMaterial ysDirectoryMaterial = ysDirectoryMaterialMapper.selectOne(queryWrapper);
String ocrResult = null;
if(ysDirectoryMaterial.getRulesExist().intValue()==1) {
if(ysDirectoryMaterial.getRulesExist().intValue()==1&&"1".equals(ysDirectoryMaterial.getVerifyDataType())) {
//调用接口识别
ocrResult = RecognizeGeneralTextSolution.recognizeGeneralTextSolution(savePath, templateId);
// ocrResult = RecognizeGeneralTextSolution.recognizeGeneralTextSolution(savePath, templateId);
//根据规则校验数据
}

@ -0,0 +1,19 @@
package org.jeecg.modules.ai.service.impl;
import org.jeecg.modules.ai.entity.YsEventType;
import org.jeecg.modules.ai.mapper.YsEventTypeMapper;
import org.jeecg.modules.ai.service.IYsEventTypeService;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2023-12-08
* @Version: V1.0
*/
@Service
public class YsEventTypeServiceImpl extends ServiceImpl<YsEventTypeMapper, YsEventType> implements IYsEventTypeService {
}

@ -17,4 +17,5 @@ public class PreExaminationMattersVo {
private Integer processingType;
private String reportTemplateUrl;
private String printTemplateUrl;
private String eventTypeName;
}

@ -9,8 +9,9 @@ public class YsDirectoryVo {
private String eventName;
private String eventCode;
private String departName;
private String eventTypeName;
private String validStatus;
private Integer evtentType;
private Integer eventType;
private Integer delFlag;
private Integer sourceOfRights;

@ -108,7 +108,7 @@ spring:
filters: stat,wall,slf4j
datasource:
master:
url: jdbc:mysql://47.92.244.192:3306/ai-intelligent-prequalification?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai&rewriteBatchedStatements=true
url: jdbc:mysql://47.92.244.192:3306/ai-inteligent?characterEncoding=UTF-8&useUnicode=true&useSSL=false&tinyInt1isBit=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai&rewriteBatchedStatements=true
username: root
password: Wzw7788521
driver-class-name: com.mysql.cj.jdbc.Driver

Loading…
Cancel
Save