Skip to content

Commit

Permalink
Don't display ocr_language in manifest. (pulibrary#550)
Browse files Browse the repository at this point in the history
  • Loading branch information
Trey Pendragon authored and Jon Stroop committed Apr 27, 2016
1 parent 05ac643 commit 03323b1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion app/schemas/plum_schema.rb
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ class PlumSchema < ActiveTriples::Schema
# Ignore things like admin data (workflow note), title, description, etc, as
# those have custom display logic.
def self.display_fields
ScannedResource.properties.values.map(&:term) - [:description, :state, :rights_statement, :holding_location, :title, :depositor, :source_metadata_identifier, :source_metadata, :date_modified, :date_uploaded, :workflow_note, :nav_date, :pdf_type] - IIIFBookSchema.properties.map(&:name)
ScannedResource.properties.values.map(&:term) - [:description, :state, :rights_statement, :holding_location, :title, :depositor, :source_metadata_identifier, :source_metadata, :date_modified, :date_uploaded, :workflow_note, :nav_date, :pdf_type, :ocr_language] - IIIFBookSchema.properties.map(&:name)
end
end
# rubocop:enable Metrics/ClassLength
4 changes: 4 additions & 0 deletions spec/services/polymorphic_manifest_builder_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,10 @@ def build_file_set(id)
it "is empty with no metadata" do
expect(result.metadata).to be_empty
end
it "doesn't render ocr_language" do
record.ocr_language = ["test"]
expect(result.metadata.first).to be_nil
end
it "has a date created" do
record.date_created = ["1981-01-31"]
expect(result.metadata).not_to be_empty
Expand Down

0 comments on commit 03323b1

Please sign in to comment.