blacklight-spotlight 3.3.0 → 3.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/spotlight/pages_controller.rb +1 -1
- data/app/controllers/spotlight/roles_controller.rb +1 -1
- data/app/helpers/spotlight/pages_helper.rb +12 -0
- data/app/helpers/spotlight/title_helper.rb +0 -2
- data/app/models/sir_trevor_rails/block.rb +85 -0
- data/app/models/sir_trevor_rails/blocks/displayable.rb +1 -1
- data/app/models/spotlight/page_content/sir_trevor.rb +13 -4
- data/app/models/translation.rb +18 -0
- data/app/views/shared/_site_sidebar.html.erb +1 -1
- data/app/views/spotlight/sir_trevor/blocks/_video_block.html.erb +5 -0
- data/config/i18n-tasks.yml +1 -0
- data/config/locales/spotlight.de.yml +40 -0
- data/lib/generators/spotlight/install_generator.rb +40 -2
- data/lib/generators/spotlight/templates/config/initializers/translation.rb +5 -5
- data/lib/generators/spotlight/templates/solr/config/schema.xml +32 -50
- data/lib/generators/spotlight/templates/solr/config/solrconfig.xml +14 -12
- data/lib/spotlight/engine.rb +1 -1
- data/lib/spotlight/version.rb +1 -1
- data/lib/tasks/spotlight_tasks.rake +20 -0
- metadata +100 -597
- data/lib/generators/spotlight/templates/config/initializers/sir_trevor_rails.rb +0 -10
- data/spec/controllers/application_controller_spec.rb +0 -30
- data/spec/controllers/spotlight/about_pages_controller_spec.rb +0 -241
- data/spec/controllers/spotlight/admin_users_controller_spec.rb +0 -53
- data/spec/controllers/spotlight/appearances_controller_spec.rb +0 -88
- data/spec/controllers/spotlight/application_controller_spec.rb +0 -11
- data/spec/controllers/spotlight/attachments_controller_spec.rb +0 -28
- data/spec/controllers/spotlight/browse_controller_spec.rb +0 -133
- data/spec/controllers/spotlight/bulk_actions_controller_spec.rb +0 -124
- data/spec/controllers/spotlight/bulk_updates_controller_spec.rb +0 -77
- data/spec/controllers/spotlight/catalog_controller_spec.rb +0 -552
- data/spec/controllers/spotlight/confirmations_controller_spec.rb +0 -38
- data/spec/controllers/spotlight/contact_email_controller_spec.rb +0 -65
- data/spec/controllers/spotlight/contact_forms_controller_spec.rb +0 -38
- data/spec/controllers/spotlight/contacts_controller_spec.rb +0 -103
- data/spec/controllers/spotlight/custom_fields_controller_spec.rb +0 -62
- data/spec/controllers/spotlight/custom_search_fields_controller_spec.rb +0 -62
- data/spec/controllers/spotlight/dashboards_controller_spec.rb +0 -68
- data/spec/controllers/spotlight/exhibits_controller_spec.rb +0 -216
- data/spec/controllers/spotlight/feature_pages_controller_spec.rb +0 -251
- data/spec/controllers/spotlight/featured_images_controller_spec.rb +0 -77
- data/spec/controllers/spotlight/filters_controller_spec.rb +0 -72
- data/spec/controllers/spotlight/groups_controller_spec.rb +0 -103
- data/spec/controllers/spotlight/home_pages_controller_spec.rb +0 -126
- data/spec/controllers/spotlight/job_trackers_controller_spec.rb +0 -37
- data/spec/controllers/spotlight/languages_controller_spec.rb +0 -70
- data/spec/controllers/spotlight/metadata_configurations_controller_spec.rb +0 -93
- data/spec/controllers/spotlight/pages_controller_spec.rb +0 -50
- data/spec/controllers/spotlight/resources/csv_upload_controller_spec.rb +0 -71
- data/spec/controllers/spotlight/resources/upload_controller_spec.rb +0 -55
- data/spec/controllers/spotlight/resources_controller_spec.rb +0 -85
- data/spec/controllers/spotlight/roles_controller_spec.rb +0 -141
- data/spec/controllers/spotlight/search_configurations_controller_spec.rb +0 -141
- data/spec/controllers/spotlight/searches_controller_spec.rb +0 -195
- data/spec/controllers/spotlight/sites_controller_spec.rb +0 -67
- data/spec/controllers/spotlight/solr_controller_spec.rb +0 -116
- data/spec/controllers/spotlight/tags_controller_spec.rb +0 -56
- data/spec/controllers/spotlight/translations_controller_spec.rb +0 -132
- data/spec/controllers/spotlight/versions_controller_spec.rb +0 -56
- data/spec/controllers/spotlight/view_configurations_controller_spec.rb +0 -35
- data/spec/examples.txt +0 -1515
- data/spec/features/about_page_spec.rb +0 -46
- data/spec/features/add_contacts_spec.rb +0 -63
- data/spec/features/add_custom_field_metadata_spec.rb +0 -88
- data/spec/features/add_iiif_manifest_spec.rb +0 -46
- data/spec/features/add_items_spec.rb +0 -135
- data/spec/features/autocomplete_typeahead_spec.rb +0 -88
- data/spec/features/browse_category_admin_spec.rb +0 -163
- data/spec/features/browse_category_navigation_spec.rb +0 -44
- data/spec/features/browse_category_spec.rb +0 -158
- data/spec/features/bulk_actions_spec.rb +0 -72
- data/spec/features/catalog_spec.rb +0 -57
- data/spec/features/confirm_email_spec.rb +0 -21
- data/spec/features/create_exhibit_spec.rb +0 -65
- data/spec/features/create_page_spec.rb +0 -21
- data/spec/features/dashboard_spec.rb +0 -34
- data/spec/features/edit_contact_spec.rb +0 -21
- data/spec/features/edit_search_fields_spec.rb +0 -79
- data/spec/features/exhibit_masthead_spec.rb +0 -112
- data/spec/features/exhibit_themes_spec.rb +0 -28
- data/spec/features/exhibits/add_tags_spec.rb +0 -35
- data/spec/features/exhibits/administration_spec.rb +0 -141
- data/spec/features/exhibits/custom_metadata_fields_spec.rb +0 -97
- data/spec/features/exhibits/custom_search_fields_spec.rb +0 -55
- data/spec/features/exhibits/edit_metadata_fields_spec.rb +0 -49
- data/spec/features/exhibits/language_create_edit_spec.rb +0 -59
- data/spec/features/exhibits/translation_editing_spec.rb +0 -463
- data/spec/features/exhibits_index_spec.rb +0 -55
- data/spec/features/feature_page_spec.rb +0 -155
- data/spec/features/home_page_spec.rb +0 -102
- data/spec/features/import_exhibit_spec.rb +0 -58
- data/spec/features/item_admin_spec.rb +0 -59
- data/spec/features/javascript/about_page_admin_spec.rb +0 -21
- data/spec/features/javascript/block_controls_spec.rb +0 -42
- data/spec/features/javascript/blocks/browse_group_categories_block_spec.rb +0 -64
- data/spec/features/javascript/blocks/featured_browse_categories_block_spec.rb +0 -46
- data/spec/features/javascript/blocks/featured_pages_block_spec.rb +0 -61
- data/spec/features/javascript/blocks/link_to_search_block_spec.rb +0 -46
- data/spec/features/javascript/blocks/rule_block_spec.rb +0 -23
- data/spec/features/javascript/blocks/search_result_block_spec.rb +0 -47
- data/spec/features/javascript/blocks/solr_documents_block_spec.rb +0 -232
- data/spec/features/javascript/blocks/solr_documents_carousel_block_spec.rb +0 -29
- data/spec/features/javascript/blocks/uploaded_items_block_spec.rb +0 -94
- data/spec/features/javascript/browse_group_admin_spec.rb +0 -45
- data/spec/features/javascript/edit_in_place_spec.rb +0 -93
- data/spec/features/javascript/feature_page_admin_spec.rb +0 -140
- data/spec/features/javascript/home_page_edit_spec.rb +0 -34
- data/spec/features/javascript/locale_selector_spec.rb +0 -66
- data/spec/features/javascript/metadata_admin_spec.rb +0 -41
- data/spec/features/javascript/multi_image_select_spec.rb +0 -50
- data/spec/features/javascript/reindex_monitor_spec.rb +0 -23
- data/spec/features/javascript/roles_admin_spec.rb +0 -38
- data/spec/features/javascript/search_config_admin_spec.rb +0 -140
- data/spec/features/javascript/search_context_spec.rb +0 -88
- data/spec/features/main_navigation_spec.rb +0 -96
- data/spec/features/metadata_admin_spec.rb +0 -18
- data/spec/features/report_a_problem_spec.rb +0 -62
- data/spec/features/site_masthead_spec.rb +0 -91
- data/spec/features/site_users_management_spec.rb +0 -74
- data/spec/features/slideshow_spec.rb +0 -21
- data/spec/features/translation_scope_spec.rb +0 -27
- data/spec/fixtures/800x600.png +0 -0
- data/spec/fixtures/avatar.png +0 -0
- data/spec/fixtures/bulk-update-template.csv +0 -57
- data/spec/fixtures/csv-upload-fixture.csv +0 -4
- data/spec/fixtures/gk446cj2442-manifest.json +0 -58
- data/spec/fixtures/iiif_responses.rb +0 -312
- data/spec/fixtures/json-upload-fixture.json +0 -3
- data/spec/fixtures/sample_solr_documents.yml +0 -9385
- data/spec/fixtures/updated-bulk-update-template-no-cols.csv +0 -4
- data/spec/fixtures/updated-bulk-update-template-w-tags.csv +0 -4
- data/spec/fixtures/updated-bulk-update-template.csv +0 -4
- data/spec/helpers/spotlight/application_helper_spec.rb +0 -196
- data/spec/helpers/spotlight/browse_helper_spec.rb +0 -13
- data/spec/helpers/spotlight/crop_helper_spec.rb +0 -11
- data/spec/helpers/spotlight/crud_link_helpers_spec.rb +0 -163
- data/spec/helpers/spotlight/languages_helper_spec.rb +0 -79
- data/spec/helpers/spotlight/main_app_helpers_spec.rb +0 -101
- data/spec/helpers/spotlight/masthead_helper_spec.rb +0 -51
- data/spec/helpers/spotlight/meta_helper_spec.rb +0 -33
- data/spec/helpers/spotlight/navbar_helper_spec.rb +0 -24
- data/spec/helpers/spotlight/pages_helper_spec.rb +0 -123
- data/spec/helpers/spotlight/roles_helper_spec.rb +0 -7
- data/spec/helpers/spotlight/search_configurations_helper_spec.rb +0 -23
- data/spec/helpers/spotlight/title_helper_spec.rb +0 -64
- data/spec/helpers/spotlight/translations_helper_spec.rb +0 -16
- data/spec/i18n_spec.rb +0 -28
- data/spec/jobs/spotlight/add_tags_job_spec.rb +0 -34
- data/spec/jobs/spotlight/add_uploads_from_csv_spec.rb +0 -58
- data/spec/jobs/spotlight/change_visibility_job_spec.rb +0 -30
- data/spec/jobs/spotlight/default_thumbnail_job_spec.rb +0 -14
- data/spec/jobs/spotlight/process_bulk_updates_csv_job_spec.rb +0 -86
- data/spec/jobs/spotlight/reindex_exhibit_job_spec.rb +0 -43
- data/spec/jobs/spotlight/reindex_job_spec.rb +0 -79
- data/spec/jobs/spotlight/remove_tags_job_spec.rb +0 -39
- data/spec/jobs/spotlight/rename_sidecar_field_job_spec.rb +0 -33
- data/spec/lib/migration/iiif_spec.rb +0 -91
- data/spec/lib/migration/page_language_spec.rb +0 -25
- data/spec/lib/spotlight/catalog_spec.rb +0 -0
- data/spec/lib/spotlight/controller_spec.rb +0 -102
- data/spec/lib/spotlight/upload_field_config_spec.rb +0 -40
- data/spec/mailers/spotlight/indexing_complete_mailer_spec.rb +0 -42
- data/spec/models/sir_trevor_rails/blocks/browse_block_spec.rb +0 -42
- data/spec/models/sir_trevor_rails/blocks/browse_group_categories_block_spec.rb +0 -41
- data/spec/models/sir_trevor_rails/blocks/featured_pages_block_spec.rb +0 -50
- data/spec/models/sir_trevor_rails/blocks/search_results_block_spec.rb +0 -23
- data/spec/models/sir_trevor_rails/blocks/solr_documents_block_spec.rb +0 -59
- data/spec/models/sir_trevor_rails/blocks/textable_spec.rb +0 -42
- data/spec/models/solr_document_spec.rb +0 -214
- data/spec/models/spotlight/ability_spec.rb +0 -118
- data/spec/models/spotlight/about_page_spec.rb +0 -19
- data/spec/models/spotlight/access_controls_enforcement_search_builder_spec.rb +0 -82
- data/spec/models/spotlight/analytics/ga_spec.rb +0 -22
- data/spec/models/spotlight/background_job_progress_spec.rb +0 -137
- data/spec/models/spotlight/blacklight_configuration_spec.rb +0 -649
- data/spec/models/spotlight/browse_category_search_builder_spec.rb +0 -49
- data/spec/models/spotlight/contact_email_spec.rb +0 -48
- data/spec/models/spotlight/contact_form_spec.rb +0 -94
- data/spec/models/spotlight/contact_image_spec.rb +0 -11
- data/spec/models/spotlight/contact_spec.rb +0 -38
- data/spec/models/spotlight/custom_field_spec.rb +0 -204
- data/spec/models/spotlight/custom_search_field_spec.rb +0 -56
- data/spec/models/spotlight/custom_translation_extension_spec.rb +0 -24
- data/spec/models/spotlight/exhibit_spec.rb +0 -383
- data/spec/models/spotlight/exhibit_thumbnail_spec.rb +0 -10
- data/spec/models/spotlight/feature_page_spec.rb +0 -87
- data/spec/models/spotlight/featured_image_spec.rb +0 -110
- data/spec/models/spotlight/field_metadata_spec.rb +0 -58
- data/spec/models/spotlight/filter_spec.rb +0 -19
- data/spec/models/spotlight/group_spec.rb +0 -19
- data/spec/models/spotlight/home_page_spec.rb +0 -38
- data/spec/models/spotlight/language_spec.rb +0 -42
- data/spec/models/spotlight/main_navigation_spec.rb +0 -19
- data/spec/models/spotlight/masthead_spec.rb +0 -45
- data/spec/models/spotlight/page_configurations_spec.rb +0 -45
- data/spec/models/spotlight/page_spec.rb +0 -303
- data/spec/models/spotlight/resource_spec.rb +0 -137
- data/spec/models/spotlight/resources/iiif_harvester_spec.rb +0 -52
- data/spec/models/spotlight/resources/iiif_manifest_spec.rb +0 -178
- data/spec/models/spotlight/resources/iiif_service_spec.rb +0 -57
- data/spec/models/spotlight/resources/upload_spec.rb +0 -71
- data/spec/models/spotlight/resources/web_spec.rb +0 -25
- data/spec/models/spotlight/role_spec.rb +0 -51
- data/spec/models/spotlight/search_spec.rb +0 -125
- data/spec/models/spotlight/site_spec.rb +0 -9
- data/spec/models/spotlight/sitemap_spec.rb +0 -113
- data/spec/models/spotlight/solr_document/atomic_updates_spec.rb +0 -56
- data/spec/models/spotlight/solr_document/uploaded_resource_spec.rb +0 -38
- data/spec/models/spotlight/solr_document_sidecar_spec.rb +0 -48
- data/spec/models/spotlight/user_spec.rb +0 -26
- data/spec/models/translation_spec.rb +0 -14
- data/spec/presenters/spotlight/iiif_manifest_presenter_spec.rb +0 -132
- data/spec/routing/spotlight/exhibit_catalog_spec.rb +0 -34
- data/spec/routing/spotlight/featured_images_spec.rb +0 -23
- data/spec/routing/spotlight/pages_routing_spec.rb +0 -42
- data/spec/services/spotlight/bulk_updates_csv_template_service_spec.rb +0 -26
- data/spec/services/spotlight/carrierwave_file_resolver_spec.rb +0 -16
- data/spec/services/spotlight/clone_translated_page_from_locale_spec.rb +0 -30
- data/spec/services/spotlight/etl/context_spec.rb +0 -66
- data/spec/services/spotlight/etl/executor_spec.rb +0 -149
- data/spec/services/spotlight/etl/pipeline_spec.rb +0 -22
- data/spec/services/spotlight/etl/solr_loader_spec.rb +0 -76
- data/spec/services/spotlight/etl/step_spec.rb +0 -70
- data/spec/services/spotlight/exhibit_import_export_service_spec.rb +0 -569
- data/spec/services/spotlight/iiif_resource_resolver_spec.rb +0 -94
- data/spec/services/spotlight/invite_users_service_spec.rb +0 -47
- data/spec/spec_helper.rb +0 -147
- data/spec/support/controllers/engine_helpers.rb +0 -9
- data/spec/support/disable_friendly_id_deprecation_warnings.rb +0 -11
- data/spec/support/features/capybara_default_max_wait_metadata_helper.rb +0 -20
- data/spec/support/features/test_features_helpers.rb +0 -92
- data/spec/support/helpers/controller_level_helpers.rb +0 -25
- data/spec/support/stub_iiif_response.rb +0 -26
- data/spec/support/views/test_view_helpers.rb +0 -20
- data/spec/test_app_templates/Gemfile.extra +0 -2
- data/spec/test_app_templates/carrierwave.rb +0 -8
- data/spec/test_app_templates/catalog_controller.rb +0 -108
- data/spec/test_app_templates/fixture.css +0 -0
- data/spec/test_app_templates/fixture.png +0 -0
- data/spec/test_app_templates/lib/generators/test_app_generator.rb +0 -69
- data/spec/test_app_templates/spotlight_test.rake +0 -14
- data/spec/uploaders/spotlight/attachment_uploader_spec.rb +0 -27
- data/spec/uploaders/spotlight/featured_image_uploader_spec.rb +0 -33
- data/spec/views/shared/_analytics.html.erb_spec.rb +0 -17
- data/spec/views/shared/_exhibit_navbar.html.erb_spec.rb +0 -127
- data/spec/views/shared/_header_navbar.html.erb_spec.rb +0 -12
- data/spec/views/shared/_masthead.html.erb_spec.rb +0 -91
- data/spec/views/shared/_user_util_links.html.erb_spec.rb +0 -102
- data/spec/views/spotlight/about_pages/_empty.html.erb_spec.rb +0 -28
- data/spec/views/spotlight/about_pages/_sidebar.html.erb_spec.rb +0 -24
- data/spec/views/spotlight/about_pages/index.html.erb_spec.rb +0 -69
- data/spec/views/spotlight/browse/_search.html.erb_spec.rb +0 -30
- data/spec/views/spotlight/browse/index.html.erb_spec.rb +0 -22
- data/spec/views/spotlight/browse/show.html.erb_spec.rb +0 -65
- data/spec/views/spotlight/catalog/_edit_default.html.erb_spec.rb +0 -63
- data/spec/views/spotlight/catalog/admin.html.erb_spec.rb +0 -39
- data/spec/views/spotlight/catalog/edit.html.erb_spec.rb +0 -20
- data/spec/views/spotlight/contacts/edit.html.erb_spec.rb +0 -43
- data/spec/views/spotlight/dashboards/_analytics.html.erb_spec.rb +0 -45
- data/spec/views/spotlight/dashboards/_reindexing_activity.html.erb_spec.rb +0 -94
- data/spec/views/spotlight/dashboards/analytics.html.erb_spec.rb +0 -33
- data/spec/views/spotlight/exhibits/_exhibit_card.html.erb_spec.rb +0 -46
- data/spec/views/spotlight/exhibits/_form.html.erb_spec.rb +0 -38
- data/spec/views/spotlight/exhibits/edit.html.erb_spec.rb +0 -29
- data/spec/views/spotlight/exhibits/index.html.erb_spec.rb +0 -140
- data/spec/views/spotlight/feature_pages/_empty.html.erb_spec.rb +0 -28
- data/spec/views/spotlight/feature_pages/_sidebar.html.erb_spec.rb +0 -45
- data/spec/views/spotlight/featured_images/_form.html.erb_spec.rb +0 -32
- data/spec/views/spotlight/featured_images/_upload_form.html.erb_spec.rb +0 -32
- data/spec/views/spotlight/home_pages/_empty.html.erb_spec.rb +0 -28
- data/spec/views/spotlight/home_pages/_sidebar.html.erb_spec.rb +0 -12
- data/spec/views/spotlight/job_trackers/show.html.erb_spec.rb +0 -65
- data/spec/views/spotlight/metadata_configurations/_metadata_field.html.erb_spec.rb +0 -30
- data/spec/views/spotlight/metadata_configurations/edit.html.erb_spec.rb +0 -23
- data/spec/views/spotlight/pages/_form.html.erb_spec.rb +0 -20
- data/spec/views/spotlight/pages/edit.html.erb_spec.rb +0 -68
- data/spec/views/spotlight/pages/index.html.erb_spec.rb +0 -42
- data/spec/views/spotlight/pages/new.html.erb_spec.rb +0 -21
- data/spec/views/spotlight/pages/show.html.erb_spec.rb +0 -84
- data/spec/views/spotlight/resources/_external_resources_form.html.erb_spec.rb +0 -36
- data/spec/views/spotlight/resources/new.html.erb_spec.rb +0 -30
- data/spec/views/spotlight/roles/index.html.erb_spec.rb +0 -30
- data/spec/views/spotlight/search_configurations/_facet_metadata.html.erb_spec.rb +0 -58
- data/spec/views/spotlight/search_configurations/_facets.html.erb_spec.rb +0 -54
- data/spec/views/spotlight/search_configurations/_search_fields.html.erb_spec.rb +0 -54
- data/spec/views/spotlight/search_configurations/_sort.html.erb_spec.rb +0 -40
- data/spec/views/spotlight/searches/_search.html.erb_spec.rb +0 -37
- data/spec/views/spotlight/searches/edit.html.erb_spec.rb +0 -40
- data/spec/views/spotlight/searches/index.html.erb_spec.rb +0 -33
- data/spec/views/spotlight/sir_trevor/blocks/_browse_block.html.erb_spec.rb +0 -20
- data/spec/views/spotlight/sir_trevor/blocks/_iframe_block.html.erb_spec.rb +0 -20
- data/spec/views/spotlight/sir_trevor/blocks/_link_to_search_block.html.erb_spec.rb +0 -20
- data/spec/views/spotlight/sir_trevor/blocks/_rule_block.html.erb_spec.rb +0 -10
- data/spec/views/spotlight/sir_trevor/blocks/_solr_documents_block.html.erb_spec.rb +0 -43
- data/spec/views/spotlight/sir_trevor/blocks/_solr_documents_carousel_block.html.erb_spec.rb +0 -34
- data/spec/views/spotlight/sir_trevor/blocks/_solr_documents_embed_block.html.erb_spec.rb +0 -53
- data/spec/views/spotlight/sir_trevor/blocks/_solr_documents_features_block.html.erb_spec.rb +0 -54
- data/spec/views/spotlight/sir_trevor/blocks/_solr_documents_grid_block.html.erb_spec.rb +0 -42
- data/spec/views/spotlight/sites/edit_exhibits.html.erb_spec.rb +0 -25
- data/spec/views/spotlight/tags/index.html.erb_spec.rb +0 -27
- data/spec/views/spotlight/translations/_import.html.erb_spec.rb +0 -24
- data/spec/views/spotlight/translations/_page.html.erb_spec.rb +0 -76
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 343306a2d21bc872b86730fa7dd740c3209dea1ed39780ac6e7b71796b2c609d
|
4
|
+
data.tar.gz: f2d93939dc404c1f43477d37f44069b1e17ce4a1334377ec9a12da9d92411e54
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fcc3ecd39516bf763110820df9c205634af02b12829f1d69d76492f205614087db70b2d5e3ebf969d51333e42020639eeb88cb330475070d76cf971d3da91ad6
|
7
|
+
data.tar.gz: 36d94f02d287b05c3473d543c46993ed33fc27c3daf9f57a5500d2ad4fe585237148154c149cf0c258597317377690c1eefdbcc5c2debfc0cfa045e92b86c836
|
@@ -7,7 +7,7 @@ module Spotlight
|
|
7
7
|
class RolesController < Spotlight::ApplicationController
|
8
8
|
before_action :authenticate_user!
|
9
9
|
load_and_authorize_resource :exhibit, class: Spotlight::Exhibit
|
10
|
-
load_and_authorize_resource through: :exhibit, except: [
|
10
|
+
load_and_authorize_resource through: :exhibit, except: %i[index update_all]
|
11
11
|
|
12
12
|
def index
|
13
13
|
role = @exhibit.roles.build
|
@@ -16,6 +16,18 @@ module Spotlight
|
|
16
16
|
end
|
17
17
|
end
|
18
18
|
|
19
|
+
def sir_trevor_format(text, format: :markdown)
|
20
|
+
if format.to_s.to_sym == :html
|
21
|
+
sir_trevor_html(text)
|
22
|
+
else
|
23
|
+
sir_trevor_markdown(text)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
def sir_trevor_html(text)
|
28
|
+
sanitize(text, tags: %w[b i a br p sup])
|
29
|
+
end
|
30
|
+
|
19
31
|
##
|
20
32
|
# Override the default #sir_trevor_markdown so we can use
|
21
33
|
# a more complete markdown rendered
|
@@ -27,10 +27,8 @@ module Spotlight
|
|
27
27
|
content_tag(:h1, html_content, class: 'page-header')
|
28
28
|
end
|
29
29
|
|
30
|
-
# rubocop:disable Naming/AccessorMethodName
|
31
30
|
def set_html_page_title(title = nil)
|
32
31
|
@page_title = strip_tags(t(:'spotlight.html_title', title: title || t(:'.title', default: :'.header'), application_name: application_name)).html_safe
|
33
32
|
end
|
34
|
-
# rubocop:enable Naming/AccessorMethodName
|
35
33
|
end
|
36
34
|
end
|
@@ -0,0 +1,85 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'ostruct'
|
4
|
+
|
5
|
+
module SirTrevorRails
|
6
|
+
# Forked from (former) upstream sir-trevor-rails 0.6.2 gem:
|
7
|
+
# https://github.com/madebymany/sir-trevor-rails/blob/931b9554f5268158b4da8817477cdc82e4e2e69c/lib/sir_trevor_rails/block.rb
|
8
|
+
# Copyright (c) 2013-2014 by ITV plc - http://www.itv.com
|
9
|
+
class Block < OpenStruct
|
10
|
+
DEFAULT_FORMAT = :markdown
|
11
|
+
|
12
|
+
def self.from_hash(hash, parent = nil)
|
13
|
+
hash = hash.deep_dup.with_indifferent_access
|
14
|
+
type_klass(hash).new(hash, parent)
|
15
|
+
end
|
16
|
+
|
17
|
+
def format
|
18
|
+
send(:[], :format).present? ? send(:[], :format).to_sym : DEFAULT_FORMAT
|
19
|
+
end
|
20
|
+
|
21
|
+
# Sets a list of custom block types to speed up lookup at runtime.
|
22
|
+
def self.custom_block_types
|
23
|
+
# You can define your custom block types directly here or in your engine config.
|
24
|
+
Spotlight::Engine.config.sir_trevor_widgets
|
25
|
+
end
|
26
|
+
|
27
|
+
def initialize(hash, parent)
|
28
|
+
@raw_data = hash
|
29
|
+
@parent = parent
|
30
|
+
@type = hash[:type].to_sym
|
31
|
+
super(hash[:data])
|
32
|
+
end
|
33
|
+
|
34
|
+
attr_reader :parent, :type
|
35
|
+
|
36
|
+
def to_partial_path
|
37
|
+
"sir_trevor/blocks/#{self.class.name.demodulize.underscore}"
|
38
|
+
end
|
39
|
+
|
40
|
+
def as_json(*_attrs)
|
41
|
+
{
|
42
|
+
type: @type.to_s,
|
43
|
+
data: marshal_dump
|
44
|
+
}
|
45
|
+
end
|
46
|
+
|
47
|
+
# Infers the block class.
|
48
|
+
# Safe lookup that tries to identify user created block class.
|
49
|
+
#
|
50
|
+
# @param [Symbol] type
|
51
|
+
def self.block_class(type)
|
52
|
+
type_name = type.to_s.camelize
|
53
|
+
block_name = "#{type_name}Block"
|
54
|
+
if custom_block_types.include?(type_name)
|
55
|
+
begin
|
56
|
+
block_name.constantize
|
57
|
+
rescue NameError
|
58
|
+
block_class!(block_name)
|
59
|
+
end
|
60
|
+
else
|
61
|
+
block_class!(block_name)
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
65
|
+
# Infers the block class.
|
66
|
+
# Failover from block_class.
|
67
|
+
# Safe lookup against the SirTevor::Blocks namespace
|
68
|
+
# If no block is found, create one with given name and inherit from Block class
|
69
|
+
#
|
70
|
+
# @param [Constant] block_name
|
71
|
+
def self.block_class!(block_name)
|
72
|
+
SirTrevorRails::Blocks.const_get(block_name)
|
73
|
+
rescue NameError
|
74
|
+
SirTrevorRails::Blocks.const_set(block_name, Class.new(Block))
|
75
|
+
end
|
76
|
+
|
77
|
+
def self.type_klass(hash)
|
78
|
+
if self == Block
|
79
|
+
block_class(hash[:type].to_sym)
|
80
|
+
else
|
81
|
+
self
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end
|
85
|
+
end
|
@@ -5,12 +5,21 @@ module Spotlight
|
|
5
5
|
# Sir-Trevor created content
|
6
6
|
class SirTrevor
|
7
7
|
def self.parse(page, attribute)
|
8
|
-
|
9
|
-
|
8
|
+
blocks = page.read_attribute(attribute)
|
9
|
+
blocks ||= [].to_json
|
10
10
|
|
11
|
-
return
|
11
|
+
return [] if blocks.blank?
|
12
12
|
|
13
|
-
|
13
|
+
blocks = JSON.parse(blocks, symbolize_names: true) if blocks.is_a?(String)
|
14
|
+
|
15
|
+
if blocks.is_a?(Hash)
|
16
|
+
blocks = blocks[:data] || blocks['data'] or
|
17
|
+
raise IndexError, 'No block data found'
|
18
|
+
end
|
19
|
+
|
20
|
+
blocks.map do |obj|
|
21
|
+
SirTrevorRails::Block.from_hash(obj, page)
|
22
|
+
end
|
14
23
|
end
|
15
24
|
end
|
16
25
|
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
unless defined?(Translation)
|
4
|
+
Translation = I18n::Backend::ActiveRecord::Translation
|
5
|
+
Translation.include Spotlight::CustomTranslationExtension
|
6
|
+
|
7
|
+
# Work-around for https://github.com/svenfuchs/i18n-active_record/pull/133
|
8
|
+
if Translation.respond_to?(:to_hash)
|
9
|
+
class << Translation
|
10
|
+
alias to_h to_hash
|
11
|
+
remove_method :to_hash
|
12
|
+
end
|
13
|
+
|
14
|
+
I18n::Backend::ActiveRecord.define_method(:init_translations) do
|
15
|
+
@translations = Translation.to_h
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -7,7 +7,7 @@
|
|
7
7
|
<li class="nav-item"><%= link_to t(:'spotlight.sites.edit.page_title'), spotlight.edit_site_path, class: 'nav-link' %></li>
|
8
8
|
<% end %>
|
9
9
|
|
10
|
-
<% if can? :
|
10
|
+
<% if can? :manage, Spotlight::Exhibit %>
|
11
11
|
<li class="nav-item"><%= link_to t(:'spotlight.sites.edit_exhibits.page_title'), spotlight.edit_site_exhibits_path, class: 'nav-link' %></li>
|
12
12
|
<li class="nav-item"><%= link_to t(:'spotlight.admin_users.index.page_title'), spotlight.admin_users_path, class: 'nav-link' %></li>
|
13
13
|
<% end %>
|
data/config/i18n-tasks.yml
CHANGED
@@ -65,6 +65,7 @@ ignore_unused:
|
|
65
65
|
- helpers.action.{edit,edit_long,new,view} # app/helpers/spotlight/crud_link_helpers.rb
|
66
66
|
- helpers.action.spotlight/search.edit_long # app/views/spotlight/searches/_search.html.erb
|
67
67
|
- spotlight.about_pages.page_options.published # app/views/spotlight/about_pages/_page_options.html.erb
|
68
|
+
- spotlight.job_trackers.show.messages.status.{completed,enqueued,failed,missing,pending} # app/views/spotlight/job_trackers/show.html.erb
|
68
69
|
- helpers.submit.contact_form.create # app/views/spotlight/shared/_report_a_problem.html.erb
|
69
70
|
- activerecord.help.spotlight/exhibit.tag_list # app/views/spotlight/exhibits/_form.html.erb
|
70
71
|
- helpers.label.solr_document.exhibit_tag_list # app/views/spotlight/catalog/_edit_default.html.erb
|
@@ -0,0 +1,40 @@
|
|
1
|
+
de:
|
2
|
+
activemodel:
|
3
|
+
attributes:
|
4
|
+
spotlight/contact_form:
|
5
|
+
email: E-Mail Adresse
|
6
|
+
message: Nachricht
|
7
|
+
name: Name
|
8
|
+
helpers:
|
9
|
+
action:
|
10
|
+
cancel: Abbrechen
|
11
|
+
submit:
|
12
|
+
contact_form:
|
13
|
+
create: Senden
|
14
|
+
created: Vielen Dank. Ihre Feedback wurde gesendet.
|
15
|
+
spotlight:
|
16
|
+
about_pages:
|
17
|
+
contacts:
|
18
|
+
header: Kontakt
|
19
|
+
header_links:
|
20
|
+
contact: Feedback
|
21
|
+
shared:
|
22
|
+
report_a_problem:
|
23
|
+
honeypot_field_explanation: Bitte ignorieren Sie dieses Textfeld. Es wird verwendet, um Spam zu erkennen. Wenn Sie etwas hier eingeben, wird Ihre Nachricht nicht gesendet.
|
24
|
+
title: Kontakten Sie Uns
|
25
|
+
browse:
|
26
|
+
search:
|
27
|
+
item_count:
|
28
|
+
one: "%{count} Suchergebnisse"
|
29
|
+
other: "%{count} Suchergebnisse"
|
30
|
+
search_box:
|
31
|
+
label: Innerhalb dieser Kategorie suchen
|
32
|
+
placeholder: Suchen…
|
33
|
+
reset: Zurücksetzen
|
34
|
+
submit: Innerhalb dieser Kategorie suchen
|
35
|
+
success:
|
36
|
+
expand_html: Suche erweitern <a href="%{expand_search_url}">"%{browse_query}"</a>.
|
37
|
+
result_number_html: <strong> %{search_size} Suchergebnisse von %{parent_search_count} Gesamteinheiten in dieser Suchkategorie gefunden</strong>.
|
38
|
+
zero_results:
|
39
|
+
expand_html: <a href="%{clear_search_url}">Suche zurücksetzen</a> oder <a href="%{expand_search_url}"> erweitern "%{browse_query}"</a>.
|
40
|
+
result_number: Es können keine Suchergebnisse gefunden werden.
|
@@ -11,7 +11,7 @@ module Spotlight
|
|
11
11
|
class_option :mailer_default_url_host, type: :string, default: '' # e.g. localhost:3000
|
12
12
|
|
13
13
|
# we're not (yet) using webpacker, so we need to re-add sprockets functionality
|
14
|
-
def
|
14
|
+
def add_js_rails6
|
15
15
|
return unless Rails.version.to_i == 6
|
16
16
|
|
17
17
|
gem 'coffee-rails', '~> 4.2'
|
@@ -29,6 +29,12 @@ module Spotlight
|
|
29
29
|
run 'bundle exec rails webpacker:install'
|
30
30
|
end
|
31
31
|
|
32
|
+
def add_js_rails7
|
33
|
+
return unless Rails.version.to_i == 7
|
34
|
+
|
35
|
+
append_to_file 'app/assets/javascripts/application.js', "\n//= require_tree .\n"
|
36
|
+
end
|
37
|
+
|
32
38
|
def inject_spotlight_routes
|
33
39
|
route "mount Spotlight::Engine, at: 'spotlight'"
|
34
40
|
gsub_file 'config/routes.rb', /^\s*root.*/ do |match|
|
@@ -44,6 +50,8 @@ module Spotlight
|
|
44
50
|
end
|
45
51
|
|
46
52
|
def riiif
|
53
|
+
gem 'riiif'
|
54
|
+
Bundler.with_clean_env { run 'bundle install' }
|
47
55
|
route "mount Riiif::Engine => '/images', as: 'riiif'"
|
48
56
|
copy_file 'config/initializers/riiif.rb'
|
49
57
|
end
|
@@ -124,7 +132,7 @@ module Spotlight
|
|
124
132
|
end
|
125
133
|
|
126
134
|
def add_osd_viewer
|
127
|
-
gem 'blacklight-gallery', '~>
|
135
|
+
gem 'blacklight-gallery', '~> 4.0'
|
128
136
|
bundle_install
|
129
137
|
generate 'blacklight_gallery:install'
|
130
138
|
end
|
@@ -169,6 +177,36 @@ module Spotlight
|
|
169
177
|
copy_file 'config/initializers/translation.rb'
|
170
178
|
end
|
171
179
|
|
180
|
+
def configure_queue
|
181
|
+
insert_into_file 'config/application.rb', after: "< Rails::Application\n" do
|
182
|
+
<<-EOF
|
183
|
+
config.active_job.queue_adapter = ENV["RAILS_QUEUE"]&.to_sym || :sidekiq
|
184
|
+
EOF
|
185
|
+
end
|
186
|
+
end
|
187
|
+
|
188
|
+
def configure_logging
|
189
|
+
insert_into_file 'config/application.rb', after: "< Rails::Application\n" do
|
190
|
+
<<-EOF
|
191
|
+
# Logging
|
192
|
+
if ENV["RAILS_LOG_TO_STDOUT"].present?
|
193
|
+
config.log_level = :debug
|
194
|
+
config.log_formatter = ::Logger::Formatter.new
|
195
|
+
# log to stdout
|
196
|
+
logger = ActiveSupport::Logger.new(STDOUT)
|
197
|
+
logger.formatter = config.log_formatter
|
198
|
+
config.logger = ActiveSupport::TaggedLogging.new(logger)
|
199
|
+
# Print deprecation notices to the Rails logger.
|
200
|
+
config.active_support.deprecation = :log
|
201
|
+
# Raise an error on page load if there are pending migrations.
|
202
|
+
config.active_record.migration_error = :page_load
|
203
|
+
# Highlight code that triggered database queries in logs.
|
204
|
+
config.active_record.verbose_query_logs = true
|
205
|
+
end
|
206
|
+
EOF
|
207
|
+
end
|
208
|
+
end
|
209
|
+
|
172
210
|
private
|
173
211
|
|
174
212
|
def bundle_install
|
@@ -3,17 +3,17 @@
|
|
3
3
|
require 'i18n/backend/active_record'
|
4
4
|
require 'i18n/backend/fallbacks'
|
5
5
|
|
6
|
-
Translation = I18n::Backend::ActiveRecord::Translation
|
7
|
-
|
8
6
|
ActiveSupport::Reloader.to_prepare do
|
9
|
-
if
|
7
|
+
# Don't allow initializer to break if DB doesn't exist yet
|
8
|
+
# see: https://github.com/projectblacklight/spotlight/issues/2133
|
9
|
+
if ENV['SKIP_TRANSLATION'].blank?
|
10
|
+
raise unless Translation.table_exists?
|
11
|
+
|
10
12
|
##
|
11
13
|
# Sets up the new Spotlight Translation backend, backed by ActiveRecord. To
|
12
14
|
# turn on the ActiveRecord backend, uncomment the following lines.
|
13
|
-
|
14
15
|
I18n.backend = I18n::Backend::ActiveRecord.new
|
15
16
|
I18n::Backend::ActiveRecord.include I18n::Backend::Memoize
|
16
|
-
Translation.include Spotlight::CustomTranslationExtension
|
17
17
|
I18n::Backend::Simple.include I18n::Backend::Memoize
|
18
18
|
I18n::Backend::Simple.include I18n::Backend::Pluralization
|
19
19
|
I18n::Backend::Simple.include I18n::Backend::Fallbacks
|
@@ -3,14 +3,14 @@
|
|
3
3
|
<!-- NOTE: various comments and unused configuration possibilities have been purged
|
4
4
|
from this file. Please refer to http://wiki.apache.org/solr/SchemaXml,
|
5
5
|
as well as the default schema file included with Solr -->
|
6
|
-
|
6
|
+
|
7
7
|
<uniqueKey>id</uniqueKey>
|
8
|
-
|
8
|
+
|
9
9
|
<fields>
|
10
10
|
<field name="id" type="string" stored="true" indexed="true" multiValued="false" required="true"/>
|
11
11
|
<field name="_version_" type="long" indexed="true" stored="true"/>
|
12
12
|
<field name="timestamp" type="date" indexed="true" stored="true" default="NOW" multiValued="false"/>
|
13
|
-
|
13
|
+
|
14
14
|
<field name="lat" type="tdouble" stored="true" indexed="true" multiValued="false"/>
|
15
15
|
<field name="lng" type="tdouble" stored="true" indexed="true" multiValued="false"/>
|
16
16
|
<field name="original_pid_tesim" type="pid_text" stored="true" indexed="true" multiValued="true"/>
|
@@ -36,7 +36,7 @@
|
|
36
36
|
-->
|
37
37
|
<dynamicField name="*_tsiv" type="text" stored="true" indexed="true" multiValued="false" termVectors="true" termPositions="true" termOffsets="true"/>
|
38
38
|
<dynamicField name="*_tsimv" type="text" stored="true" indexed="true" multiValued="true" termVectors="true" termPositions="true" termOffsets="true"/>
|
39
|
-
|
39
|
+
|
40
40
|
<!-- English text (_te...) -->
|
41
41
|
<!--
|
42
42
|
<dynamicField name="*_tei" type="text_en" stored="false" indexed="true" multiValued="false"/>
|
@@ -52,7 +52,7 @@
|
|
52
52
|
-->
|
53
53
|
<dynamicField name="*_tesiv" type="text_en" stored="true" indexed="true" multiValued="false" termVectors="true" termPositions="true" termOffsets="true"/>
|
54
54
|
<dynamicField name="*_tesimv" type="text_en" stored="true" indexed="true" multiValued="true" termVectors="true" termPositions="true" termOffsets="true"/>
|
55
|
-
|
55
|
+
|
56
56
|
<!-- string (_s...) -->
|
57
57
|
<!--
|
58
58
|
<dynamicField name="*_si" type="string" stored="false" indexed="true" multiValued="false"/>
|
@@ -65,7 +65,7 @@
|
|
65
65
|
<!--
|
66
66
|
<dynamicField name="*_ssort" type="alphaSort" stored="false" indexed="true" multiValued="false"/>
|
67
67
|
-->
|
68
|
-
|
68
|
+
|
69
69
|
<!-- integer (_i...) -->
|
70
70
|
<!--
|
71
71
|
<dynamicField name="*_ii" type="int" stored="false" indexed="true" multiValued="false"/>
|
@@ -75,7 +75,7 @@
|
|
75
75
|
<dynamicField name="*_ism" type="int" stored="true" indexed="false" multiValued="true"/>
|
76
76
|
<dynamicField name="*_isi" type="int" stored="true" indexed="true" multiValued="false"/>
|
77
77
|
<dynamicField name="*_isim" type="int" stored="true" indexed="true" multiValued="true"/>
|
78
|
-
|
78
|
+
|
79
79
|
<!-- trie integer (_it...) (for faster range queries) -->
|
80
80
|
<!--
|
81
81
|
<dynamicField name="*_iti" type="tint" stored="false" indexed="true" multiValued="false"/>
|
@@ -85,7 +85,7 @@
|
|
85
85
|
<dynamicField name="*_itsm" type="tint" stored="true" indexed="false" multiValued="true"/>
|
86
86
|
<dynamicField name="*_itsi" type="tint" stored="true" indexed="true" multiValued="false"/>
|
87
87
|
<dynamicField name="*_itsim" type="tint" stored="true" indexed="true" multiValued="true"/>
|
88
|
-
|
88
|
+
|
89
89
|
<!-- date (_dt...) -->
|
90
90
|
<!-- The format for this date field is of the form 1995-12-31T23:59:59Z
|
91
91
|
Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z -->
|
@@ -97,7 +97,7 @@
|
|
97
97
|
<dynamicField name="*_dtsm" type="date" stored="true" indexed="false" multiValued="true"/>
|
98
98
|
<dynamicField name="*_dtsi" type="date" stored="true" indexed="true" multiValued="false"/>
|
99
99
|
<dynamicField name="*_dtsim" type="date" stored="true" indexed="true" multiValued="true"/>
|
100
|
-
|
100
|
+
|
101
101
|
<!-- trie date (_dtt...) (for faster range queries) -->
|
102
102
|
<!--
|
103
103
|
<dynamicField name="*_dtti" type="tdate" stored="false" indexed="true" multiValued="false"/>
|
@@ -107,7 +107,7 @@
|
|
107
107
|
<dynamicField name="*_dttsm" type="tdate" stored="true" indexed="false" multiValued="true"/>
|
108
108
|
<dynamicField name="*_dttsi" type="tdate" stored="true" indexed="true" multiValued="false"/>
|
109
109
|
<dynamicField name="*_dttsim" type="tdate" stored="true" indexed="true" multiValued="true"/>
|
110
|
-
|
110
|
+
|
111
111
|
<!-- long (_l...) -->
|
112
112
|
<!--
|
113
113
|
<dynamicField name="*_li" type="long" stored="false" indexed="true" multiValued="false"/>
|
@@ -117,7 +117,7 @@
|
|
117
117
|
<dynamicField name="*_lsm" type="long" stored="true" indexed="false" multiValued="true"/>
|
118
118
|
<dynamicField name="*_lsi" type="long" stored="true" indexed="true" multiValued="false"/>
|
119
119
|
<dynamicField name="*_lsim" type="long" stored="true" indexed="true" multiValued="true"/>
|
120
|
-
|
120
|
+
|
121
121
|
<!-- trie long (_lt...) (for faster range queries) -->
|
122
122
|
<!--
|
123
123
|
<dynamicField name="*_lti" type="tlong" stored="false" indexed="true" multiValued="false"/>
|
@@ -127,7 +127,7 @@
|
|
127
127
|
<dynamicField name="*_ltsm" type="tlong" stored="true" indexed="false" multiValued="true"/>
|
128
128
|
<dynamicField name="*_ltsi" type="tlong" stored="true" indexed="true" multiValued="false"/>
|
129
129
|
<dynamicField name="*_ltsim" type="tlong" stored="true" indexed="true" multiValued="true"/>
|
130
|
-
|
130
|
+
|
131
131
|
<!-- double (_db...) -->
|
132
132
|
<!--
|
133
133
|
<dynamicField name="*_dbi" type="double" stored="false" indexed="true" multiValued="false"/>
|
@@ -137,7 +137,7 @@
|
|
137
137
|
<dynamicField name="*_dbsm" type="double" stored="true" indexed="false" multiValued="true"/>
|
138
138
|
<dynamicField name="*_dbsi" type="double" stored="true" indexed="true" multiValued="false"/>
|
139
139
|
<dynamicField name="*_dbsim" type="double" stored="true" indexed="true" multiValued="true"/>
|
140
|
-
|
140
|
+
|
141
141
|
<!-- trie double (_dbt...) (for faster range queries) -->
|
142
142
|
<!--
|
143
143
|
<dynamicField name="*_dbti" type="tdouble" stored="false" indexed="true" multiValued="false"/>
|
@@ -147,7 +147,7 @@
|
|
147
147
|
<dynamicField name="*_dbtsm" type="tdouble" stored="true" indexed="false" multiValued="true"/>
|
148
148
|
<dynamicField name="*_dbtsi" type="tdouble" stored="true" indexed="true" multiValued="false"/>
|
149
149
|
<dynamicField name="*_dbtsim" type="tdouble" stored="true" indexed="true" multiValued="true"/>
|
150
|
-
|
150
|
+
|
151
151
|
<!-- float (_f...) -->
|
152
152
|
<!--
|
153
153
|
<dynamicField name="*_fi" type="float" stored="false" indexed="true" multiValued="false"/>
|
@@ -157,7 +157,7 @@
|
|
157
157
|
<dynamicField name="*_fsm" type="float" stored="true" indexed="false" multiValued="true"/>
|
158
158
|
<dynamicField name="*_fsi" type="float" stored="true" indexed="true" multiValued="false"/>
|
159
159
|
<dynamicField name="*_fsim" type="float" stored="true" indexed="true" multiValued="true"/>
|
160
|
-
|
160
|
+
|
161
161
|
<!-- trie float (_ft...) (for faster range queries) -->
|
162
162
|
<!--
|
163
163
|
<dynamicField name="*_fti" type="tfloat" stored="false" indexed="true" multiValued="false"/>
|
@@ -167,28 +167,13 @@
|
|
167
167
|
<dynamicField name="*_ftsm" type="tfloat" stored="true" indexed="false" multiValued="true"/>
|
168
168
|
<dynamicField name="*_ftsi" type="tfloat" stored="true" indexed="true" multiValued="false"/>
|
169
169
|
<dynamicField name="*_ftsim" type="tfloat" stored="true" indexed="true" multiValued="true"/>
|
170
|
-
|
170
|
+
|
171
171
|
<!-- boolean (_b...) -->
|
172
172
|
<!--
|
173
173
|
<dynamicField name="*_bi" type="boolean" stored="false" indexed="true" multiValued="false"/>
|
174
174
|
-->
|
175
175
|
<dynamicField name="*_bs" type="boolean" stored="true" indexed="false" multiValued="false"/>
|
176
176
|
<dynamicField name="*_bsi" type="boolean" stored="true" indexed="true" multiValued="false"/>
|
177
|
-
|
178
|
-
<!-- Type used to index the lat and lon components for the "location" FieldType -->
|
179
|
-
<!--
|
180
|
-
<dynamicField name="*_coordinate" type="tdouble" indexed="true" stored="false" />
|
181
|
-
-->
|
182
|
-
|
183
|
-
<!-- location (_ll...) -->
|
184
|
-
<!--
|
185
|
-
<dynamicField name="*_lli" type="location" stored="false" indexed="true" multiValued="false"/>
|
186
|
-
<dynamicField name="*_llim" type="location" stored="false" indexed="true" multiValued="true"/>
|
187
|
-
-->
|
188
|
-
<dynamicField name="*_lls" type="location" stored="true" indexed="false" multiValued="false"/>
|
189
|
-
<dynamicField name="*_llsm" type="location" stored="true" indexed="false" multiValued="true"/>
|
190
|
-
<dynamicField name="*_llsi" type="location" stored="true" indexed="true" multiValued="false"/>
|
191
|
-
<dynamicField name="*_llsim" type="location" stored="true" indexed="true" multiValued="true"/>
|
192
177
|
|
193
178
|
<!-- you must define copyField source and dest fields explicity or schemaBrowser doesn't work -->
|
194
179
|
<field name="all_text_timv" type="text" stored="false" indexed="true" multiValued="true" termVectors="true" termPositions="true" termOffsets="true"/>
|
@@ -208,32 +193,32 @@
|
|
208
193
|
|
209
194
|
<types>
|
210
195
|
<fieldType name="string" class="solr.StrField" sortMissingLast="true" />
|
211
|
-
<fieldType name="boolean" class="solr.BoolField" sortMissingLast="true"/>
|
196
|
+
<fieldType name="boolean" class="solr.BoolField" sortMissingLast="true"/>
|
212
197
|
<fieldType name="rand" class="solr.RandomSortField" omitNorms="true"/>
|
213
|
-
|
198
|
+
|
214
199
|
<!-- Default numeric field types. -->
|
215
200
|
<fieldType name="int" class="solr.TrieIntField" precisionStep="0" positionIncrementGap="0"/>
|
216
201
|
<fieldType name="float" class="solr.TrieFloatField" precisionStep="0" positionIncrementGap="0"/>
|
217
202
|
<fieldType name="long" class="solr.TrieLongField" precisionStep="0" positionIncrementGap="0"/>
|
218
203
|
<fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" positionIncrementGap="0"/>
|
219
|
-
|
204
|
+
|
220
205
|
<!-- trie numeric field types for faster range queries -->
|
221
206
|
<fieldType name="tint" class="solr.TrieIntField" precisionStep="8" positionIncrementGap="0"/>
|
222
207
|
<fieldType name="tfloat" class="solr.TrieFloatField" precisionStep="8" positionIncrementGap="0"/>
|
223
208
|
<fieldType name="tlong" class="solr.TrieLongField" precisionStep="8" positionIncrementGap="0"/>
|
224
209
|
<fieldType name="tdouble" class="solr.TrieDoubleField" precisionStep="8" positionIncrementGap="0"/>
|
225
|
-
|
210
|
+
|
226
211
|
<!-- The format for this date field is of the form 1995-12-31T23:59:59Z
|
227
212
|
Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z
|
228
213
|
-->
|
229
214
|
<fieldType name="date" class="solr.TrieDateField" precisionStep="0" positionIncrementGap="0"/>
|
230
215
|
<!-- A Trie based date field for faster date range queries and date faceting. -->
|
231
216
|
<fieldType name="tdate" class="solr.TrieDateField" precisionStep="6" positionIncrementGap="0"/>
|
232
|
-
|
233
|
-
|
217
|
+
|
218
|
+
|
234
219
|
<!-- This point type indexes the coordinates as separate fields (subFields)
|
235
220
|
If subFieldType is defined, it references a type, and a dynamic field
|
236
|
-
definition is created matching *___<typename>. Alternately, if
|
221
|
+
definition is created matching *___<typename>. Alternately, if
|
237
222
|
subFieldSuffix is defined, that is used to create the subFields.
|
238
223
|
Example: if subFieldType="double", then the coordinates would be
|
239
224
|
indexed in fields myloc_0___double,myloc_1___double.
|
@@ -243,17 +228,14 @@
|
|
243
228
|
users normally should not need to know about them.
|
244
229
|
-->
|
245
230
|
<fieldType name="point" class="solr.PointType" dimension="2" subFieldSuffix="_d"/>
|
246
|
-
|
247
|
-
<!-- A specialized field for geospatial search. If indexed, this fieldType must not be multivalued. -->
|
248
|
-
<fieldType name="location" class="solr.LatLonType" subFieldSuffix="_coordinate"/>
|
249
|
-
|
231
|
+
|
250
232
|
<!-- An alternative geospatial field type new to Solr 4. It supports multiValued and polygon shapes.
|
251
233
|
For more information about this and other Spatial fields new to Solr 4, see:
|
252
234
|
http://wiki.apache.org/solr/SolrAdaptersForLuceneSpatial4
|
253
235
|
-->
|
254
236
|
<fieldType name="location_rpt" class="solr.SpatialRecursivePrefixTreeFieldType"
|
255
237
|
geo="true" distErrPct="0.025" maxDistErr="0.000009" distanceUnits="degrees" />
|
256
|
-
|
238
|
+
|
257
239
|
<fieldType name="text" class="solr.TextField" omitNorms="false">
|
258
240
|
<analyzer>
|
259
241
|
<tokenizer class="solr.ICUTokenizerFactory"/>
|
@@ -261,7 +243,7 @@
|
|
261
243
|
<filter class="solr.TrimFilterFactory"/>
|
262
244
|
</analyzer>
|
263
245
|
</fieldType>
|
264
|
-
|
246
|
+
|
265
247
|
<!-- A text field that only splits on whitespace for exact matching of words -->
|
266
248
|
<fieldType name="text_ws" class="solr.TextField" positionIncrementGap="100">
|
267
249
|
<analyzer>
|
@@ -269,7 +251,7 @@
|
|
269
251
|
<filter class="solr.TrimFilterFactory"/>
|
270
252
|
</analyzer>
|
271
253
|
</fieldType>
|
272
|
-
|
254
|
+
|
273
255
|
<!-- single token analyzed text, for sorting. Punctuation is significant. -->
|
274
256
|
<fieldtype name="alphaSort" class="solr.TextField" sortMissingLast="true" omitNorms="true">
|
275
257
|
<analyzer>
|
@@ -278,7 +260,7 @@
|
|
278
260
|
<filter class="solr.TrimFilterFactory" />
|
279
261
|
</analyzer>
|
280
262
|
</fieldtype>
|
281
|
-
|
263
|
+
|
282
264
|
<!-- A text field with defaults appropriate for English -->
|
283
265
|
<fieldType name="text_en" class="solr.TextField" positionIncrementGap="100">
|
284
266
|
<analyzer>
|
@@ -321,7 +303,7 @@
|
|
321
303
|
<tokenizer class="solr.KeywordTokenizerFactory"/>
|
322
304
|
</analyzer>
|
323
305
|
</fieldType>
|
324
|
-
|
306
|
+
|
325
307
|
<!-- queries for paths match documents at that path, or in descendent paths -->
|
326
308
|
<fieldType name="descendent_path" class="solr.TextField">
|
327
309
|
<analyzer type="index">
|
@@ -331,7 +313,7 @@
|
|
331
313
|
<tokenizer class="solr.KeywordTokenizerFactory" />
|
332
314
|
</analyzer>
|
333
315
|
</fieldType>
|
334
|
-
|
316
|
+
|
335
317
|
<!-- queries for paths match documents at that path, or in ancestor paths -->
|
336
318
|
<fieldType name="ancestor_path" class="solr.TextField">
|
337
319
|
<analyzer type="index">
|
@@ -341,7 +323,7 @@
|
|
341
323
|
<tokenizer class="solr.PathHierarchyTokenizerFactory" delimiter="/" />
|
342
324
|
</analyzer>
|
343
325
|
</fieldType>
|
344
|
-
|
326
|
+
|
345
327
|
</types>
|
346
|
-
|
328
|
+
|
347
329
|
</schema>
|