Browse Source

Merge remote-tracking branch 'origin/prod-5.1.3' into prod-5.1.3

zhongwei
haungxing 3 months ago
parent
commit
3c559c4293
  1. 3
      hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/train/vo/TrainParamVo.java
  2. 23
      hzims-service/assets/src/main/java/com/hnac/hzims/spare/service/impl/SpWarehouseOutServiceImpl.java
  3. 4
      hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java
  4. 2
      hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/task/mapper/TaskMapper.xml
  5. 5
      hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/train/service/impl/TrainServiceImpl.java

3
hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/train/vo/TrainParamVo.java

@ -20,4 +20,7 @@ public class TrainParamVo {
@ApiModelProperty(value = "培训结束时间") @ApiModelProperty(value = "培训结束时间")
private String endTime; private String endTime;
@ApiModelProperty(value = "主讲人名称")
private String speakerName;
} }

23
hzims-service/assets/src/main/java/com/hnac/hzims/spare/service/impl/SpWarehouseOutServiceImpl.java

@ -16,6 +16,7 @@ import com.hnac.hzims.spare.service.*;
import com.hnac.hzims.spare.vo.SpWarehouseOutVO; import com.hnac.hzims.spare.vo.SpWarehouseOutVO;
import com.hnac.hzims.spare.vo.WtSpBasicVO; import com.hnac.hzims.spare.vo.WtSpBasicVO;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import org.apache.commons.lang3.ObjectUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springblade.core.log.exception.ServiceException; import org.springblade.core.log.exception.ServiceException;
@ -258,16 +259,18 @@ public class SpWarehouseOutServiceImpl extends ServiceImpl<SpWarehouseOutMapper,
List<WtSpBasicVO> basicVOList = new ArrayList<>(); List<WtSpBasicVO> basicVOList = new ArrayList<>();
for (int i = 0; i < basicList.size(); i++) { for (int i = 0; i < basicList.size(); i++) {
WtSpBasicEntity spBasicEntity = basicService.getById(basicList.get(i).getSpBasicId()); WtSpBasicEntity spBasicEntity = basicService.getById(basicList.get(i).getSpBasicId());
WtSpBasicVO spBasicVO = new WtSpBasicVO(); if (ObjectUtils.isNotEmpty(spBasicEntity)) {
spBasicVO.setId(spBasicEntity.getId()); WtSpBasicVO spBasicVO = new WtSpBasicVO();
spBasicVO.setCode(spBasicEntity.getCode()); spBasicVO.setId(spBasicEntity.getId());
spBasicVO.setName(spBasicEntity.getName()); spBasicVO.setCode(spBasicEntity.getCode());
spBasicVO.setSpecifications(spBasicEntity.getSpecifications()); spBasicVO.setName(spBasicEntity.getName());
spBasicVO.setUnit(spBasicEntity.getUnit()); spBasicVO.setSpecifications(spBasicEntity.getSpecifications());
spBasicVO.setPrice(spBasicEntity.getPrice()); spBasicVO.setUnit(spBasicEntity.getUnit());
spBasicVO.setStock(basicList.get(i).getAmount().longValue()); spBasicVO.setPrice(spBasicEntity.getPrice());
spBasicVO.setCreateTime(spBasicEntity.getCreateTime()); spBasicVO.setStock(basicList.get(i).getAmount().longValue());
basicVOList.add(spBasicVO); spBasicVO.setCreateTime(spBasicEntity.getCreateTime());
basicVOList.add(spBasicVO);
}
} }
spWarehouseOutVO.setBasicVOList(basicVOList); spWarehouseOutVO.setBasicVOList(basicVOList);
return spWarehouseOutVO; return spWarehouseOutVO;

4
hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/inspect/impl/TaskServiceImpl.java

@ -41,8 +41,8 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, TaskEntity> impleme
// 查询所有巡检任务 // 查询所有巡检任务
List<TaskEntity> tasks = this.list(new LambdaQueryWrapper<TaskEntity>() {{ List<TaskEntity> tasks = this.list(new LambdaQueryWrapper<TaskEntity>() {{
ge(TaskEntity::getPlanStartTime, start) ge(TaskEntity::getPlanStartTime, start)
.le(TaskEntity::getPlanStartTime, end) .le(TaskEntity::getPlanStartTime, end)
.in(TaskEntity::getCreateDept, areas); .in(TaskEntity::getCreateDept, areas);
}}); }});
if(CollectionUtil.isEmpty(tasks)){ if(CollectionUtil.isEmpty(tasks)){
return task; return task;

2
hzims-service/inspect/src/main/java/com/hnac/hzinfo/inspect/task/mapper/TaskMapper.xml

@ -16,7 +16,7 @@
and t.PLAN_START_TIME &gt;= #{task.planStartTime} and t.PLAN_START_TIME &gt;= #{task.planStartTime}
</if> </if>
<if test="task.planStartTimeEnd != null"> <if test="task.planStartTimeEnd != null">
and t.PLAN_START_TIME &gt;= #{task.planStartTime} and t.PLAN_START_TIME &lt;= #{task.planStartTimeEnd}
</if> </if>
<if test="task.planEndTime != null"> <if test="task.planEndTime != null">
and t.PLAN_END_TIME &lt;= #{task.planEndTime} and t.PLAN_END_TIME &lt;= #{task.planEndTime}

5
hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/train/service/impl/TrainServiceImpl.java

@ -32,7 +32,7 @@ public class TrainServiceImpl extends ServiceImpl<TrainMapper, TrainEntity> impl
LambdaQueryWrapper<TrainEntity> wrapper = new LambdaQueryWrapper(); LambdaQueryWrapper<TrainEntity> wrapper = new LambdaQueryWrapper();
wrapper.orderByDesc(TrainEntity::getCreateTime); wrapper.orderByDesc(TrainEntity::getCreateTime);
if(StringUtil.isNotBlank(params.getStationId())){ if(StringUtil.isNotBlank(params.getStationId())){
wrapper.eq(TrainEntity::getStationId,params.getStartTime()); wrapper.eq(TrainEntity::getStationId,params.getStationId());
} }
if(StringUtil.isNotBlank(params.getStartTime())){ if(StringUtil.isNotBlank(params.getStartTime())){
wrapper.ge(TrainEntity::getTrainStartTime,params.getStartTime() + " 00:00:00"); wrapper.ge(TrainEntity::getTrainStartTime,params.getStartTime() + " 00:00:00");
@ -40,6 +40,9 @@ public class TrainServiceImpl extends ServiceImpl<TrainMapper, TrainEntity> impl
if(StringUtil.isNotBlank(params.getEndTime())){ if(StringUtil.isNotBlank(params.getEndTime())){
wrapper.le(TrainEntity::getTrainStartTime,params.getEndTime() + " 23:59:59"); wrapper.le(TrainEntity::getTrainStartTime,params.getEndTime() + " 23:59:59");
} }
if(StringUtil.isNotBlank(params.getSpeakerName())){
wrapper.like(TrainEntity::getSpeakerName,params.getSpeakerName());
}
return super.page(page,wrapper); return super.page(page,wrapper);
} }

Loading…
Cancel
Save