Sha256: 110c0b125cd3e4a391441b6ea5ebe898dc6e25bea5104d1ccc256da3cbd706ac

Contents?: true

Size: 1.13 KB

Versions: 12

Compression:

Stored size: 1.13 KB

Contents

<%= admin_form_for [:admin, parent, resource] do |f| %>
  <%= f.inputs do %>
    <%= f.input :user,
                collection: membership_users_collection(parent, resource),
                include_blank: false,
                input_html: { disabled: !f.object.new_record? || parent_type == :user }%>
    <% if params[:entity_type].to_sym == :entry %>
      <%= render partial: 'admin/memberships/entity_entry_input', locals: {f: f} %>
    <% else %>
      <%= render partial: 'admin/memberships/entity_account_input', locals: {f: f} %>
    <% end %>
    <%= f.hidden_field :entity_type, value: "Pageflow::#{params[:entity_type].capitalize}" %>
  <% end %>
  <%= f.inputs do %>
    <%= render partial: 'admin/memberships/role_hint' %>
    <%= f.input :role,
                collection: membership_roles_collection("Pageflow::#{params[:entity_type]
                                                          .capitalize}"),
                                                          include_blank: false %>
  <% end %>
  <%= f.actions do %>
    <%= f.action(:submit) %>
    <%= f.action(:cancel, :wrapper_html => {:class => 'cancel'}) %>
  <% end %>
<% end %>

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
pageflow-12.0.4 app/views/admin/memberships/_form.html.erb
pageflow-12.0.3 app/views/admin/memberships/_form.html.erb
pageflow-12.0.2 app/views/admin/memberships/_form.html.erb
pageflow-12.0.1 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc7 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc6 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc5 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc4 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc3 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc2 app/views/admin/memberships/_form.html.erb
pageflow-12.0.0.rc1 app/views/admin/memberships/_form.html.erb