hyrax 3.3.0 → 3.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (255) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +26 -17
  3. data/.dassie/.env +2 -1
  4. data/.dassie/Gemfile +1 -1
  5. data/.dassie/app/forms/collection_resource_form.rb +8 -0
  6. data/.dassie/app/indexers/collection_resource_indexer.rb +8 -0
  7. data/.dassie/app/models/collection_resource.rb +35 -0
  8. data/.dassie/config/initializers/file_services.rb +4 -0
  9. data/.dassie/config/initializers/hyrax.rb +12 -1
  10. data/.dassie/config/metadata/collection_resource.yaml +23 -0
  11. data/.dassie/db/seeds.rb +74 -17
  12. data/.dassie/spec/forms/collection_resource_form_spec.rb +13 -0
  13. data/.dassie/spec/indexers/collection_resource_indexer_spec.rb +14 -0
  14. data/.dassie/spec/models/collection_resource_spec.rb +13 -0
  15. data/.github/release.yml +26 -0
  16. data/.gitignore +3 -0
  17. data/.regen +1 -1
  18. data/.rubocop.yml +1 -1
  19. data/.rubocop_fixme.yml +22 -3
  20. data/CONTAINERS.md +18 -13
  21. data/Dockerfile +4 -3
  22. data/app/actors/hyrax/actors/file_actor.rb +6 -4
  23. data/app/actors/hyrax/actors/transfer_request_actor.rb +3 -7
  24. data/app/assets/javascripts/hyrax/analytics_events.js +8 -2
  25. data/app/assets/javascripts/hyrax/autocomplete/linked_data.es6 +1 -3
  26. data/app/assets/javascripts/hyrax/collections_v2.es6 +13 -0
  27. data/app/controllers/concerns/hyrax/collections_controller_behavior.rb +1 -3
  28. data/app/controllers/concerns/hyrax/controller.rb +21 -0
  29. data/app/controllers/concerns/hyrax/works_controller_behavior.rb +83 -59
  30. data/app/controllers/hyrax/admin/admin_sets_controller.rb +105 -19
  31. data/app/controllers/hyrax/admin/permission_template_accesses_controller.rb +12 -19
  32. data/app/controllers/hyrax/batch_edits_controller.rb +12 -3
  33. data/app/controllers/hyrax/batch_uploads_controller.rb +4 -0
  34. data/app/controllers/hyrax/citations_controller.rb +1 -1
  35. data/app/controllers/hyrax/dashboard/collections_controller.rb +176 -83
  36. data/app/controllers/hyrax/single_use_links_viewer_controller.rb +1 -1
  37. data/app/forms/hyrax/forms/administrative_set_form.rb +19 -1
  38. data/app/forms/hyrax/forms/batch_edit_form.rb +1 -1
  39. data/app/forms/hyrax/forms/collection_form.rb +1 -1
  40. data/app/forms/hyrax/forms/dashboard/nest_collection_form.rb +21 -6
  41. data/app/forms/hyrax/forms/pcdm_collection_form.rb +30 -2
  42. data/app/forms/hyrax/forms/permission_template_form.rb +17 -9
  43. data/app/forms/hyrax/forms/resource_form.rb +23 -5
  44. data/app/forms/hyrax/forms/widgets/admin_set_visibility.rb +1 -1
  45. data/app/helpers/hyrax/collections_helper.rb +14 -0
  46. data/app/helpers/hyrax/membership_helper.rb +1 -1
  47. data/app/helpers/hyrax/trophy_helper.rb +1 -1
  48. data/app/helpers/hyrax/url_helper.rb +1 -1
  49. data/app/indexers/hyrax/administrative_set_indexer.rb +8 -2
  50. data/app/indexers/hyrax/deep_indexing_service.rb +1 -1
  51. data/app/indexers/hyrax/file_set_indexer.rb +1 -0
  52. data/app/indexers/hyrax/pcdm_collection_indexer.rb +3 -2
  53. data/app/indexers/hyrax/thumbnail_indexer.rb +31 -0
  54. data/app/indexers/hyrax/valkyrie_file_set_indexer.rb +6 -6
  55. data/app/indexers/hyrax/valkyrie_indexer.rb +4 -2
  56. data/app/indexers/hyrax/valkyrie_work_indexer.rb +13 -0
  57. data/app/inputs/controlled_vocabulary_input.rb +2 -0
  58. data/app/jobs/change_depositor_event_job.rb +47 -0
  59. data/app/jobs/characterize_job.rb +43 -3
  60. data/app/jobs/concerns/hyrax/members_permission_job_behavior.rb +1 -1
  61. data/app/jobs/content_depositor_change_event_job.rb +2 -1
  62. data/app/jobs/hyrax/propagate_change_depositor_job.rb +32 -0
  63. data/app/jobs/import_url_job.rb +4 -6
  64. data/app/jobs/inherit_permissions_job.rb +1 -1
  65. data/app/jobs/valkyrie_create_derivatives_job.rb +25 -0
  66. data/app/jobs/valkyrie_ingest_job.rb +41 -35
  67. data/app/models/admin_set.rb +10 -2
  68. data/app/models/collection_branding_info.rb +8 -6
  69. data/app/models/concerns/hyrax/collection_behavior.rb +3 -3
  70. data/app/models/concerns/hyrax/file_set/characterization.rb +7 -1
  71. data/app/models/concerns/hyrax/solr_document/metadata.rb +1 -0
  72. data/app/models/concerns/hyrax/solr_document_behavior.rb +9 -3
  73. data/app/models/concerns/hyrax/user.rb +11 -0
  74. data/app/models/concerns/hyrax/work_behavior.rb +1 -1
  75. data/app/models/featured_work_list.rb +0 -1
  76. data/app/models/hyrax/administrative_set.rb +36 -1
  77. data/app/models/hyrax/collection_type.rb +2 -2
  78. data/app/models/hyrax/file_metadata.rb +37 -3
  79. data/app/models/hyrax/file_set.rb +43 -4
  80. data/app/models/hyrax/group.rb +19 -0
  81. data/app/models/hyrax/pcdm_collection.rb +56 -1
  82. data/app/models/hyrax/permission_template.rb +11 -5
  83. data/app/models/hyrax/work.rb +91 -0
  84. data/app/models/job_io_wrapper.rb +1 -1
  85. data/app/models/proxy_deposit_request.rb +1 -1
  86. data/app/presenters/hyrax/admin_set_presenter.rb +2 -2
  87. data/app/presenters/hyrax/member_presenter_factory.rb +2 -4
  88. data/app/presenters/hyrax/pcdm_member_presenter_factory.rb +2 -2
  89. data/app/presenters/hyrax/work_show_presenter.rb +10 -6
  90. data/app/search_builders/hyrax/dashboard/collections_search_builder.rb +2 -2
  91. data/app/search_builders/hyrax/dashboard/managed_search_filters.rb +44 -4
  92. data/app/search_builders/hyrax/dashboard/nested_collections_search_builder.rb +2 -2
  93. data/app/search_builders/hyrax/my/collections_search_builder.rb +11 -4
  94. data/app/services/hyrax/access_control_list.rb +20 -6
  95. data/app/services/hyrax/adapters/nesting_index_adapter.rb +3 -3
  96. data/app/services/hyrax/admin_set_create_service.rb +21 -37
  97. data/app/services/hyrax/change_content_depositor_service.rb +2 -2
  98. data/app/services/hyrax/change_depositor_service.rb +70 -0
  99. data/app/services/hyrax/characterization/valkyrie_characterization_service.rb +4 -6
  100. data/app/services/hyrax/collections/collection_member_service.rb +3 -5
  101. data/app/services/hyrax/collections/nested_collection_query_service.rb +24 -12
  102. data/app/services/hyrax/custom_queries/navigators/child_file_sets_navigator.rb +45 -0
  103. data/app/services/hyrax/custom_queries/navigators/child_filesets_navigator.rb +7 -2
  104. data/app/services/hyrax/custom_queries/navigators/parent_work_navigator.rb +54 -0
  105. data/app/services/hyrax/default_middleware_stack.rb +3 -0
  106. data/app/services/hyrax/file_set_derivatives_service.rb +21 -2
  107. data/app/services/hyrax/file_set_type_service.rb +2 -5
  108. data/app/services/hyrax/listeners/file_metadata_listener.rb +31 -1
  109. data/app/services/hyrax/listeners/member_cleanup_listener.rb +27 -11
  110. data/app/services/hyrax/listeners/metadata_index_listener.rb +39 -0
  111. data/app/services/hyrax/listeners/proxy_deposit_listener.rb +14 -8
  112. data/app/services/hyrax/location_service.rb +33 -0
  113. data/app/services/hyrax/multiple_membership_checker.rb +46 -1
  114. data/app/services/hyrax/resource_visibility_propagator.rb +1 -1
  115. data/app/services/hyrax/simple_schema_loader.rb +5 -1
  116. data/app/services/hyrax/solr_query_service.rb +12 -7
  117. data/app/services/hyrax/thumbnail_path_service.rb +1 -1
  118. data/app/services/hyrax/valkyrie_persist_derivatives.rb +50 -0
  119. data/app/services/hyrax/valkyrie_upload.rb +94 -0
  120. data/app/services/hyrax/work_uploads_handler.rb +0 -10
  121. data/app/services/hyrax/workflow/workflow_importer.rb +7 -9
  122. data/app/services/hyrax/workflow/workflow_schema.rb +3 -5
  123. data/app/strategies/hyrax/strategies/yaml_strategy.rb +4 -6
  124. data/app/uploaders/hyrax/uploaded_file_uploader.rb +4 -4
  125. data/app/utils/hyrax/data_destroyers/collection_branding_destroyer.rb +29 -0
  126. data/app/utils/hyrax/data_destroyers/collection_types_destroyer.rb +26 -0
  127. data/app/utils/hyrax/data_destroyers/default_admin_set_id_cache_destroyer.rb +26 -0
  128. data/app/utils/hyrax/data_destroyers/featured_works_destroyer.rb +27 -0
  129. data/app/utils/hyrax/data_destroyers/permission_templates_destroyer.rb +30 -0
  130. data/app/utils/hyrax/data_destroyers/repository_metadata_destroyer.rb +42 -0
  131. data/app/utils/hyrax/data_destroyers/stats_destroyer.rb +33 -0
  132. data/app/utils/hyrax/data_maintenance.rb +51 -0
  133. data/app/utils/hyrax/required_data_seeder.rb +21 -0
  134. data/app/utils/hyrax/required_data_seeders/collection_seeder.rb +26 -0
  135. data/app/utils/hyrax/required_data_seeders/collection_type_seeder.rb +36 -0
  136. data/app/utils/hyrax/test_data_seeder.rb +24 -0
  137. data/app/utils/hyrax/test_data_seeders/collection_seeder.rb +91 -0
  138. data/app/utils/hyrax/test_data_seeders/collection_type_seeder.rb +72 -0
  139. data/app/utils/hyrax/test_data_seeders/user_seeder.rb +52 -0
  140. data/app/validators/hyrax/collection_membership_validator.rb +39 -0
  141. data/app/views/catalog/_index_header_list_default.html.erb +8 -1
  142. data/app/views/catalog/_thumbnail_list_default.html.erb +8 -3
  143. data/app/views/collections/edit_fields/_based_near.html.erb +7 -7
  144. data/app/views/hyrax/admin/admin_sets/_form_participant_table.html.erb +2 -2
  145. data/app/views/hyrax/admin/admin_sets/_form_participants.html.erb +2 -2
  146. data/app/views/hyrax/admin/admin_sets/_form_visibility.html.erb +2 -2
  147. data/app/views/hyrax/admin/admin_sets/_form_workflow.erb +1 -1
  148. data/app/views/hyrax/admin/collection_types/index.html.erb +1 -1
  149. data/app/views/hyrax/base/_form.html.erb +1 -1
  150. data/app/views/hyrax/base/_form_child_work_relationships.html.erb +1 -1
  151. data/app/views/hyrax/dashboard/collections/_default_group.html.erb +2 -2
  152. data/app/views/hyrax/dashboard/collections/_form.html.erb +24 -17
  153. data/app/views/hyrax/dashboard/collections/_form_branding.html.erb +1 -0
  154. data/app/views/hyrax/dashboard/collections/_form_discovery.html.erb +6 -3
  155. data/app/views/hyrax/dashboard/collections/_form_share.html.erb +2 -2
  156. data/app/views/hyrax/dashboard/collections/_form_share_table.html.erb +3 -3
  157. data/app/views/hyrax/dashboard/collections/_list_collections.html.erb +2 -2
  158. data/app/views/hyrax/dashboard/sidebar/_activity.html.erb +1 -1
  159. data/app/views/hyrax/dashboard/works/_default_group.html.erb +1 -1
  160. data/app/views/hyrax/dashboard/works/_list_works.html.erb +1 -1
  161. data/app/views/hyrax/file_sets/_actions.html.erb +2 -2
  162. data/app/views/hyrax/my/_facet_pagination.html.erb +12 -9
  163. data/app/views/hyrax/my/_work_action_menu.html.erb +8 -9
  164. data/app/views/hyrax/my/collections/_default_group.html.erb +2 -2
  165. data/app/views/hyrax/my/collections/_list_collections.html.erb +2 -2
  166. data/app/views/hyrax/my/collections/index.html.erb +3 -2
  167. data/app/views/hyrax/my/works/_default_group.html.erb +1 -1
  168. data/app/views/hyrax/my/works/_list_works.html.erb +1 -2
  169. data/app/views/hyrax/my/works/_tabs.html.erb +6 -1
  170. data/app/views/hyrax/my/works/index.html.erb +4 -2
  171. data/chart/hyrax/Chart.yaml +11 -7
  172. data/chart/hyrax/README.md +22 -1
  173. data/chart/hyrax/templates/_helpers.tpl +4 -0
  174. data/chart/hyrax/templates/cron-embargo.yaml +5 -0
  175. data/chart/hyrax/templates/cron-lease.yaml +5 -0
  176. data/chart/hyrax/templates/deployment-worker.yaml +11 -0
  177. data/chart/hyrax/templates/ingress.yaml +7 -6
  178. data/chart/hyrax/values.yaml +152 -0
  179. data/config/features.rb +48 -50
  180. data/config/initializers/listeners.rb +0 -1
  181. data/config/initializers/{valkryrie_storage.rb → storage_adapter_initializer.rb} +5 -0
  182. data/config/locales/hyrax.de.yml +18 -17
  183. data/config/locales/hyrax.en.yml +30 -28
  184. data/config/locales/hyrax.es.yml +10 -9
  185. data/config/locales/hyrax.fr.yml +2 -1
  186. data/config/locales/hyrax.it.yml +3 -2
  187. data/config/locales/hyrax.pt-BR.yml +2 -1
  188. data/config/locales/hyrax.zh.yml +2 -1
  189. data/config/metadata/basic_metadata.yaml +2 -0
  190. data/config/metadata/core_metadata.yaml +1 -1
  191. data/docker-compose.yml +47 -42
  192. data/documentation/developing-your-hyrax-based-app.md +1 -1
  193. data/documentation/legacyREADME.md +1 -1
  194. data/hyrax.gemspec +5 -3
  195. data/lib/generators/hyrax/collection_resource/USAGE +20 -0
  196. data/lib/generators/hyrax/collection_resource/collection_resource_generator.rb +133 -0
  197. data/lib/generators/hyrax/collection_resource/templates/collection.rb.erb +34 -0
  198. data/lib/generators/hyrax/collection_resource/templates/collection_form.rb.erb +7 -0
  199. data/lib/generators/hyrax/collection_resource/templates/collection_form_spec.rb.erb +13 -0
  200. data/lib/generators/hyrax/collection_resource/templates/collection_indexer.rb.erb +7 -0
  201. data/lib/generators/hyrax/collection_resource/templates/collection_indexer_spec.rb.erb +13 -0
  202. data/lib/generators/hyrax/collection_resource/templates/collection_metadata.yaml +22 -0
  203. data/lib/generators/hyrax/collection_resource/templates/collection_spec.rb.erb +12 -0
  204. data/lib/generators/hyrax/install_generator.rb +9 -0
  205. data/lib/hyrax/administrative_set_name.rb +18 -0
  206. data/lib/hyrax/collection_name.rb +2 -0
  207. data/lib/hyrax/configuration.rb +22 -0
  208. data/lib/hyrax/controlled_vocabularies/location.rb +9 -2
  209. data/lib/hyrax/controlled_vocabularies/resource_label_caching.rb +42 -0
  210. data/lib/hyrax/controlled_vocabularies.rb +1 -0
  211. data/lib/hyrax/publisher.rb +49 -0
  212. data/lib/hyrax/schema.rb +16 -13
  213. data/lib/hyrax/specs/capybara.rb +1 -1
  214. data/lib/hyrax/specs/shared_specs/hydra_works.rb +11 -5
  215. data/lib/hyrax/specs/shared_specs/indexers.rb +117 -3
  216. data/lib/hyrax/transactions/admin_set_create.rb +2 -1
  217. data/lib/hyrax/transactions/admin_set_destroy.rb +22 -0
  218. data/lib/hyrax/transactions/admin_set_update.rb +21 -0
  219. data/lib/hyrax/transactions/collection_destroy.rb +22 -0
  220. data/lib/hyrax/transactions/collection_update.rb +5 -2
  221. data/lib/hyrax/transactions/container.rb +97 -23
  222. data/lib/hyrax/transactions/create_work.rb +3 -0
  223. data/lib/hyrax/transactions/destroy_work.rb +3 -0
  224. data/lib/hyrax/transactions/steps/apply_collection_permission_template.rb +2 -0
  225. data/lib/hyrax/transactions/steps/apply_permission_template.rb +2 -0
  226. data/lib/hyrax/transactions/steps/apply_visibility.rb +2 -0
  227. data/lib/hyrax/transactions/steps/change_depositor.rb +46 -0
  228. data/lib/hyrax/transactions/steps/check_for_empty_admin_set.rb +36 -0
  229. data/lib/hyrax/transactions/steps/delete_access_control.rb +32 -0
  230. data/lib/hyrax/transactions/steps/delete_resource.rb +19 -3
  231. data/lib/hyrax/transactions/steps/destroy_work.rb +3 -1
  232. data/lib/hyrax/transactions/steps/ensure_permission_template.rb +2 -0
  233. data/lib/hyrax/transactions/steps/save.rb +24 -6
  234. data/lib/hyrax/transactions/steps/save_access_control.rb +2 -2
  235. data/lib/hyrax/transactions/steps/save_collection_banner.rb +59 -0
  236. data/lib/hyrax/transactions/steps/save_collection_logo.rb +109 -0
  237. data/lib/hyrax/transactions/steps/save_work.rb +3 -0
  238. data/lib/hyrax/transactions/steps/set_user_as_creator.rb +41 -0
  239. data/lib/hyrax/transactions/steps/update_work_members.rb +51 -0
  240. data/lib/hyrax/transactions/update_work.rb +4 -3
  241. data/lib/hyrax/transactions/work_create.rb +1 -1
  242. data/lib/hyrax/transactions/work_destroy.rb +2 -1
  243. data/lib/hyrax/transactions/work_update.rb +19 -0
  244. data/lib/hyrax/version.rb +1 -1
  245. data/lib/wings/active_fedora_converter/file_metadata_node.rb +48 -0
  246. data/lib/wings/active_fedora_converter/instance_builder.rb +68 -0
  247. data/lib/wings/active_fedora_converter.rb +3 -3
  248. data/lib/wings/attribute_transformer.rb +5 -1
  249. data/lib/wings/services/custom_queries/find_file_metadata.rb +19 -8
  250. data/lib/wings/setup.rb +3 -1
  251. data/lib/wings/valkyrie/persister.rb +2 -0
  252. data/lib/wings/valkyrie/query_service.rb +6 -7
  253. data/lib/wings/valkyrie/storage.rb +7 -1
  254. data/template.rb +1 -1
  255. metadata +99 -12
@@ -1,13 +1,16 @@
1
- <div class="prev_next_links btn-group pull-left">
2
- <%= link_to_previous_page @pagination, raw(t('views.pagination.previous')), route_set: hyrax, params: search_state.to_h, param_name: Blacklight::Solr::FacetPaginator.request_keys[:page], class: 'btn btn-link', data: {ajax_modal: "preserve"} do %>
3
- <span class="disabled btn btn-disabled"><%= raw(t('views.pagination.previous')) %></span>
4
- <% end %>
5
- <%= link_to_next_page @pagination, raw(t('views.pagination.next')), route_set: hyrax, params: search_state.to_h, param_name: Blacklight::Solr::FacetPaginator.request_keys[:page], class: 'btn btn-link', data: {ajax_modal: "preserve"} do %>
1
+ <div class="prev_next_links btn-group pull-left">
2
+ <% if @pagination.first_page? %>
3
+ <span class="disabled btn btn-disabled"><%= raw(t('views.pagination.previous')) %></span>
4
+ <% else %>
5
+ <%= link_to_previous_page @pagination, raw(t('views.pagination.previous')), route_set: hyrax, params: search_state.to_h, param_name: Blacklight::Solr::FacetPaginator.request_keys[:page], class: 'btn btn-link', data: {ajax_modal: "preserve"} %>
6
+ <% end %>
6
7
 
