Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/arclight/traject/ead2_component_config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,7 @@

NAME_ELEMENTS.map do |selector|
to_field 'names_ssim', extract_xpath("./controlaccess/#{selector}"), unique
to_field 'names_ssim', extract_xpath(".//#{selector}"), unique
to_field "#{selector}_ssim", extract_xpath(".//#{selector}")
end

Expand Down
3 changes: 3 additions & 0 deletions spec/features/fielded_search_results_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@
it '#name' do
visit search_catalog_path q: 'root', search_field: 'name'
within('.document-position-1') do
expect(page).to have_css '.index_title', text: /Dr. Root and L. Raymond Higgins/
end
within('.document-position-2') do
expect(page).to have_css '.index_title', text: /Alpha Omega Alpha Archives/
end
end
Expand Down
4 changes: 2 additions & 2 deletions spec/features/highlighted_search_results_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
visit search_catalog_path q: 'william root', search_field: 'name'
within '.document-position-1' do
within '.al-document-highlight' do
expect(page).to have_css 'em', text: 'William', count: 3
expect(page).to have_css 'em', text: 'Root', count: 3
expect(page).to have_css 'em', text: 'William', count: 1
expect(page).to have_css 'em', text: 'Root', count: 2
end
end
end
Expand Down
4 changes: 4 additions & 0 deletions spec/features/traject/ead2_indexing_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,10 @@ def components(result)
)
end

it 'names' do
expect(first_component['names_ssim']).to include 'Stanford, Leland'
end

it 'geogname' do
%w[geogname_ssim geogname_ssm].each do |field|
expect(all_components.first[field]).to be_nil
Expand Down
3 changes: 3 additions & 0 deletions spec/fixtures/ead/sul-spec/a0011.xml
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,9 @@
<container id="aspace_76137544d2e63550e7a7ef7cf2168c48"
label="Mixed Materials" type="box">1
</container>
<origination label="Creator">
<persname rules="aacr" source="naf">Stanford, Leland</persname>
</origination>
</did>
</c01>
</dsc>
Expand Down