|
|
@ -10,8 +10,6 @@ import org.apache.ibatis.annotations.Param; |
|
|
|
import org.apache.ibatis.annotations.Select; |
|
|
|
import org.springframework.stereotype.Repository; |
|
|
|
|
|
|
|
import java.util.Map; |
|
|
|
|
|
|
|
/** |
|
|
|
* @ClassName: VideoWarningMapper |
|
|
|
* @Description: TODO |
|
|
@ -27,8 +25,9 @@ public interface VideoWarningMapper extends BaseMapper<VideoWarning> { |
|
|
|
"SELECT a.id,a.code,a.type,a.name,a.warning_time," + |
|
|
|
" (case when a.type = 1 then (select dike_name from bs_sgc_df_gcda where dike_code = a.code and expr_date is null) " + |
|
|
|
" when a.type = 2 then (select waga_name from bs_sgc_sz_jbxx where waga_code = a.code and expr_date is null ) end) as objName " + |
|
|
|
" FROM bs_sgc_stc_spfx a order by a.create_time desc" + |
|
|
|
" <if test='dto.code != null and dto.code != \"\"'>" + |
|
|
|
" FROM bs_sgc_stc_spfx a " + |
|
|
|
"WHERE 1=1" + |
|
|
|
"<if test='dto.code != null and dto.code != \"\"'>" + |
|
|
|
"AND a.code = #{dto.code} " + |
|
|
|
"</if>" + |
|
|
|
"<if test='dto.startTime != null'>" + |
|
|
@ -43,14 +42,11 @@ public interface VideoWarningMapper extends BaseMapper<VideoWarning> { |
|
|
|
"#{type}" + |
|
|
|
"</foreach>" + |
|
|
|
"</if>" + |
|
|
|
"<if test='order != null' and order.size() > 0'>" + |
|
|
|
"ORDER BY " + |
|
|
|
"<foreach collection='order' item='value' separator=','>" + |
|
|
|
"${value.key} ${value.value}" + |
|
|
|
"</foreach>" + |
|
|
|
"<if test='order != null and order != \"\"'>" + |
|
|
|
"ORDER BY ${order} " + |
|
|
|
"</if>" + |
|
|
|
"</script>") |
|
|
|
IPage<VideoWarningDto> search(Page<VideoWarning> page, @Param("dto") WarningQueDto dto, @Param("order") Map<String, Object> params); |
|
|
|
IPage<VideoWarningDto> search(Page<VideoWarning> page, @Param("dto") WarningQueDto dto, @Param("order") String order); |
|
|
|
|
|
|
|
@Select("<script>" + |
|
|
|
"SELECT a.id,a.code,a.type,a.name,a.warning_time ," + |
|
|
|