|
@@ -16,6 +16,7 @@ import com.rshy.project.hy.model.enums.SexEnum;
|
|
|
import com.rshy.project.hy.server.FaceRetrievaServer;
|
|
|
import com.rshy.project.hy.server.ItfwServer;
|
|
|
import com.rshy.project.hy.server.dto.PctjkmInfoDTO;
|
|
|
+import com.rshy.project.hy.server.dto.PctrchlDTO;
|
|
|
import com.rshy.project.hy.server.dto.RepositoryDTO;
|
|
|
import com.rshy.project.hy.server.dto.ResultDTO;
|
|
|
import com.rshy.project.hy.server.param.RshyParam;
|
|
@@ -27,7 +28,6 @@ import com.rshy.project.hy.util.ObjectUtils;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.data.redis.core.RedisTemplate;
|
|
|
import org.springframework.data.redis.core.StringRedisTemplate;
|
|
|
import org.springframework.stereotype.Component;
|
|
|
|
|
@@ -119,9 +119,16 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
Date date = DateUtil.parse(IdcardUtil.getBirthByIdCard(rshyParam.getSfzh()));
|
|
|
rshyVo.setBirthday(DateUtil.format(date, "yyyy-M-d"));
|
|
|
|
|
|
- if (resultDTO.getPctztDTO() != null) {
|
|
|
+ PctrchlDTO pctrchlDTO = resultDTO.getPctrchlDTO();
|
|
|
+ resultDTO.setPctrchlDTO(null);
|
|
|
+ String hcjg = "";
|
|
|
+ if (pctrchlDTO != null) {
|
|
|
+ hcjg = pctrchlDTO.getHcjg();
|
|
|
+ }
|
|
|
+
|
|
|
+ if (resultDTO.getPctztDTO() != null || StrUtil.containsAnyIgnoreCase(hcjg, "抓捕")) {
|
|
|
rshyVo.setPass(PassStatusEnum.NO_PASSING.getCode()).setTts(PassStatusEnum.NO_PASSING.getDesc()).setDisplayMsg(PassStatusEnum.NO_PASSING.getDesc()).setWarning(new StringBuilder().append("在逃人员:").append(resultDTO.getPctztDTO().getJyaq()).toString()).setKind(resultDTO.getPctztDTO().getZtrylxmc());
|
|
|
- } else if (ObjectUtils.allFieldIsNULL(resultDTO)) {
|
|
|
+ } else if (ObjectUtils.allFieldIsNULL(resultDTO) || StrUtil.containsAnyIgnoreCase(hcjg, "通过")) {
|
|
|
rshyVo.setPass(PassStatusEnum.NORMAL_TRAFFIC.getCode()).setDisplayMsg(PassStatusEnum.NORMAL_TRAFFIC.getDesc()).setTts(PassStatusEnum.NORMAL_TRAFFIC.getDesc());
|
|
|
} else {
|
|
|
rshyVo.setPass(PassStatusEnum.RIGHT_WAY.getCode()).setKind(kind(resultDTO)).setWarning(warning(resultDTO)).setDisplayMsg(PassStatusEnum.RIGHT_WAY.getDesc()).setTts(PassStatusEnum.RIGHT_WAY.getDesc());
|
|
@@ -161,6 +168,7 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
|
|
|
/**
|
|
|
* 今日进站次数
|
|
|
+ *
|
|
|
* @param idNumber 身份证号
|
|
|
* @return
|
|
|
*/
|
|
@@ -170,7 +178,7 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
String timesStr = stringRedisTemplate.opsForValue().get(cacheKey);
|
|
|
if (timesStr == null) {
|
|
|
//今日进站次数
|
|
|
- stringRedisTemplate.opsForValue().set(cacheKey, String.valueOf(times),DateUtil.endOfDay(DateUtil.date()).getTime() - DateUtil.date().getTime(), TimeUnit.MILLISECONDS);
|
|
|
+ stringRedisTemplate.opsForValue().set(cacheKey, String.valueOf(times), DateUtil.endOfDay(DateUtil.date()).getTime() - DateUtil.date().getTime(), TimeUnit.MILLISECONDS);
|
|
|
} else {
|
|
|
times = Integer.valueOf(timesStr) + 1;
|
|
|
stringRedisTemplate.opsForValue().increment(cacheKey);
|