Sha256: 4784d0cb859aa7fc4098e75eb6da8c2db77209472889877e0cda8d3b505e5cbc

Contents?: true

Size: 1.38 KB

Versions: 20

Compression:

Stored size: 1.38 KB

Contents

<%= form_for @permission do |f| %>

  <%= render 'error_messages', object: f.object %>

  <%= f.label :permission_type %>
  <%= f.select :permission_type, options_for_enum(@permission, :permission_type) %>
  
  <%= f.label :adeia_element_id %>
  <%= f.collection_select :adeia_element_id, Adeia::Element.all, :id, :name %>

  <%= f.label :global_owner %>
  <%= f.grouped_collection_select :global_owner, [ User, Adeia::Group ], :all, :human_name, :to_global_id, :name %>

  <%= f.label :read_right %>
  <%= f.check_box :read_right %>

  <%= f.label :create_right %>
  <%= f.check_box :create_right %>

  <%= f.label :update_right %>
  <%= f.check_box :update_right %>

  <%= f.label :destroy_right %>
  <%= f.check_box :destroy_right %>

  <%= f.label :resource_id %>
  <%= f.number_field :resource_id %>

  <%= f.fields_for :actions, (@permission.actions.build unless @permission.actions.any?) do |action_f| %>
    <div class="fields-for">
      <div class="actions-fields">
        <%= action_f.label :name %>
        <%= action_f.text_field :name %>

        <button class="remove-fields" data-type="actions"><%= t "adeia.permissions.form.actions.destroy" %></button>
      </div>

      <button class="add-fields" data-type="actions" data-count="<%= @permission.actions.count %>">
        <%= t "adeia.permissions.form.actions.add" %>
      </button>
    </div>

  <% end %>

  <%= f.submit %>

<% end %>

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
adeia-0.15.1 app/views/adeia/permissions/_form.html.erb
adeia-0.15.0 app/views/adeia/permissions/_form.html.erb
adeia-0.14.0 app/views/adeia/permissions/_form.html.erb
adeia-0.13.1 app/views/adeia/permissions/_form.html.erb
adeia-0.13.0 app/views/adeia/permissions/_form.html.erb
adeia-0.12.0 app/views/adeia/permissions/_form.html.erb
adeia-0.11.11 app/views/adeia/permissions/_form.html.erb
adeia-0.11.10 app/views/adeia/permissions/_form.html.erb
adeia-0.11.9 app/views/adeia/permissions/_form.html.erb
adeia-0.11.8 app/views/adeia/permissions/_form.html.erb
adeia-0.11.7 app/views/adeia/permissions/_form.html.erb
adeia-0.11.6 app/views/adeia/permissions/_form.html.erb
adeia-0.11.5 app/views/adeia/permissions/_form.html.erb
adeia-0.11.4 app/views/adeia/permissions/_form.html.erb
adeia-0.11.3 app/views/adeia/permissions/_form.html.erb
adeia-0.11.2 app/views/adeia/permissions/_form.html.erb
adeia-0.11.0 app/views/adeia/permissions/_form.html.erb
adeia-0.10.5 app/views/adeia/permissions/_form.html.erb
adeia-0.10.4 app/views/adeia/permissions/_form.html.erb
adeia-0.10.3 app/views/adeia/permissions/_form.html.erb