7
- <span class="disabled btn btn-disabled"><%= raw(t('views.pagination.next')) %></span>
8
- <% end %>
9
-
10
- </div>
8
+ <% if @pagination.last_page? %>
9
+ <span class="disabled btn btn-disabled"><%= raw(t('views.pagination.next')) %></span>
10
+ <% else %>
11
+ <%= link_to_next_page @pagination, raw(t('views.pagination.next')), route_set: hyrax, params: search_state.to_h, param_name: Blacklight::Solr::FacetPaginator.request_keys[:page], class: 'btn btn-link', data: {ajax_modal: "preserve"} %>
12
+ <% end %>
13
+ </div>
11
14
 
12
15
  <div class="sort_options btn-group pull-right">
13
16
  <% if @pagination.sort == 'index' -%>
@@ -12,34 +12,33 @@
12
12
 
13
13
  <% if can? :edit, document.id %>
14
14
  <li role="menuitem" tabindex="-1">
15
- <%= link_to [main_app, :edit, document] do %>
16
- <i class="glyphicon glyphicon-pencil" aria-hidden="true"></i>
17
- <span> <%= t("hyrax.dashboard.my.action.edit_work") %> </span>
15
+ <%= link_to [main_app, :edit, document],
16
+ id: 'action-edit-work' do %>
17
+ <%= t("hyrax.dashboard.my.action.edit_work") %>
18
18
  <% end %>
