Browse Source

修复不规范的代码

zhongwei
Jone 4 months ago
parent
commit
72e7b5e76c
  1. 5
      hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/monitor/entity/HisDataYc.java
  2. 2
      hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/task/service/impl/TaskServiceImpl.java
  3. 2
      hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyRecServiceImpl.java
  4. 1
      hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CarCheckTemplateServiceImpl.java
  5. 1
      hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java

5
hzims-service-api/equipment-api/src/main/java/com/hnac/hzims/monitor/entity/HisDataYc.java

@ -55,7 +55,10 @@ public class HisDataYc {
HisDataYc other = (HisDataYc) obj;
if (datatime == null) {
return other.datatime == null;
} else return datatime.equals(other.datatime);
} else {
return datatime.equals(other.datatime);
}
}
@Override

2
hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/task/service/impl/TaskServiceImpl.java

@ -271,7 +271,7 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, TaskEntity> impleme
R<String> r = sysClient.getParamValue(TaskContants.OPEN_MULTIPLE_TASK);
if (r.isSuccess() && "0".equals(r.getData())) {//处理同时开启几个任务的情况
Long count = taskUserService.count(Wrappers.<TaskUserEntity>query().lambda().eq(TaskUserEntity::getUserId, userId).eq(TaskUserEntity::getClaimStatus, ClaimStatusEnum.COLLECT.getStatus()));
if (count > 0l) {
if (count > 0L) {
log.error("不能同时开启两个巡检任务");
throw new ServiceException("不能同时开启两个巡检任务");
}

2
hzims-service/operational/src/main/java/com/hnac/hzims/operational/duty/service/impl/ImsDutyRecServiceImpl.java

@ -821,7 +821,7 @@ public class ImsDutyRecServiceImpl extends ServiceImpl<ImsDutyRecMapper, ImsDuty
}});
String dutyTime = DateUtil.format(mainEntityById.getDutyDate(), DateUtil.PATTERN_DATE) + " " +DateUtil.format(classEntity.getStartTime(), DateUtil.PATTERN_TIME);
Date dutyDate = DateUtil.parse(dutyTime, PATTERN_DATETIME);
if (dutyDate.getTime() > new Date().getTime()) {
if (dutyDate.getTime() > System.currentTimeMillis()) {
return R.fail("指定的值班开始时间不能晚于当前时间");
}

1
hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/service/impl/CarCheckTemplateServiceImpl.java

@ -69,6 +69,7 @@ public class CarCheckTemplateServiceImpl extends ServiceImpl<CarCheckTemplateMap
/**
* 根据名称获取车检模板
*/
@Override
public CarCheckTemplateEntity getCarCheckTemplateByName(String name) {
QueryWrapper<CarCheckTemplateEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.lambda().eq(CarCheckTemplateEntity::getTemplateName, name);

1
hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/twoTicket/service/impl/TicketProcessServiceImpl.java

@ -1355,6 +1355,7 @@ public class TicketProcessServiceImpl implements TicketProcessService, StartProc
* @param key
* @param value
*/
@Override
public void getDataConversion(Map<String, Object> dataConversion, String key, Object value) {
String newValue = value == null ? (String) value : value.toString();
if (StringUtils.isNoneBlank(newValue)) {

Loading…
Cancel
Save