diff --git a/app/views/hyrax/dashboard/collections/_show_document_list.html.erb b/app/views/hyrax/dashboard/collections/_show_document_list.html.erb new file mode 100644 index 00000000..a1be89e2 --- /dev/null +++ b/app/views/hyrax/dashboard/collections/_show_document_list.html.erb @@ -0,0 +1,17 @@ + + + + + + + + + <% if current_user %> + + <% end %> + + + + <%= render partial: 'show_document_list_row', collection: documents, as: :document %> + +
List of items in this collection
 TitleDate UploadedVisibilityAction
diff --git a/app/views/hyrax/dashboard/collections/_sort_and_per_page.html.erb b/app/views/hyrax/dashboard/collections/_sort_and_per_page.html.erb new file mode 100644 index 00000000..8fd54641 --- /dev/null +++ b/app/views/hyrax/dashboard/collections/_sort_and_per_page.html.erb @@ -0,0 +1,32 @@ +
+ <%= render 'form_for_select_collection', user_collections: @user_collections %> + + <% if params[:action] == "edit" && @response.response['numFound'] > 1 %> +
+ <% session[:batch_edit_state] = "on" %> + <%= button_for_remove_selected_from_collection collection %> +
+ <% end %> +
+ <%# kind of hacky way to get this to work on catalog and folder controllers. May be able to simple do {action: "index"} but I'm not sure -%> + <% if @response.response['numFound'] > 1 && !sort_fields.empty? %> + <%= form_tag collection_path(collection), method: :get, class: 'per_page form-horizontal' do %> +
+
+ <%= t('hyrax.sort_label') %> + <%= label_tag(:sort, "Sort By:".html_safe) %> + <%= select_tag(:sort, options_for_select(sort_fields, h(params[:sort]))) %> + <%= label_tag(:per_page) do %> + Show <%= select_tag(:per_page, options_for_select(['10', '20', '50', '100'], h(params[:per_page])), title: "Number of results to display per page") %> + per page + <% end %> + <%= render_hash_as_hidden_fields(search_state.params_for_search.except(:per_page, :sort)) %> +     + +
+ <%= render 'view_type_group' %> +
+ <% end %> + <% end %> +
+