Revert non rulingcom email constraint

This commit is contained in:
chris 2013-07-04 14:20:13 +08:00
parent bec0bd76e4
commit 2c331bf1a5
1 changed files with 4 additions and 2 deletions

View File

@ -73,7 +73,8 @@ class Admin::MemberSelectsController < OrbitBackendController
@field = params[:field]
roles = Role.all
@sorted_users = roles.inject({}) do |users, role|
users[role] = role.users.where(:email.not => /guest|rulingcom/) - selected_users
# users[role] = role.users.where(:email.not => /guest|rulingcom/) - selected_users
users[role] = role.users.where(:email.not => /guest/) - selected_users
users
end
end
@ -82,7 +83,8 @@ class Admin::MemberSelectsController < OrbitBackendController
roles = Role.find(params[:role_ids]) rescue []
@field = params[:field]
@users = roles.inject([]) do |users, role|
users += role.users.where(:email.not => /guest|rulingcom/).entries
# users += role.users.where(:email.not => /guest|rulingcom/).entries
users += role.users.where(:email.not => /guest/).entries
users
end
render 'admin/member_selects/update_selected_users'