提交 d2bb1116 作者: 刘明祎-运维用途

添加搜索条件

上级 6dd1b675
......@@ -54,6 +54,10 @@ public class IndustryCaseQO implements Serializable {
@Min(value = 1, groups = Page.class)
private Integer pageSize;
@ApiModelProperty(value = "是否是热点新闻")
private Integer isHot;
public void buildCurrentPage() {
this.pageNo = (pageNo - 1) * pageSize;
}
......
......@@ -40,6 +40,9 @@ public class IndustryNewsQO implements Serializable {
@Min(value = 1, groups = Page.class)
private Integer pageSize;
@ApiModelProperty(value = "是否是热点新闻")
private Integer isHot;
public void buildCurrentPage() {
this.pageNo = (pageNo - 1) * pageSize;
}
......
......@@ -31,7 +31,8 @@
news_contents,
origin,
create_time,
update_time
update_time,
is_hot
from industry_news
where is_deleted = 0
<if test=" userIds != null ">
......@@ -43,6 +44,9 @@
<if test="date != null ">
and Date(create_time) = #{date}
</if>
<if test="isHot != null">
and is_hot = #{isHot}
</if>
<if test="keyword != null ">
and news_title like CONCAT("%",#{keyword},"%")
</if>
......@@ -170,6 +174,9 @@
<if test="endTime != null">
and create_time &lt;= #{endTime}
</if>
<if test="isHot != null">
and is_hot = #{isHot}
</if>
</where>
order by is_hot desc,create_time desc
limit #{pageNo}, #{pageSize}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论