#encoding: utf-8
module UsersHelper

  include ApplicationHelper

  def admin_select(f)
    f.select(:admin_level, [ ["Keine", 0], ["Innerhalb der eigenen Rolle", 10], ["Alle", 20]] )
  end

  def states
    if theUser(session).is_admin?
      return FederalState.order(:id).to_a
    else
      return theUser(session).federal_states
    end
  end
end
