Commit c04adf1b authored by 耿迪迪's avatar 耿迪迪

隐患审核复查审核记录

parent 6f58bd6e
...@@ -44,6 +44,10 @@ public class TDangerApprovalRecord extends BaseEntity ...@@ -44,6 +44,10 @@ public class TDangerApprovalRecord extends BaseEntity
private String nickName; private String nickName;
/** 审核类型:0.复查 1.审核 */
@Excel(name = "审核类型",readConverterExp = "0=复查 1=审核")
private String type;
public void setApprovalId(Long approvalId) public void setApprovalId(Long approvalId)
{ {
this.approvalId = approvalId; this.approvalId = approvalId;
...@@ -116,6 +120,14 @@ public class TDangerApprovalRecord extends BaseEntity ...@@ -116,6 +120,14 @@ public class TDangerApprovalRecord extends BaseEntity
this.nickName = nickName; this.nickName = nickName;
} }
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
......
...@@ -171,9 +171,31 @@ public class TDangerServiceImpl implements ITDangerService ...@@ -171,9 +171,31 @@ public class TDangerServiceImpl implements ITDangerService
tDangerStatus.setOptime(new Date()); tDangerStatus.setOptime(new Date());
tDangerStatus.setAdminId(SecurityUtils.getLoginUser().getUser().getUserId()); tDangerStatus.setAdminId(SecurityUtils.getLoginUser().getUser().getUserId());
tDangerStatusMapper.insertTDangerStatus(tDangerStatus); tDangerStatusMapper.insertTDangerStatus(tDangerStatus);
//2026-10-13 复查记录加入审核记录表
saveCheckRecord(tDanger);
return tDangerMapper.updateTDanger(tDanger); return tDangerMapper.updateTDanger(tDanger);
} }
/**
* 2026-10-13
* 保存复查记录
* @param tDanger
*/
private void saveCheckRecord(TDanger tDanger) {
//复查标识
if(null != tDanger.getParams() && tDanger.getParams().containsKey("bhFlag")){
//2026-10-13 复查记录加入审核记录表
//隐患记录
TDangerApprovalRecord tDangerApprovalRecord = new TDangerApprovalRecord();
tDangerApprovalRecord.setDangerId(tDanger.getId());
tDangerApprovalRecord.setUserId(SecurityUtils.getLoginUser().getUser().getUserId());
tDangerApprovalRecord.setApprovalStatus(tDanger.getParams().containsKey("bhFlag") ? "1" : "0");
if(StringUtils.isNotEmpty(tDanger.getCheckRemark())) tDangerApprovalRecord.setSuggestion(tDanger.getCheckRemark());
tDangerApprovalRecord.setType("0");
tDangerApprovalRecordService.insertTDangerApprovalRecord(tDangerApprovalRecord);
}
}
/** /**
* 批量删除安检隐患整改 * 批量删除安检隐患整改
* *
...@@ -290,6 +312,7 @@ public class TDangerServiceImpl implements ITDangerService ...@@ -290,6 +312,7 @@ public class TDangerServiceImpl implements ITDangerService
tDangerApprovalRecord.setUserId(SecurityUtils.getLoginUser().getUser().getUserId()); tDangerApprovalRecord.setUserId(SecurityUtils.getLoginUser().getUser().getUserId());
tDangerApprovalRecord.setApprovalStatus(approvalVo.getState()); tDangerApprovalRecord.setApprovalStatus(approvalVo.getState());
tDangerApprovalRecord.setSuggestion(approvalVo.getSuggestion()); tDangerApprovalRecord.setSuggestion(approvalVo.getSuggestion());
tDangerApprovalRecord.setType("1");
tDangerApprovalRecordService.insertTDangerApprovalRecord(tDangerApprovalRecord); tDangerApprovalRecordService.insertTDangerApprovalRecord(tDangerApprovalRecord);
} }
return 1; return 1;
......
...@@ -15,6 +15,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -15,6 +15,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="isDel" column="is_del" /> <result property="isDel" column="is_del" />
<result property="remarks" column="remarks" /> <result property="remarks" column="remarks" />
<result property="type" column="type" />
</resultMap> </resultMap>
<sql id="selectTDangerApprovalRecordVo"> <sql id="selectTDangerApprovalRecordVo">
...@@ -29,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -29,6 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
record.update_time, record.update_time,
record.is_del, record.is_del,
record.remarks, record.remarks,
record.type,
su.nick_name as nickName su.nick_name as nickName
FROM FROM
t_danger_approval_record record t_danger_approval_record record
...@@ -44,6 +46,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -44,6 +46,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="suggestion != null and suggestion != ''"> and record.suggestion = #{suggestion}</if> <if test="suggestion != null and suggestion != ''"> and record.suggestion = #{suggestion}</if>
<if test="isDel != null and isDel != ''"> and record.is_del = #{isDel}</if> <if test="isDel != null and isDel != ''"> and record.is_del = #{isDel}</if>
<if test="remarks != null and remarks != ''"> and record.remarks = #{remarks}</if> <if test="remarks != null and remarks != ''"> and record.remarks = #{remarks}</if>
<if test="type != null and type != ''"> and record.type = #{type}</if>
</where> </where>
ORDER BY record.create_time ASC ORDER BY record.create_time ASC
</select> </select>
...@@ -65,6 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -65,6 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateTime != null">update_time,</if> <if test="updateTime != null">update_time,</if>
<if test="isDel != null">is_del,</if> <if test="isDel != null">is_del,</if>
<if test="remarks != null">remarks,</if> <if test="remarks != null">remarks,</if>
<if test="type != null">type,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="dangerId != null">#{dangerId},</if> <if test="dangerId != null">#{dangerId},</if>
...@@ -76,6 +80,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -76,6 +80,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateTime != null">#{updateTime},</if> <if test="updateTime != null">#{updateTime},</if>
<if test="isDel != null">#{isDel},</if> <if test="isDel != null">#{isDel},</if>
<if test="remarks != null">#{remarks},</if> <if test="remarks != null">#{remarks},</if>
<if test="type != null">#{type},</if>
</trim> </trim>
</insert> </insert>
...@@ -91,6 +96,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -91,6 +96,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">update_time = #{updateTime},</if>
<if test="isDel != null">is_del = #{isDel},</if> <if test="isDel != null">is_del = #{isDel},</if>
<if test="remarks != null">remarks = #{remarks},</if> <if test="remarks != null">remarks = #{remarks},</if>
<if test="type != null">type = #{type},</if>
</trim> </trim>
where approval_id = #{approvalId} where approval_id = #{approvalId}
</update> </update>
......
...@@ -931,7 +931,7 @@ export default { ...@@ -931,7 +931,7 @@ export default {
}, },
//获取审核记录 //获取审核记录
getDangerApprovalList(dangerId){ getDangerApprovalList(dangerId){
dangerApprovalListInfo({dangerId:dangerId}).then(res =>{ dangerApprovalListInfo({dangerId:dangerId,type: "1"}).then(res =>{
if(res.code == 200){ if(res.code == 200){
this.dangerApprovalList = res.data; this.dangerApprovalList = res.data;
} }
......
...@@ -917,7 +917,7 @@ export default { ...@@ -917,7 +917,7 @@ export default {
}, },
//获取审核记录 //获取审核记录
getDangerApprovalList(dangerId){ getDangerApprovalList(dangerId){
dangerApprovalListInfo({dangerId:dangerId}).then(res =>{ dangerApprovalListInfo({dangerId:dangerId,type: "1"}).then(res =>{
if(res.code == 200){ if(res.code == 200){
this.dangerApprovalList = res.data; this.dangerApprovalList = res.data;
} }
......
...@@ -917,7 +917,7 @@ export default { ...@@ -917,7 +917,7 @@ export default {
}, },
//获取审核记录 //获取审核记录
getDangerApprovalList(dangerId){ getDangerApprovalList(dangerId){
dangerApprovalListInfo({dangerId:dangerId}).then(res =>{ dangerApprovalListInfo({dangerId:dangerId,type: "1"}).then(res =>{
if(res.code == 200){ if(res.code == 200){
this.dangerApprovalList = res.data; this.dangerApprovalList = res.data;
} }
......
...@@ -883,7 +883,7 @@ export default { ...@@ -883,7 +883,7 @@ export default {
}, },
//获取审核记录 //获取审核记录
getDangerApprovalList(dangerId){ getDangerApprovalList(dangerId){
dangerApprovalListInfo({dangerId:dangerId}).then(res =>{ dangerApprovalListInfo({dangerId:dangerId,type: "1"}).then(res =>{
if(res.code == 200){ if(res.code == 200){
this.dangerApprovalList = res.data; this.dangerApprovalList = res.data;
} }
......
...@@ -871,7 +871,7 @@ export default { ...@@ -871,7 +871,7 @@ export default {
}, },
//获取审核记录 //获取审核记录
getDangerApprovalList(dangerId){ getDangerApprovalList(dangerId){
dangerApprovalListInfo({dangerId:dangerId}).then(res =>{ dangerApprovalListInfo({dangerId:dangerId,type: "1"}).then(res =>{
if(res.code == 200){ if(res.code == 200){
this.dangerApprovalList = res.data; this.dangerApprovalList = res.data;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment