Sha256: 702e45ccce84adaadf408d943569158ac9e4467fd32ec998188e4e75e5c51ebc

Contents?: true

Size: 1.42 KB

Versions: 4

Compression:

Stored size: 1.42 KB

Contents

<% fieldset_class  ||= '' %>
<% select_label_id ||= '' %>

<%= form_tag add_member_collections_path, method: :put do %>
  <fieldset class="required <%= fieldset_class %>">
    <%= hidden_field_tag :collectible_id, collectible.pid %>

    <div class="control-group collection_id">
      <div class="controls">
        <% options = "" %>
        <% collections = available_collections(collectible) %>
        <% if collections.any? -%>
          <% options << '<optgroup label="Your Collections">'.html_safe %>
          <% options << options_from_collection_for_select(collections, "pid", "title") %>
          <% options << '</optgroup>'.html_safe %>
        <% end %>
        <% options << options_from_collection_for_select(available_profiles, "pid", "title") %>
        <% if current_users_profile_sections.any? %>
          <% options << '<optgroup label="Profile Sections">'.html_safe %>
          <% options << options_from_collection_for_select(current_users_profile_sections, "pid", "title") %>
          <% options << '</optgroup>'.html_safe %>
        <% end %>
        <%= select_tag :profile_collection_id, options, prompt: 'Make a Selection', class: 'input-xlarge', :'aria-labelledby' => select_label_id %>
      </div>
    </div>

  </fieldset>
  <div class="form-actions">
    <%= submit_tag "Add It!", class: 'btn btn-primary' %>
    <%= link_to 'never mind', root_path, class: 'btn btn-link', data: { dismiss: 'modal' } %>
  </div>
<% end %>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
curate-0.6.6 app/views/curate/collections/_form_to_add_member.html.erb
curate-0.6.5 app/views/curate/collections/_form_to_add_member.html.erb
curate-0.6.4 app/views/curate/collections/_form_to_add_member.html.erb
curate-0.6.3 app/views/curate/collections/_form_to_add_member.html.erb