arclight 0.1.0 → 1.6.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.
- checksums.yaml +5 -5
- data/.all-contributorsrc +450 -0
- data/.codeclimate.yml +5 -0
- data/.eslintrc +14 -4
- data/.github/workflows/ruby.yml +51 -0
- data/.gitignore +2 -0
- data/.rspec +0 -1
- data/.rubocop.yml +503 -48
- data/.rubocop_todo.yml +122 -0
- data/.solr_wrapper +2 -1
- data/CONTRIBUTING.md +5 -5
- data/CONTRIBUTORS.md +79 -0
- data/Gemfile +15 -10
- data/README.md +47 -32
- data/Rakefile +0 -1
- data/app/assets/images/blacklight/bookmark.svg +1 -0
- data/app/assets/images/blacklight/collection.svg +5 -0
- data/app/assets/images/blacklight/compact.svg +1 -25
- data/app/assets/images/blacklight/container.svg +5 -0
- data/app/assets/images/blacklight/ead.svg +1 -0
- data/app/assets/images/blacklight/file.svg +5 -0
- data/app/assets/images/blacklight/folder.svg +1 -0
- data/app/assets/images/blacklight/list.svg +1 -0
- data/app/assets/images/blacklight/minus.svg +1 -0
- data/app/assets/images/blacklight/online.svg +5 -0
- data/app/assets/images/blacklight/pdf.svg +1 -0
- data/app/assets/images/blacklight/plus.svg +1 -0
- data/app/assets/images/blacklight/repository.svg +1 -0
- data/app/assets/javascripts/arclight/arclight.js +4 -9
- data/app/assets/javascripts/arclight/oembed_controller.js +58 -0
- data/app/assets/javascripts/arclight/truncate_controller.js +27 -0
- data/app/assets/stylesheets/arclight/application.scss +4 -3
- data/app/assets/stylesheets/arclight/build.scss +4 -0
- data/app/assets/stylesheets/arclight/modules/hierarchy_and_online_contents.scss +117 -136
- data/app/assets/stylesheets/arclight/modules/highlights.scss +3 -2
- data/app/assets/stylesheets/arclight/modules/icons.scss +20 -0
- data/app/assets/stylesheets/arclight/modules/layout.scss +203 -16
- data/app/assets/stylesheets/arclight/modules/mastheads.scss +27 -45
- data/app/assets/stylesheets/arclight/modules/repositories.scss +3 -7
- data/app/assets/stylesheets/arclight/modules/repository_card.scss +5 -50
- data/app/assets/stylesheets/arclight/modules/search_form.scss +9 -0
- data/app/assets/stylesheets/arclight/modules/search_results.scss +200 -25
- data/app/assets/stylesheets/arclight/modules/show_collection.scss +21 -61
- data/app/assets/stylesheets/arclight/modules/truncator.scss +58 -0
- data/app/assets/stylesheets/arclight/responsive.scss +13 -0
- data/app/assets/stylesheets/arclight/variables.scss +25 -2
- data/app/components/arclight/access_component.html.erb +14 -0
- data/app/components/arclight/access_component.rb +25 -0
- data/app/components/arclight/bookmark_component.html.erb +25 -0
- data/app/components/arclight/bookmark_component.rb +9 -0
- data/app/components/arclight/breadcrumb_component.rb +50 -0
- data/app/components/arclight/breadcrumbs_hierarchy_component.html.erb +34 -0
- data/app/components/arclight/breadcrumbs_hierarchy_component.rb +25 -0
- data/app/components/arclight/collection_context_component.html.erb +12 -0
- data/app/components/arclight/collection_context_component.rb +27 -0
- data/app/components/arclight/collection_info_component.html.erb +28 -0
- data/app/components/arclight/collection_info_component.rb +26 -0
- data/app/components/arclight/collection_sidebar_component.html.erb +15 -0
- data/app/components/arclight/collection_sidebar_component.rb +39 -0
- data/app/{views/catalog/_search_results_repository.html.erb → components/arclight/constraints_component.html.erb} +2 -1
- data/app/components/arclight/constraints_component.rb +17 -0
- data/app/components/arclight/document_collection_context_component.html.erb +29 -0
- data/app/components/arclight/document_collection_context_component.rb +28 -0
- data/app/components/arclight/document_collection_hierarchy_component.html.erb +50 -0
- data/app/components/arclight/document_collection_hierarchy_component.rb +62 -0
- data/app/components/arclight/document_component.html.erb +39 -0
- data/app/components/arclight/document_component.rb +49 -0
- data/app/components/arclight/document_components_hierarchy_component.html.erb +20 -0
- data/app/components/arclight/document_components_hierarchy_component.rb +34 -0
- data/app/components/arclight/document_download_component.html.erb +24 -0
- data/app/components/arclight/document_download_component.rb +71 -0
- data/app/components/arclight/embed_component.html.erb +10 -0
- data/app/components/arclight/embed_component.rb +43 -0
- data/app/components/arclight/expand_hierarchy_button_component.html.erb +5 -0
- data/app/components/arclight/expand_hierarchy_button_component.rb +16 -0
- data/app/components/arclight/group_component.html.erb +34 -0
- data/app/components/arclight/group_component.rb +23 -0
- data/app/components/arclight/header_component.html.erb +5 -0
- data/app/components/arclight/header_component.rb +10 -0
- data/app/components/arclight/index_metadata_field_component.html.erb +16 -0
- data/app/components/arclight/index_metadata_field_component.rb +20 -0
- data/app/components/arclight/masthead_component.html.erb +17 -0
- data/app/components/arclight/masthead_component.rb +10 -0
- data/app/components/arclight/metadata_section_component.html.erb +13 -0
- data/app/components/arclight/metadata_section_component.rb +22 -0
- data/app/components/arclight/oembed_viewer_component.html.erb +5 -0
- data/app/components/arclight/oembed_viewer_component.rb +16 -0
- data/app/components/arclight/online_content_filter_component.html.erb +15 -0
- data/app/components/arclight/online_content_filter_component.rb +17 -0
- data/app/components/arclight/online_status_indicator_component.rb +19 -0
- data/app/components/arclight/repository_breadcrumb_component.html.erb +10 -0
- data/app/components/arclight/repository_breadcrumb_component.rb +17 -0
- data/app/components/arclight/repository_location_component.html.erb +20 -0
- data/app/components/arclight/repository_location_component.rb +10 -0
- data/app/components/arclight/search_bar_component.html.erb +27 -0
- data/app/components/arclight/search_bar_component.rb +32 -0
- data/app/components/arclight/search_result_breadcrumbs_component.html.erb +6 -0
- data/app/components/arclight/search_result_breadcrumbs_component.rb +37 -0
- data/app/components/arclight/search_result_component.html.erb +20 -0
- data/app/components/arclight/search_result_component.rb +18 -0
- data/app/components/arclight/search_result_title_component.html.erb +15 -0
- data/app/components/arclight/search_result_title_component.rb +15 -0
- data/app/components/arclight/sidebar_component.html.erb +9 -0
- data/app/components/arclight/sidebar_component.rb +19 -0
- data/app/components/arclight/upper_metadata_layout_component.rb +10 -0
- data/app/components/blacklight/icons/bookmark_component.rb +12 -0
- data/app/components/blacklight/icons/collection_component.rb +14 -0
- data/app/components/blacklight/icons/compact_component.rb +12 -0
- data/app/components/blacklight/icons/container_component.rb +14 -0
- data/app/components/blacklight/icons/ead_component.rb +12 -0
- data/app/components/blacklight/icons/file_component.rb +14 -0
- data/app/components/blacklight/icons/folder_component.rb +12 -0
- data/app/components/blacklight/icons/online_component.rb +15 -0
- data/app/components/blacklight/icons/pdf_component.rb +12 -0
- data/app/components/blacklight/icons/repository_component.rb +12 -0
- data/app/controllers/arclight/repositories_controller.rb +4 -4
- data/app/helpers/arclight/ead_format_helpers.rb +309 -0
- data/app/helpers/arclight/field_config_helpers.rb +26 -0
- data/app/helpers/arclight_helper.rb +55 -120
- data/app/models/arclight/document_downloads.rb +122 -0
- data/app/models/arclight/parent.rb +9 -9
- data/app/models/arclight/parents.rb +9 -4
- data/app/models/arclight/requests/aeon_external_request.rb +42 -0
- data/app/models/arclight/requests/aeon_web_ead.rb +52 -0
- data/app/models/arclight/requests/google_form.rb +8 -3
- data/app/models/concerns/arclight/catalog.rb +33 -11
- data/app/models/concerns/arclight/search_behavior.rb +22 -21
- data/app/models/concerns/arclight/solr_document.rb +88 -59
- data/app/presenters/arclight/show_presenter.rb +34 -7
- data/app/views/arclight/_requests.html.erb +7 -0
- data/app/views/arclight/repositories/_repository.html.erb +22 -41
- data/app/views/arclight/repositories/index.html.erb +5 -0
- data/app/views/arclight/repositories/show.html.erb +7 -8
- data/app/views/arclight/requests/_aeon_external_request_endpoint.html.erb +8 -0
- data/app/views/arclight/requests/_aeon_web_ead.html.erb +6 -0
- data/app/views/arclight/requests/_google_form.html.erb +4 -5
- data/app/views/catalog/_document_list.html.erb +8 -0
- data/app/views/catalog/_group.html.erb +4 -0
- data/app/views/catalog/_group_toggle.html.erb +10 -0
- data/app/views/catalog/_search_results_header.html.erb +3 -0
- data/app/views/catalog/hierarchy.html.erb +19 -0
- data/app/views/catalog/index.html.erb +16 -7
- data/app/views/shared/_breadcrumbs.html.erb +3 -15
- data/app/views/shared/_main_menu_links.html.erb +1 -1
- data/arclight.gemspec +22 -17
- data/config/breadcrumbs.rb +24 -0
- data/config/i18n-tasks.yml +134 -0
- data/config/importmap.rb +3 -0
- data/config/locales/arclight.en.yml +90 -55
- data/config/routes.rb +1 -1
- data/docker-compose.yml +16 -0
- data/lib/arclight/digital_object.rb +2 -1
- data/lib/arclight/engine.rb +23 -31
- data/lib/arclight/exceptions.rb +1 -0
- data/lib/arclight/hash_absolute_xpath.rb +62 -0
- data/lib/arclight/level_label.rb +46 -0
- data/lib/arclight/missing_id_strategy.rb +21 -0
- data/lib/arclight/normalized_date.rb +24 -20
- data/lib/arclight/normalized_id.rb +7 -2
- data/lib/arclight/normalized_title.rb +3 -0
- data/lib/arclight/repository.rb +72 -47
- data/lib/arclight/routes/hierarchy.rb +19 -0
- data/lib/arclight/routes.rb +8 -0
- data/lib/arclight/traject/ead2_component_config.rb +335 -0
- data/lib/arclight/traject/ead2_config.rb +316 -0
- data/lib/arclight/traject/nokogiri_namespaceless_reader.rb +22 -0
- data/lib/arclight/version.rb +1 -1
- data/lib/arclight/year_range.rb +13 -4
- data/lib/arclight.rb +6 -1
- data/lib/generators/arclight/install_generator.rb +110 -10
- data/lib/generators/arclight/templates/arclight.scss +6 -3
- data/lib/generators/arclight/templates/catalog_controller.rb +249 -173
- data/lib/generators/arclight/templates/config/downloads.yml +12 -0
- data/lib/generators/arclight/templates/config/locales/arclight.en.yml +61 -0
- data/lib/generators/arclight/templates/config/repositories.yml +42 -31
- data/lib/generators/arclight/update_generator.rb +1 -1
- data/lib/tasks/index.rake +25 -28
- data/package.json +15 -9
- data/solr/conf/schema.xml +101 -332
- data/solr/conf/solrconfig.xml +99 -164
- data/tasks/arclight.rake +22 -11
- data/template.rb +6 -11
- metadata +230 -105
- data/.travis.yml +0 -33
- data/app/assets/javascripts/arclight/collection_context.js +0 -18
- data/app/assets/javascripts/arclight/collection_navigation.js +0 -114
- data/app/assets/javascripts/arclight/collection_scrollspy.js +0 -6
- data/app/assets/javascripts/arclight/component_ancestors.js +0 -56
- data/app/assets/javascripts/arclight/oembed_viewer.js +0 -39
- data/app/assets/javascripts/arclight/truncator.js.erb +0 -23
- data/app/assets/stylesheets/arclight/bootstrap_overrides.scss +0 -3
- data/app/assets/stylesheets/arclight/modules/sidebar.scss +0 -16
- data/app/controllers/concerns/arclight/field_config_helpers.rb +0 -86
- data/app/factories/blacklight_field_configuration_factory.rb +0 -29
- data/app/views/arclight/repositories/_in_person_repository.html.erb +0 -19
- data/app/views/arclight/viewers/_oembed.html.erb +0 -7
- data/app/views/catalog/_arclight_document_index_header.html.erb +0 -13
- data/app/views/catalog/_arclight_document_index_header_online_contents_default.html.erb +0 -0
- data/app/views/catalog/_arclight_document_show_header.html.erb +0 -15
- data/app/views/catalog/_arclight_document_show_header_collection.html.erb +0 -12
- data/app/views/catalog/_arclight_index_compact_default.html.erb +0 -15
- data/app/views/catalog/_arclight_online_content_indicator.html.erb +0 -5
- data/app/views/catalog/_arclight_rangelimit.html.erb +0 -24
- data/app/views/catalog/_arclight_viewer_default.html.erb +0 -1
- data/app/views/catalog/_collection_contents.html.erb +0 -12
- data/app/views/catalog/_collection_count.html.erb +0 -7
- data/app/views/catalog/_collection_downloads.html.erb +0 -17
- data/app/views/catalog/_collection_online_contents.html.erb +0 -17
- data/app/views/catalog/_collection_overview.html.erb +0 -7
- data/app/views/catalog/_component_overview.html.erb +0 -46
- data/app/views/catalog/_context_card.html.erb +0 -27
- data/app/views/catalog/_context_sidebar.html.erb +0 -8
- data/app/views/catalog/_custom_metadata.html.erb +0 -16
- data/app/views/catalog/_home.html.erb +0 -1
- data/app/views/catalog/_index_breadcrumb_default.html.erb +0 -3
- data/app/views/catalog/_index_default.html.erb +0 -17
- data/app/views/catalog/_index_header.html.erb +0 -7
- data/app/views/catalog/_index_header_hierarchy_default.html.erb +0 -42
- data/app/views/catalog/_index_header_online_contents_default.html.erb +0 -1
- data/app/views/catalog/_index_hierarchy_default.html.erb +0 -28
- data/app/views/catalog/_index_online_contents_default.html.erb +0 -6
- data/app/views/catalog/_results_histogram.html.erb +0 -10
- data/app/views/catalog/_search_results.html.erb +0 -31
- data/app/views/catalog/_search_within_form.html.erb +0 -16
- data/app/views/catalog/_show_breadcrumbs_default.html.erb +0 -7
- data/app/views/catalog/_show_collection.html.erb +0 -40
- data/app/views/catalog/_show_component_sidebar.html.erb +0 -12
- data/app/views/catalog/_show_default.html.erb +0 -32
- data/app/views/catalog/_show_header.html.erb +0 -5
- data/app/views/catalog/_show_sidebar.html.erb +0 -30
- data/app/views/layouts/catalog_result.html.erb +0 -7
- data/app/views/shared/_context_sidebar.html.erb +0 -8
- data/app/views/shared/_header_navbar.html.erb +0 -54
- data/lib/arclight/custom_component.rb +0 -98
- data/lib/arclight/custom_document.rb +0 -93
- data/lib/arclight/indexer.rb +0 -9
- data/lib/arclight/shared_indexing_behavior.rb +0 -97
- data/lib/arclight/shared_terminology_behavior.rb +0 -65
- data/lib/arclight/solr_ead_indexer_ext.rb +0 -159
- data/lib/arclight/viewer.rb +0 -45
- data/lib/arclight/viewers/oembed.rb +0 -56
- data/lib/generators/arclight/templates/arclight.js +0 -2
- data/solr/conf/scripts.conf +0 -24
- data/vendor/assets/javascripts/responsiveTruncator.js +0 -69
- data/vendor/assets/javascripts/stickyfill.js +0 -480
- /data/app/assets/images/{blacklight → arclight}/logo.png +0 -0
- /data/{app/views/catalog/_arclight_document_index_header_hierarchy_default.html.erb → config/repositories.yml} +0 -0
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<% doc_presenter = show_presenter(document).with_field_group(field_accessor) %>
|
|
2
|
-
|
|
3
|
-
<%= content_tag(:div, id: t("arclight.views.show.sections.#{field_accessor}").parameterize) do %>
|
|
4
|
-
<h3 class='al-show-sub-heading'>
|
|
5
|
-
<%= t("arclight.views.show.sections.#{field_accessor}", level: document.level) %>
|
|
6
|
-
</h3>
|
|
7
|
-
|
|
8
|
-
<dl class="row dl-invert">
|
|
9
|
-
<% generic_document_fields(field_accessor).each do |field_name, field| %>
|
|
10
|
-
<% if generic_should_render_field?(field_accessor, document, field) %>
|
|
11
|
-
<dt class="blacklight-<%= field_name.parameterize %> col-md-3"><%= generic_render_document_field_label(field_accessor, document, field: field_name) %></dt>
|
|
12
|
-
<dd class="blacklight-<%= field_name.parameterize %> col-md-9"><%= doc_presenter.field_value field_name %></dd>
|
|
13
|
-
<% end %>
|
|
14
|
-
<% end %>
|
|
15
|
-
</dl>
|
|
16
|
-
<% end %>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
<%= content_tag('div', class: 'al-document-creator') do %>
|
|
2
|
-
<%= document.creator %>
|
|
3
|
-
<% end if document.creator %>
|
|
4
|
-
|
|
5
|
-
<%= content_tag('div', class: 'al-document-extent') do %>
|
|
6
|
-
<%= document.extent %>
|
|
7
|
-
<% end if document.extent %>
|
|
8
|
-
|
|
9
|
-
<%= content_tag('div', class: 'al-document-abstract-or-scope', title: document.abstract_or_scope) do %>
|
|
10
|
-
<%= content_tag('div', 'data-arclight-truncate' => true) do %>
|
|
11
|
-
<%= document.abstract_or_scope %>
|
|
12
|
-
<% end %>
|
|
13
|
-
<% end if document.abstract_or_scope %>
|
|
14
|
-
|
|
15
|
-
<%= content_tag('div', class: 'al-document-highlight') do %>
|
|
16
|
-
<%= document.highlights.join('<br/>').html_safe %>
|
|
17
|
-
<% end if document.highlights %>
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
<%# header bar for doc items in index view -%>
|
|
2
|
-
<header class="documentHeader row" data-document-id="<%= document.id %>">
|
|
3
|
-
<h3 class="index_title document-title-heading col-md-12">
|
|
4
|
-
<% counter = document_counter_with_offset(document_counter) %>
|
|
5
|
-
<%= link_to_document document, document_show_link_field(document), counter: counter %>
|
|
6
|
-
</h3>
|
|
7
|
-
</header>
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
<header class="documentHeader row" data-document-id="<%= document.id %>">
|
|
2
|
-
<% requestable = item_requestable?('', { document: document }) %>
|
|
3
|
-
<% side_content = document.children? || requestable %>
|
|
4
|
-
<h3 class="index_title document-title-heading <%= side_content ? 'col-md-9' : 'col-md-12' %> ">
|
|
5
|
-
<% if document.containers.present? %>
|
|
6
|
-
<span class="document-title-containers">
|
|
7
|
-
<%= document.containers.join(', ') %>:
|
|
8
|
-
</span>
|
|
9
|
-
<% end %>
|
|
10
|
-
<% counter = document_counter_with_offset(document_counter) %>
|
|
11
|
-
<%= link_to_document document, document_show_link_field(document), counter: counter %>
|
|
12
|
-
</h3>
|
|
13
|
-
|
|
14
|
-
<div class="al-hierarchy-side-content float-right <%= side_content ? 'col-md-3' : 'col' %> ">
|
|
15
|
-
<% unless hierarchy_component_context? %>
|
|
16
|
-
<div class="index-document-functions">
|
|
17
|
-
<%= render partial: 'catalog/bookmark_control', locals: { document: document } %>
|
|
18
|
-
</div>
|
|
19
|
-
<% end %>
|
|
20
|
-
<% if requestable %>
|
|
21
|
-
<%= render partial: 'arclight/requests/google_form', locals: { document: document } %>
|
|
22
|
-
<% end %>
|
|
23
|
-
<% if document.children? %>
|
|
24
|
-
<div class='al-hierarchy-children-status'>
|
|
25
|
-
<span class='badge badge-default al-number-of-children-badge'>
|
|
26
|
-
<%= t(:'arclight.views.index.number_of_children', count: document.number_of_children) %>
|
|
27
|
-
<% unless hierarchy_component_context? %>
|
|
28
|
-
<%= link_to(
|
|
29
|
-
t('arclight.hierarchy.view_all'),
|
|
30
|
-
"##{document.reference}-collapsible-hierarchy",
|
|
31
|
-
class: 'al-toggle-view-all',
|
|
32
|
-
data: {
|
|
33
|
-
toggle: 'collapse'
|
|
34
|
-
}
|
|
35
|
-
)
|
|
36
|
-
%>
|
|
37
|
-
<% end %>
|
|
38
|
-
</span>
|
|
39
|
-
</div>
|
|
40
|
-
<% end %>
|
|
41
|
-
</div>
|
|
42
|
-
</header>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
<%= render_document_partial(document, :index_header_hierarchy, document_counter: document_counter) %>
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
<%= content_tag('div', class: 'al-document-abstract-or-scope', title: document.abstract_or_scope) do %>
|
|
2
|
-
<%= content_tag(:h4, I18n.t('arclight.hierarchy.scope_and_contents'), class: 'al-hierarchy-sub-heading') %>
|
|
3
|
-
<%= content_tag('div', 'data-arclight-truncate' => true) do %>
|
|
4
|
-
<%= document.abstract_or_scope %>
|
|
5
|
-
<% end %>
|
|
6
|
-
<% end if document.abstract_or_scope %>
|
|
7
|
-
|
|
8
|
-
<% if document.number_of_children > 0 %>
|
|
9
|
-
<%= content_tag(:div, id: "#{document.reference}-collapsible-hierarchy",
|
|
10
|
-
class: "collapse al-hierarchy-level-#{document.component_level}",
|
|
11
|
-
) do %>
|
|
12
|
-
|
|
13
|
-
<%= content_tag(
|
|
14
|
-
:div, '',
|
|
15
|
-
class: 'al-contents',
|
|
16
|
-
data: {
|
|
17
|
-
arclight: {
|
|
18
|
-
hierarchy: true,
|
|
19
|
-
level: document.component_level + 1,
|
|
20
|
-
path: search_catalog_path,
|
|
21
|
-
name: document.collection_name,
|
|
22
|
-
parent: document.reference
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
) %>
|
|
26
|
-
|
|
27
|
-
<% end %>
|
|
28
|
-
<% end %>
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
<%= content_tag('div', class: 'al-document-abstract-or-scope', title: document.abstract_or_scope) do %>
|
|
2
|
-
<%= content_tag(:h4, I18n.t('arclight.hierarchy.scope_and_contents'), class: 'al-hierarchy-sub-heading') %>
|
|
3
|
-
<%= content_tag('div', 'data-arclight-truncate' => true) do %>
|
|
4
|
-
<%= document.abstract_or_scope %>
|
|
5
|
-
<% end %>
|
|
6
|
-
<% end if document.abstract_or_scope %>
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
<div class='al-data-range-histogram row'>
|
|
2
|
-
<div class='col-md-12'>
|
|
3
|
-
<div id='al-date-range-histogram-content' class='collapse facet-content'>
|
|
4
|
-
<%= render partial: 'arclight_rangelimit', locals: { field_name: :date_range_sim, solr_field: :date_range_sim } %>
|
|
5
|
-
</div>
|
|
6
|
-
<a class='float-right' data-toggle='collapse' href='#al-date-range-histogram-content' aria-expanded='false' aria-controls='al-date-range-histogram-content'>
|
|
7
|
-
<%= t('arclight.date_range_histogram.show_hide') %>
|
|
8
|
-
</a>
|
|
9
|
-
</div>
|
|
10
|
-
</div>
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
<h2 class="sr-only top-content-title"><%= t('blacklight.search.search_results_header') %></h2>
|
|
2
|
-
|
|
3
|
-
<% @page_title = t('blacklight.search.page_title.title', :constraints => render_search_to_page_title(params), :application_name => application_name) %>
|
|
4
|
-
|
|
5
|
-
<% content_for(:head) do %>
|
|
6
|
-
<%= render_opensearch_response_metadata %>
|
|
7
|
-
<%= rss_feed_link_tag %>
|
|
8
|
-
<%= atom_feed_link_tag %>
|
|
9
|
-
<% end %>
|
|
10
|
-
|
|
11
|
-
<% content_for(:container_header) do %>
|
|
12
|
-
<%= render 'shared/breadcrumbs' %>
|
|
13
|
-
<%= render 'search_results_repository' %>
|
|
14
|
-
<%= render 'collection_count' %>
|
|
15
|
-
<%= render 'results_histogram' %>
|
|
16
|
-
<%= render 'constraints' %>
|
|
17
|
-
<% end %>
|
|
18
|
-
|
|
19
|
-
<%= render 'search_header' %>
|
|
20
|
-
|
|
21
|
-
<h2 class="sr-only"><%= t('blacklight.search.search_results') %></h2>
|
|
22
|
-
|
|
23
|
-
<%- if @response.empty? %>
|
|
24
|
-
<%= render "zero_results" %>
|
|
25
|
-
<%- elsif render_grouped_response? %>
|
|
26
|
-
<%= render_grouped_document_index %>
|
|
27
|
-
<%- else %>
|
|
28
|
-
<%= render_document_index %>
|
|
29
|
-
<%- end %>
|
|
30
|
-
|
|
31
|
-
<%= render 'results_pagination' %>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<%= form_tag search_action_url, method: :get, class: 'search-query-form', role: 'search' do %>
|
|
2
|
-
<%= render_hash_as_hidden_fields({f: {collection_sim: [@document.collection_name]}}) %>
|
|
3
|
-
<div class='input-group'>
|
|
4
|
-
<%= hidden_field_tag :search_field, search_fields.first.last %>
|
|
5
|
-
<%= hidden_field_tag :search_field, 'within_collection' %>
|
|
6
|
-
|
|
7
|
-
<label for='q' class='sr-only'><%= t('arclight.views.show.search_within') %></label>
|
|
8
|
-
<%= text_field_tag :q, params[:q], class: 'search_q q form-control', id: 'q', autofocus: should_autofocus_on_search_box? %>
|
|
9
|
-
|
|
10
|
-
<span class='input-group-btn'>
|
|
11
|
-
<button type='submit' class='btn btn-primary search-btn' id='search'>
|
|
12
|
-
<%= blacklight_icon :search %>
|
|
13
|
-
</button>
|
|
14
|
-
</span>
|
|
15
|
-
</div>
|
|
16
|
-
<% end %>
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
<div class='al-show-breadcrumb'>
|
|
2
|
-
<%= link_to t('arclight.routes.home'), root_path %>
|
|
3
|
-
<%= t('arclight.breadcrumb_separator') %>
|
|
4
|
-
<%= link_to t('arclight.routes.collections'), arclight_engine.collections_path %>
|
|
5
|
-
<%= t('arclight.breadcrumb_separator') %>
|
|
6
|
-
<%= safe_join([parents_to_links(document), document.normalized_title].reject(&:empty?), t('arclight.breadcrumb_separator')) %>
|
|
7
|
-
</div>
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
<div class='row'>
|
|
2
|
-
<div class='col-md-3'>
|
|
3
|
-
<%= render partial: 'show_sidebar' %>
|
|
4
|
-
</div>
|
|
5
|
-
<div class='col-md-9'>
|
|
6
|
-
<ul class='nav nav-pills' role='tablist'>
|
|
7
|
-
<li class='nav-item'>
|
|
8
|
-
<a class='nav-link active' data-toggle='pill' href='#overview' role='tab'>
|
|
9
|
-
<%= t 'arclight.views.show.overview' %>
|
|
10
|
-
</a>
|
|
11
|
-
</li>
|
|
12
|
-
<li class='nav-item'>
|
|
13
|
-
<a class='nav-link disabled' data-toggle='pill' href='#contents' role='tab' data-hierarchy-enable-me='true'>
|
|
14
|
-
<%= t 'arclight.views.show.no_contents' %>
|
|
15
|
-
</a>
|
|
16
|
-
</li>
|
|
17
|
-
<li class='nav-item'>
|
|
18
|
-
<a class='nav-link <%= 'disabled' unless document.digital_objects.present? || document.online_content? %>' data-toggle='pill' href='#online-content' role='tab' data-arclight-online-content-tab='true'>
|
|
19
|
-
<% if document.digital_objects.present? || document.online_content? %>
|
|
20
|
-
<%= t 'arclight.views.show.online_content' %>
|
|
21
|
-
<% else %>
|
|
22
|
-
<%= t 'arclight.views.show.no_online_content' %>
|
|
23
|
-
<% end %>
|
|
24
|
-
</a>
|
|
25
|
-
</li>
|
|
26
|
-
<%= render partial: 'collection_downloads', locals: { downloads: collection_downloads(document) } %>
|
|
27
|
-
</ul>
|
|
28
|
-
<div class='tab-content'>
|
|
29
|
-
<div class='tab-pane active' id='overview' role='tabpanel'>
|
|
30
|
-
<%= render 'collection_overview' %>
|
|
31
|
-
</div>
|
|
32
|
-
<div class='tab-pane' id='contents' role='tabpanel'>
|
|
33
|
-
<%= render 'collection_contents' %>
|
|
34
|
-
</div>
|
|
35
|
-
<div class='tab-pane' id='online-content' role='tabpanel'>
|
|
36
|
-
<%= render partial: 'collection_online_contents', locals: { document: document } %>
|
|
37
|
-
</div>
|
|
38
|
-
</div>
|
|
39
|
-
</div>
|
|
40
|
-
</div>
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
<div class='al-sticky-sidebar'>
|
|
2
|
-
<h2 class="sr-only">Sidebar</h2>
|
|
3
|
-
|
|
4
|
-
<% unless blacklight_config.show.component_sidebar_items.nil? %>
|
|
5
|
-
<div id="accordion" role="tablist" aria-multiselectable="true">
|
|
6
|
-
<% items = blacklight_config.show.component_sidebar_items.select { |i| fields_have_content?(@document, i) } %>
|
|
7
|
-
<% items.each_with_index do |item, index| %>
|
|
8
|
-
<%= render partial: 'context_card', locals: { document: @document, field_accessor: item, card_index: index} %>
|
|
9
|
-
<% end %>
|
|
10
|
-
</div>
|
|
11
|
-
<% end %>
|
|
12
|
-
</div>
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
<div class='row'>
|
|
2
|
-
<div class='col-md-3'>
|
|
3
|
-
<%= render partial: 'show_component_sidebar' %>
|
|
4
|
-
</div>
|
|
5
|
-
<div class='col-md-9'>
|
|
6
|
-
<ul class='nav nav-pills' role='tablist'>
|
|
7
|
-
<li class='nav-item'>
|
|
8
|
-
<a class='nav-link active' data-toggle='pill' href='#overview' role='tab'>
|
|
9
|
-
<%= t 'arclight.views.show.overview' %>
|
|
10
|
-
</a>
|
|
11
|
-
</li>
|
|
12
|
-
<li class='nav-item'>
|
|
13
|
-
<a class='nav-link <%= 'disabled' unless document.online_content? %>' data-toggle='pill' href='#online-content' role='tab' data-arclight-online-content-tab='true'>
|
|
14
|
-
<% if document.online_content? %>
|
|
15
|
-
<%= t 'arclight.views.show.online_content' %>
|
|
16
|
-
<% else %>
|
|
17
|
-
<%= t 'arclight.views.show.no_online_content' %>
|
|
18
|
-
<% end %>
|
|
19
|
-
</a>
|
|
20
|
-
</li>
|
|
21
|
-
</ul>
|
|
22
|
-
<div class='tab-content'>
|
|
23
|
-
<div class='tab-pane active' id='overview' role='tabpanel'>
|
|
24
|
-
<%= render 'component_overview' %>
|
|
25
|
-
</div>
|
|
26
|
-
<div class='tab-pane' id='online-content' role='tabpanel'>
|
|
27
|
-
<%= render_document_partial(document, 'arclight_viewer') %>
|
|
28
|
-
</div>
|
|
29
|
-
</div>
|
|
30
|
-
</div>
|
|
31
|
-
|
|
32
|
-
</div>
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
<div class='al-sticky-sidebar'>
|
|
2
|
-
<h2 class="sr-only">Sidebar</h2>
|
|
3
|
-
<div class='card'>
|
|
4
|
-
<div class='card-header'>
|
|
5
|
-
<h3 class="mb-0">Search within this collection</h3>
|
|
6
|
-
</div>
|
|
7
|
-
<div class='card-block'>
|
|
8
|
-
<%= render 'search_within_form' %>
|
|
9
|
-
</div>
|
|
10
|
-
</div>
|
|
11
|
-
<div class='al-sidebar-navigation-overview card'>
|
|
12
|
-
<div class='card-header'>
|
|
13
|
-
<h3 class="mb-0"><%= t('arclight.views.show.navigation_sidebar.title') %></h3>
|
|
14
|
-
</div>
|
|
15
|
-
<div class='card-block'>
|
|
16
|
-
<ul class='nav nav-pills flex-column'>
|
|
17
|
-
<% unless blacklight_config.show.metadata_partials.nil? %>
|
|
18
|
-
<% blacklight_config.show.metadata_partials.each do |item| %>
|
|
19
|
-
<% next unless fields_have_content?(@document, item) %>
|
|
20
|
-
<li class='nav-item'>
|
|
21
|
-
<%= link_to t("arclight.views.show.sections.#{item}"), "##{t("arclight.views.show.sections.#{item}").parameterize}", class: 'nav-link' %>
|
|
22
|
-
</li>
|
|
23
|
-
<% end %>
|
|
24
|
-
<% end %>
|
|
25
|
-
</ul>
|
|
26
|
-
</div>
|
|
27
|
-
</div>
|
|
28
|
-
|
|
29
|
-
<%= render 'shared/context_sidebar' %>
|
|
30
|
-
</div>
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
<% unless blacklight_config.show.context_sidebar_items.nil? %>
|
|
2
|
-
<div id="accordion" role="tablist" aria-multiselectable="true">
|
|
3
|
-
<% items = blacklight_config.show.context_sidebar_items.select { |i| fields_have_content?(@document, i) } %>
|
|
4
|
-
<% items.each_with_index do |item, index| %>
|
|
5
|
-
<%= render partial: 'context_card', locals: { document: @document, field_accessor: item, card_index: index} %>
|
|
6
|
-
<% end %>
|
|
7
|
-
</div>
|
|
8
|
-
<% end %>
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
<nav class="navbar navbar-toggleable-md navbar-inverse bg-inverse" role="navigation">
|
|
2
|
-
<div class="<%= container_classes %>">
|
|
3
|
-
<button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#user-util-collapse" aria-controls="user-util-collapse" aria-expanded="false" aria-label="Toggle navigation">
|
|
4
|
-
<span class="navbar-toggler-icon"></span>
|
|
5
|
-
</button>
|
|
6
|
-
|
|
7
|
-
<%= link_to application_name, root_path, class: "navbar-brand" %>
|
|
8
|
-
|
|
9
|
-
<div class="collapse navbar-collapse justify-content-md-end" id="user-util-collapse">
|
|
10
|
-
<%= render 'shared/user_util_links' %>
|
|
11
|
-
</div>
|
|
12
|
-
</div>
|
|
13
|
-
</nav>
|
|
14
|
-
|
|
15
|
-
<% if controller_name == 'catalog' && !has_search_parameters? && action_name == 'index' %>
|
|
16
|
-
<div class='al-homepage-masthead jumbotron'>
|
|
17
|
-
<div class='row'>
|
|
18
|
-
<div class='col-md-8 offset-md-2'>
|
|
19
|
-
<h1 class='text-center'><%= t('arclight.masthead_heading') %></h1>
|
|
20
|
-
</div>
|
|
21
|
-
</div>
|
|
22
|
-
<div class='row'>
|
|
23
|
-
<div class='col-md-6 offset-md-3'>
|
|
24
|
-
<div class='navbar-search'>
|
|
25
|
-
<%= render_search_bar %>
|
|
26
|
-
</div>
|
|
27
|
-
</div>
|
|
28
|
-
</div>
|
|
29
|
-
<nav class="navbar" role="navigation">
|
|
30
|
-
<ul class="nav justify-content-center">
|
|
31
|
-
<%= render 'shared/main_menu_links' %>
|
|
32
|
-
</ul>
|
|
33
|
-
</nav>
|
|
34
|
-
</div>
|
|
35
|
-
<% else %>
|
|
36
|
-
<div class='bg-faded al-masthead'>
|
|
37
|
-
<div class="container">
|
|
38
|
-
<h1><%= t('arclight.masthead_heading') %></h1>
|
|
39
|
-
</div>
|
|
40
|
-
</div>
|
|
41
|
-
<div class="navbar-search navbar navbar-toggleable-sm bg-faded" role="navigation">
|
|
42
|
-
<div class="<%= container_classes %>">
|
|
43
|
-
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
|
|
44
|
-
<span class="navbar-toggler-icon"></span>
|
|
45
|
-
</button>
|
|
46
|
-
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
|
47
|
-
<ul class="navbar-nav mr-auto">
|
|
48
|
-
<%= render 'shared/main_menu_links' %>
|
|
49
|
-
</ul>
|
|
50
|
-
<%= render_search_bar %>
|
|
51
|
-
</div>
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
54
|
-
<% end %>
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Arclight
|
|
4
|
-
##
|
|
5
|
-
# An Arclight custom component indexing code
|
|
6
|
-
class CustomComponent < SolrEad::Component
|
|
7
|
-
extend Arclight::SharedTerminologyBehavior
|
|
8
|
-
include Arclight::SharedIndexingBehavior
|
|
9
|
-
use_terminology SolrEad::Component
|
|
10
|
-
|
|
11
|
-
# we extend the terminology to provide additional fields and/or indexing strategies
|
|
12
|
-
# than `solr_ead` provides as-is. in many cases we're doing redundant indexing, but
|
|
13
|
-
# we're trying to modify the `solr_ead` gem as little as possible
|
|
14
|
-
extend_terminology do |t|
|
|
15
|
-
# identifiers
|
|
16
|
-
t.level(path: 'c/@level', index_as: %i[displayable]) # machine-readable for string `level_ssm`
|
|
17
|
-
t.otherlevel(path: 'c/@otherlevel', index_as: %i[displayable])
|
|
18
|
-
t.ref_(path: '/c/@id', index_as: %i[displayable])
|
|
19
|
-
|
|
20
|
-
# facets
|
|
21
|
-
t.creator(path: "c/did/origination[@label='creator']/*/text()", index_as: %i[displayable facetable symbol])
|
|
22
|
-
t.places(path: 'c/controlaccess/geogname/text()', index_as: %i[displayable facetable symbol])
|
|
23
|
-
|
|
24
|
-
add_unitid(t, 'c/')
|
|
25
|
-
add_extent(t, 'c/')
|
|
26
|
-
add_dates(t, 'c/')
|
|
27
|
-
add_searchable_notes(t, 'c/')
|
|
28
|
-
end
|
|
29
|
-
|
|
30
|
-
def to_solr(solr_doc = {})
|
|
31
|
-
super
|
|
32
|
-
solr_doc['id'] = Arclight::NormalizedId.new(solr_doc['id']).to_s
|
|
33
|
-
solr_doc['creator_sort'] = creator.to_a.join(', ') if creator.present?
|
|
34
|
-
add_component_fields(solr_doc)
|
|
35
|
-
solr_doc
|
|
36
|
-
end
|
|
37
|
-
|
|
38
|
-
private
|
|
39
|
-
|
|
40
|
-
def add_component_fields(solr_doc)
|
|
41
|
-
component_field_definitions.each do |field|
|
|
42
|
-
# we want to use `set_field` rather than `insert_field` since we may be overriding fields
|
|
43
|
-
Solrizer.set_field(solr_doc, field[:name], field[:value], field[:index_as])
|
|
44
|
-
end
|
|
45
|
-
add_date_ranges(solr_doc)
|
|
46
|
-
add_normalized_title(solr_doc)
|
|
47
|
-
resolve_repository(solr_doc)
|
|
48
|
-
add_digital_content(prefix: 'c/did', solr_doc: solr_doc)
|
|
49
|
-
end
|
|
50
|
-
|
|
51
|
-
def component_field_definitions
|
|
52
|
-
[
|
|
53
|
-
{ name: 'level', value: formatted_level, index_as: :facetable },
|
|
54
|
-
{ name: 'names', value: names, index_as: :symbol },
|
|
55
|
-
{ name: 'access_subjects', value: access_subjects, index_as: :symbol },
|
|
56
|
-
{ name: 'containers', value: containers, index_as: :symbol },
|
|
57
|
-
{ name: 'has_online_content', value: online_content?, index_as: :symbol }
|
|
58
|
-
]
|
|
59
|
-
end
|
|
60
|
-
|
|
61
|
-
def resolve_repository(solr_doc)
|
|
62
|
-
repository = solr_doc[Solrizer.solr_name('repository', :displayable)]
|
|
63
|
-
%i[displayable facetable].each do |index_as|
|
|
64
|
-
Solrizer.set_field(solr_doc, 'repository', repository_as_configured(repository), index_as)
|
|
65
|
-
end
|
|
66
|
-
end
|
|
67
|
-
|
|
68
|
-
# @see http://eadiva.com/2/c/
|
|
69
|
-
def formatted_level
|
|
70
|
-
# terminology definitions for level yield Arrays and in this case single values
|
|
71
|
-
# TODO: OM changes the behavior of `level = level.first` such that it always returns `nil`
|
|
72
|
-
# so need our own local variable here
|
|
73
|
-
actual_level = level.first.to_s if level.respond_to? :first
|
|
74
|
-
|
|
75
|
-
if actual_level == 'otherlevel'
|
|
76
|
-
alternative_level = otherlevel.first.to_s if otherlevel.respond_to? :first
|
|
77
|
-
alternative_level.present? ? alternative_level : 'Other'
|
|
78
|
-
elsif actual_level.present?
|
|
79
|
-
actual_level.capitalize
|
|
80
|
-
end
|
|
81
|
-
end
|
|
82
|
-
|
|
83
|
-
def names
|
|
84
|
-
names_array(%w[corpname famname name persname], parent: 'c')
|
|
85
|
-
end
|
|
86
|
-
|
|
87
|
-
def access_subjects
|
|
88
|
-
subjects_array(%w[subject function occupation genreform], parent: 'c')
|
|
89
|
-
end
|
|
90
|
-
|
|
91
|
-
def containers
|
|
92
|
-
contains = search('//container').to_a
|
|
93
|
-
contains.map do |c|
|
|
94
|
-
"#{c.attributes['type'].try(:value)} #{c.text}".strip
|
|
95
|
-
end
|
|
96
|
-
end
|
|
97
|
-
end
|
|
98
|
-
end
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Arclight
|
|
4
|
-
##
|
|
5
|
-
# An Arclight custom document indexing code
|
|
6
|
-
class CustomDocument < SolrEad::Document
|
|
7
|
-
extend Arclight::SharedTerminologyBehavior
|
|
8
|
-
include Arclight::SharedIndexingBehavior
|
|
9
|
-
use_terminology SolrEad::Document
|
|
10
|
-
|
|
11
|
-
# we extend the terminology to provide additional fields and/or indexing strategies
|
|
12
|
-
# than `solr_ead` provides as-is. in many cases we're doing redundant indexing, but
|
|
13
|
-
# we're trying to modify the `solr_ead` gem as little as possible
|
|
14
|
-
extend_terminology do |t|
|
|
15
|
-
# facets
|
|
16
|
-
t.repository(path: 'archdesc/did/repository/corpname/text() | archdesc/did/repository/name/text()', index_as: %i[displayable facetable])
|
|
17
|
-
t.creator(path: "archdesc/did/origination[@label='creator']/*/text()", index_as: %i[displayable facetable symbol])
|
|
18
|
-
t.creator_persname(path: "archdesc/did/origination[@label='creator']/persname/text()", index_as: %i[displayable facetable symbol])
|
|
19
|
-
t.creator_corpname(path: "archdesc/did/origination[@label='creator']/corpname/text()", index_as: %i[displayable facetable symbol])
|
|
20
|
-
t.creator_famname(path: "archdesc/did/origination[@label='creator']/famname/text()", index_as: %i[displayable facetable symbol])
|
|
21
|
-
t.function(path: 'archdesc/controlaccess/function/text()', index_as: %i[displayable facetable])
|
|
22
|
-
t.occupation(path: 'archdesc/controlaccess/occupation/text()', index_as: %i[displayable facetable])
|
|
23
|
-
t.places(path: 'archdesc/controlaccess/geogname/text()', index_as: %i[displayable facetable symbol])
|
|
24
|
-
|
|
25
|
-
add_unitid(t, 'archdesc/')
|
|
26
|
-
add_extent(t, 'archdesc/')
|
|
27
|
-
add_dates(t, 'archdesc/')
|
|
28
|
-
add_searchable_notes(t, 'archdesc/')
|
|
29
|
-
end
|
|
30
|
-
|
|
31
|
-
def to_solr(solr_doc = {})
|
|
32
|
-
super
|
|
33
|
-
solr_doc['id'] = Arclight::NormalizedId.new(eadid.first).to_s
|
|
34
|
-
solr_doc['creator_sort'] = creator.to_a.join(', ') if creator.present?
|
|
35
|
-
add_document_fields(solr_doc)
|
|
36
|
-
solr_doc
|
|
37
|
-
end
|
|
38
|
-
|
|
39
|
-
private
|
|
40
|
-
|
|
41
|
-
def add_document_fields(solr_doc)
|
|
42
|
-
arclight_field_definitions.each do |field|
|
|
43
|
-
# we want to use `set_field` rather than `insert_field` since we may be overriding fields
|
|
44
|
-
Solrizer.set_field(solr_doc, field[:name], field[:value], field[:index_as])
|
|
45
|
-
end
|
|
46
|
-
|
|
47
|
-
add_date_ranges(solr_doc)
|
|
48
|
-
add_digital_content(prefix: 'ead/archdesc', solr_doc: solr_doc)
|
|
49
|
-
add_normalized_titles(solr_doc)
|
|
50
|
-
end
|
|
51
|
-
|
|
52
|
-
def add_normalized_titles(solr_doc)
|
|
53
|
-
title = add_normalized_title(solr_doc)
|
|
54
|
-
Solrizer.set_field(solr_doc, 'collection', title, :facetable)
|
|
55
|
-
Solrizer.set_field(solr_doc, 'collection', title, :displayable)
|
|
56
|
-
end
|
|
57
|
-
|
|
58
|
-
def arclight_field_definitions
|
|
59
|
-
[
|
|
60
|
-
{ name: 'level', value: 'collection', index_as: :displayable },
|
|
61
|
-
{ name: 'level', value: 'Collection', index_as: :facetable },
|
|
62
|
-
{ name: 'names', value: names, index_as: :symbol },
|
|
63
|
-
{ name: 'access_subjects', value: access_subjects, index_as: :symbol },
|
|
64
|
-
{ name: 'creators', value: creators, index_as: :symbol },
|
|
65
|
-
{ name: 'has_online_content', value: online_content?, index_as: :symbol },
|
|
66
|
-
{ name: 'repository', value: repository_as_configured(repository), index_as: :displayable },
|
|
67
|
-
{ name: 'repository', value: repository_as_configured(repository), index_as: :facetable },
|
|
68
|
-
{ name: 'names_coll', value: names_coll, index_as: :symbol }
|
|
69
|
-
]
|
|
70
|
-
end
|
|
71
|
-
|
|
72
|
-
def names
|
|
73
|
-
[corpname, famname, name, persname].flatten.compact.uniq - repository
|
|
74
|
-
end
|
|
75
|
-
|
|
76
|
-
def names_coll
|
|
77
|
-
names_array(%w[corpname famname name persname], parent: 'archdesc')
|
|
78
|
-
end
|
|
79
|
-
|
|
80
|
-
def creators
|
|
81
|
-
[creator_persname, creator_corpname, creator_famname].flatten.compact.uniq - repository
|
|
82
|
-
end
|
|
83
|
-
|
|
84
|
-
# Combine subjets into one group from
|
|
85
|
-
# <controlaccess/><subject></subject>
|
|
86
|
-
# <controlaccess/><function></function>
|
|
87
|
-
# <controlaccess/><genreform></genreform>
|
|
88
|
-
# <controlaccess/><occupation></occupation>
|
|
89
|
-
def access_subjects
|
|
90
|
-
subjects_array(%w[subject function occupation genreform], parent: 'archdesc')
|
|
91
|
-
end
|
|
92
|
-
end
|
|
93
|
-
end
|