19
19
  </li>
20
20
 
21
21
  <li role="menuitem" tabindex="-1">
22
22
  <%= link_to [main_app, document],
23
23
  method: :delete,
24
+ id: 'action-delete-work',
24
25
  data: {
25
26
  confirm: t("hyrax.dashboard.my.action.work_confirmation", application_name: application_name) } do %>
26
- <i class="glyphicon glyphicon-trash" aria-hidden="true"></i>
27
- <span> <%= t("hyrax.dashboard.my.action.delete_work") %> </span>
27
+ <%= t("hyrax.dashboard.my.action.delete_work") %>
28
28
  <% end %>
29
29
  </li>
30
30
  <% end %>
31
31
 
32
32
  <li role="menuitem" tabindex="-1">
33
33
  <%= display_trophy_link(current_user, document.id) do |text| %>
34
- <i class="glyphicon glyphicon-star" aria-hidden="true"></i> <%= text %>
34
+ <%= text %>
35
35
  <% end %>
36
36
  </li>
37
37
 
38
38
  <% if can? :transfer, document.id %>
39
39
  <li role="menuitem" tabindex="-1">
40
- <%= link_to(hyrax.new_work_transfer_path(document.id), class: 'itemicon itemtransfer', title: t("hyrax.dashboard.my.action.transfer")) do %>
41
- <i class="glyphicon glyphicon-transfer" aria-hidden="true"></i>
42
- <span> <%= t("hyrax.dashboard.my.action.transfer") %> </span>
40
+ <%= link_to(hyrax.new_work_transfer_path(document.id), id: 'action-transfer-work', class: 'itemicon itemtransfer', title: t("hyrax.dashboard.my.action.transfer")) do %>
41
+ <%= t("hyrax.dashboard.my.action.transfer") %>
43
42
  <% end %>
44
43
  </li>
45
44
  <% end %>
@@ -5,9 +5,9 @@
5
5
  <th class="check-all"><label for="check_all" class="sr-only"><%= t("hyrax.dashboard.my.sr.check_all_label") %></label><%= render_check_all %></th>
6
6
  <th><%= t("hyrax.dashboard.my.heading.title") %></th>
7
7
  <th><%= t("hyrax.dashboard.my.heading.type") %></th>
8
- <th><%= t("hyrax.dashboard.my.heading.collection.visibility") %></th>
9
- <th><%= t("hyrax.dashboard.my.heading.items") %></th>
10
8
  <th><%= t("hyrax.dashboard.my.heading.last_modified") %></th>
9
+ <th><%= t("hyrax.dashboard.my.heading.items") %></th>
10
+ <th><%= t("hyrax.dashboard.my.heading.collection.visibility") %></th>
11
11
  <th><%= t("hyrax.dashboard.my.heading.action") %></th>
12
12
  </tr>
13
13
  </thead>
@@ -60,9 +60,9 @@
60
60
  <td class="collection_type">
61
61
  <%= collection_presenter.collection_type_badge %>
62
62
  </td>
63
- <td><%= collection_presenter.permission_badge %></td>
63
+ <td class="date"><%= collection_presenter.modified_date %> </td>
64
64
  <td><%= collection_presenter.total_viewable_items %></td>
65
- <td class="date"><%= collection_presenter.modified_date.try(:to_formatted_s, :standard) %> </td>
65
+ <td><%= collection_presenter.permission_badge %></td>
66
66
  <td>
67
67
  <% if collection_presenter.solr_document.admin_set? %>
