feat(eightwork): 添加对step_17其他参数的解析支持
parent
eab5c0bac2
commit
8d497c65f0
|
|
@ -130,6 +130,26 @@ public class EightworkInfoQueryExe {
|
|||
if (chooseLimitedSpaceJson == null) {
|
||||
chooseLimitedSpaceJson = new JSONObject();
|
||||
}
|
||||
JSONObject step17Json = infoJson.getJSONObject("step_17");
|
||||
if (step17Json == null) {
|
||||
step17Json = new JSONObject();
|
||||
}
|
||||
JSONObject step17OtherParamsJson = step17Json.getJSONObject("otherParams");
|
||||
if (step17OtherParamsJson == null && StringUtils.isNotBlank(step17Json.getString("otherParams"))) {
|
||||
try {
|
||||
step17OtherParamsJson = JSONObject.parseObject(step17Json.getString("otherParams"));
|
||||
} catch (Exception e) {
|
||||
log.warn("解析 step_17.otherParams 失败,使用空对象: workId={}", eightworkInfoDO.getWorkId(), e);
|
||||
step17OtherParamsJson = new JSONObject();
|
||||
}
|
||||
}
|
||||
if (step17OtherParamsJson == null) {
|
||||
step17OtherParamsJson = new JSONObject();
|
||||
}
|
||||
String workPersonCount = step17OtherParamsJson.getString("limitSpaceWorkNum");
|
||||
if (StringUtils.isBlank(workPersonCount)) {
|
||||
workPersonCount = infoJson.getString("limitSpaceWorkNum");
|
||||
}
|
||||
|
||||
EightworkConfinedspaceExcelExportEntity userExcelExportEntity = new EightworkConfinedspaceExcelExportEntity();
|
||||
userExcelExportEntity.setWorkTime(infoJson.getString("applyTime"));
|
||||
|
|
@ -138,7 +158,7 @@ public class EightworkInfoQueryExe {
|
|||
userExcelExportEntity.setSpaceNameAndCode(infoJson.getString("limitedSpaceNameAndCode"));
|
||||
userExcelExportEntity.setLocationAndRange(chooseLimitedSpaceJson.getString("positionAndRange"));
|
||||
userExcelExportEntity.setRiskLevel(chooseLimitedSpaceJson.getString("riskLevelName"));
|
||||
userExcelExportEntity.setWorkPersonCount(infoJson.getString("limitSpaceWorkNum"));
|
||||
userExcelExportEntity.setWorkPersonCount(workPersonCount);
|
||||
|
||||
//获取
|
||||
EightworkSupplementaryInfoDO eightworkSupplementaryInfoDO = eightworkSupplementaryInfoDOMap.get(eightworkInfoDO.getWorkId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue