| | |
| | | @ApiImplicitParam(paramType = "query", name = "pageNum", dataType = "int", required = false, value = "当前页,默认1"), |
| | | @ApiImplicitParam(paramType = "query", name = "pageSize", dataType = "int", required = false, value = "每页数目,默认10"), |
| | | @ApiImplicitParam(paramType = "query", name = "companyId", dataType = "int", required = false, value = "公司id"), |
| | | @ApiImplicitParam(paramType = "query", name = "deptId", dataType = "int", required = false, value = "部门id"), |
| | | }) |
| | | @GetMapping("/selectCorrectionList") |
| | | public CommonResult selectCorrectionList(Integer companyId){ |
| | | return CommonResult.success(correctionService.selectCorrectionList(companyId)); |
| | | public CommonResult selectCorrectionList(Correction correction){ |
| | | return CommonResult.success(correctionService.selectCorrectionList(correction)); |
| | | } |
| | | @RepeatSubmit |
| | | @ApiOperation(value = "新增整改管理") |
| | |
| | | @TableField("format") |
| | | private String format; |
| | | |
| | | @ApiModelProperty("年份") |
| | | @TableField("year") |
| | | private String year; |
| | | // @ApiModelProperty("年份") |
| | | // @TableField("year") |
| | | // private String year; |
| | | |
| | | @ApiModelProperty("部门管理") |
| | | @TableField("dept_id") |
| | |
| | | @TableField("update_time") |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("部门名称") |
| | | @TableField(exist = false) |
| | | private String deptName; |
| | | |
| | | |
| | | } |
| | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | @ApiModelProperty("企业id") |
| | | @TableField("company_id") |
| | | private Integer companyId; |
| | | // @ApiModelProperty("企业id") |
| | | // @TableField("company_id") |
| | | // private Integer companyId; |
| | | |
| | | @ApiModelProperty("检查id") |
| | | @TableField("audit_id") |
| | |
| | | @Mapper |
| | | public interface CorrectionMapper extends BaseMapper<Correction> { |
| | | |
| | | List<Correction> selectCorrectionList(Integer companyId); |
| | | List<Correction> selectCorrectionList(Correction correction); |
| | | } |
| | |
| | | * @since 2025-07-10 15:11:50 |
| | | */ |
| | | public interface CorrectionService extends IService<Correction> { |
| | | CommonPage selectCorrectionList(Integer companyId); |
| | | CommonPage selectCorrectionList(Correction correction); |
| | | |
| | | CommonResult insertCorrection(Correction correction); |
| | | |
| | |
| | | @Autowired |
| | | private CorrectionMapper correctionMapper; |
| | | @Override |
| | | public CommonPage selectCorrectionList(Integer companyId) { |
| | | public CommonPage selectCorrectionList(Correction correction) { |
| | | PageUtils.startPage(); |
| | | List<Correction> corrections = correctionMapper.selectCorrectionList(companyId); |
| | | List<Correction> corrections = correctionMapper.selectCorrectionList(correction); |
| | | return CommonPage.restPage(corrections); |
| | | } |
| | | |
| | |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | |
| | | if (ObjectUtil.isNotEmpty(internalAuditCheck.getInternalAuditCheckPeople())){ |
| | | batchInsert(internalAuditCheck.getInternalAuditCheckPeople(),internalAuditCheck1.getId()); |
| | | } |
| | | |
| | | return CommonResult.success(); |
| | | } |
| | | return CommonResult.failed(); |
| | | } |
| | |
| | | if (update > 0) { |
| | | List<InternalAuditCheckPerson> internalAuditCheckPeople = internalAuditCheck.getInternalAuditCheckPeople(); |
| | | if (ObjectUtil.isNotEmpty(internalAuditCheckPeople)){ |
| | | List<Long> collect = internalAuditCheckPeople.stream().map(InternalAuditCheckPerson::getAuditUserId) |
| | | .collect(Collectors.toList()); |
| | | Set<Long> collect = internalAuditCheckPeople.stream().map(InternalAuditCheckPerson::getAuditUserId) |
| | | .collect(Collectors.toSet()); |
| | | if (collect.size() != internalAuditCheckPeople.size()){ |
| | | throw new RuntimeException("选择的受审人员重复"); |
| | | throw new RuntimeException("受审人员重复"); |
| | | } |
| | | LambdaQueryWrapper<InternalAuditCheckPerson> queryWrapper = new LambdaQueryWrapper<>(); |
| | | queryWrapper.eq(InternalAuditCheckPerson::getAuditId, internalAuditCheck.getId()); |
| | |
| | | List<InternalAuditCheckPerson> internalAuditCheckPeople = internalAuditCheckPersonMapper.selectList(queryWrapper); |
| | | internalAuditCheckVo.setInternalAuditCheckPeople(internalAuditCheckPeople); |
| | | |
| | | return CommonResult.success(internalAuditCheck); |
| | | return CommonResult.success(internalAuditCheckVo); |
| | | } |
| | | } |
| | |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.gkhy.exam.system.mapper.CorrectionMapper"> |
| | | |
| | | <select id="selectCorrectionList" resultType="com.gkhy.exam.system.domain.Correction" parameterType="int"> |
| | | <select id="selectCorrectionList" resultType="com.gkhy.exam.system.domain.Correction" parameterType="com.gkhy.exam.system.domain.Correction"> |
| | | select * from correction where del_flag = 0 |
| | | <if test="companyId != null"> |
| | | and company_id = #{companyId} |
| | | </if> |
| | | <if test="deptId != null"> |
| | | and dept_id = #{deptId} |
| | | </if> |
| | | order by create_time desc |
| | | </select> |
| | | </mapper> |
| | |
| | | <result column="create_time" jdbcType="TIMESTAMP" property="createTime" /> |
| | | <result column="update_by" jdbcType="VARCHAR" property="updateBy" /> |
| | | <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" /> |
| | | <result column="dept_name" jdbcType="VARCHAR" property="deptName" /> |
| | | </resultMap> |
| | | |
| | | <select id="selectInternalAuditCheckList" parameterType="int" resultMap="BaseResultMap"> |
| | | select |
| | | id, company_id, dept_id, audit_id, audit_date, caluse_num, caluse_content, check_record, inconsistent, del_flag, create_by, create_time, update_by, update_time |
| | | from internal_audit_check |
| | | where del_flag = 0 |
| | | a.id, a.company_id, a.dept_id, b.dept_name,a.audit_id, a.audit_date, a.caluse_num, a.caluse_content, a.check_record, a.inconsistent, a.del_flag, a.create_by, a.create_time, a.update_by, a.update_time |
| | | from internal_audit_check a |
| | | left join sys_dept b on a.dept_id = b.dept_id |
| | | |
| | | where a.del_flag = 0 |
| | | <if test="companyId != null"> |
| | | and company_id = #{companyId} |
| | | and a.company_id = #{companyId} |
| | | </if> |
| | | order by create_time desc |
| | | order by a.create_time desc |
| | | </select> |
| | | |
| | | |
| | |
| | | |
| | | insert into internal_audit_check_person (audit_user_name, audit_user_id,audit_id,create_time,create_by) values |
| | | <foreach item="item" index="index" collection="list" separator=","> |
| | | (#{item.auditUserName}, #{item.auditUserId}, #{item.auditId},#{createTime},#{createBy}}) |
| | | (#{item.auditUserName}, #{item.auditUserId}, #{item.auditId},#{item.createTime},#{item.createBy}) |
| | | </foreach> |
| | | </insert> |
| | | |
| | |
| | | <if test="userType != null"> |
| | | AND u.user_type = #{userType} |
| | | </if> |
| | | <if test="deptId != null"> |
| | | AND d.dept_id = #{deptId} |
| | | </if> |
| | | <if test="companyId != null "> |
| | | AND u.company_id = #{companyId} |
| | | </if> |