Sha256: 950c9c9e647c0b9529eae677db4d9368b7826c4edecddee59e5642abb47a057a

Contents?: true

Size: 1.22 KB

Versions: 23

Compression:

Stored size: 1.22 KB

Contents

<%= bootstrap_form_for([current_exhibit, @resource.becomes(Spotlight::Resources::Upload)], layout: :horizontal, label_col: 'col-md-2', control_col: 'col-sm-6 col-md-6', html: { class: 'item-upload-form', multipart: true } ) do |f| %>
  <%= f.url_field :url, type: "file", help: t('.url-field.help', extensions: Spotlight::Engine.config.allowed_upload_extensions.join(' ')), label: "File" %>
  <%= f.fields_for :data do |d| %>
    <% Spotlight::Resources::Upload.fields(current_exhibit).each do |config| %>
      <%= d.send(config.form_field_type, config.field_name, label: uploaded_field_label(config)) %>
    <% end %>

    <% current_exhibit.custom_fields.each do |custom_field| %>
      <%= render partial: "spotlight/custom_fields/form_group/#{custom_field.field_type}", locals: { inline: true, f: d, field: custom_field, value: nil }  %>
    <% end %>
  <% end %>
  <div class="form-actions">
    <div class="primary-actions">
      <%= hidden_field_tag :tab, 'upload', id: nil %>
      <%= cancel_link @resource, :back, class: 'btn-sizing' %>
      <%= f.submit t('.add_item_and_continue'), name: 'add-and-continue', class: 'btn btn-secondary' %>
      <%= f.submit t('.add_item'), class: 'btn btn-primary' %>
    </div>
  </div>
<% end %>

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
blacklight-spotlight-3.6.0.beta10 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta9 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta8 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.5.0.4 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta7 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.5.0.3 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta6 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta5 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta4 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta3 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.6.0.beta1 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.5.0.2 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.5.0.1 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.5.0 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.4.1 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.4 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.3 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.2.2 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.2.1 app/views/spotlight/resources/upload/_form.html.erb
blacklight-spotlight-3.4.2 app/views/spotlight/resources/upload/_form.html.erb