blacklight-spotlight 0.19.1 → 0.19.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/spotlight/_bootstrap_overrides.scss +0 -12
- data/app/models/concerns/spotlight/resources/open_graph.rb +0 -4
- data/app/models/spotlight/resource.rb +11 -62
- data/app/models/spotlight/resources/upload.rb +8 -46
- data/app/services/spotlight/solr_document_builder.rb +67 -0
- data/app/services/spotlight/upload_solr_document_builder.rb +48 -0
- data/app/views/layouts/spotlight/spotlight.html.erb +1 -0
- data/lib/spotlight/version.rb +1 -1
- data/spec/models/spotlight/resource_spec.rb +1 -16
- data/spec/models/spotlight/resources/open_graph_spec.rb +8 -3
- data/spec/models/spotlight/resources/upload_spec.rb +27 -23
- data/spec/services/spotlight/solr_document_builder_spec.rb +22 -0
- metadata +186 -183
- data/app/views/catalog/_search_form.html.erb +0 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 38fb99b5c2366b2cf6ac5a264e215ed7b0611c43
|
4
|
+
data.tar.gz: 72ba109b5f3c5d257de360f0faf3b8a6eee1b24b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 029fc6b6a22f5e5b12c71d50a2721a6f638a808988dbfdc2e3fafa614fb670d11eedd62fe45a15da36aa1262b1c8098efa16bb659594a65998065605520da1ad
|
7
|
+
data.tar.gz: dfccd052193692da330ee70c0bc9b728961fd36ab8855884d7a9ff7cdd2a495370a99ebc66a4574904f6092f90edc5c5349c0aa7b87eb6554b75108d606db50b
|
@@ -50,18 +50,6 @@ h1,h2,h3,h4,h5,h6 {
|
|
50
50
|
}
|
51
51
|
}
|
52
52
|
|
53
|
-
.dropdown-toggle {
|
54
|
-
.glyphicon {
|
55
|
-
line-height: 1.5;
|
56
|
-
}
|
57
|
-
}
|
58
|
-
|
59
|
-
.search-btn, .view-type-group {
|
60
|
-
.glyphicon {
|
61
|
-
line-height: 1.45;
|
62
|
-
}
|
63
|
-
}
|
64
|
-
|
65
53
|
#content > .page-header:first-child {
|
66
54
|
margin-top: 0;
|
67
55
|
}
|
@@ -5,6 +5,9 @@ module Spotlight
|
|
5
5
|
include Spotlight::SolrDocument::AtomicUpdates
|
6
6
|
include ActiveSupport::Benchmarkable
|
7
7
|
|
8
|
+
class_attribute :document_builder_class
|
9
|
+
self.document_builder_class = SolrDocumentBuilder
|
10
|
+
|
8
11
|
extend ActiveModel::Callbacks
|
9
12
|
define_model_callbacks :index
|
10
13
|
|
@@ -40,66 +43,8 @@ module Spotlight
|
|
40
43
|
Spotlight::ReindexJob.perform_later(self)
|
41
44
|
end
|
42
45
|
|
43
|
-
|
44
|
-
|
45
|
-
# @abstract
|
46
|
-
# Convert this resource into zero-to-many new solr documents. The data here
|
47
|
-
# should be merged into the resource-specific {#to_solr} data.
|
48
|
-
#
|
49
|
-
# @return [Hash] a single solr document hash
|
50
|
-
# @return [Enumerator<Hash>] multiple solr document hashes. This can be a
|
51
|
-
# simple array, or an lazy enumerator
|
52
|
-
def to_solr
|
53
|
-
(exhibit_specific_solr_data || {}).merge(spotlight_resource_metadata_for_solr || {})
|
54
|
-
end
|
55
|
-
|
56
|
-
protected
|
57
|
-
|
58
|
-
##
|
59
|
-
# @return an enumerator of all the indexable documents for this resource
|
60
|
-
def documents_to_index
|
61
|
-
data = to_solr
|
62
|
-
return [] if data.blank?
|
63
|
-
data &&= [data] if data.is_a? Hash
|
64
|
-
|
65
|
-
return to_enum(:documents_to_index) { data.size } unless block_given?
|
66
|
-
|
67
|
-
data.lazy.reject(&:blank?).each do |doc|
|
68
|
-
yield doc.reverse_merge(existing_solr_doc_hash(doc[unique_key]) || {})
|
69
|
-
end
|
70
|
-
end
|
71
|
-
|
72
|
-
private
|
73
|
-
|
74
|
-
##
|
75
|
-
# Get any exhibit-specific metadata stored in e.g. sidecars, tags, etc
|
76
|
-
# This needs the generated solr document
|
77
|
-
def existing_solr_doc_hash(id)
|
78
|
-
document_model.new(unique_key => id).to_solr if document_model && id.present?
|
79
|
-
end
|
80
|
-
|
81
|
-
def unique_key
|
82
|
-
if document_model
|
83
|
-
document_model.unique_key.to_sym
|
84
|
-
else
|
85
|
-
:id
|
86
|
-
end
|
87
|
-
end
|
88
|
-
|
89
|
-
def exhibit_specific_solr_data
|
90
|
-
exhibit.solr_data if exhibit
|
91
|
-
end
|
92
|
-
|
93
|
-
def spotlight_resource_metadata_for_solr
|
94
|
-
{
|
95
|
-
Spotlight::Engine.config.resource_global_id_field => (to_global_id.to_s if persisted?),
|
96
|
-
document_model.resource_type_field => self.class.to_s.tableize
|
97
|
-
}
|
98
|
-
end
|
99
|
-
|
100
|
-
def document_model
|
101
|
-
exhibit.blacklight_config.document_model if exhibit
|
102
|
-
end
|
46
|
+
def document_model
|
47
|
+
exhibit.blacklight_config.document_model if exhibit
|
103
48
|
end
|
104
49
|
|
105
50
|
concerning :Indexing do
|
@@ -112,7 +57,7 @@ module Spotlight
|
|
112
57
|
count = 0
|
113
58
|
|
114
59
|
run_callbacks :index do
|
115
|
-
documents_to_index.each_slice(batch_size) do |batch|
|
60
|
+
document_builder.documents_to_index.each_slice(batch_size) do |batch|
|
116
61
|
write_to_index(batch)
|
117
62
|
update(last_indexed_count: (count += batch.length))
|
118
63
|
end
|
@@ -122,13 +67,17 @@ module Spotlight
|
|
122
67
|
end
|
123
68
|
end
|
124
69
|
|
70
|
+
def document_builder
|
71
|
+
@document_builder ||= document_builder_class.new(self)
|
72
|
+
end
|
73
|
+
|
125
74
|
protected
|
126
75
|
|
127
76
|
def reindex_with_logging
|
128
77
|
time_start = Time.zone.now
|
129
78
|
|
130
79
|
update(indexed_at: time_start,
|
131
|
-
last_indexed_estimate: documents_to_index.size,
|
80
|
+
last_indexed_estimate: document_builder.documents_to_index.size,
|
132
81
|
last_indexed_finished: nil,
|
133
82
|
last_index_elapsed_time: nil)
|
134
83
|
|
@@ -10,6 +10,8 @@ module Spotlight
|
|
10
10
|
# we want to do this before reindexing
|
11
11
|
after_create :update_document_sidecar
|
12
12
|
|
13
|
+
self.document_builder_class = UploadSolrDocumentBuilder
|
14
|
+
|
13
15
|
def self.fields(exhibit)
|
14
16
|
@fields ||= {}
|
15
17
|
@fields[exhibit] ||= begin
|
@@ -18,54 +20,18 @@ module Spotlight
|
|
18
20
|
end
|
19
21
|
end
|
20
22
|
|
21
|
-
def
|
22
|
-
|
23
|
+
def compound_id
|
24
|
+
"#{exhibit_id}-#{id}"
|
23
25
|
end
|
24
26
|
|
25
|
-
def
|
26
|
-
|
27
|
-
|
28
|
-
solr_hash = super
|
29
|
-
|
30
|
-
add_default_solr_fields solr_hash
|
31
|
-
|
32
|
-
add_image_dimensions solr_hash
|
33
|
-
|
34
|
-
add_file_versions solr_hash
|
35
|
-
|
36
|
-
add_sidecar_fields solr_hash
|
37
|
-
|
38
|
-
solr_hash
|
27
|
+
def sidecar
|
28
|
+
@sidecar ||= document_model.new(id: compound_id).sidecar(exhibit)
|
39
29
|
end
|
40
30
|
|
41
31
|
private
|
42
32
|
|
43
|
-
def
|
44
|
-
|
45
|
-
end
|
46
|
-
|
47
|
-
def add_image_dimensions(solr_hash)
|
48
|
-
dimensions = ::MiniMagick::Image.open(url.file.file)[:dimensions]
|
49
|
-
solr_hash[:spotlight_full_image_width_ssm] = dimensions.first
|
50
|
-
solr_hash[:spotlight_full_image_height_ssm] = dimensions.last
|
51
|
-
end
|
52
|
-
|
53
|
-
def add_file_versions(solr_hash)
|
54
|
-
spotlight_image_derivatives.each do |config|
|
55
|
-
solr_hash[config[:field]] = if config[:version]
|
56
|
-
url.send(config[:version]).url
|
57
|
-
else
|
58
|
-
url.url
|
59
|
-
end
|
60
|
-
end
|
61
|
-
end
|
62
|
-
|
63
|
-
def add_sidecar_fields(solr_hash)
|
64
|
-
solr_hash.merge! sidecar.to_solr
|
65
|
-
end
|
66
|
-
|
67
|
-
def compound_id
|
68
|
-
"#{exhibit_id}-#{id}"
|
33
|
+
def configured_fields
|
34
|
+
self.class.fields(exhibit)
|
69
35
|
end
|
70
36
|
|
71
37
|
def update_document_sidecar
|
@@ -83,10 +49,6 @@ module Spotlight
|
|
83
49
|
def configured_fields_data
|
84
50
|
data.slice(*configured_fields.map(&:field_name).map(&:to_s)).select { |_k, v| v.present? }
|
85
51
|
end
|
86
|
-
|
87
|
-
def sidecar
|
88
|
-
@sidecar ||= document_model.new(id: compound_id).sidecar(exhibit)
|
89
|
-
end
|
90
52
|
end
|
91
53
|
end
|
92
54
|
end
|
@@ -0,0 +1,67 @@
|
|
1
|
+
module Spotlight
|
2
|
+
# Creates solr documents for the documents in a resource
|
3
|
+
class SolrDocumentBuilder
|
4
|
+
def initialize(resource)
|
5
|
+
@resource = resource
|
6
|
+
end
|
7
|
+
|
8
|
+
attr_reader :resource
|
9
|
+
delegate :exhibit, :document_model, to: :resource
|
10
|
+
|
11
|
+
##
|
12
|
+
# @return an enumerator of all the indexable documents for this resource
|
13
|
+
def documents_to_index
|
14
|
+
data = to_solr
|
15
|
+
return [] if data.blank?
|
16
|
+
data &&= [data] if data.is_a? Hash
|
17
|
+
|
18
|
+
return to_enum(:documents_to_index) { data.size } unless block_given?
|
19
|
+
|
20
|
+
data.lazy.reject(&:blank?).each do |doc|
|
21
|
+
yield doc.reverse_merge(existing_solr_doc_hash(doc[unique_key]) || {})
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
protected
|
26
|
+
|
27
|
+
##
|
28
|
+
# @abstract
|
29
|
+
# Convert this resource into zero-to-many new solr documents. The data here
|
30
|
+
# should be merged into the resource-specific {#to_solr} data.
|
31
|
+
#
|
32
|
+
# @return [Hash] a single solr document hash
|
33
|
+
# @return [Enumerator<Hash>] multiple solr document hashes. This can be a
|
34
|
+
# simple array, or an lazy enumerator
|
35
|
+
def to_solr
|
36
|
+
(exhibit_specific_solr_data || {}).merge(spotlight_resource_metadata_for_solr || {})
|
37
|
+
end
|
38
|
+
|
39
|
+
private
|
40
|
+
|
41
|
+
##
|
42
|
+
# Get any exhibit-specific metadata stored in e.g. sidecars, tags, etc
|
43
|
+
# This needs the generated solr document
|
44
|
+
def existing_solr_doc_hash(id)
|
45
|
+
document_model.new(unique_key => id).to_solr if document_model && id.present?
|
46
|
+
end
|
47
|
+
|
48
|
+
def unique_key
|
49
|
+
if document_model
|
50
|
+
document_model.unique_key.to_sym
|
51
|
+
else
|
52
|
+
:id
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
def exhibit_specific_solr_data
|
57
|
+
exhibit.solr_data if exhibit
|
58
|
+
end
|
59
|
+
|
60
|
+
def spotlight_resource_metadata_for_solr
|
61
|
+
{
|
62
|
+
Spotlight::Engine.config.resource_global_id_field => (resource.to_global_id.to_s if resource.persisted?),
|
63
|
+
document_model.resource_type_field => resource.class.to_s.tableize
|
64
|
+
}
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
@@ -0,0 +1,48 @@
|
|
1
|
+
module Spotlight
|
2
|
+
# Creates solr documents for the uploaded documents in a resource
|
3
|
+
class UploadSolrDocumentBuilder < SolrDocumentBuilder
|
4
|
+
delegate :compound_id, to: :resource
|
5
|
+
|
6
|
+
def to_solr
|
7
|
+
resource.store_url! # so that #url doesn't return the tmp directory
|
8
|
+
|
9
|
+
solr_hash = super
|
10
|
+
|
11
|
+
add_default_solr_fields solr_hash
|
12
|
+
|
13
|
+
add_image_dimensions solr_hash
|
14
|
+
|
15
|
+
add_file_versions solr_hash
|
16
|
+
|
17
|
+
add_sidecar_fields solr_hash
|
18
|
+
|
19
|
+
solr_hash
|
20
|
+
end
|
21
|
+
|
22
|
+
private
|
23
|
+
|
24
|
+
def add_default_solr_fields(solr_hash)
|
25
|
+
solr_hash[exhibit.blacklight_config.document_model.unique_key.to_sym] = compound_id
|
26
|
+
end
|
27
|
+
|
28
|
+
def add_image_dimensions(solr_hash)
|
29
|
+
dimensions = ::MiniMagick::Image.open(resource.url.file.file)[:dimensions]
|
30
|
+
solr_hash[:spotlight_full_image_width_ssm] = dimensions.first
|
31
|
+
solr_hash[:spotlight_full_image_height_ssm] = dimensions.last
|
32
|
+
end
|
33
|
+
|
34
|
+
def add_file_versions(solr_hash)
|
35
|
+
resource.spotlight_image_derivatives.each do |config|
|
36
|
+
solr_hash[config[:field]] = if config[:version]
|
37
|
+
resource.url.send(config[:version]).url
|
38
|
+
else
|
39
|
+
resource.url.url
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
def add_sidecar_fields(solr_hash)
|
45
|
+
solr_hash.merge! resource.sidecar.to_solr
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
data/lib/spotlight/version.rb
CHANGED
@@ -4,21 +4,6 @@ describe Spotlight::Resource, type: :model do
|
|
4
4
|
end
|
5
5
|
let(:exhibit) { FactoryGirl.create(:exhibit) }
|
6
6
|
|
7
|
-
describe '#to_solr' do
|
8
|
-
before do
|
9
|
-
allow(subject).to receive(:exhibit).and_return(exhibit)
|
10
|
-
allow(subject).to receive_messages(type: 'Spotlight::Resource::Something', id: 15, persisted?: true)
|
11
|
-
end
|
12
|
-
it 'includes a reference to the resource' do
|
13
|
-
expect(subject.to_solr).to include spotlight_resource_id_ssim: subject.to_global_id.to_s
|
14
|
-
end
|
15
|
-
|
16
|
-
it 'includes exhibit-specific data' do
|
17
|
-
allow(exhibit).to receive(:solr_data).and_return(exhibit_data: true)
|
18
|
-
expect(subject.to_solr).to include exhibit_data: true
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
7
|
describe '#reindex' do
|
23
8
|
context 'with a provider that generates ids' do
|
24
9
|
subject do
|
@@ -31,7 +16,7 @@ describe Spotlight::Resource, type: :model do
|
|
31
16
|
SolrDocument.new(id: 123).sidecars.create!(exhibit: exhibit, data: { document_data: true })
|
32
17
|
allow(subject).to receive_messages(to_global_id: '')
|
33
18
|
|
34
|
-
allow(subject).to receive(:to_solr).and_return(solr_response)
|
19
|
+
allow(subject.document_builder).to receive(:to_solr).and_return(solr_response)
|
35
20
|
end
|
36
21
|
|
37
22
|
it 'includes exhibit document-specific data' do
|
@@ -1,7 +1,12 @@
|
|
1
|
-
|
2
1
|
describe Spotlight::Resources::OpenGraph, type: :model do
|
2
|
+
class TestDocBuilder < Spotlight::SolrDocumentBuilder
|
3
|
+
def to_solr
|
4
|
+
super.merge(resource.opengraph_properties)
|
5
|
+
end
|
6
|
+
end
|
7
|
+
|
3
8
|
class TestResource < Spotlight::Resource
|
4
|
-
|
9
|
+
self.document_builder_class = TestDocBuilder
|
5
10
|
include Spotlight::Resources::OpenGraph
|
6
11
|
end
|
7
12
|
|
@@ -14,7 +19,7 @@ describe Spotlight::Resources::OpenGraph, type: :model do
|
|
14
19
|
allow(subject).to receive_messages id: 15, opengraph_properties: {}, exhibit: exhibit, persisted?: true
|
15
20
|
end
|
16
21
|
|
17
|
-
let(:solr_doc) { subject.to_solr }
|
22
|
+
let(:solr_doc) { subject.document_builder.to_solr }
|
18
23
|
|
19
24
|
it 'includes this record id' do
|
20
25
|
expect(solr_doc).to include spotlight_resource_id_ssim: subject.to_global_id.to_s
|
@@ -2,9 +2,8 @@
|
|
2
2
|
describe Spotlight::Resources::Upload, type: :model do
|
3
3
|
let!(:exhibit) { FactoryGirl.create :exhibit }
|
4
4
|
let!(:custom_field) { FactoryGirl.create :custom_field, exhibit: exhibit }
|
5
|
-
|
6
|
-
|
7
|
-
end
|
5
|
+
let(:resource) { described_class.new(exhibit: exhibit) }
|
6
|
+
let(:doc_builder) { resource.document_builder }
|
8
7
|
|
9
8
|
let(:configured_fields) { [title_field] + described_class.fields(exhibit) }
|
10
9
|
let(:title_field) { OpenStruct.new(field_name: 'configured_title_field') }
|
@@ -19,22 +18,23 @@ describe Spotlight::Resources::Upload, type: :model do
|
|
19
18
|
end
|
20
19
|
|
21
20
|
before do
|
22
|
-
allow(
|
21
|
+
allow(resource).to receive(:configured_fields).and_return configured_fields
|
23
22
|
allow(described_class).to receive(:fields).and_return configured_fields
|
24
23
|
|
25
|
-
allow(
|
24
|
+
allow(resource.send(:blacklight_solr)).to receive(:update)
|
26
25
|
allow(Spotlight::Engine.config).to receive(:upload_title_field).and_return(title_field)
|
27
|
-
|
28
|
-
|
29
|
-
|
26
|
+
resource.data = upload_data
|
27
|
+
resource.url = File.open(File.join(FIXTURES_PATH, '800x600.png'))
|
28
|
+
resource.save
|
30
29
|
end
|
31
30
|
|
32
31
|
context 'with a custom upload title field' do
|
33
32
|
let(:title_field) { OpenStruct.new(field_name: 'configured_title_field', solr_field: :some_other_field) }
|
33
|
+
subject { doc_builder.to_solr }
|
34
34
|
|
35
35
|
describe '#to_solr' do
|
36
36
|
it 'stores the title field in the provided solr field' do
|
37
|
-
expect(subject
|
37
|
+
expect(subject[:some_other_field]).to eq 'Title Data'
|
38
38
|
end
|
39
39
|
end
|
40
40
|
end
|
@@ -51,42 +51,46 @@ describe Spotlight::Resources::Upload, type: :model do
|
|
51
51
|
end
|
52
52
|
|
53
53
|
describe '#to_solr' do
|
54
|
+
subject { doc_builder.to_solr }
|
55
|
+
|
54
56
|
it 'maps a single uploaded field to multiple solr fields' do
|
55
|
-
expect(subject
|
56
|
-
expect(subject
|
57
|
+
expect(subject['a']).to eq 'value'
|
58
|
+
expect(subject['b']).to eq 'value'
|
57
59
|
end
|
58
60
|
end
|
59
61
|
end
|
60
62
|
|
61
63
|
describe '#to_solr' do
|
64
|
+
subject { doc_builder.to_solr }
|
65
|
+
|
62
66
|
it 'has the exhibit id and the upload id as the solr id' do
|
63
|
-
expect(subject
|
67
|
+
expect(subject[:id]).to eq "#{resource.exhibit.id}-#{resource.id}"
|
64
68
|
end
|
65
69
|
|
66
70
|
it 'has a title field using the exhibit specific blacklight_config' do
|
67
|
-
expect(subject
|
71
|
+
expect(subject['configured_title_field']).to eq 'Title Data'
|
68
72
|
end
|
69
73
|
|
70
74
|
it 'has the other additional configured fields' do
|
71
|
-
expect(subject
|
72
|
-
expect(subject
|
73
|
-
expect(subject
|
75
|
+
expect(subject[:spotlight_upload_description_tesim]).to eq 'Description Data'
|
76
|
+
expect(subject[:spotlight_upload_attribution_tesim]).to eq 'Attribution Data'
|
77
|
+
expect(subject[:spotlight_upload_date_tesim]).to eq 'Date Data'
|
74
78
|
end
|
75
79
|
|
76
80
|
it 'has a spotlight_resource_type field' do
|
77
|
-
expect(subject
|
81
|
+
expect(subject[:spotlight_resource_type_ssim]).to eq 'spotlight/resources/uploads'
|
78
82
|
end
|
79
83
|
it 'has the various image fields' do
|
80
|
-
expect(subject
|
81
|
-
expect(subject
|
82
|
-
expect(subject
|
84
|
+
expect(subject).to have_key Spotlight::Engine.config.full_image_field
|
85
|
+
expect(subject).to have_key Spotlight::Engine.config.thumbnail_field
|
86
|
+
expect(subject).to have_key Spotlight::Engine.config.square_image_field
|
83
87
|
end
|
84
88
|
it 'has the full image dimensions fields' do
|
85
|
-
expect(subject
|
86
|
-
expect(subject
|
89
|
+
expect(subject[:spotlight_full_image_height_ssm]).to eq 600
|
90
|
+
expect(subject[:spotlight_full_image_width_ssm]).to eq 800
|
87
91
|
end
|
88
92
|
it 'has fields representing exhibit specific custom fields' do
|
89
|
-
expect(subject
|
93
|
+
expect(subject[custom_field.solr_field]).to eq 'Custom Field Data'
|
90
94
|
end
|
91
95
|
end
|
92
96
|
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
describe Spotlight::SolrDocumentBuilder do
|
2
|
+
let(:exhibit) { FactoryGirl.create(:exhibit) }
|
3
|
+
let(:doc_builder) { described_class.new(resource) }
|
4
|
+
let(:resource) { Spotlight::Resource.new }
|
5
|
+
|
6
|
+
describe '#to_solr' do
|
7
|
+
subject { doc_builder.send(:to_solr) }
|
8
|
+
|
9
|
+
before do
|
10
|
+
allow(resource).to receive(:exhibit).and_return(exhibit)
|
11
|
+
allow(resource).to receive_messages(type: 'Spotlight::Resource::Something', id: 15, persisted?: true)
|
12
|
+
end
|
13
|
+
it 'includes a reference to the resource' do
|
14
|
+
expect(subject).to include spotlight_resource_id_ssim: resource.to_global_id.to_s
|
15
|
+
end
|
16
|
+
|
17
|
+
it 'includes exhibit-specific data' do
|
18
|
+
allow(exhibit).to receive(:solr_data).and_return(exhibit_data: true)
|
19
|
+
expect(subject).to include exhibit_data: true
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blacklight-spotlight
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.19.
|
4
|
+
version: 0.19.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Beer
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2016-07-
|
14
|
+
date: 2016-07-25 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: rails
|
@@ -249,14 +249,14 @@ dependencies:
|
|
249
249
|
requirements:
|
250
250
|
- - "~>"
|
251
251
|
- !ruby/object:Gem::Version
|
252
|
-
version: '1.
|
252
|
+
version: '1.6'
|
253
253
|
type: :runtime
|
254
254
|
prerelease: false
|
255
255
|
version_requirements: !ruby/object:Gem::Requirement
|
256
256
|
requirements:
|
257
257
|
- - "~>"
|
258
258
|
- !ruby/object:Gem::Version
|
259
|
-
version: '1.
|
259
|
+
version: '1.6'
|
260
260
|
- !ruby/object:Gem::Dependency
|
261
261
|
name: roar-rails
|
262
262
|
requirement: !ruby/object:Gem::Requirement
|
@@ -913,6 +913,8 @@ files:
|
|
913
913
|
- app/serializers/spotlight/main_navigation_representer.rb
|
914
914
|
- app/serializers/spotlight/page_representer.rb
|
915
915
|
- app/services/spotlight/carrierwave_file_resolver.rb
|
916
|
+
- app/services/spotlight/solr_document_builder.rb
|
917
|
+
- app/services/spotlight/upload_solr_document_builder.rb
|
916
918
|
- app/uploaders/spotlight/attachment_uploader.rb
|
917
919
|
- app/uploaders/spotlight/avatar_uploader.rb
|
918
920
|
- app/uploaders/spotlight/featured_image_uploader.rb
|
@@ -925,7 +927,6 @@ files:
|
|
925
927
|
- app/views/blacklight/nav/_search_history.html.erb
|
926
928
|
- app/views/catalog/_image_default.html.erb
|
927
929
|
- app/views/catalog/_save_search.html.erb
|
928
|
-
- app/views/catalog/_search_form.html.erb
|
929
930
|
- app/views/devise/confirmations/new.html.erb
|
930
931
|
- app/views/devise/mailer/invitation_instructions.html.erb
|
931
932
|
- app/views/layouts/spotlight/home.html.erb
|
@@ -1292,6 +1293,7 @@ files:
|
|
1292
1293
|
- spec/routing/spotlight/pages_routing_spec.rb
|
1293
1294
|
- spec/serializers/spotlight/exhibit_export_serializer_spec.rb
|
1294
1295
|
- spec/services/spotlight/carrierwave_file_resolver_spec.rb
|
1296
|
+
- spec/services/spotlight/solr_document_builder_spec.rb
|
1295
1297
|
- spec/spec_helper.rb
|
1296
1298
|
- spec/support/controllers/engine_helpers.rb
|
1297
1299
|
- spec/support/features/test_features_helpers.rb
|
@@ -1383,221 +1385,222 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
1383
1385
|
version: '0'
|
1384
1386
|
requirements: []
|
1385
1387
|
rubyforge_project:
|
1386
|
-
rubygems_version: 2.
|
1388
|
+
rubygems_version: 2.6.4
|
1387
1389
|
signing_key:
|
1388
1390
|
specification_version: 4
|
1389
1391
|
summary: Enable librarians, curators, and others who are responsible for digital collections
|
1390
1392
|
to create attractive, feature-rich websites that feature these collections.
|
1391
1393
|
test_files:
|
1392
|
-
- spec/views/_user_util_links.html.erb_spec.rb
|
1393
|
-
- spec/views/shared/_footer.html.erb_spec.rb
|
1394
|
-
- spec/views/shared/_exhibit_navbar.html.erb_spec.rb
|
1395
|
-
- spec/views/shared/_analytics.html.erb_spec.rb
|
1396
|
-
- spec/views/shared/_header_navbar.html.erb_spec.rb
|
1397
|
-
- spec/views/shared/_masthead.html.erb_spec.rb
|
1398
|
-
- spec/views/spotlight/home_pages/_empty.html.erb_spec.rb
|
1399
|
-
- spec/views/spotlight/home_pages/_sidebar.html.erb_spec.rb
|
1400
|
-
- spec/views/spotlight/roles/index.html.erb_spec.rb
|
1401
|
-
- spec/views/spotlight/dashboards/analytics.html.erb_spec.rb
|
1402
|
-
- spec/views/spotlight/dashboards/_analytics.html.erb_spec.rb
|
1403
|
-
- spec/views/spotlight/exhibits/_exhibit_card_front.html.erb_spec.rb
|
1404
|
-
- spec/views/spotlight/exhibits/edit.html.erb_spec.rb
|
1405
|
-
- spec/views/spotlight/exhibits/index.html.erb_spec.rb
|
1406
|
-
- spec/views/spotlight/sites/edit_exhibits.html.erb_spec.rb
|
1407
|
-
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_embed_block.html.erb_spec.rb
|
1408
|
-
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_features_block.html.erb_spec.rb
|
1409
|
-
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_carousel_block.html.erb_spec.rb
|
1410
|
-
- spec/views/spotlight/sir_trevor/blocks/_iframe_block.html.erb_spec.rb
|
1411
|
-
- spec/views/spotlight/sir_trevor/blocks/_rule_block.html.erb_spec.rb
|
1412
|
-
- spec/views/spotlight/sir_trevor/blocks/_browse_block.html.erb_spec.rb
|
1413
|
-
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_grid_block.html.erb_spec.rb
|
1414
|
-
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_block.html.erb_spec.rb
|
1415
|
-
- spec/views/spotlight/feature_pages/_empty.html.erb_spec.rb
|
1416
|
-
- spec/views/spotlight/feature_pages/_sidebar.html.erb_spec.rb
|
1417
|
-
- spec/views/spotlight/search_configurations/_facet_metadata.html.erb_spec.rb
|
1418
|
-
- spec/views/spotlight/search_configurations/_sort.html.erb_spec.rb
|
1419
|
-
- spec/views/spotlight/search_configurations/_search_fields.html.erb_spec.rb
|
1420
|
-
- spec/views/spotlight/about_pages/_empty.html.erb_spec.rb
|
1421
|
-
- spec/views/spotlight/about_pages/_sidebar.html.erb_spec.rb
|
1422
|
-
- spec/views/spotlight/about_pages/index.html.erb_spec.rb
|
1423
|
-
- spec/views/spotlight/searches/_search.html.erb_spec.rb
|
1424
|
-
- spec/views/spotlight/searches/edit.html.erb_spec.rb
|
1425
|
-
- spec/views/spotlight/searches/index.html.erb_spec.rb
|
1426
|
-
- spec/views/spotlight/contacts/edit.html.erb_spec.rb
|
1427
|
-
- spec/views/spotlight/browse/_search.html.erb_spec.rb
|
1428
|
-
- spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
|
1429
|
-
- spec/views/spotlight/browse/show.html.erb_spec.rb
|
1430
|
-
- spec/views/spotlight/browse/index.html.erb_spec.rb
|
1431
|
-
- spec/views/spotlight/metadata_configurations/_metadata_field.html.erb_spec.rb
|
1432
|
-
- spec/views/spotlight/metadata_configurations/edit.html.erb_spec.rb
|
1433
|
-
- spec/views/spotlight/catalog/admin.html.erb_spec.rb
|
1434
|
-
- spec/views/spotlight/catalog/edit.html.erb_spec.rb
|
1435
|
-
- spec/views/spotlight/catalog/_edit_default.html.erb_spec.rb
|
1436
|
-
- spec/views/spotlight/resources/new.html.erb_spec.rb
|
1437
|
-
- spec/views/spotlight/resources/_external_resources_form.html.erb_spec.rb
|
1438
|
-
- spec/views/spotlight/pages/new.html.erb_spec.rb
|
1439
|
-
- spec/views/spotlight/pages/show.html.erb_spec.rb
|
1440
|
-
- spec/views/spotlight/pages/edit.html.erb_spec.rb
|
1441
|
-
- spec/views/spotlight/pages/index.html.erb_spec.rb
|
1442
|
-
- spec/views/spotlight/tags/index.html.erb_spec.rb
|
1443
|
-
- spec/support/views/test_view_helpers.rb
|
1444
|
-
- spec/support/controllers/engine_helpers.rb
|
1445
|
-
- spec/support/helpers/controller_level_helpers.rb
|
1446
|
-
- spec/support/features/test_features_helpers.rb
|
1447
1394
|
- spec/controllers/application_controller_spec.rb
|
1448
|
-
- spec/controllers/spotlight/
|
1449
|
-
- spec/controllers/spotlight/
|
1395
|
+
- spec/controllers/spotlight/about_pages_controller_spec.rb
|
1396
|
+
- spec/controllers/spotlight/admin_users_controller_spec.rb
|
1397
|
+
- spec/controllers/spotlight/appearances_controller_spec.rb
|
1450
1398
|
- spec/controllers/spotlight/application_controller_spec.rb
|
1451
|
-
- spec/controllers/spotlight/versions_controller_spec.rb
|
1452
1399
|
- spec/controllers/spotlight/attachments_controller_spec.rb
|
1453
|
-
- spec/controllers/spotlight/appearances_controller_spec.rb
|
1454
|
-
- spec/controllers/spotlight/search_configurations_controller_spec.rb
|
1455
|
-
- spec/controllers/spotlight/admin_users_controller_spec.rb
|
1456
1400
|
- spec/controllers/spotlight/browse_controller_spec.rb
|
1457
|
-
- spec/controllers/spotlight/feature_pages_controller_spec.rb
|
1458
|
-
- spec/controllers/spotlight/sites_controller_spec.rb
|
1459
|
-
- spec/controllers/spotlight/tags_controller_spec.rb
|
1460
|
-
- spec/controllers/spotlight/confirmations_controller_spec.rb
|
1461
|
-
- spec/controllers/spotlight/home_pages_controller_spec.rb
|
1462
|
-
- spec/controllers/spotlight/resources/upload_controller_spec.rb
|
1463
|
-
- spec/controllers/spotlight/resources/csv_upload_controller_spec.rb
|
1464
|
-
- spec/controllers/spotlight/roles_controller_spec.rb
|
1465
1401
|
- spec/controllers/spotlight/catalog_controller_spec.rb
|
1466
|
-
- spec/controllers/spotlight/
|
1467
|
-
- spec/controllers/spotlight/solr_controller_spec.rb
|
1402
|
+
- spec/controllers/spotlight/confirmations_controller_spec.rb
|
1468
1403
|
- spec/controllers/spotlight/contact_forms_controller_spec.rb
|
1404
|
+
- spec/controllers/spotlight/contacts_controller_spec.rb
|
1469
1405
|
- spec/controllers/spotlight/custom_fields_controller_spec.rb
|
1470
|
-
- spec/controllers/spotlight/filters_controller_spec.rb
|
1471
1406
|
- spec/controllers/spotlight/dashboards_controller_spec.rb
|
1407
|
+
- spec/controllers/spotlight/exhibits_controller_spec.rb
|
1408
|
+
- spec/controllers/spotlight/feature_pages_controller_spec.rb
|
1409
|
+
- spec/controllers/spotlight/filters_controller_spec.rb
|
1410
|
+
- spec/controllers/spotlight/home_pages_controller_spec.rb
|
1472
1411
|
- spec/controllers/spotlight/metadata_configurations_controller_spec.rb
|
1412
|
+
- spec/controllers/spotlight/resources/csv_upload_controller_spec.rb
|
1413
|
+
- spec/controllers/spotlight/resources/upload_controller_spec.rb
|
1473
1414
|
- spec/controllers/spotlight/resources_controller_spec.rb
|
1474
|
-
- spec/controllers/spotlight/
|
1415
|
+
- spec/controllers/spotlight/roles_controller_spec.rb
|
1416
|
+
- spec/controllers/spotlight/search_configurations_controller_spec.rb
|
1475
1417
|
- spec/controllers/spotlight/searches_controller_spec.rb
|
1476
|
-
- spec/
|
1477
|
-
- spec/
|
1478
|
-
- spec/
|
1479
|
-
- spec/
|
1480
|
-
- spec/
|
1481
|
-
- spec/
|
1482
|
-
- spec/
|
1483
|
-
- spec/
|
1484
|
-
- spec/
|
1485
|
-
- spec/
|
1486
|
-
- spec/
|
1487
|
-
- spec/
|
1488
|
-
- spec/
|
1489
|
-
- spec/
|
1490
|
-
- spec/
|
1491
|
-
- spec/helpers/spotlight/navbar_helper_spec.rb
|
1492
|
-
- spec/helpers/spotlight/crud_link_helpers_spec.rb
|
1493
|
-
- spec/uploaders/spotlight/item_uploader_spec.rb
|
1494
|
-
- spec/test_app_templates/catalog_controller.rb
|
1495
|
-
- spec/test_app_templates/spotlight_test.rake
|
1496
|
-
- spec/test_app_templates/lib/generators/test_app_generator.rb
|
1497
|
-
- spec/test_app_templates/carrierwave.rb
|
1498
|
-
- spec/features/edit_search_fields_spec.rb
|
1499
|
-
- spec/features/browse_category_admin_spec.rb
|
1500
|
-
- spec/features/exhibits/add_tags_spec.rb
|
1501
|
-
- spec/features/exhibits/edit_metadata_fields_spec.rb
|
1502
|
-
- spec/features/exhibits/custom_metadata_fields_spec.rb
|
1503
|
-
- spec/features/exhibits/administration_spec.rb
|
1504
|
-
- spec/features/site_admin_management_spec.rb
|
1418
|
+
- spec/controllers/spotlight/sites_controller_spec.rb
|
1419
|
+
- spec/controllers/spotlight/solr_controller_spec.rb
|
1420
|
+
- spec/controllers/spotlight/tags_controller_spec.rb
|
1421
|
+
- spec/controllers/spotlight/versions_controller_spec.rb
|
1422
|
+
- spec/controllers/spotlight/view_configurations_controller_spec.rb
|
1423
|
+
- spec/factories/contacts.rb
|
1424
|
+
- spec/factories/custom_fields.rb
|
1425
|
+
- spec/factories/exhibits.rb
|
1426
|
+
- spec/factories/featured_images.rb
|
1427
|
+
- spec/factories/pages.rb
|
1428
|
+
- spec/factories/resources.rb
|
1429
|
+
- spec/factories/roles.rb
|
1430
|
+
- spec/factories/searches.rb
|
1431
|
+
- spec/factories/tags.rb
|
1432
|
+
- spec/factories/users.rb
|
1505
1433
|
- spec/features/about_page_spec.rb
|
1506
|
-
- spec/features/
|
1434
|
+
- spec/features/add_contacts_spec.rb
|
1435
|
+
- spec/features/add_custom_field_metadata_spec.rb
|
1436
|
+
- spec/features/add_items_spec.rb
|
1437
|
+
- spec/features/browse_category_admin_spec.rb
|
1507
1438
|
- spec/features/browse_category_spec.rb
|
1508
1439
|
- spec/features/catalog_spec.rb
|
1509
|
-
- spec/features/user_admin_spec.rb
|
1510
|
-
- spec/features/dashboard_spec.rb
|
1511
1440
|
- spec/features/confirm_email_spec.rb
|
1512
|
-
- spec/features/
|
1513
|
-
- spec/features/exhibit_masthead_spec.rb
|
1514
|
-
- spec/features/add_custom_field_metadata_spec.rb
|
1515
|
-
- spec/features/item_admin_spec.rb
|
1516
|
-
- spec/features/tags_admin_spec.rb
|
1517
|
-
- spec/features/slideshow_spec.rb
|
1441
|
+
- spec/features/create_exhibit_spec.rb
|
1518
1442
|
- spec/features/create_page_spec.rb
|
1519
|
-
- spec/features/
|
1520
|
-
- spec/features/
|
1443
|
+
- spec/features/curator_items.rb
|
1444
|
+
- spec/features/dashboard_spec.rb
|
1521
1445
|
- spec/features/edit_contact_spec.rb
|
1522
|
-
- spec/features/
|
1446
|
+
- spec/features/edit_search_fields_spec.rb
|
1447
|
+
- spec/features/exhibit_masthead_spec.rb
|
1448
|
+
- spec/features/exhibits/add_tags_spec.rb
|
1449
|
+
- spec/features/exhibits/administration_spec.rb
|
1450
|
+
- spec/features/exhibits/custom_metadata_fields_spec.rb
|
1451
|
+
- spec/features/exhibits/edit_metadata_fields_spec.rb
|
1452
|
+
- spec/features/exhibits_index_spec.rb
|
1453
|
+
- spec/features/feature_page_spec.rb
|
1454
|
+
- spec/features/home_page_spec.rb
|
1455
|
+
- spec/features/import_exhibit_spec.rb
|
1456
|
+
- spec/features/item_admin_spec.rb
|
1457
|
+
- spec/features/javascript/about_page_admin_spec.rb
|
1523
1458
|
- spec/features/javascript/block_controls_spec.rb
|
1524
|
-
- spec/features/javascript/search_config_admin_spec.rb
|
1525
|
-
- spec/features/javascript/home_page_edit_spec.rb
|
1526
|
-
- spec/features/javascript/preview_block_spec.rb
|
1527
|
-
- spec/features/javascript/rule_block_spec.rb
|
1528
|
-
- spec/features/javascript/feature_page_admin_spec.rb
|
1529
|
-
- spec/features/javascript/metadata_admin_spec.rb
|
1530
|
-
- spec/features/javascript/roles_admin_spec.rb
|
1531
|
-
- spec/features/javascript/reindex_monitor_spec.rb
|
1532
1459
|
- spec/features/javascript/blocks/featured_browse_categories_block_spec.rb
|
1533
|
-
- spec/features/javascript/blocks/solr_documents_block_spec.rb
|
1534
|
-
- spec/features/javascript/blocks/search_result_block_spec.rb
|
1535
1460
|
- spec/features/javascript/blocks/featured_pages_block_spec.rb
|
1461
|
+
- spec/features/javascript/blocks/search_result_block_spec.rb
|
1462
|
+
- spec/features/javascript/blocks/solr_documents_block_spec.rb
|
1536
1463
|
- spec/features/javascript/blocks/uploaded_items_block_spec.rb
|
1537
|
-
- spec/features/javascript/search_context_spec.rb
|
1538
|
-
- spec/features/javascript/about_page_admin_spec.rb
|
1539
1464
|
- spec/features/javascript/edit_in_place_spec.rb
|
1540
|
-
- spec/features/
|
1541
|
-
- spec/features/
|
1542
|
-
- spec/features/
|
1543
|
-
- spec/features/
|
1544
|
-
- spec/features/
|
1465
|
+
- spec/features/javascript/feature_page_admin_spec.rb
|
1466
|
+
- spec/features/javascript/home_page_edit_spec.rb
|
1467
|
+
- spec/features/javascript/metadata_admin_spec.rb
|
1468
|
+
- spec/features/javascript/multi_image_select_spec.rb
|
1469
|
+
- spec/features/javascript/preview_block_spec.rb
|
1470
|
+
- spec/features/javascript/reindex_monitor_spec.rb
|
1471
|
+
- spec/features/javascript/roles_admin_spec.rb
|
1472
|
+
- spec/features/javascript/rule_block_spec.rb
|
1473
|
+
- spec/features/javascript/search_config_admin_spec.rb
|
1474
|
+
- spec/features/javascript/search_context_spec.rb
|
1545
1475
|
- spec/features/main_navigation_spec.rb
|
1546
|
-
- spec/features/
|
1547
|
-
- spec/features/
|
1548
|
-
- spec/
|
1549
|
-
- spec/
|
1550
|
-
- spec/
|
1551
|
-
- spec/
|
1552
|
-
- spec/
|
1553
|
-
- spec/
|
1554
|
-
- spec/
|
1555
|
-
- spec/
|
1556
|
-
- spec/
|
1557
|
-
- spec/
|
1558
|
-
- spec/
|
1559
|
-
- spec/
|
1560
|
-
- spec/
|
1561
|
-
- spec/
|
1476
|
+
- spec/features/metadata_admin_spec.rb
|
1477
|
+
- spec/features/report_a_problem_spec.rb
|
1478
|
+
- spec/features/site_admin_management_spec.rb
|
1479
|
+
- spec/features/site_masthead_spec.rb
|
1480
|
+
- spec/features/slideshow_spec.rb
|
1481
|
+
- spec/features/tags_admin_spec.rb
|
1482
|
+
- spec/features/user_admin_spec.rb
|
1483
|
+
- spec/fixtures/800x600.png
|
1484
|
+
- spec/fixtures/avatar.png
|
1485
|
+
- spec/fixtures/csv-upload-fixture.csv
|
1486
|
+
- spec/fixtures/sample_solr_documents.yml
|
1487
|
+
- spec/helpers/spotlight/application_helper_spec.rb
|
1488
|
+
- spec/helpers/spotlight/browse_helper_spec.rb
|
1489
|
+
- spec/helpers/spotlight/crud_link_helpers_spec.rb
|
1490
|
+
- spec/helpers/spotlight/jcrop_helper_spec.rb
|
1491
|
+
- spec/helpers/spotlight/main_app_helpers_spec.rb
|
1492
|
+
- spec/helpers/spotlight/navbar_helper_spec.rb
|
1493
|
+
- spec/helpers/spotlight/pages_helper_spec.rb
|
1494
|
+
- spec/helpers/spotlight/roles_helper_spec.rb
|
1495
|
+
- spec/helpers/spotlight/search_configurations_helper_spec.rb
|
1496
|
+
- spec/helpers/spotlight/title_helper_spec.rb
|
1497
|
+
- spec/jobs/spotlight/default_thumbnail_job_spec.rb
|
1498
|
+
- spec/jobs/spotlight/reindex_job_spec.rb
|
1499
|
+
- spec/jobs/spotlight/rename_sidecar_field_job_spec.rb
|
1500
|
+
- spec/lib/spotlight/catalog_spec.rb
|
1501
|
+
- spec/lib/spotlight/controller_spec.rb
|
1562
1502
|
- spec/mailers/spotlight/indexing_complete_mailer_spec.rb
|
1563
|
-
- spec/models/
|
1564
|
-
- spec/models/
|
1503
|
+
- spec/models/sir_trevor_rails/blocks/browse_block_spec.rb
|
1504
|
+
- spec/models/sir_trevor_rails/blocks/solr_documents_block_spec.rb
|
1505
|
+
- spec/models/sir_trevor_rails/blocks/textable_spec.rb
|
1506
|
+
- spec/models/solr_document_spec.rb
|
1565
1507
|
- spec/models/spotlight/ability_spec.rb
|
1566
|
-
- spec/models/spotlight/image_derivatives_spec.rb
|
1567
1508
|
- spec/models/spotlight/about_page_spec.rb
|
1568
|
-
- spec/models/spotlight/
|
1569
|
-
- spec/models/spotlight/
|
1570
|
-
- spec/models/spotlight/solr_document/atomic_updates_spec.rb
|
1571
|
-
- spec/models/spotlight/solr_document/spotlight_images_spec.rb
|
1572
|
-
- spec/models/spotlight/masthead_spec.rb
|
1509
|
+
- spec/models/spotlight/access_controls_enforcement_search_builder_spec.rb
|
1510
|
+
- spec/models/spotlight/analytics/ga_spec.rb
|
1573
1511
|
- spec/models/spotlight/blacklight_configuration_spec.rb
|
1512
|
+
- spec/models/spotlight/contact_email_spec.rb
|
1513
|
+
- spec/models/spotlight/contact_form_spec.rb
|
1514
|
+
- spec/models/spotlight/contact_spec.rb
|
1515
|
+
- spec/models/spotlight/custom_field_spec.rb
|
1516
|
+
- spec/models/spotlight/default_thumbnailable_concern_spec.rb
|
1517
|
+
- spec/models/spotlight/exhibit_spec.rb
|
1518
|
+
- spec/models/spotlight/feature_page_spec.rb
|
1574
1519
|
- spec/models/spotlight/featured_image_spec.rb
|
1575
1520
|
- spec/models/spotlight/field_metadata_spec.rb
|
1576
|
-
- spec/models/spotlight/
|
1577
|
-
- spec/models/spotlight/
|
1521
|
+
- spec/models/spotlight/filter_spec.rb
|
1522
|
+
- spec/models/spotlight/home_page_spec.rb
|
1523
|
+
- spec/models/spotlight/image_derivatives_spec.rb
|
1524
|
+
- spec/models/spotlight/main_navigation_spec.rb
|
1525
|
+
- spec/models/spotlight/masthead_spec.rb
|
1526
|
+
- spec/models/spotlight/page_spec.rb
|
1578
1527
|
- spec/models/spotlight/reindex_progress_spec.rb
|
1579
1528
|
- spec/models/spotlight/resource_spec.rb
|
1580
|
-
- spec/models/spotlight/access_controls_enforcement_search_builder_spec.rb
|
1581
|
-
- spec/models/spotlight/solr_document_sidecar_spec.rb
|
1582
|
-
- spec/models/spotlight/default_thumbnailable_concern_spec.rb
|
1583
|
-
- spec/models/spotlight/role_spec.rb
|
1584
|
-
- spec/models/spotlight/site_spec.rb
|
1585
|
-
- spec/models/spotlight/resources/upload_spec.rb
|
1586
1529
|
- spec/models/spotlight/resources/open_graph_spec.rb
|
1530
|
+
- spec/models/spotlight/resources/upload_spec.rb
|
1587
1531
|
- spec/models/spotlight/resources/web_spec.rb
|
1588
|
-
- spec/models/spotlight/
|
1532
|
+
- spec/models/spotlight/role_spec.rb
|
1589
1533
|
- spec/models/spotlight/search_spec.rb
|
1590
|
-
- spec/models/spotlight/
|
1591
|
-
- spec/models/spotlight/
|
1592
|
-
- spec/models/spotlight/
|
1593
|
-
- spec/models/spotlight/
|
1594
|
-
- spec/models/spotlight/
|
1595
|
-
- spec/models/spotlight/
|
1596
|
-
- spec/models/spotlight/
|
1597
|
-
- spec/
|
1598
|
-
- spec/
|
1599
|
-
- spec/
|
1600
|
-
- spec/
|
1601
|
-
- spec/
|
1602
|
-
- spec/lib/spotlight/catalog_spec.rb
|
1534
|
+
- spec/models/spotlight/site_spec.rb
|
1535
|
+
- spec/models/spotlight/sitemap_spec.rb
|
1536
|
+
- spec/models/spotlight/solr_document/atomic_updates_spec.rb
|
1537
|
+
- spec/models/spotlight/solr_document/spotlight_images_spec.rb
|
1538
|
+
- spec/models/spotlight/solr_document/uploaded_resource_spec.rb
|
1539
|
+
- spec/models/spotlight/solr_document_sidecar_spec.rb
|
1540
|
+
- spec/models/spotlight/user_spec.rb
|
1541
|
+
- spec/routing/spotlight/exhibit_catalog_spec.rb
|
1542
|
+
- spec/routing/spotlight/pages_routing_spec.rb
|
1543
|
+
- spec/serializers/spotlight/exhibit_export_serializer_spec.rb
|
1544
|
+
- spec/services/spotlight/carrierwave_file_resolver_spec.rb
|
1545
|
+
- spec/services/spotlight/solr_document_builder_spec.rb
|
1603
1546
|
- spec/spec_helper.rb
|
1547
|
+
- spec/support/controllers/engine_helpers.rb
|
1548
|
+
- spec/support/features/test_features_helpers.rb
|
1549
|
+
- spec/support/helpers/controller_level_helpers.rb
|
1550
|
+
- spec/support/views/test_view_helpers.rb
|
1551
|
+
- spec/test_app_templates/carrierwave.rb
|
1552
|
+
- spec/test_app_templates/catalog_controller.rb
|
1553
|
+
- spec/test_app_templates/lib/generators/test_app_generator.rb
|
1554
|
+
- spec/test_app_templates/spotlight_test.rake
|
1555
|
+
- spec/uploaders/spotlight/item_uploader_spec.rb
|
1556
|
+
- spec/views/_user_util_links.html.erb_spec.rb
|
1557
|
+
- spec/views/shared/_analytics.html.erb_spec.rb
|
1558
|
+
- spec/views/shared/_exhibit_navbar.html.erb_spec.rb
|
1559
|
+
- spec/views/shared/_footer.html.erb_spec.rb
|
1560
|
+
- spec/views/shared/_header_navbar.html.erb_spec.rb
|
1561
|
+
- spec/views/shared/_masthead.html.erb_spec.rb
|
1562
|
+
- spec/views/spotlight/about_pages/_empty.html.erb_spec.rb
|
1563
|
+
- spec/views/spotlight/about_pages/_sidebar.html.erb_spec.rb
|
1564
|
+
- spec/views/spotlight/about_pages/index.html.erb_spec.rb
|
1565
|
+
- spec/views/spotlight/browse/_search.html.erb_spec.rb
|
1566
|
+
- spec/views/spotlight/browse/_sort_and_per_page.html.erb_spec.rb
|
1567
|
+
- spec/views/spotlight/browse/index.html.erb_spec.rb
|
1568
|
+
- spec/views/spotlight/browse/show.html.erb_spec.rb
|
1569
|
+
- spec/views/spotlight/catalog/_edit_default.html.erb_spec.rb
|
1570
|
+
- spec/views/spotlight/catalog/admin.html.erb_spec.rb
|
1571
|
+
- spec/views/spotlight/catalog/edit.html.erb_spec.rb
|
1572
|
+
- spec/views/spotlight/contacts/edit.html.erb_spec.rb
|
1573
|
+
- spec/views/spotlight/dashboards/_analytics.html.erb_spec.rb
|
1574
|
+
- spec/views/spotlight/dashboards/analytics.html.erb_spec.rb
|
1575
|
+
- spec/views/spotlight/exhibits/_exhibit_card_front.html.erb_spec.rb
|
1576
|
+
- spec/views/spotlight/exhibits/edit.html.erb_spec.rb
|
1577
|
+
- spec/views/spotlight/exhibits/index.html.erb_spec.rb
|
1578
|
+
- spec/views/spotlight/feature_pages/_empty.html.erb_spec.rb
|
1579
|
+
- spec/views/spotlight/feature_pages/_sidebar.html.erb_spec.rb
|
1580
|
+
- spec/views/spotlight/home_pages/_empty.html.erb_spec.rb
|
1581
|
+
- spec/views/spotlight/home_pages/_sidebar.html.erb_spec.rb
|
1582
|
+
- spec/views/spotlight/metadata_configurations/_metadata_field.html.erb_spec.rb
|
1583
|
+
- spec/views/spotlight/metadata_configurations/edit.html.erb_spec.rb
|
1584
|
+
- spec/views/spotlight/pages/edit.html.erb_spec.rb
|
1585
|
+
- spec/views/spotlight/pages/index.html.erb_spec.rb
|
1586
|
+
- spec/views/spotlight/pages/new.html.erb_spec.rb
|
1587
|
+
- spec/views/spotlight/pages/show.html.erb_spec.rb
|
1588
|
+
- spec/views/spotlight/resources/_external_resources_form.html.erb_spec.rb
|
1589
|
+
- spec/views/spotlight/resources/new.html.erb_spec.rb
|
1590
|
+
- spec/views/spotlight/roles/index.html.erb_spec.rb
|
1591
|
+
- spec/views/spotlight/search_configurations/_facet_metadata.html.erb_spec.rb
|
1592
|
+
- spec/views/spotlight/search_configurations/_search_fields.html.erb_spec.rb
|
1593
|
+
- spec/views/spotlight/search_configurations/_sort.html.erb_spec.rb
|
1594
|
+
- spec/views/spotlight/searches/_search.html.erb_spec.rb
|
1595
|
+
- spec/views/spotlight/searches/edit.html.erb_spec.rb
|
1596
|
+
- spec/views/spotlight/searches/index.html.erb_spec.rb
|
1597
|
+
- spec/views/spotlight/sir_trevor/blocks/_browse_block.html.erb_spec.rb
|
1598
|
+
- spec/views/spotlight/sir_trevor/blocks/_iframe_block.html.erb_spec.rb
|
1599
|
+
- spec/views/spotlight/sir_trevor/blocks/_rule_block.html.erb_spec.rb
|
1600
|
+
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_block.html.erb_spec.rb
|
1601
|
+
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_carousel_block.html.erb_spec.rb
|
1602
|
+
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_embed_block.html.erb_spec.rb
|
1603
|
+
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_features_block.html.erb_spec.rb
|
1604
|
+
- spec/views/spotlight/sir_trevor/blocks/_solr_documents_grid_block.html.erb_spec.rb
|
1605
|
+
- spec/views/spotlight/sites/edit_exhibits.html.erb_spec.rb
|
1606
|
+
- spec/views/spotlight/tags/index.html.erb_spec.rb
|
@@ -1,24 +0,0 @@
|
|
1
|
-
<%= form_tag search_action_url, method: :get, class: 'search-query-form clearfix navbar-form', role: 'search' do %>
|
2
|
-
<%= render_hash_as_hidden_fields(search_state.params_for_search.except(:q, :search_field, :qt, :page, :utf8)) %>
|
3
|
-
|
4
|
-
<div class="input-group">
|
5
|
-
<% if search_fields.length > 1 %>
|
6
|
-
<span class="input-group-addon for-search-field">
|
7
|
-
<label for="search_field" class="sr-only"><%= t('blacklight.search.form.search_field.label') %></label>
|
8
|
-
<%= select_tag(:search_field, options_for_select(search_fields, h(params[:search_field])), title: t('blacklight.search.form.search_field.title'), id: "search_field", class: "search_field") %>
|
9
|
-
</span>
|
10
|
-
<% elsif search_fields.length == 1 %>
|
11
|
-
<%= hidden_field_tag :search_field, search_fields.first.last %>
|
12
|
-
<% end %>
|
13
|
-
|
14
|
-
<label for="q" class="sr-only"><%= t('blacklight.search.form.search.label') %></label>
|
15
|
-
<%= text_field_tag :q, params[:q], placeholder: t('blacklight.search.form.search.placeholder'), class: "search_q q form-control", id: "q", autofocus: should_autofocus_on_search_box? %>
|
16
|
-
|
17
|
-
<span class="input-group-btn">
|
18
|
-
<button type="submit" class="btn btn-primary search-btn" id="search">
|
19
|
-
<span class="submit-search-text"><%= t('blacklight.search.form.submit') %></span>
|
20
|
-
<span class="glyphicon glyphicon-search"></span>
|
21
|
-
</button>
|
22
|
-
</span>
|
23
|
-
</div>
|
24
|
-
<% end %>
|