<div id="c-admin-users">
  <div id="a-edit">
    <h1>Edit User: <%= @user.name %></h1>

    <%= form_tag(admin_user_path(@user), :method => :put, :class => "simple_form") do %>
      <%= hidden_field_tag "id", @user.id %>

      <div class="input integer optional">
        <label for="user_level" class="optional">Level</label>
        <%= user_level_select(:user, :level) %>
      </div>

      <div class="input">
        <label for="user_can_upload_free" class="optional">Unrestricted Uploads</label>
        <%= select(:user, :can_upload_free, [["Yes", true], ["No", false]]) %>
      </div>

      <div class="input">
        <label for="user_can_approve_posts" class="optional">Approve Posts</label>
        <%= select(:user, :can_approve_posts, [["Yes", true], ["No", false]]) %>
      </div>

      <%= submit_tag "Update" %>
    <% end %>
  </div>
</div>

<%= render "users/secondary_links" %>

<% content_for(:page_title) do %>
  Edit User - <%= Danbooru.config.app_name %>
<% end %>