68
68
  <%= render '/hyrax/my/admin_set_action_menu', admin_set_presenter: collection_presenter %>
@@ -25,6 +25,7 @@
25
25
  <% if @collection_type_list_presenter.many? %>
26
26
  <% # modal to select type %>
27
27
  <button type="button"
28
+ id="add-new-collection-button"
28
29
  class="btn btn-primary"
29
30
  data-toggle="modal"
30
31
  data-target="#collectiontypes-to-create"
@@ -33,7 +34,7 @@
33
34
  </button>
34
35
  <% else @collection_type_list_presenter.any? %>
35
36
  <% # link directly to create collection form with type %>
36
- <%= link_to(t('helpers.action.collection.new'), append_collection_type_url(new_dashboard_collection_path, @collection_type_list_presenter.first_collection_type.id), class: 'btn btn-primary') %>
37
+ <%= link_to(t('helpers.action.collection.new'), append_collection_type_url(new_dashboard_collection_path, @collection_type_list_presenter.first_collection_type.id), id: 'add-new-collection-button', class: 'btn btn-primary') %>
37
38
  <% end %>
38
39
  <% end %>
39
40
  </section>
@@ -46,7 +47,7 @@
46
47
  <% elsif current_page?(hyrax.dashboard_collections_path(locale: nil)) && !current_ability.admin? %>
47
48
  <span class="count-display"><%= I18n.t('hyrax.my.count.collections.you_manage', total_count: @response.total_count).html_safe %></span>
48
49
  <% else %>
49
- <span class="count-display"><%= I18n.t('hyrax.my.count.collections.in_repo', total_count: @response.total_count).html_safe %></span>
50
+ <span class="count-display"><%= I18n.t('hyrax.my.count.collections.in_repo', total_count: @response.total_count).html_safe %></span>
50
51
  <% end %>
51
52
  </div>
52
53
  <div class="panel-body">
@@ -5,7 +5,7 @@
5
5
  <tr>
6
6
  <th class="check-all"><label for="check_all" class="sr-only"><%= t("hyrax.dashboard.my.sr.check_all_label") %></label><%= render_check_all %></th>
7
7
  <th><%= t("hyrax.dashboard.my.heading.title") %></th>
8
- <th class='text-center'><%= t("hyrax.dashboard.my.heading.date_uploaded") %></th>
8
+ <th class='text-center'><%= t("hyrax.dashboard.my.heading.last_modified") %></th>
9
9
  <th class='text-center'><%= t("hyrax.dashboard.my.heading.highlighted") %></th>
10
10
  <th class='text-center'><%= t("hyrax.dashboard.my.heading.work.visibility") %></th>
11
11
  <th class='text-center'><%= t("hyrax.dashboard.my.heading.action") %></th>
@@ -28,8 +28,7 @@
28
28
  </div>
29
29
  </div>
30
30
  </td>
31
-
32
- <td class="date text-center"><%= document.date_uploaded %></td>
31
+ <td class="date text-center"><%= document.date_modified %></td>
33
32
  <td class='text-center'>
34
33
  <span class="fa <%= current_user.trophies.where(work_id: document.id).exists? ? 'fa-star highlighted-work' : 'fa-star-o trophy-off' %>" aria-hidden="true"></span></td>
35
34
  <td class='text-center'><%= render_visibility_link document %></td>
@@ -1,6 +1,11 @@
1
1
  <ul class="nav nav-tabs" id="my_nav" role="list">
2
2
  <li<%= ' class="active"'.html_safe if current_page?(hyrax.dashboard_works_path(locale: nil)) %>>
3
- <%= link_to t("hyrax.dashboard.#{current_ability.admin? ? 'all' : 'managed'}.works"), hyrax.dashboard_works_path %>
3
+ <% if params[:add_works_to_collection].present? && params[:add_works_to_collection_label].present? %>
4
+ <%= link_to t("hyrax.dashboard.#{current_ability.admin? ? 'all' : 'managed'}.works"), hyrax.dashboard_works_path(add_works_to_collection: params[:add_works_to_collection], add_works_to_collection_label: params[:add_works_to_collection_label]) %>
5
+ <% else %>
6
+ <%= link_to t("hyrax.dashboard.#{current_ability.admin? ? 'all' : 'managed'}.works"), hyrax.dashboard_works_path %>
7
+ <% end %>
8
+
4
9
  </li>
5
10
  <li<%= ' class="active"'.html_safe if current_page?(hyrax.my_works_path(locale: nil)) %>>
6
11
  <%= link_to t('hyrax.dashboard.my.your_works'), hyrax.my_works_path %>
@@ -30,6 +30,7 @@
30
30
  t(:'helpers.action.work.new'),
31
31
  '#',
32
32
  data: { behavior: "select-work", target: "#worktypes-to-create", 'create-type' => 'single' },
33
+ id: 'add-new-work-button',
33
34
  class: 'btn btn-primary'
34
35
  ) %>
35
36
  <% else # simple link to the first work type %>
@@ -43,6 +44,7 @@
43
44
  <%= link_to(
44
45
  t(:'helpers.action.work.new'),
45
46
  new_polymorphic_path([main_app, @create_work_presenter.first_model]),
47
+ id: 'add-new-work-button',
46
48
  class: 'btn btn-primary'
47
49
  ) %>
48
50
  <% end %>
@@ -60,9 +62,9 @@
60
62
  <% elsif current_page?(hyrax.dashboard_works_path(locale: nil)) && !current_ability.admin? %>
61
63
  <span class="count-display"><%= I18n.t('hyrax.my.count.works.you_manage', total_count: @response.total_count).html_safe %></span>
62
64
  <% else %>
63
- <span class="count-display"><%= I18n.t('hyrax.my.count.works.in_repo', total_count: @response.total_count).html_safe %></span>
65
+ <span class="count-display"><%= I18n.t('hyrax.my.count.works.in_repo', total_count: @response.total_count).html_safe %></span>
64
66
  <% end %>
65
- </div>
67
+ </div>
66
68
  <div class="panel-body">
67
69
  <%= render 'search_header' %>
68
70
  <h2 class="sr-only"><%= t('hyrax.my.count.works.works_listing') %></h2>
@@ -2,8 +2,8 @@ apiVersion: v2
2
2
  name: hyrax
3
3
  description: An open-source, Samvera-powered digital repository system
4
4
  type: application
5
- version: 1.0.2
6
- appVersion: 3.1.0
5
+ version: 1.5.1
6
+ appVersion: 3.3.0
7
7
  dependencies:
8
8
  - name: fcrepo
9
9
  version: 0.8.0
@@ -11,21 +11,25 @@ dependencies:
11
11
  condition: fcrepo.enabled
