|
@@ -64,25 +64,25 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
ResultDTO resultDTO = new ResultDTO();
|
|
|
resultDTO.setPctgkryDTO(gkryDTO);
|
|
|
DateTime beginDate = DateTime.now();
|
|
|
- PctjkmInfoDTO barCodes = null;
|
|
|
+ PctjkmInfoDTO jkmInfo = null;
|
|
|
|
|
|
if (StringUtils.isNotBlank(rshyParam.getBarCode()) || StringUtils.isNotBlank(rshyParam.getSfzh())) {
|
|
|
try {
|
|
|
//查询健康码信息
|
|
|
- barCodes = itfwServer.getPctjkm(rshyParam.getBarCode(), rshyParam.getSfzh(), rshyParam.getTimeout());
|
|
|
+ jkmInfo = itfwServer.getPctjkm(rshyParam.getBarCode(), rshyParam.getSfzh(), rshyParam.getTimeout());
|
|
|
} catch (Exception e) {
|
|
|
log.error("查询健康码信息异常:{}", e.getMessage());
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
|
|
|
- if (barCodes == null) {
|
|
|
+ if (jkmInfo == null) {
|
|
|
return rshyVo;
|
|
|
}
|
|
|
|
|
|
- rshyParam.setSfzh(barCodes.getId_num());
|
|
|
- rshyParam.setXm(barCodes.getUser_name());
|
|
|
- String codeLabel = barCodes.getCOLOR_CODE_LABEL();
|
|
|
- String phone = barCodes.getPn();
|
|
|
+ rshyParam.setSfzh(jkmInfo.getId_num());
|
|
|
+ rshyParam.setXm(jkmInfo.getUser_name());
|
|
|
+ String codeLabel = jkmInfo.getCOLOR_CODE_LABEL();
|
|
|
+ String phone = jkmInfo.getPn();
|
|
|
rshyVo.setXm(rshyParam.getXm()).setSfzh(rshyParam.getSfzh()).setHealthCode(codeLabel).setPhone(phone);
|
|
|
}
|
|
|
|
|
@@ -95,13 +95,15 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
add(() -> resultDTO.setPcthsResultDTO(itfwServer.getPcths(rshyParam.getSfzh(), rshyParam.getTimeout())));
|
|
|
|
|
|
if (StrUtil.isNotBlank(rshyParam.getPhoto())) {
|
|
|
- add(() -> resultDTO.setPersonIdentifyDTO(viidServer.personIdentify(rshyParam.getPhoto(), rshyParam.getTimeout())));
|
|
|
+ //add(() -> resultDTO.setPersonIdentifyDTO(viidServer.personIdentify(rshyParam.getPhoto(), rshyParam.getTimeout())));
|
|
|
add(() -> quickRshyVo.set(getQuickRyhyInfo(new RshyQuickParam().setPhoto(rshyParam.getPhoto()).setTimeout(rshyParam.getTimeout()))));
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
|
|
|
- if (rshyParam.getScreenLocked() == 0 && (barCodes == null || PassStatusEnum.GREEN_CODE.getDesc().equals(barCodes.getCOLOR_CODE_LABEL()))) {
|
|
|
+ //if (rshyParam.getScreenLocked() == 0 && (barCodes == null || PassStatusEnum.GREEN_CODE.getDesc().equals(barCodes.getCOLOR_CODE_LABEL()))) {
|
|
|
+ //绿码人员继续进行七大类管控接口和人车核录接口比对
|
|
|
+ if (jkmInfo != null && PassStatusEnum.GREEN_CODE.getDesc().equals(jkmInfo.getCOLOR_CODE_LABEL())) {
|
|
|
taskList.add(() -> resultDTO.getPctgkryDTO().setPctdfkDTO(itfwServer.getPctdfk(rshyParam.getSfzh(), "", rshyParam.getTimeout())));
|
|
|
taskList.add(() -> resultDTO.getPctgkryDTO().setPctjsryDTO(itfwServer.getPctjsry(rshyParam.getSfzh(), rshyParam.getTimeout())));
|
|
|
taskList.add(() -> resultDTO.getPctgkryDTO().setPctztDTO(itfwServer.getPctzt(rshyParam.getSfzh(), rshyParam.getTimeout())));
|
|
@@ -133,44 +135,44 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
rshyVo.setXb(SexEnum.codeOf(IdcardUtil.getGenderByIdCard(rshyParam.getSfzh())).getDesc());
|
|
|
Date date = DateUtil.parse(IdcardUtil.getBirthByIdCard(rshyParam.getSfzh()));
|
|
|
rshyVo.setBirthday(DateUtil.format(date, "yyyy-M-d"));
|
|
|
- PctrchlDTO pctrchlDTO = resultDTO.getPctrchlDTO();
|
|
|
- //resultDTO.setPctrchlDTO(null);
|
|
|
- String hcjg = "";
|
|
|
- if (pctrchlDTO != null) {
|
|
|
- hcjg = pctrchlDTO.getHcjg();
|
|
|
- }
|
|
|
+
|
|
|
+ String hcjg = resultDTO.getPctrchlDTO() == null ? "" : resultDTO.getPctrchlDTO().getHcjg();
|
|
|
+
|
|
|
|
|
|
//if (rshyVo.getNucleic_acid().getStatus() == 0) {
|
|
|
// rshyVo.setPass(PassStatusEnum.NO_COMPLIANCE.getCode()).setTts(PassStatusEnum.NO_COMPLIANCE.getTts()).setDisplayMsg(PassStatusEnum.NO_COMPLIANCE.getDesc());
|
|
|
//}else {
|
|
|
|
|
|
+ System.out.println("省厅置信接口: " + resultDTO.getPersonIdentifyDTO());
|
|
|
if (resultDTO.getPersonIdentifyDTO() != null && !rshyParam.getSfzh().equals(resultDTO.getPersonIdentifyDTO().getIdNumber())) {
|
|
|
- //认证或者人码不符
|
|
|
+ //人证或者人码不符
|
|
|
rshyVo.setPass(PassStatusEnum.NO_MATCHED.getCode()).setTimes(times(rshyParam.getSfzh())).setTts(PassStatusEnum.NO_MATCHED.getTts()).setDisplayMsg(PassStatusEnum.NO_MATCHED.getDesc()).setWarning(PassStatusEnum.NO_MATCHED.getDesc()).setKind(PassStatusEnum.NO_MATCHED.getDesc());
|
|
|
- } else if (barCodes != null && PassStatusEnum.RED_CODE.getDesc().equalsIgnoreCase(barCodes.getCOLOR_CODE_LABEL())) {
|
|
|
+ } else if (jkmInfo != null && PassStatusEnum.RED_CODE.getDesc().equalsIgnoreCase(jkmInfo.getCOLOR_CODE_LABEL())) {
|
|
|
//红码
|
|
|
rshyVo.setPass(PassStatusEnum.RED_CODE.getCode()).setTimes(times(rshyParam.getSfzh())).setTts(PassStatusEnum.RED_CODE.getTts()).setDisplayMsg(PassStatusEnum.RED_CODE.getDesc()).setWarning(PassStatusEnum.RED_CODE.getDesc()).setKind("健康码" + PassStatusEnum.RED_CODE.getDesc());
|
|
|
- } else if (barCodes != null && PassStatusEnum.YELLOW_CODE.getDesc().equalsIgnoreCase(barCodes.getCOLOR_CODE_LABEL())) {
|
|
|
+ } else if (jkmInfo != null && PassStatusEnum.YELLOW_CODE.getDesc().equalsIgnoreCase(jkmInfo.getCOLOR_CODE_LABEL())) {
|
|
|
//黄码
|
|
|
rshyVo.setPass(PassStatusEnum.YELLOW_CODE.getCode()).setTimes(times(rshyParam.getSfzh())).setTts(PassStatusEnum.YELLOW_CODE.getTts()).setDisplayMsg(PassStatusEnum.YELLOW_CODE.getDesc()).setWarning(PassStatusEnum.YELLOW_CODE.getDesc()).setKind("健康码" + PassStatusEnum.YELLOW_CODE.getDesc());
|
|
|
} else if (resultDTO.getPctgkryDTO().getPctztDTO() != null || StrUtil.containsAnyIgnoreCase(hcjg, "抓捕") || StrUtil.containsAnyIgnoreCase(hcjg, "拦截")) {
|
|
|
//在逃 或者 人车核录接口返回 抓捕或者拦截
|
|
|
rshyVo.setPass(PassStatusEnum.NO_PASSING.getCode()).setTts(PassStatusEnum.NO_PASSING.getTts()).setDisplayMsg(PassStatusEnum.NO_PASSING.getDesc()).setWarning("在逃人员:" + resultDTO.getPctgkryDTO().getPctztDTO().getJyaq()).setKind(resultDTO.getPctgkryDTO().getPctztDTO().getZtrylxmc());
|
|
|
- //} else if (ObjectUtils.allFieldIsNULL(resultDTO.getPctgkryDTO()) || StrUtil.containsAnyIgnoreCase(hcjg, "通过")) {
|
|
|
- // rshyVo.setPass(PassStatusEnum.NORMAL_TRAFFIC.getCode()).setDisplayMsg(PassStatusEnum.NORMAL_TRAFFIC.getDesc()).setTts(PassStatusEnum.NORMAL_TRAFFIC.getTts());
|
|
|
+ //} else if (ObjectUtils.allFieldIsNULL(resultDTO.getPctgkryDTO()) || StrUtil.containsAnyIgnoreCase(hcjg, "通过")) {
|
|
|
+ // rshyVo.setPass(PassStatusEnum.NORMAL_TRAFFIC.getCode()).setDisplayMsg(PassStatusEnum.NORMAL_TRAFFIC.getDesc()).setTts(PassStatusEnum.NORMAL_TRAFFIC.getTts());
|
|
|
} else if (!ObjectUtils.allFieldIsNULL(resultDTO.getPctgkryDTO()) || StrUtil.containsAnyIgnoreCase(hcjg, "存疑")) {
|
|
|
+ //七大类管控人员(在逃除外)和人车核录接口返回存疑人员
|
|
|
rshyVo.setPass(PassStatusEnum.RIGHT_WAY.getCode()).setKind(kind(resultDTO)).setWarning(warning(resultDTO)).setDisplayMsg(PassStatusEnum.RIGHT_WAY.getDesc()).setTts(PassStatusEnum.RIGHT_WAY.getTts());
|
|
|
} else if (quickRshyVo.get() != null && StrUtil.isNotEmpty(quickRshyVo.get().getSfzh())) {
|
|
|
//快速通行
|
|
|
rshyVo = quickRshyVo.get();
|
|
|
} else {
|
|
|
+ //正常通过
|
|
|
rshyVo.setPass(PassStatusEnum.NORMAL_TRAFFIC.getCode()).setDisplayMsg(PassStatusEnum.NORMAL_TRAFFIC.getDesc()).setTts(PassStatusEnum.NORMAL_TRAFFIC.getTts());
|
|
|
}
|
|
|
|
|
|
if (rshyVo.getHealthCode() != null) {
|
|
|
rshyVo.setTts(rshyVo.getHealthCode());
|
|
|
}
|
|
|
- //}
|
|
|
+
|
|
|
log.info("普通核验响应内容:{}", JSON.toJSONString(rshyVo));
|
|
|
return rshyVo;
|
|
|
}
|
|
@@ -227,7 +229,7 @@ public class RshyJkManagerImpl implements RshyJkManager {
|
|
|
.setWarning(stringMap.get(repositoryVO.getRepository_id())).setDisplayMsg(RepositoryEnum.COUNTRY_LARGE.getId().equals(repositoryVO.getRepository_id()) ? PassStatusEnum.NO_PASSING.getDesc() : PassStatusEnum.RIGHT_WAY.getDesc())
|
|
|
.setTts(RepositoryEnum.COUNTRY_LARGE.getId().equals(repositoryVO.getRepository_id()) ? PassStatusEnum.NO_PASSING.getTts() : PassStatusEnum.RIGHT_WAY.getTts()).setHealthCode(StrUtil.EMPTY).setSfzh(repositoryVO.getPersonId())
|
|
|
.setXm(repositoryVO.getName()).setXb(SexEnum.codeOf(repositoryVO.getGender()).getDesc()).setMz(StrUtil.EMPTY).setPhone(StrUtil.EMPTY).setAddress(StrUtil.EMPTY).setPhoto(rshyQuickParam.getPhoto());
|
|
|
- log.info("快速核验响应内容:{}", JSON.toJSONString(rshyVo));
|
|
|
+ //log.info("快速核验响应内容:{}", JSON.toJSONString(rshyVo));
|
|
|
return rshyVo;
|
|
|
}
|
|
|
|