Sha256: c870cc9168b2d753cbd25db22df2c22080f26013a802a632d4f75c5d0188b8bb

Contents?: true

Size: 844 Bytes

Versions: 4

Compression:

Stored size: 844 Bytes

Contents

<div>
  <%= render :partial => 'spree/shared/error_messages', :locals => { :target => @role } %>
</div>

<table>
  <%= form_tag [:admin, @role], :method => method do %>
    <tr><td>Name:</td><td><%= text_field_tag 'role[name]', @role.name %></td></tr>
    <tr><td>Permissions:</td>
    <td><% @permissions.each do |permission| %>
      <% if @role.has_permission?(permission.title) %>
        <span class='permission-check-box'><%= check_box_tag 'role[permission_ids][]', permission.id, true %><%= permission.title.gsub('-',' ').titleize %></span>
      <% else %>
        <span class='permission-check-box'><%= check_box_tag 'role[permission_ids][]', permission.id %><%= permission.title.gsub('-',' ').titleize %></span>
      <% end %>
      <br />
    <% end %></td></tr>
    <tr><td></td><td><%= submit_tag %></td></tr>
  <% end %>
</table>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
spree_admin_roles_and_access-1.2.1 app/views/spree/admin/roles/_form.html.erb
spree_admin_roles_and_access-1.2.0 app/views/spree/admin/roles/_form.html.erb
spree_admin_roles_and_access-1.1.0 app/views/spree/admin/roles/_form.html.erb
spree_admin_roles_and_access-1.0.0 app/views/spree/admin/roles/_form.html.erb