12
12
  - name: memcached
13
13
  version: 4.2.21
14
- repository: https://charts.bitnami.com/bitnami
14
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
15
15
  condition: memcached.enabled
16
16
  - name: minio
17
17
  version: 6.7.2
18
- repository: https://charts.bitnami.com/bitnami
18
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
19
19
  condition: minio.enabled
20
20
  - name: postgresql
21
21
  version: 10.3.13
22
- repository: https://charts.bitnami.com/bitnami
22
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
23
23
  condition: postgresql.enabled
24
24
  - name: redis
25
25
  version: 10.7.16
26
- repository: https://charts.bitnami.com/bitnami
26
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
27
27
  condition: redis.enabled
28
28
  - name: solr
29
29
  version: 1.0.1
30
- repository: https://charts.bitnami.com/bitnami
30
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
31
31
  condition: solr.enabled
32
+ - name: nginx
33
+ version: 9.8.0
34
+ repository: https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnami
35
+ condition: nginx.enabled
@@ -116,7 +116,7 @@ Then update the helm charts with the following:
116
116
  HELM_EXPERIMENTAL_OCI=1 helm dependency update chart/hyrax
117
117
  ```
118
118
 
119
- Without the `HELM_EXPERIMENTAL_OCI=1` switch you might see the following error:
119
+ If your `helm` version is before 3.8, without the `HELM_EXPERIMENTAL_OCI=1` switch you might see the following error:
120
120
 
121
121
  ```sh
122
122
  repository oci://ghcr.io/samvera is an OCI registry: this feature has been marked as experimental and is not enabled by default. Please set HELM_EXPERIMENTAL_OCI=1 in your environment to use this feature”
@@ -142,6 +142,27 @@ Some shell commands of house cleaning and destruction:
142
142
  * Remove hanging docker instances: `docker rm $(docker ps -a -q) -f`
143
143
  * Removing dangling docker images: `docker rmi $(docker images -f "dangling=true" -q)`
144
144
 
145
+ ## Building and Pushing the Chart Package
146
+
147
+ We currently build and push new chart versions manually. This needs to happen
148
+ any time the chart version in [`Chart.yaml`](./Chart.yaml) is incremented.
149
+
150
+ To publish the Hyrax chart, you'll need to be in one of the GitHub groups with
151
+ push permissions. These groups are:
152
+
153
+ - `@samvera/admins`
154
+ - `@samvera/hyrax` (and all its subgroups)
155
+
156
+ To build the package, it's helpful to have a clean checkout of the current
157
+ `main` branch, then:
158
+
159
+ ```sh
160
+ HELM_EXPERIMENTAL_OCI=1 helm dependency update chart/hyrax
161
+ HELM_EXPERIMENTAL_OCI=1 helm package chart/hyrax
162
+ HELM_EXPERIMENTAL_OCI=1 helm push hyrax-[VERSION].tgz oci://ghcr.io/samvera/charts
163
+ ```
164
+
165
+
145
166
  [containers]: ../../CONTAINERS.md#hyrax-image
146
167
  [dassie]: ../../.dassie/README.md
147
168
  [dassie-image]: https://hub.docker.com/r/samveralabs/dassie
@@ -179,6 +179,10 @@ We truncate at 63 chars because some Kubernetes name fields are limited to this
179
179
  {{- printf "redis://:%s@%s:%s" .Values.redis.password (include "hyrax.redis.host" .) "6379/0" -}}
180
180
  {{- end -}}
181
181
 
182
+ {{- define "hyrax.nginx.host" -}}
183
+ {{- printf "%s-%s" .Release.Name "nginx" | trunc 63 | trimSuffix "-" -}}
184
+ {{- end -}}
185
+
182
186
  {{- define "hyrax.sharedPvcAccessModes" -}}
183
187
  {{- if .Values.worker.enabled }}
184
188
  accessModes:
@@ -11,6 +11,11 @@ spec:
11
11
  jobTemplate:
12
12
  spec:
13
13
  template:
14
+ metadata:
15
+ {{- with .Values.podAnnotations }}
16
+ annotations:
17
+ {{- toYaml . | nindent 12 }}
18
+ {{- end }}
14
19
  spec:
15
20
  containers:
16
21
  - name: embargo-release
@@ -11,6 +11,11 @@ spec:
11
11
  jobTemplate:
12
12
  spec:
13
13
  template:
14
+ metadata:
15
+ {{- with .Values.podAnnotations }}
16
+ annotations:
17
+ {{- toYaml . | nindent 12 }}
18
+ {{- end }}
14
19
  spec:
15
20
  containers:
16
21
  - name: lease-release
@@ -64,6 +64,17 @@ spec:
64
64
  {{- end }}
65
65
  env:
66
66
  {{- toYaml .Values.worker.extraEnvVars | nindent 12 }}
67
+ {{- if .Values.worker.readinessProbe.enabled }}
68
+ readinessProbe:
69
+ exec:
70
+ command:
71
+ {{- toYaml .Values.worker.readinessProbe.command | nindent 16 }}
72
+ failureThreshold: {{ .Values.worker.readinessProbe.failureThreshold }}
73
+ initialDelaySeconds: {{ .Values.worker.readinessProbe.initialDelaySeconds }}
74
+ periodSeconds: {{ .Values.worker.readinessProbe.periodSeconds }}
75
+ successThreshold: {{ .Values.worker.readinessProbe.successThreshold }}
76
+ timeoutSeconds: {{ .Values.worker.readinessProbe.timeoutSeconds }}
77
+ {{- end }}
67
78
  volumeMounts:
68
79
  - name: derivatives
69
80
  mountPath: /app/samvera/derivatives
@@ -1,6 +1,7 @@
1
1
  {{- if .Values.ingress.enabled -}}
2
- {{- $fullName := include "hyrax.fullname" . -}}
3
- {{- $svcPort := .Values.service.port -}}
2
+ {{- $svcFullName := ternary (include "hyrax.nginx.host" .) (include "hyrax.fullname" .) .Values.nginx.enabled -}}
3
+ {{- $svcPort := ternary .Values.nginx.service.port .Values.service.port .Values.nginx.enabled -}}
4
+
4
5
  {{- $beta := semverCompare "<1.19-0" (default .Capabilities.KubeVersion.Version .Values.kubeVersion) -}}
5
6
  {{- if $beta }}
6
7
  apiVersion: networking.k8s.io/v1beta1
@@ -9,7 +10,7 @@ apiVersion: networking.k8s.io/v1
9
10
  {{- end }}
10
11
  kind: Ingress
11
12
  metadata:
