Sha256: 8f0c18b03790946b66587b69f55199b0b25b5573868d4e969c0445da40489480

Contents?: true

Size: 1.46 KB

Versions: 7

Compression:

Stored size: 1.46 KB

Contents

<%= simple_form_for [main_app, @form],
                    html: {
                      data: { behavior: 'work-form',
                              'param-key' => @form.model_name.param_key },
                      multipart: true
                    } do |f| %>
  <% if f.object.errors.any? %>
    <div class="alert alert-danger alert-dismissable" role="alert">
      <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
      <%= f.object.errors.full_messages_for(:base).send(SimpleForm.error_method) %>
      <%= render 'form_in_works_error', f: f %>
      <%= render 'form_ordered_members_error', f: f %>
      <%= render 'form_collections_error', f: f %>
      <%= render 'form_visibility_error', f: f %>
    </div>
  <% end %>
  <% if Flipflop.batch_upload? && f.object.new_record? %>
    <% provide :metadata_tab do %>
      <p class="switch-upload-type">To create a separate work for each of the files, go to <%= link_to "Batch upload", hyrax.new_batch_upload_path %></p>
    <% end %>
  <% end %>
  <%= render 'hyrax/base/guts4form', f: f, tabs: form_tabs_for(form: f.object) %>
<% end %>

<script type="text/javascript">
  Blacklight.onLoad(function() {
    <%# This causes the page to switch back to the default template if they've
        previously visited the batch download page in this Turbolinks session %>
    $("#fileupload").fileupload('option', 'downloadTemplateId', 'template-download')
  });
</script>

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
hyrax-2.9.6 app/views/hyrax/base/_form.html.erb
hyrax-2.9.5 app/views/hyrax/base/_form.html.erb
hyrax-2.9.4 app/views/hyrax/base/_form.html.erb
hyrax-2.9.3 app/views/hyrax/base/_form.html.erb
hyrax-2.9.2 app/views/hyrax/base/_form.html.erb
hyrax-2.9.1 app/views/hyrax/base/_form.html.erb
hyrax-2.9.0 app/views/hyrax/base/_form.html.erb