| | |
| | | } |
| | | |
| | | |
| | | public enum FILM_CATEGORY { |
| | | all("全部"), war("战争"); |
| | | |
| | | FILM_CATEGORY(String desc) { |
| | | this.desc = desc; |
| | | } |
| | | |
| | | private String desc; |
| | | |
| | | public String getDesc() { |
| | | return desc; |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | private Integer id; |
| | | |
| | | private String category; |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | if(StringUtils.isNotBlank(dto.getCreateDateEndStr())){ |
| | | dto.setCreateDateEnd(DateUtils.dateToLocalDateTime(dto.getCreateDateEndStr(),false)); |
| | | } |
| | | if (!StringUtils.isEmpty(dto.getCategory()) && Constants.FILM_CATEGORY.all.getDesc().equals(dto.getCategory())) { |
| | | //当时全部的时时候值设置为空,表示查询全部 |
| | | dto.setCategory(null); |
| | | } |
| | | |
| | | //todo 这里的用户ID可能为空,用户存在不登录的情况下访问,传null |
| | | try { |
| | |
| | | <if test="dto.classify != null and dto.classify != ''"> |
| | | AND t.classify = #{dto.classify} |
| | | </if> |
| | | <if test="dto.category != null and dto.category != ''"> |
| | | AND t.keywords LIKE CONCAT('%', #{dto.category}, '%') |
| | | </if> |
| | | <if test="dto.createDateBegin != null"> |
| | | <![CDATA[ |
| | | AND t.create_time >= #{dto.createDateBegin} |