12
- name: {{ $fullName }}
13
+ name: {{ include "hyrax.fullname" . }}
13
14
  labels:
14
15
  {{- include "hyrax.labels" . | nindent 4 }}
15
16
  {{- with .Values.ingress.annotations }}
@@ -37,14 +38,14 @@ spec:
37
38
  pathType: {{ .pathType | default "ImplementationSpecific" }}
38
39
  backend:
39
40
  {{- if $beta }}
40
- serviceName: {{ $fullName }}
41
+ serviceName: {{ $svcFullName }}
41
42
  servicePort: {{ $svcPort }}
42
43
  {{- else }}
43
44
  service:
44
- name: {{ $fullName }}
45
+ name: {{ $svcFullName }}
45
46
  port:
46
47
  number: {{ $svcPort }}
47
48
  {{- end }}
48
49
  {{- end }}
49
50
  {{- end }}
50
- {{- end }}
51
+ {{- end }}
@@ -201,6 +201,18 @@ worker:
201
201
  affinity: {}
202
202
  resources: {}
203
203
 
204
+ # see: https://github.com/mperham/sidekiq/wiki/Kubernetes#health-checks
205
+ readinessProbe:
206
+ enabled: false
207
+ # command:
208
+ # - cat
209
+ # - /app/samvera/hyrax-webapp/tmp/sidekiq_process_has_started_and_will_begin_processing_jobs
210
+ # initialDelaySeconds: 10
211
+ # periodSeconds: 2
212
+ # timeoutSeconds: 1
213
+ # failureThreshold: 10
214
+ # successThreshold: 2
215
+
204
216
  fcrepo:
205
217
  enabled: true
206
218
  externalDatabaseUsername: "hyrax"
@@ -238,6 +250,144 @@ postgresql:
238
250
  # persistence:
239
251
  # size: 10Gi
240
252
 
253
+
254
+ ## Nginx proxy is used to keep puma from having to serve static assets
255
+ ## and to act as an auth proxy for Cantelope
256
+ nginx:
257
+ enabled: false
258
+ # The set up below does malicious bot / ip blocking and mounts
259
+ # vaolumes to allow nginx to server assets and other public directory items
260
+ # image:
261
+ # registry: registry.gitlab.com
262
+ # repository: notch8/scripts/bitnami-nginx
263
+ # tag: 1.21.5-debian-10-r4
264
+ # extraVolumes:
265
+ # - name: "uploads"
266
+ # persistentVolumeClaim:
267
+ # claimName: {{ .Values.global.hyraxHostName }}-uploads
268
+ # extraVolumeMounts:
269
+ # - name: uploads
270
+ # mountPath: /app/samvera/hyrax-webapp/public/system
271
+ # subPath: public-system
272
+ # - name: uploads
273
+ # mountPath: /app/samvera/hyrax-webapp/public/uploads
274
+ # subPath: public-uploads
275
+ # - name: uploads
276
+ # mountPath: /app/samvera/hyrax-webapp/public/uv
277
+ # subPath: public-uv
278
+ # - name: uploads
279
+ # mountPath: /app/samvera/hyrax-webapp/public/assets
280
+ # subPath: public-assets
281
+ # serverBlock: |-
282
+ # upstream rails_app {
283
+ # server {{ .Values.global.hyraxHostName }};
284
+ # }
285
+
286
+ # map $status $loggable {
287
+ # ~^444 0;
288
+ # default 1;
289
+ # }
290
+
291
+ # log_format loki 'host=$host ip=$http_x_forwarded_for remote_user=$remote_user [$time_local] '
292
+ # 'request="$request" status=$status bytes=$body_bytes_sent '
293
+ # 'referer="$http_referer" agent="$http_user_agent" request_time=$request_time upstream_response_time=$upstream_response_time upstream_response_length=$upstream_response_length';
294
+
295
+ # error_log /opt/bitnami/nginx/logs/error.log warn;
296
+ # #tcp_nopush on;
297
+
298
+ # # Cloudflare ips see for refresh
299
+ # # https://support.cloudflare.com/hc/en-us/articles/200170786-Restoring-original-visitor-IPs-logging-visitor-IP-addresses
300
+ # # update list https://www.cloudflare.com/ips/
301
+ # set_real_ip_from 103.21.244.0/22;
302
+ # set_real_ip_from 103.22.200.0/22;
303
+ # set_real_ip_from 103.31.4.0/22;
304
+ # set_real_ip_from 104.16.0.0/13;
305
+ # set_real_ip_from 104.24.0.0/14;
306
+ # set_real_ip_from 108.162.192.0/18;
307
+ # set_real_ip_from 131.0.72.0/22;
308
+ # set_real_ip_from 141.101.64.0/18;
309
+ # set_real_ip_from 162.158.0.0/15;
310
+ # set_real_ip_from 172.64.0.0/13;
311
+ # set_real_ip_from 173.245.48.0/20;
312
+ # set_real_ip_from 188.114.96.0/20;
313
+ # set_real_ip_from 190.93.240.0/20;
314
+ # set_real_ip_from 197.234.240.0/22;
315
+ # set_real_ip_from 198.41.128.0/17;
316
+ # set_real_ip_from 2400:cb00::/32;
317
+ # set_real_ip_from 2606:4700::/32;
318
+ # set_real_ip_from 2803:f800::/32;
319
+ # set_real_ip_from 2405:b500::/32;
320
+ # set_real_ip_from 2405:8100::/32;
321
+ # set_real_ip_from 2a06:98c0::/29;
322
+ # set_real_ip_from 2c0f:f248::/32;
323
+
324
+ # real_ip_header X-Forwarded-For;
325
+ # real_ip_recursive on;
326
+ # include /opt/bitnami/nginx/conf/conf.d/*.conf;
327
+ # server {
328
+ # listen 8080;
329
+ # server_name _;
330
+ # root /app/samvera/hyrax-webapp/public;
331
+ # index index.html;
332
+
333
+ # client_body_in_file_only clean;
334
+ # client_body_buffer_size 32K;
335
+ # client_max_body_size 0;
336
+ # access_log /opt/bitnami/nginx/logs/access.log loki;
337
+ # # if=$loggable;
338
+
339
+ # sendfile on;
340
+ # send_timeout 300s;
341
+
342
+ # include /opt/bitnami/nginx/conf/bots.d/ddos.conf;
343
+ # include /opt/bitnami/nginx/conf/bots.d/blockbots.conf;
344
+
345
+ # location ~ (\.php|\.aspx|\.asp) {
346
+ # return 404;
347
+ # }
348
+
349
+ # # deny requests for files that should never be accessed
350
+ # location ~ /\. {
351
+ # deny all;
352
+ # }
353
+
354
+ # location ~* ^.+\.(rb|log)$ {
355
+ # deny all;
356
+ # }
357
+
358
+ # # serve static (compiled) assets directly if they exist (for rails production)
359
+ # location ~ ^/(assets|packs|fonts|images|javascripts|stylesheets|swfs|system)/ {
360
+ # try_files $uri @rails;
361
+
362
+ # # access_log off;
363
+ # gzip_static on; # to serve pre-gzipped version
364
+
365
+ # expires max;
366
+ # add_header Cache-Control public;
367
+
368
+ # # Some browsers still send conditional-GET requests if there's a
369
+ # # Last-Modified header or an ETag header even if they haven't
370
+ # # reached the expiry date sent in the Expires header.
371
+ # add_header Last-Modified "";
372
+ # add_header ETag "";
373
+ # break;
374
+ # }
375
+
376
+ # # send non-static file requests to the app server
377
+ # location / {
378
+ # try_files $uri @rails;
379
+ # }
380
+
381
+ # location @rails {
382
+ # proxy_set_header X-Real-IP $remote_addr;
383
+ # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
384
+ # proxy_set_header Host $http_host;
385
+ # proxy_redirect off;
386
+ # proxy_pass http://rails_app;
387
+ # }
388
+ # }
389
+
390
+
241
391
  redis:
