全周期档案查询修改
parent
b0e1d1d681
commit
de2acc3d04
|
|
@ -29,7 +29,7 @@ public class CommonDataPageSo {
|
|||
@Schema(description = "时间范围")
|
||||
private DateRangeSo dateSo;
|
||||
|
||||
@Schema(description = "类型(1大事记 2调度指令 3维修养护 4安全鉴定 5除险加固 6白蚁普查)")
|
||||
@Schema(description = "类型(1大事记 2调度记录 3维修养护 4安全鉴定 5除险加固 6白蚁普查)")
|
||||
private List<Integer> types;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ public class ProjectEventsVo {
|
|||
if (this.type == 1) {
|
||||
this.typeName = "大事记";
|
||||
} else if (this.type == 2) {
|
||||
this.typeName = "调度指令";
|
||||
this.typeName = "调度记录";
|
||||
} else if (this.type == 3) {
|
||||
this.typeName = "维修养护";
|
||||
}else if (this.type == 4) {
|
||||
|
|
|
|||
|
|
@ -106,4 +106,20 @@ public interface ProjectEventsMapper extends BaseMapper<ProjectEvents> {
|
|||
</script>
|
||||
""")
|
||||
List<Long> queryTermiteDetail(@Param("id") Long id);
|
||||
|
||||
@Select("""
|
||||
<script>
|
||||
|
||||
select t.id,t.start_time as eventsDate,t.dispatch_detail as eventsDesc,2 as type from public.dispatch_record t
|
||||
<where>
|
||||
<if test="obj.dateSo != null and obj.dateSo.start != null">
|
||||
t.start_time <![CDATA[>=]]> #{obj.dateSo.start}
|
||||
</if>
|
||||
<if test="obj.dateSo != null and obj.dateSo.end != null">
|
||||
and t.start_time <![CDATA[<=]]> #{obj.dateSo.end}
|
||||
</if>
|
||||
</where>
|
||||
</script>
|
||||
""")
|
||||
List<ProjectEventsVo> dispatchList(@Param("obj") CommonDataPageSo page);
|
||||
}
|
||||
|
|
@ -136,6 +136,10 @@ public class ProjectEventsService extends ServiceImpl<ProjectEventsMapper, Proje
|
|||
List<ProjectEventsVo> projectEventsVos = this.baseMapper.eventList(page);
|
||||
list.addAll(projectEventsVos);
|
||||
}
|
||||
if(CollectionUtils.isEmpty(types) || (CollectionUtils.isNotEmpty(types)) && types.contains(2)){
|
||||
List<ProjectEventsVo> projectEventsVos = this.baseMapper.dispatchList(page);
|
||||
list.addAll(projectEventsVos);
|
||||
}
|
||||
if(CollectionUtils.isEmpty(types) || (CollectionUtils.isNotEmpty(types)) && types.contains(3)){
|
||||
List<ProjectEventsVo> projectEventsVos = this.baseMapper.maintainList(page);
|
||||
list.addAll(projectEventsVos);
|
||||
|
|
|
|||
Loading…
Reference in New Issue