<%= if @acl[:id] link_to_remote _('btn_x'), :url => acl_path(@acl), :method => :get else link_to_function _('btn_x'), "['add_acl', 'add_acl_form'].each(Element.toggle);" end %>
<%= error_messages_for(:acl, :object => @acl) %>
<% if @acl[:id] %> <%= form_remote_tag(:url=> acl_path(@acl)) %> <%= hidden_field('acl', 'id') %> <% else %> <%= form_remote_tag(:url=> acls_path) %> <% end %>
<%= _('group')%> <%= help(_('acl_group_help')) %> <%= select('acl', 'group_id', visitor.all_groups.map{|g| [g.name, g.id]}) %>
<%= _('action')%> <%= help(_('acl_action_help')) %> <%= select('acl', 'action', Acl::ACTIONS ) %> <%= _('create only: allow') %> <%= select('acl', 'create_kpath', Node.kpaths_for_form ) %>
<%= _('priority')%> <%= help(_('acl_priority_help')) %> <%= text_field('acl', 'priority', :size => 4 ) %>
<%= _('name')%> <%= text_field('acl', 'name', :size=>15 ) %>
<%= _('mode')%> <%= help(_('acl_mode_help')) %> <%= text_field('acl', 'mode', :size=>15 ) %>
<%= _('format')%> <%= help(_('acl_format_help')) %> <%= text_field('acl', 'format', :size=>15 ) %>
<%= _('description')%> <%= text_area('acl', 'description', :rows => 2, :cols => 40) %>
<%= _('query')%> <%= help(_('acl_query_help')) %> <%= text_area('acl', 'query', :rows => 4, :cols => 40) %>
<%= _('exec group')%> <%= help(_('acl_exec_group_help')) %> <%= select('acl', 'exec_group_id', visitor.all_groups.map{|g| [g.name, g.id]}, :include_blank => true) %>
<%= _('exec skin')%> <%= help(_('acl_exec_skin_help')) %> <%= select('acl', 'exec_skin_id', form_skins, {:include_blank => true, :selected => @acl.exec_skin_zip}) %>
'/>
<% if !@acl.new_record? -%> <%= form_remote_tag(:url => acl_path(@acl), :confirm => _('Are you sure you want to destroy this access ?') ) %>

<%= _('destroy acl') %> '>

<% end -%>