阿里云消息通知优化
This commit is contained in:
parent
d00b461151
commit
1e32df45b0
|
|
@ -46,25 +46,25 @@ public class UserDaoImpl extends HibernateBaseDao<User, Integer> implements User
|
|||
public List<Integer> getUserIds(String pushType,Integer firstResult, int maxResults) {
|
||||
//商家用户
|
||||
if(PushTypeEnum.all_shops_push.getKey().equals(pushType)){
|
||||
String sql = "select user_id from tbl_user where user_type=? and is_register_netease=? limit ?,?";
|
||||
String sql = "select user.user_id from tbl_user user,tbl_aliyun_device_info device where user_type=? and user.user_id = device.user_id and is_register_netease=? limit ?,?";
|
||||
List<Integer> list = this.getSession().createSQLQuery(sql).setString(0, UserTypeEnum.userType1.getKey()).setString(1, BooleanEnum.YES.getKey()).setInteger(2, firstResult).setInteger(3,maxResults).list();
|
||||
return list;
|
||||
}
|
||||
//安卓用户
|
||||
else if(PushTypeEnum.all_android_push.getKey().equals(pushType)){
|
||||
String sql = "select user_id from tbl_user where login_type=? and is_register_netease=? limit ?,?";
|
||||
String sql = "select user.user_id from tbl_user user,tbl_aliyun_device_info device where login_type=? and user.user_id = device.user_id and is_register_netease=? limit ?,?";
|
||||
List<Integer> list = this.getSession().createSQLQuery(sql).setString(0, PhoneTypeEnum.android.getKey()).setString(1, BooleanEnum.YES.getKey()).setInteger(2, firstResult).setInteger(3,maxResults).list();
|
||||
return list;
|
||||
}
|
||||
//IOS用户
|
||||
else if(PushTypeEnum.all_ios_push.getKey().equals(pushType)){
|
||||
String sql = "select user_id from tbl_user where login_type=? and is_register_netease=? limit ?,?";
|
||||
String sql = "select user.user_id from tbl_user user,tbl_aliyun_device_info device where login_type=? and user.user_id = device.user_id and is_register_netease=? limit ?,?";
|
||||
List<Integer> list = this.getSession().createSQLQuery(sql).setString(0, PhoneTypeEnum.ios.getKey()).setString(1, BooleanEnum.YES.getKey()).setInteger(2, firstResult).setInteger(3,maxResults).list();
|
||||
return list;
|
||||
}
|
||||
//所有用户
|
||||
else if(PushTypeEnum.all_push.getKey().equals(pushType)){
|
||||
String sql = "select user_id from tbl_user where is_register_netease=? limit ?,?";
|
||||
String sql = "select user.user_id from tbl_user user,tbl_aliyun_device_info device where is_register_netease=? and user.user_id = device.user_id limit ?,?";
|
||||
List<Integer> list = this.getSession().createSQLQuery(sql).setString(0, BooleanEnum.YES.getKey()).setInteger(1, firstResult).setInteger(2,maxResults).list();
|
||||
return list;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
#broker_url=tcp://test.ifish7.com:61616
|
||||
broker_url=tcp://www.ifish7.com:61616
|
||||
broker_url=tcp://localhost:61616
|
||||
username=admin
|
||||
#password=admin
|
||||
password=adminifish7
|
||||
|
|
|
|||
Loading…
Reference in New Issue