<%= notice %>

Document · Destroy Download Links <% if params[:document_id] %> <%= link_to '+ New Download Link', new_document_document_download_path(@document), { class: 'btn btn-primary float-right' } %> <% end %>

<% if params[:document_id] %>

<%= @document.title %>

<% else %>

Destroy Multiple Download Links

<% end %>

Upload a CSV File

<%= simple_form_for DocumentDownload.new, url: destroy_all_admin_document_downloads_path, method: :post, multipart: true do |f| %>
<%= f.simple_fields_for :downloads do |download_fields| %> <%= download_fields.input :file, as: :file, input_html: {} %> <%- end %>
<%= submit_tag "- Destroy All", {class: 'btn btn-danger'} %>
<% end %>

Example CSV File

id friendlier_id
1 a35bf4a4-e3ef-483e-98c4-7ea1b04b0f0d
207 a35bf4a4-e3ef-483e-98c4-7ea1b04b0f0d
... ...
CSV File Column Definitions
id
The database table row identifier
friendlier_id
The associated GEOMG document's friendlier id