242
392
  enabled: true
243
393
  password: mysecret
@@ -273,6 +423,8 @@ global:
273
423
  postgresql:
274
424
  postgresqlUsername: hyrax
275
425
  postgresqlPassword: hyrax_pass
426
+ # This is th name of the running rails server pod
427
+ hyraxHostName: hyrax
276
428
 
277
429
  nodeSelector: {}
278
430
 
data/config/features.rb CHANGED
@@ -1,53 +1,51 @@
1
1
  # frozen_string_literal: true
2
2
  Flipflop.configure do
3
- begin
4
- # Strategies will be used in the order listed here.
5
- strategy :cookie
6
- strategy :active_record, class: Hyrax::Feature
7
- strategy Hyrax::Strategies::YamlStrategy, config: Hyrax.config.feature_config_path
8
- strategy :default
9
-
10
- feature :proxy_deposit,
11
- default: true,
12
- description: "Depositors may designate proxies to deposit works on their behalf"
13
-
14
- feature :transfer_works,
15
- default: true,
16
- description: "Depositors may transfer their works to another user"
17
-
18
- # Note, if this is deactivated, a default admin set will be created and all
19
- # works will be assigned to it when they are created.
20
- feature :assign_admin_set,
21
- default: true,
22
- description: "Ability to assign uploaded items to an admin set"
23
-
24
- feature :show_deposit_agreement,
25
- default: true,
26
- description: "Show a deposit agreement to users creating works"
27
-
28
- feature :active_deposit_agreement_acceptance,
29
- default: Hyrax.config.active_deposit_agreement_acceptance?,
30
- description: "Require an active acceptance of the deposit agreement by checking a checkbox"
31
-
32
- feature :batch_upload,
33
- default: false,
34
- description: "Enable uploading batches of works"
35
-
36
- feature :hide_private_items,
37
- default: false,
38
- description: "Do not show the private items."
39
-
40
- feature :hide_users_list,
41
- default: true,
42
- description: "Do not show users list unless user has authenticated."
43
-
44
- feature :cache_work_iiif_manifest,
45
- default: false,
46
- description: "Use Rails.cache to cache the JSON document for IIIF manifests"
47
- feature :read_only,
48
- default: false,
49
- description: "Put the system into read-only mode. Deposits, edits, approvals and anything that makes a change to the data will be disabled."
50
- rescue Flipflop::StrategyError, Flipflop::FeatureError => err
51
- Rails.logger.warn "Ignoring #{err}: #{err.message}"
52
- end
3
+ # Strategies will be used in the order listed here.
4
+ strategy :cookie
5
+ strategy :active_record, class: Hyrax::Feature
6
+ strategy Hyrax::Strategies::YamlStrategy, config: Hyrax.config.feature_config_path
7
+ strategy :default
8
+
9
+ feature :proxy_deposit,
10
+ default: true,
11
+ description: "Depositors may designate proxies to deposit works on their behalf"
12
+
13
+ feature :transfer_works,
14
+ default: true,
15
+ description: "Depositors may transfer their works to another user"
16
+
17
+ # Note, if this is deactivated, a default admin set will be created and all
18
+ # works will be assigned to it when they are created.
19
+ feature :assign_admin_set,
20
+ default: true,
21
+ description: "Ability to assign uploaded items to an admin set"
22
+
23
+ feature :show_deposit_agreement,
24
+ default: true,
25
+ description: "Show a deposit agreement to users creating works"
26
+
27
+ feature :active_deposit_agreement_acceptance,
28
+ default: Hyrax.config.active_deposit_agreement_acceptance?,
29
+ description: "Require an active acceptance of the deposit agreement by checking a checkbox"
30
+
31
+ feature :batch_upload,
32
+ default: false,
33
+ description: "Enable uploading batches of works"
34
+
35
+ feature :hide_private_items,
36
+ default: false,
37
+ description: "Do not show the private items."
38
+
39
+ feature :hide_users_list,
40
+ default: true,
41
+ description: "Do not show users list unless user has authenticated."
42
+
43
+ feature :cache_work_iiif_manifest,
44
+ default: false,
45
+ description: "Use Rails.cache to cache the JSON document for IIIF manifests"
46
+ feature :read_only,
47
+ default: false,
48
+ description: "Put the system into read-only mode. Deposits, edits, approvals and anything that makes a change to the data will be disabled."
49
+ rescue Flipflop::StrategyError, Flipflop::FeatureError => err
50
+ Rails.logger.warn "Ignoring #{err}: #{err.message}"
53
51
  end
@@ -9,7 +9,6 @@ Hyrax.publisher.subscribe(Hyrax::Listeners::FileSetLifecycleNotificationListener
9
9
  Hyrax.publisher.subscribe(Hyrax::Listeners::MemberCleanupListener.new)
10
10
  Hyrax.publisher.subscribe(Hyrax::Listeners::MetadataIndexListener.new)
11
11
  Hyrax.publisher.subscribe(Hyrax::Listeners::ObjectLifecycleListener.new)
12
- Hyrax.publisher.subscribe(Hyrax::Listeners::ProxyDepositListener.new)
13
12
  Hyrax.publisher.subscribe(Hyrax::Listeners::TrophyCleanupListener.new)
14
13
  Hyrax.publisher.subscribe(Hyrax::Listeners::WorkflowListener.new)
15
14