diff --git a/src/main/java/com/biutag/supervision/mapper/RpcInfringerResultMapper.java b/src/main/java/com/biutag/supervision/mapper/RpcInfringerResultMapper.java index 3b33f03..a011dc1 100644 --- a/src/main/java/com/biutag/supervision/mapper/RpcInfringerResultMapper.java +++ b/src/main/java/com/biutag/supervision/mapper/RpcInfringerResultMapper.java @@ -16,6 +16,11 @@ public interface RpcInfringerResultMapper extends BaseMapper List selectNamesByTime(Date beginTime, Date endTime); + @Select("select distinct id_code , id, rpc_id,tort_name,defend_handle_way,defend_handle_way_name,gender from rpc_infringer_result " + + " WHERE rpc_id = #{id} ") + List selectDistinctId(String id); + + @Select(" SELECT rir.* from rpc_infringer_result rir LEFT JOIN rpc_apply as rpa" + " on rpa.rpc_id = rir.rpc_id" + " WHERE rpa.crt_time between #{beginTime} and #{endTime} " + diff --git a/src/main/java/com/biutag/supervision/pojo/entity/RpcApplySupervise.java b/src/main/java/com/biutag/supervision/pojo/entity/RpcApplySupervise.java index 0545ed9..f656b19 100644 --- a/src/main/java/com/biutag/supervision/pojo/entity/RpcApplySupervise.java +++ b/src/main/java/com/biutag/supervision/pojo/entity/RpcApplySupervise.java @@ -63,8 +63,10 @@ public class RpcApplySupervise { private String factReason; // 案发环节 + @TableField("incident_link") private String incidentLink; + @TableField("incident_link_name") private String incidentLinkName; //录入人警号 private String inputEmpNo; diff --git a/src/main/java/com/biutag/supervision/service/RpcApplySuperviseService.java b/src/main/java/com/biutag/supervision/service/RpcApplySuperviseService.java index bacff4f..f27fa28 100644 --- a/src/main/java/com/biutag/supervision/service/RpcApplySuperviseService.java +++ b/src/main/java/com/biutag/supervision/service/RpcApplySuperviseService.java @@ -106,7 +106,8 @@ public class RpcApplySuperviseService extends ServiceImpl rpcInfringerResults = rpcInfringerResultService.list(new LambdaQueryWrapper().select(RpcInfringerResult::getIdCode).eq(RpcInfringerResult::getRpcId,id)); + List rpcInfringerResults = + rpcInfringerResultService.selectDistinctId(id); if (ArrayUtil.isNotEmpty(rpcInfringerResults)){ superviseVo.setRpcInfringerResults(rpcInfringerResults); } diff --git a/src/main/java/com/biutag/supervision/service/RpcInfringerResultService.java b/src/main/java/com/biutag/supervision/service/RpcInfringerResultService.java index 5058903..f983da1 100644 --- a/src/main/java/com/biutag/supervision/service/RpcInfringerResultService.java +++ b/src/main/java/com/biutag/supervision/service/RpcInfringerResultService.java @@ -5,7 +5,14 @@ import com.biutag.supervision.mapper.RpcInfringerResultMapper; import com.biutag.supervision.pojo.entity.RpcInfringerResult; import org.springframework.stereotype.Service; +import java.util.List; + @Service public class RpcInfringerResultService extends ServiceImpl { + + public List selectDistinctId(String id){ + return baseMapper.selectDistinctId(id); + } + } diff --git a/src/main/resources/mapper/RpcApplySuperviseMapper.xml b/src/main/resources/mapper/RpcApplySuperviseMapper.xml index 05305b8..aa72bfb 100644 --- a/src/main/resources/mapper/RpcApplySuperviseMapper.xml +++ b/src/main/resources/mapper/RpcApplySuperviseMapper.xml @@ -7,12 +7,15 @@