|
|
@@ -127,7 +127,7 @@ public class AdminManagerImplDao implements AdminManagerDao {
|
|
|
public List<AdminManager> queryPage(String sqlx, int page, int rows) {
|
|
|
SqlUtil.filterKeyword(sqlx);
|
|
|
int start = (page - 1) * rows;// 每页的起始下标
|
|
|
- String sql = selectSql + " WHERE a.status!=0 " + sqlx + " ORDER BY a.id DESC limit :start,:rows ";
|
|
|
+ String sql = selectSql + " WHERE a.status!=0 and a.hotel_name is not null " + sqlx + " ORDER BY a.id DESC limit :start,:rows ";
|
|
|
MapSqlParameterSource sps = new MapSqlParameterSource();
|
|
|
sps.addValue("start", start);
|
|
|
sps.addValue("rows", rows);
|
|
|
@@ -140,7 +140,7 @@ public class AdminManagerImplDao implements AdminManagerDao {
|
|
|
@Override
|
|
|
public int queryTotal(String sqlx) {
|
|
|
SqlUtil.filterKeyword(sqlx);
|
|
|
- String sql = "SELECT count(*) FROM`admin_manager` where status!=0 " + sqlx;
|
|
|
+ String sql = "SELECT count(*) FROM`admin_manager` where status!=0 and hotel_name is not null " + sqlx;
|
|
|
MapSqlParameterSource sps = new MapSqlParameterSource();
|
|
|
return namedParameterJdbcTemplate.queryForInt(sql, sps);
|
|
|
}
|