<% if f.object.group.blank? || f.object.group.active? %> <%= f.select :group_id, active_user_groups_select_options(current_user) %> <% else %> <%= f.object.user_group.name %> <% end %>