%= error_messages_for :user %>
<% form_for [:admin, @user] do |f| %>
<%= f.label :login %>
<%= f.text_field :login %>
<%= f.label :email %>
<%= f.text_field :email %>
<%= f.label :password %>
<%= f.password_field :password %>
Leaving password blank keeps the current password
<%= f.label :password_confirmation %>
<%= f.password_field :password_confirmation %>
<%= f.label :plugin_access %>
<% @available_plugins.each do |plugin| -%>
<%# Since the dashboard is always included by the framework, this will maintain the user's order %>
<% if Refinery::Plugins.always_allowed.titles.include?(plugin) or (plugin == 'Users' and @user.id == current_user.id) %>
<%= hidden_field_tag 'user[plugins][]', plugin %>
<% else %>
-
<%= check_box_tag 'user[plugins][]', plugin, @selected_plugin_titles.include?(plugin), :id => "plugins_#{plugin.downcase.gsub(" ", "_")}" %>
<%= f.label 'user[plugins][]', plugin, :class => "stripped", :for => "plugins_#{plugin.downcase.gsub(" ", "_")}" %>
<% end %>
<% end %>
<%= render :partial => "/shared/admin/form_actions", :locals => {:f => f, :continue_editing => false} %>
<% end %>