dog_biscuits 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.circleci/config.yml +115 -0
- data/.codeclimate.yml +52 -0
- data/.gitignore +24 -0
- data/.rspec +3 -0
- data/.rubocop.yml +45 -0
- data/.rubocop_todo.yml +92 -0
- data/.travis.yml +18 -0
- data/CODE_OF_CONDUCT.md +36 -0
- data/CONTRIBUTING.md +161 -0
- data/Gemfile +40 -0
- data/LICENSE +14 -0
- data/README.md +98 -0
- data/Rakefile +35 -0
- data/SUPPORT.md +5 -0
- data/bin/console +15 -0
- data/bin/setup +7 -0
- data/dog_biscuits.gemspec +38 -0
- data/lib/dog_biscuits.rb +352 -0
- data/lib/dog_biscuits/actors/apply_authorities.rb +32 -0
- data/lib/dog_biscuits/actors/singular_attributes.rb +17 -0
- data/lib/dog_biscuits/blacklight/commands.rb +118 -0
- data/lib/dog_biscuits/configuration.rb +506 -0
- data/lib/dog_biscuits/importers/authority.rb +65 -0
- data/lib/dog_biscuits/indexers/collection_indexer.rb +10 -0
- data/lib/dog_biscuits/indexers/concerns/indexes_common.rb +58 -0
- data/lib/dog_biscuits/indexers/conference_item_indexer.rb +17 -0
- data/lib/dog_biscuits/indexers/dataset_indexer.rb +25 -0
- data/lib/dog_biscuits/indexers/digital_archival_object_indexer.rb +19 -0
- data/lib/dog_biscuits/indexers/exam_paper_indexer.rb +10 -0
- data/lib/dog_biscuits/indexers/journal_article_indexer.rb +15 -0
- data/lib/dog_biscuits/indexers/package_indexer.rb +19 -0
- data/lib/dog_biscuits/indexers/published_work_indexer.rb +16 -0
- data/lib/dog_biscuits/indexers/thesis_indexer.rb +16 -0
- data/lib/dog_biscuits/models/authorities/agent.rb +78 -0
- data/lib/dog_biscuits/models/authorities/agents/group.rb +59 -0
- data/lib/dog_biscuits/models/authorities/agents/historic_person.rb +55 -0
- data/lib/dog_biscuits/models/authorities/agents/organisation.rb +56 -0
- data/lib/dog_biscuits/models/authorities/agents/person.rb +75 -0
- data/lib/dog_biscuits/models/authorities/concept.rb +91 -0
- data/lib/dog_biscuits/models/authorities/concept_scheme.rb +65 -0
- data/lib/dog_biscuits/models/authorities/event.rb +74 -0
- data/lib/dog_biscuits/models/authorities/place.rb +86 -0
- data/lib/dog_biscuits/models/authorities/project.rb +60 -0
- data/lib/dog_biscuits/models/authority.rb +42 -0
- data/lib/dog_biscuits/models/collections/collection.rb +32 -0
- data/lib/dog_biscuits/models/concerns/behaviours/pure_specific_behaviour.rb +17 -0
- data/lib/dog_biscuits/models/concerns/behaviours/validate_concept_related.rb +12 -0
- data/lib/dog_biscuits/models/concerns/behaviours/validate_concept_scheme.rb +16 -0
- data/lib/dog_biscuits/models/concerns/behaviours/validate_label.rb +12 -0
- data/lib/dog_biscuits/models/concerns/behaviours/validate_place.rb +12 -0
- data/lib/dog_biscuits/models/concerns/behaviours/work_behaviour.rb +21 -0
- data/lib/dog_biscuits/models/concerns/extended_solr_document.rb +147 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/archivematica/archivematica.rb +73 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/archives_hub/access_provided_by.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/archives_hub/country_code.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/archives_hub/hub_dates.rb +17 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/archives_hub/maintenance_agency_code.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/awarding_institution.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/edition.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/identified_by.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/part.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/part_of.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/series.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibframe/subtitle.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibo/presented_at.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/bibo/publication_status.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/datacite/resource_type_general.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/abstract.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/access_rights.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/bibliographic_citation.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/contributor.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/creator.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date_accepted.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date_available.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date_copyrighted.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date_created.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/date_issued.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/description.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/extent.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/format.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/identifier.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/language.rb +17 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/publisher.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/resource_type.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/rights.rb +17 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/rights_holder.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/simple_versions.rb +18 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/source.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dc/subject.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/dwc/event_date.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/edm/edm_rights.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/fabio/date_collected.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/foaf/based_near.rb +12 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/foaf/foaf_name.rb +16 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/frapo/output_of.rb +18 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/geo/geo.rb +27 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/geonames/country_code.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/geonames/place_properties.rb +66 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/lc_identifiers/doi.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/lc_identifiers/isbn.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/lc_identifiers/official_url.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/lc_identifiers/orcid.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/for_indexing.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/former_identifier.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/generic_authority_terms.rb +22 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/generic_qualifier.rb +16 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/last_access.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/main_file.rb +24 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/module_code.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/number_of_downloads.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/packaged_by.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/readme_file.rb +26 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/local/requestor_email.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/mads/related_authority.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/marc_relators/advisor.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/marc_relators/editor.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/marc_relators/funder.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/marc_relators/place_of_publication.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/mods/date_valid.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/owl/owl_same_as.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/premis/has_restriction.rb +15 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/property_sets/person_properties.rb +92 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/pure/managing_organisation.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/pure/pure.rb +28 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/rdf/rdf_type.rb +12 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/rdf/rdfs_label.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/rdf/related_url.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/alternate_name.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/content_version.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/date_published.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/date_updated.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/department.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/end_date.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/issue_number.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/keyword.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/location.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/pagination.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/start_date.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/schema/volume_number.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/skos/skos_labels.rb +18 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/skos/skos_note.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/skos/skos_related.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/uketd/date_of_award.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/uketd/qualification.rb +17 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/ulcc/date_submitted.rb +14 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/ulcc/official_url.rb +13 -0
- data/lib/dog_biscuits/models/concerns/metadata_properties/ulcc/refereed.rb +13 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/common/common_labels.rb +9 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/common/common_metadata.rb +64 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/common/common_rights.rb +10 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/conference_item_metadata.rb +24 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/dataset_metadata.rb +36 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/digital_archival_object_metadata.rb +13 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/exam_paper_metadata.rb +14 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/journal_article_metadata.rb +24 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/package_metadata.rb +13 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/published_work_metadata.rb +26 -0
- data/lib/dog_biscuits/models/concerns/model_property_sets/thesis_metadata.rb +17 -0
- data/lib/dog_biscuits/models/filesets/file_set.rb +30 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/canvas.rb +15 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/contained_file.rb +13 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_date_certainty.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_editorial_note.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_entry.rb +19 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_entry_date.rb +10 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_entry_type.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_is_referenced_by.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_language.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_marginalium.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_note.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_as_written.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_descriptor.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_descriptor_as_written.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_note.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_related_person.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_related_place.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_person_role.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_place_as_written.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_place_note.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_place_role.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_place_type.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_related_agent.rb +20 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_related_place.rb +13 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_section_type.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_single_date.rb +10 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/db/db_subject.rb +5 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/entry.rb +59 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/entry/entry_date.rb +17 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/entry/related_agent.rb +62 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/entry/related_place.rb +28 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/entry/single_date.rb +19 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/folio.rb +42 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/image.rb +25 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/manifest.rb +15 -0
- data/lib/dog_biscuits/models/to_refactor_or_remove/register.rb +21 -0
- data/lib/dog_biscuits/models/work.rb +37 -0
- data/lib/dog_biscuits/models/works/conference_item.rb +37 -0
- data/lib/dog_biscuits/models/works/dataset.rb +42 -0
- data/lib/dog_biscuits/models/works/digital_archival_object.rb +28 -0
- data/lib/dog_biscuits/models/works/exam_paper.rb +33 -0
- data/lib/dog_biscuits/models/works/journal_article.rb +37 -0
- data/lib/dog_biscuits/models/works/package.rb +47 -0
- data/lib/dog_biscuits/models/works/published_work.rb +38 -0
- data/lib/dog_biscuits/models/works/thesis.rb +34 -0
- data/lib/dog_biscuits/property_mappings/property_mappings.rb +585 -0
- data/lib/dog_biscuits/railtie.rb +13 -0
- data/lib/dog_biscuits/services/table_based_authority_extended.rb +10 -0
- data/lib/dog_biscuits/services/terms.rb +57 -0
- data/lib/dog_biscuits/services/terms_service.rb +162 -0
- data/lib/dog_biscuits/solr/index_types.rb +33 -0
- data/lib/dog_biscuits/validators/concept_related_validator.rb +13 -0
- data/lib/dog_biscuits/validators/concept_scheme_member_validator.rb +10 -0
- data/lib/dog_biscuits/validators/label_validator.rb +55 -0
- data/lib/dog_biscuits/validators/place_validator.rb +10 -0
- data/lib/dog_biscuits/version.rb +5 -0
- data/lib/dog_biscuits/vocab/borthwick_registers.rb +321 -0
- data/lib/dog_biscuits/vocab/generic.rb +204 -0
- data/lib/dog_biscuits/vocab/oais_archivematica.rb +116 -0
- data/lib/dog_biscuits/vocab/pure_terms.rb +65 -0
- data/lib/dog_biscuits/vocab/uketd.rb +45 -0
- data/lib/dog_biscuits/vocab/ulcc_terms.rb +55 -0
- data/lib/generators/dog_biscuits/USAGE +50 -0
- data/lib/generators/dog_biscuits/authority_generator.rb +55 -0
- data/lib/generators/dog_biscuits/catalog_generator.rb +18 -0
- data/lib/generators/dog_biscuits/dates_generator.rb +98 -0
- data/lib/generators/dog_biscuits/generate_all_generator.rb +29 -0
- data/lib/generators/dog_biscuits/imagify_generator.rb +67 -0
- data/lib/generators/dog_biscuits/install_generator.rb +82 -0
- data/lib/generators/dog_biscuits/locales_generator.rb +20 -0
- data/lib/generators/dog_biscuits/schema_org_generator.rb +20 -0
- data/lib/generators/dog_biscuits/templates/_date_template.html.erb +7 -0
- data/lib/generators/dog_biscuits/templates/app/controllers/catalog_controller.rb +133 -0
- data/lib/generators/dog_biscuits/templates/app/helpers/dog_biscuits_helper.rb +43 -0
- data/lib/generators/dog_biscuits/templates/app/renderers/package_ids_renderer.rb +13 -0
- data/lib/generators/dog_biscuits/templates/app/renderers/packaged_by_ids_renderer.rb +11 -0
- data/lib/generators/dog_biscuits/templates/app/renderers/publication_status_renderer.rb +16 -0
- data/lib/generators/dog_biscuits/templates/app/services/concerns/file_authority_concern.rb +14 -0
- data/lib/generators/dog_biscuits/templates/app/services/concerns/local_authority_concern.rb +18 -0
- data/lib/generators/dog_biscuits/templates/app/services/local_form_metadata_service.rb +15 -0
- data/lib/generators/dog_biscuits/templates/app/views/hyrax/base/_form_metadata.html.erb +23 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_abstract.html.erb +5 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_default.html.erb +6 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_funder.html.erb +8 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_note.html.erb +5 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_part_of.html.erb +17 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_publication_status.html.erb +6 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_refereed.html.erb +5 -0
- data/lib/generators/dog_biscuits/templates/app/views/records/edit_fields/_resource_type_general.html.erb +2 -0
- data/lib/generators/dog_biscuits/templates/authority_service.rb.erb +25 -0
- data/lib/generators/dog_biscuits/templates/config/authorities/content_versions.yml +25 -0
- data/lib/generators/dog_biscuits/templates/config/authorities/publication_statuses.yml +19 -0
- data/lib/generators/dog_biscuits/templates/config/authorities/qualification_levels.yml +13 -0
- data/lib/generators/dog_biscuits/templates/config/authorities/qualification_names.yml +31 -0
- data/lib/generators/dog_biscuits/templates/config/authorities/resource_type_generals.yml +47 -0
- data/lib/generators/dog_biscuits/templates/config/dog_biscuits.yml +3 -0
- data/lib/generators/dog_biscuits/templates/config/initializers/catalog_search_builder_overrides.rb +18 -0
- data/lib/generators/dog_biscuits/templates/config/initializers/dog_biscuits.rb +144 -0
- data/lib/generators/dog_biscuits/templates/dog_biscuits.en.yml.erb +11 -0
- data/lib/generators/dog_biscuits/templates/schema_org.yml.erb +4 -0
- data/lib/generators/dog_biscuits/work/USAGE +35 -0
- data/lib/generators/dog_biscuits/work/templates/README +31 -0
- data/lib/generators/dog_biscuits/work/templates/_attribute_rows.html.erb +22 -0
- data/lib/generators/dog_biscuits/work/templates/actor.rb.erb +25 -0
- data/lib/generators/dog_biscuits/work/templates/form.rb.erb +18 -0
- data/lib/generators/dog_biscuits/work/templates/indexer.rb.erb +23 -0
- data/lib/generators/dog_biscuits/work/templates/model.rb.erb +16 -0
- data/lib/generators/dog_biscuits/work/templates/presenter.rb.erb +20 -0
- data/lib/generators/dog_biscuits/work/work_generator.rb +102 -0
- data/lib/tasks/authorities.rake +22 -0
- metadata +476 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module DogBiscuits
|
|
4
|
+
class Package < Work
|
|
5
|
+
# Needed to set the type
|
|
6
|
+
include ::Hydra::Works::WorkBehavior
|
|
7
|
+
|
|
8
|
+
# Order matters because included metadata finalises things:
|
|
9
|
+
# 1) type and local metadata
|
|
10
|
+
# 2) indexer
|
|
11
|
+
# 3) included metadata
|
|
12
|
+
|
|
13
|
+
type << DogBiscuits::Vocab::Generic.Package
|
|
14
|
+
|
|
15
|
+
# Local metadata
|
|
16
|
+
has_and_belongs_to_many :packages,
|
|
17
|
+
class_name: 'DogBiscuits::Work',
|
|
18
|
+
predicate: DogBiscuits::Vocab::Generic.packages,
|
|
19
|
+
inverse_of: :packaged_by
|
|
20
|
+
|
|
21
|
+
# Indexer
|
|
22
|
+
# Metadata
|
|
23
|
+
# include DogBiscuits::PackageMetadata
|
|
24
|
+
|
|
25
|
+
before_save :add_types
|
|
26
|
+
|
|
27
|
+
def package?
|
|
28
|
+
true
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
# It's an AIP if it has an AIP UUID
|
|
32
|
+
def aip?
|
|
33
|
+
aip_uuid.blank? ? false : true
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
# It's a DIP if it has a DIP UUID
|
|
37
|
+
def dip?
|
|
38
|
+
dip_uuid.blank? ? false : true
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
# If object is a DIP/AIP, add the rdf type
|
|
42
|
+
def add_types
|
|
43
|
+
rdf_type << DogBiscuits::Vocab::OaisArchivematica.DisseminationInformationPackage if dip?
|
|
44
|
+
rdf_type << DogBiscuits::Vocab::OaisArchivematica.ArchivalInformationPackage if aip?
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
end
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module DogBiscuits
|
|
4
|
+
class PublishedWork < Work
|
|
5
|
+
# Needed to set the type
|
|
6
|
+
include ::Hydra::Works::WorkBehavior
|
|
7
|
+
|
|
8
|
+
# Order matters because included metadata finalises things:
|
|
9
|
+
# 1) type and local metadata
|
|
10
|
+
# 2) indexer
|
|
11
|
+
# 3) included metadata
|
|
12
|
+
|
|
13
|
+
type << DogBiscuits::Vocab::UlccTerms.PublishedWork
|
|
14
|
+
type << ::RDF::Vocab::SCHEMA.Book
|
|
15
|
+
|
|
16
|
+
# Indexer
|
|
17
|
+
# self.indexer = DogBiscuits::PublishedWorkIndexer
|
|
18
|
+
# Metadata
|
|
19
|
+
# include DogBiscuits::PublishedWorkMetadata
|
|
20
|
+
|
|
21
|
+
# before_save :combine_dates
|
|
22
|
+
|
|
23
|
+
def published_work?
|
|
24
|
+
true
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# Create single date field from all dates.
|
|
28
|
+
def combine_dates
|
|
29
|
+
tmpdate = date
|
|
30
|
+
tmpdate << date_published
|
|
31
|
+
tmpdate << date_available
|
|
32
|
+
tmpdate << date_accepted
|
|
33
|
+
tmpdate << date_submitted
|
|
34
|
+
tmpdate << date_created
|
|
35
|
+
self.date = tmpdate
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module DogBiscuits
|
|
4
|
+
class Thesis < Work
|
|
5
|
+
# Needed to set the type
|
|
6
|
+
include ::Hydra::Works::WorkBehavior
|
|
7
|
+
|
|
8
|
+
# Order matters because included metadata finalises things:
|
|
9
|
+
# 1) type and local metadata
|
|
10
|
+
# 2) indexer
|
|
11
|
+
# 3) included metadata
|
|
12
|
+
|
|
13
|
+
type << ::RDF::URI.intern('https://bib.schema.org/Thesis')
|
|
14
|
+
|
|
15
|
+
## Indexer
|
|
16
|
+
# self.indexer = DogBiscuits::ThesisIndexer
|
|
17
|
+
# Metadata
|
|
18
|
+
# include DogBiscuits::ThesisMetadata
|
|
19
|
+
|
|
20
|
+
# before_save :combine_dates
|
|
21
|
+
|
|
22
|
+
def thesis?
|
|
23
|
+
true
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
# Create single date field from all dates.
|
|
27
|
+
def combine_dates
|
|
28
|
+
tmpdate = date
|
|
29
|
+
tmpdate << date_of_award
|
|
30
|
+
tmpdate << date_created
|
|
31
|
+
self.date = tmpdate
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
end
|
|
@@ -0,0 +1,585 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# rubocop:disable Metrics/LineLength
|
|
4
|
+
# rubocop:disable Metrics/MethodLength
|
|
5
|
+
# rubocop:disable Metrics/ModuleLength
|
|
6
|
+
|
|
7
|
+
module DogBiscuits
|
|
8
|
+
module PropertyMappings
|
|
9
|
+
attr_writer :property_mappings
|
|
10
|
+
|
|
11
|
+
# Add all properties to the property_mappings hash.
|
|
12
|
+
# Allowed values:
|
|
13
|
+
# label: a human-readable label for the property REQUIRED
|
|
14
|
+
# index: any additional options for the blacklight index in an array
|
|
15
|
+
# excluding helper_method and item prop
|
|
16
|
+
# provide in a hash, eg. [{ if: false }], or [{ link_to_search: true }]
|
|
17
|
+
# nb. for link_to_search, just provide true
|
|
18
|
+
# schema_org: hash containing property; can also include type and value
|
|
19
|
+
# help_text: help text to include in the form
|
|
20
|
+
# render_as: a custom renderer for the field (omit facetable)
|
|
21
|
+
# helper_method: a helper method used to render this property in the catalog
|
|
22
|
+
|
|
23
|
+
# NOTE: Labels MUST be wrapped in single quotes and help_text MUST be wrapped in double quotes
|
|
24
|
+
def property_mappings
|
|
25
|
+
@property_mappings ||=
|
|
26
|
+
{
|
|
27
|
+
file_format: {
|
|
28
|
+
label: 'File format',
|
|
29
|
+
index: [{ link_to_search: true }]
|
|
30
|
+
},
|
|
31
|
+
embargo_release_date: {
|
|
32
|
+
label: 'Embargo releases on',
|
|
33
|
+
index: [{ type: :date }],
|
|
34
|
+
helper_method: :human_readable_date
|
|
35
|
+
},
|
|
36
|
+
lease_expiration_date: {
|
|
37
|
+
label: 'Lease expires on',
|
|
38
|
+
index: [{ type: :date }],
|
|
39
|
+
helper_method: :human_readable_date
|
|
40
|
+
},
|
|
41
|
+
depositor: {
|
|
42
|
+
helper_method: :link_to_profile,
|
|
43
|
+
label: 'Owner'
|
|
44
|
+
},
|
|
45
|
+
proxy_depositor: {
|
|
46
|
+
# index: "('proxy_depositor', :symbol",
|
|
47
|
+
helper_method: :link_to_profile,
|
|
48
|
+
label: 'Depositor'
|
|
49
|
+
},
|
|
50
|
+
date_uploaded: {
|
|
51
|
+
label: 'Date uploaded',
|
|
52
|
+
helper_method: :human_readable_date
|
|
53
|
+
},
|
|
54
|
+
date_modified: {
|
|
55
|
+
label: 'Date modified',
|
|
56
|
+
helper_method: :human_readable_date
|
|
57
|
+
},
|
|
58
|
+
abstract: {
|
|
59
|
+
label: 'Abstract',
|
|
60
|
+
helper_method: :truncate_text_and_iconify_link,
|
|
61
|
+
schema_org: {
|
|
62
|
+
property: "description"
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
advisor: {
|
|
66
|
+
schema_org: {
|
|
67
|
+
property: "contributor",
|
|
68
|
+
type: "http://schema.org/Person",
|
|
69
|
+
value: "name"
|
|
70
|
+
},
|
|
71
|
+
label: 'Advisor / supervisor',
|
|
72
|
+
help_text: 'Thesis advisor or supervisor.'
|
|
73
|
+
},
|
|
74
|
+
access_provided_by: {
|
|
75
|
+
schema_org: {
|
|
76
|
+
property: "provider",
|
|
77
|
+
type: "http://schema.org/Organization",
|
|
78
|
+
value: "name"
|
|
79
|
+
},
|
|
80
|
+
label: 'Access provided by',
|
|
81
|
+
help_text: 'Repository'
|
|
82
|
+
},
|
|
83
|
+
alt: {
|
|
84
|
+
label: 'Altitude'
|
|
85
|
+
},
|
|
86
|
+
awarding_institution: {
|
|
87
|
+
index: [{ link_to_search: true }],
|
|
88
|
+
label: 'Awarding institution'
|
|
89
|
+
},
|
|
90
|
+
based_near: {
|
|
91
|
+
index: [{ link_to_search: true }],
|
|
92
|
+
schema_org: {
|
|
93
|
+
property: "contentLocation",
|
|
94
|
+
type: "http://schema.org/Place",
|
|
95
|
+
value: "name"
|
|
96
|
+
},
|
|
97
|
+
label: 'Location',
|
|
98
|
+
help_text: "A place name related to the work, such as its site of publication, or the city, state, or country the work contents are about. Calls upon the <a href='http://www.geonames.org'>GeoNames web service</a>."
|
|
99
|
+
},
|
|
100
|
+
based_near_label: {
|
|
101
|
+
index: [{ link_to_search: true }],
|
|
102
|
+
schema_org: {
|
|
103
|
+
property: "contentLocation",
|
|
104
|
+
type: "http://schema.org/Place",
|
|
105
|
+
value: "name"
|
|
106
|
+
},
|
|
107
|
+
label: 'Location',
|
|
108
|
+
help_text: "A place name related to the work, such as its site of publication, or the city, state, or country the work contents are about. Calls upon the <a href='http://www.geonames.org'>GeoNames web service</a>."
|
|
109
|
+
},
|
|
110
|
+
content_version: {
|
|
111
|
+
help_text: "The version of the file, eg. Author's Original or Accepted Manuscript."
|
|
112
|
+
},
|
|
113
|
+
contributor: {
|
|
114
|
+
index: [{ link_to_search: true }],
|
|
115
|
+
schema_org: {
|
|
116
|
+
property: "contributor",
|
|
117
|
+
type: "http://schema.org/Person",
|
|
118
|
+
value: "name"
|
|
119
|
+
},
|
|
120
|
+
label: 'Contributor',
|
|
121
|
+
help_text: "A person or group you want to recognize for playing a role in the creation of the work, but not the primary role."
|
|
122
|
+
},
|
|
123
|
+
contributor_combined: {
|
|
124
|
+
index: [{ link_to_search: true }],
|
|
125
|
+
schema_org: {
|
|
126
|
+
property: "contributor",
|
|
127
|
+
type: "http://schema.org/Person",
|
|
128
|
+
value: "name"
|
|
129
|
+
},
|
|
130
|
+
label: 'Contributor'
|
|
131
|
+
},
|
|
132
|
+
contributor_type: {
|
|
133
|
+
label: 'Contributor type'
|
|
134
|
+
},
|
|
135
|
+
creator: {
|
|
136
|
+
index: [{ link_to_search: true }],
|
|
137
|
+
label: 'Creator',
|
|
138
|
+
schema_org: {
|
|
139
|
+
property: "creator",
|
|
140
|
+
type: "http://schema.org/Person",
|
|
141
|
+
value: "name"
|
|
142
|
+
},
|
|
143
|
+
help_text: "The person or group responsible for the work. Usually this is the author of the content. Personal names should be entered with the last name first, e.g. "Smith, John."."
|
|
144
|
+
},
|
|
145
|
+
date: {
|
|
146
|
+
label: 'Date',
|
|
147
|
+
help_text: 'A date for the work.'
|
|
148
|
+
},
|
|
149
|
+
date_accepted: {
|
|
150
|
+
label: 'Date accepted'
|
|
151
|
+
},
|
|
152
|
+
date_available: {
|
|
153
|
+
schema_org: {
|
|
154
|
+
property: "datePublished"
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
date_collected: {
|
|
158
|
+
label: 'Date collected'
|
|
159
|
+
},
|
|
160
|
+
date_copyrighted: {
|
|
161
|
+
label: 'Date copyrighted'
|
|
162
|
+
},
|
|
163
|
+
date_created: {
|
|
164
|
+
schema_org: {
|
|
165
|
+
property: "dateCreated"
|
|
166
|
+
},
|
|
167
|
+
help_text: "The date on which the work was created."
|
|
168
|
+
},
|
|
169
|
+
date_issued: {
|
|
170
|
+
label: 'Date issued'
|
|
171
|
+
},
|
|
172
|
+
# Only used for the date range facet
|
|
173
|
+
date_range: {
|
|
174
|
+
label: 'Date range'
|
|
175
|
+
},
|
|
176
|
+
date_published: {
|
|
177
|
+
schema_org: {
|
|
178
|
+
property: "datePublished"
|
|
179
|
+
},
|
|
180
|
+
label: 'Publication date'
|
|
181
|
+
},
|
|
182
|
+
date_submitted: {
|
|
183
|
+
label: 'Date submitted'
|
|
184
|
+
},
|
|
185
|
+
date_of_award: {
|
|
186
|
+
label: 'Date of award'
|
|
187
|
+
},
|
|
188
|
+
date_updated: {
|
|
189
|
+
helper_method: :human_readable_date
|
|
190
|
+
},
|
|
191
|
+
date_valid: {
|
|
192
|
+
label: 'Date valid'
|
|
193
|
+
},
|
|
194
|
+
dc_access_rights: {
|
|
195
|
+
label: 'Access rights'
|
|
196
|
+
},
|
|
197
|
+
department: {
|
|
198
|
+
label: 'Department, School or Faculty'
|
|
199
|
+
},
|
|
200
|
+
description: {
|
|
201
|
+
label: 'Description or summary',
|
|
202
|
+
helper_method: :truncate_text_and_iconify_link,
|
|
203
|
+
schema_org: {
|
|
204
|
+
property: "description"
|
|
205
|
+
},
|
|
206
|
+
help_text: "Free-text notes about the work. Examples include abstracts of a paper or citation information for a journal article."
|
|
207
|
+
},
|
|
208
|
+
doi: {
|
|
209
|
+
schema_org: {
|
|
210
|
+
property: "identifier"
|
|
211
|
+
},
|
|
212
|
+
label: 'DOI',
|
|
213
|
+
help_text: 'Digital Object Identifier (DOI) for the work.'
|
|
214
|
+
},
|
|
215
|
+
edition: {
|
|
216
|
+
label: 'Edition',
|
|
217
|
+
schema_org: {
|
|
218
|
+
property: "version"
|
|
219
|
+
}
|
|
220
|
+
},
|
|
221
|
+
editor: {
|
|
222
|
+
label: 'Editor',
|
|
223
|
+
schema_org: {
|
|
224
|
+
property: "editor"
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
extent: {
|
|
228
|
+
label: 'Extent'
|
|
229
|
+
},
|
|
230
|
+
event_date: {
|
|
231
|
+
label: 'Date of event'
|
|
232
|
+
},
|
|
233
|
+
start_date: {
|
|
234
|
+
label: 'Start date'
|
|
235
|
+
},
|
|
236
|
+
end_date: {
|
|
237
|
+
label: 'End date'
|
|
238
|
+
},
|
|
239
|
+
dc_format: {
|
|
240
|
+
label: 'Format'
|
|
241
|
+
},
|
|
242
|
+
former_identifier: {
|
|
243
|
+
label: 'Former identifier',
|
|
244
|
+
schema_org: {
|
|
245
|
+
property: "identifier"
|
|
246
|
+
},
|
|
247
|
+
help_text: 'A former identifier, URL or other reference for the work.'
|
|
248
|
+
},
|
|
249
|
+
funder: {
|
|
250
|
+
label: 'Funder',
|
|
251
|
+
schema_org: {
|
|
252
|
+
property: "funder"
|
|
253
|
+
},
|
|
254
|
+
help_text: 'Funding body or oraganisation funding the work.'
|
|
255
|
+
},
|
|
256
|
+
has_restriction: {
|
|
257
|
+
label: 'Restriction note'
|
|
258
|
+
},
|
|
259
|
+
human_readable_type: {
|
|
260
|
+
label: 'Type',
|
|
261
|
+
schema_org: {
|
|
262
|
+
'Conference Item' => 'http://schema.org/ScholarlyArticle',
|
|
263
|
+
'Dataset' => 'http://schema.org/Dataset',
|
|
264
|
+
'Exam Paper' => 'http://schema.org/CreativeWork',
|
|
265
|
+
'Journal Article' => 'http://schema.org/ScholarlyArticle',
|
|
266
|
+
'Package' => 'http://schema.org/Dataset',
|
|
267
|
+
'Published Work' => 'http://schema.org/CreativeWork'
|
|
268
|
+
}
|
|
269
|
+
},
|
|
270
|
+
identifier: {
|
|
271
|
+
label: 'Identifier',
|
|
272
|
+
helper_method: :index_field_link,
|
|
273
|
+
schema_org: {
|
|
274
|
+
property: "identifier"
|
|
275
|
+
},
|
|
276
|
+
help_text: "A unique handle identifying the work. An example would be a DOI for a journal article, or an ISBN or OCLC number for a book."
|
|
277
|
+
},
|
|
278
|
+
isbn: {
|
|
279
|
+
schema_org: {
|
|
280
|
+
property: "identifier"
|
|
281
|
+
},
|
|
282
|
+
label: 'ISBN',
|
|
283
|
+
help_text: 'The International Standard Book Number for the work.'
|
|
284
|
+
},
|
|
285
|
+
issue_number: {
|
|
286
|
+
schema_org: {
|
|
287
|
+
property: "issueNumber"
|
|
288
|
+
},
|
|
289
|
+
label: 'Issue'
|
|
290
|
+
},
|
|
291
|
+
journal: {
|
|
292
|
+
schema_org: {
|
|
293
|
+
property: "isPartOf",
|
|
294
|
+
type: "http://schema.org/CreativeWork",
|
|
295
|
+
value: "name"
|
|
296
|
+
},
|
|
297
|
+
label: 'Journal name'
|
|
298
|
+
},
|
|
299
|
+
keyword: {
|
|
300
|
+
index: [{ link_to_search: true }],
|
|
301
|
+
label: 'Keywords',
|
|
302
|
+
schema_org: {
|
|
303
|
+
property: "keywords"
|
|
304
|
+
},
|
|
305
|
+
help_text: "Words or phrases you select to describe what the work is about. These are used to search for content."
|
|
306
|
+
},
|
|
307
|
+
language: {
|
|
308
|
+
index: [{ link_to_search: true }],
|
|
309
|
+
label: 'Language',
|
|
310
|
+
schema_org: {
|
|
311
|
+
property: "language"
|
|
312
|
+
},
|
|
313
|
+
help_text: "The language of the work's content."
|
|
314
|
+
},
|
|
315
|
+
last_access: {
|
|
316
|
+
label: 'Date of last access'
|
|
317
|
+
},
|
|
318
|
+
lat: {
|
|
319
|
+
label: 'Latitude'
|
|
320
|
+
},
|
|
321
|
+
license: {
|
|
322
|
+
label: 'License',
|
|
323
|
+
helper_method: :license_links,
|
|
324
|
+
render_as: :license,
|
|
325
|
+
help_text: "Licensing and distribution information governing access to the work. Select from the provided drop-down list."
|
|
326
|
+
},
|
|
327
|
+
location: {
|
|
328
|
+
label: 'Location'
|
|
329
|
+
},
|
|
330
|
+
long: {
|
|
331
|
+
label: 'Longitude'
|
|
332
|
+
},
|
|
333
|
+
managing_organisation: {
|
|
334
|
+
label: 'Managing organisation'
|
|
335
|
+
},
|
|
336
|
+
module_code: {
|
|
337
|
+
schema_org: {
|
|
338
|
+
property: "identifier"
|
|
339
|
+
},
|
|
340
|
+
label: 'Module code'
|
|
341
|
+
},
|
|
342
|
+
note: {
|
|
343
|
+
label: 'Note',
|
|
344
|
+
schema_org: {
|
|
345
|
+
property: "note"
|
|
346
|
+
},
|
|
347
|
+
help_text: "A general note about the work."
|
|
348
|
+
},
|
|
349
|
+
number_of_downloads: {
|
|
350
|
+
label: 'Number of downloads'
|
|
351
|
+
},
|
|
352
|
+
official_url: {
|
|
353
|
+
schema_org: {
|
|
354
|
+
property: "significantLink"
|
|
355
|
+
},
|
|
356
|
+
label: 'Official URL',
|
|
357
|
+
render_as: :external_link
|
|
358
|
+
},
|
|
359
|
+
output_of: {
|
|
360
|
+
label: 'Output of project or grant'
|
|
361
|
+
},
|
|
362
|
+
package_ids: {
|
|
363
|
+
label: "Package contains",
|
|
364
|
+
help_text: 'Packages these works. Customarily, the package is a digital preservation AIP or DIP.',
|
|
365
|
+
render_as: :package_ids
|
|
366
|
+
},
|
|
367
|
+
packaged_by_ids: {
|
|
368
|
+
label: "In package",
|
|
369
|
+
help_text: 'Packaged by the following work. Customarily, the package is a digital preservation AIP or DIP.',
|
|
370
|
+
render_as: :packaged_by_ids
|
|
371
|
+
},
|
|
372
|
+
packaged_by_titles: {
|
|
373
|
+
label: "In package"
|
|
374
|
+
},
|
|
375
|
+
pagination: {
|
|
376
|
+
schema_org: {
|
|
377
|
+
property: "pagination"
|
|
378
|
+
},
|
|
379
|
+
label: 'Pages'
|
|
380
|
+
},
|
|
381
|
+
part: {
|
|
382
|
+
label: 'Part name',
|
|
383
|
+
schema_org: {
|
|
384
|
+
property: "isPartOf",
|
|
385
|
+
type: "http://schema.org/CreativeWork",
|
|
386
|
+
value: "name"
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
place_of_publication: {
|
|
390
|
+
label: 'Place of publication',
|
|
391
|
+
schema_org: {
|
|
392
|
+
property: "location",
|
|
393
|
+
type: "http://schema.org/Place",
|
|
394
|
+
value: "name"
|
|
395
|
+
}
|
|
396
|
+
},
|
|
397
|
+
presented_at: {
|
|
398
|
+
label: 'Presented at',
|
|
399
|
+
schema_org: {
|
|
400
|
+
property: "workPerformed",
|
|
401
|
+
type: "http://schema.org/Event",
|
|
402
|
+
value: "name"
|
|
403
|
+
}
|
|
404
|
+
},
|
|
405
|
+
part_of: {
|
|
406
|
+
label: 'Part of',
|
|
407
|
+
help_text: "A Work that this this physically or logically contained in, such as a conference proceeding, or series.",
|
|
408
|
+
schema_org: {
|
|
409
|
+
property: "isPartOf",
|
|
410
|
+
type: "http://schema.org/CreativeWork",
|
|
411
|
+
value: "name"
|
|
412
|
+
}
|
|
413
|
+
},
|
|
414
|
+
publication_status: {
|
|
415
|
+
label: 'Publication status',
|
|
416
|
+
render_as: 'publication_status',
|
|
417
|
+
helper_method: 'publication_status'
|
|
418
|
+
},
|
|
419
|
+
publisher: {
|
|
420
|
+
index: [{ link_to_search: true }],
|
|
421
|
+
schema_org: {
|
|
422
|
+
property: "publisher",
|
|
423
|
+
type: "http://schema.org/Organization",
|
|
424
|
+
value: "name"
|
|
425
|
+
},
|
|
426
|
+
help_text: "The person or group making the work available. Generally this is the institution.",
|
|
427
|
+
label: 'Publisher'
|
|
428
|
+
},
|
|
429
|
+
qualification_level: {
|
|
430
|
+
label: 'Qualification level'
|
|
431
|
+
},
|
|
432
|
+
qualification_name: {
|
|
433
|
+
label: 'Qualification name'
|
|
434
|
+
},
|
|
435
|
+
refereed: {
|
|
436
|
+
label: 'Peer reviewed?'
|
|
437
|
+
},
|
|
438
|
+
related_url: {
|
|
439
|
+
schema_org: {
|
|
440
|
+
property: "relatedLink"
|
|
441
|
+
},
|
|
442
|
+
render_as: :external_link,
|
|
443
|
+
help_text: "A link to a website or other specific content (audio, video, PDF document) related to the work. An example is the URL of a research project from which the work was derived.",
|
|
444
|
+
label: 'Related URL'
|
|
445
|
+
},
|
|
446
|
+
resource_type: {
|
|
447
|
+
index: [{ link_to_search: true }],
|
|
448
|
+
schema_org: {
|
|
449
|
+
'Article' => "http://schema.org/Article",
|
|
450
|
+
'Audio' => "http://schema.org/AudioObject",
|
|
451
|
+
'Book' => "http://schema.org/Book",
|
|
452
|
+
'Conference Proceeding' => "http://schema.org/ScholarlyArticle",
|
|
453
|
+
'Dataset' => "http://schema.org/Dataset",
|
|
454
|
+
'Dissertation' => "http://schema.org/ScholarlyArticle",
|
|
455
|
+
'Image' => "http://schema.org/ImageObject",
|
|
456
|
+
'Map or Cartographic Material' => "http://schema.org/Map",
|
|
457
|
+
'Masters Thesis' => "http://schema.org/ScholarlyArticle",
|
|
458
|
+
'Part of Book' => "http://schema.org/Book",
|
|
459
|
+
'Research Paper' => "http://schema.org/ScholarlyArticle",
|
|
460
|
+
'Software or Program Code' => "http://schema.org/Code",
|
|
461
|
+
'Video' => "http://schema.org/VideoObject"
|
|
462
|
+
},
|
|
463
|
+
label: 'Resource type',
|
|
464
|
+
help_text: "Pre-defined categories to describe the type of content being uploaded, such as "article" or "dataset." More than one type may be selected."
|
|
465
|
+
},
|
|
466
|
+
# datacite-specific
|
|
467
|
+
resource_type_general: {
|
|
468
|
+
schema_org: {
|
|
469
|
+
'Audiovisual' => "http://schema.org/MediaObject",
|
|
470
|
+
'Collection' => "http://bib.schema.org/Collection",
|
|
471
|
+
'DataPaper' => "http://schema.org/CreativeWork",
|
|
472
|
+
'Dataset' => "http://schema.org/Dataset",
|
|
473
|
+
'Event' => "http://schema.org/Event",
|
|
474
|
+
'Image' => "http://schema.org/ImageObject",
|
|
475
|
+
'InteractiveResource' => "http://schema.org/CreativeWork",
|
|
476
|
+
'Model' => "http://schema.org/CreativeWork",
|
|
477
|
+
'PhysicalObject' => "http://schema.org/Thing",
|
|
478
|
+
'Service' => "http://schema.org/Service",
|
|
479
|
+
'Software' => "http://schema.org/Code",
|
|
480
|
+
'Sound' => "http://schema.org/AudioObject",
|
|
481
|
+
'Text' => "http://schema.org/CreativeWork",
|
|
482
|
+
'Workflow' => "http://schema.org/CreativeWork",
|
|
483
|
+
'Other' => "http://schema.org/Thing"
|
|
484
|
+
},
|
|
485
|
+
label: 'General resource type'
|
|
486
|
+
},
|
|
487
|
+
rights_statement: {
|
|
488
|
+
helper_method: :rights_statement_links,
|
|
489
|
+
render_as: :rights_statement,
|
|
490
|
+
label: 'Rights statement'
|
|
491
|
+
},
|
|
492
|
+
series: {
|
|
493
|
+
schema_org: {
|
|
494
|
+
property: "isPartOf",
|
|
495
|
+
type: "http://schema.org/CreativeWork",
|
|
496
|
+
value: "name"
|
|
497
|
+
},
|
|
498
|
+
label: 'Series'
|
|
499
|
+
},
|
|
500
|
+
source: {
|
|
501
|
+
label: 'Source'
|
|
502
|
+
},
|
|
503
|
+
subject: {
|
|
504
|
+
index: [{ link_to_search: true }],
|
|
505
|
+
schema_org: {
|
|
506
|
+
property: "about",
|
|
507
|
+
type: "http://schema.org/Thing",
|
|
508
|
+
value: "name"
|
|
509
|
+
},
|
|
510
|
+
help_text: "Headings or index terms describing what the work is about; these do need to conform to an existing vocabulary.",
|
|
511
|
+
label: 'Subject'
|
|
512
|
+
},
|
|
513
|
+
subtitle: {
|
|
514
|
+
schema_org: {
|
|
515
|
+
property: "name"
|
|
516
|
+
},
|
|
517
|
+
label: 'Subtitle'
|
|
518
|
+
},
|
|
519
|
+
title: {
|
|
520
|
+
index: [{ if: false }],
|
|
521
|
+
schema_org: {
|
|
522
|
+
property: "name"
|
|
523
|
+
},
|
|
524
|
+
label: 'Title',
|
|
525
|
+
help_text: "A name to aid in identifying a work."
|
|
526
|
+
},
|
|
527
|
+
volume_number: {
|
|
528
|
+
schema_org: {
|
|
529
|
+
property: "volumeNumber"
|
|
530
|
+
},
|
|
531
|
+
label: 'Volume'
|
|
532
|
+
},
|
|
533
|
+
aip_uuid: {
|
|
534
|
+
label: 'AIP UUID'
|
|
535
|
+
},
|
|
536
|
+
transfer_uuid: {
|
|
537
|
+
label: 'Transfer UUID'
|
|
538
|
+
},
|
|
539
|
+
sip_uuid: {
|
|
540
|
+
label: 'SIP UUID'
|
|
541
|
+
},
|
|
542
|
+
dip_uuid: {
|
|
543
|
+
label: 'DIP UUID'
|
|
544
|
+
},
|
|
545
|
+
aip_status: {
|
|
546
|
+
label: 'AIP Status'
|
|
547
|
+
},
|
|
548
|
+
dip_status: {
|
|
549
|
+
label: 'DIP Status'
|
|
550
|
+
},
|
|
551
|
+
aip_size: {
|
|
552
|
+
label: 'AIP Size'
|
|
553
|
+
},
|
|
554
|
+
dip_size: {
|
|
555
|
+
label: 'DIP Size'
|
|
556
|
+
},
|
|
557
|
+
aip_current_path: {
|
|
558
|
+
label: 'AIP Current Path'
|
|
559
|
+
},
|
|
560
|
+
dip_current_path: {
|
|
561
|
+
label: 'DIP Current Path'
|
|
562
|
+
},
|
|
563
|
+
aip_current_location: {
|
|
564
|
+
label: 'AIP Current Location'
|
|
565
|
+
},
|
|
566
|
+
dip_current_location: {
|
|
567
|
+
label: 'DIP Current Location'
|
|
568
|
+
},
|
|
569
|
+
aip_resource_uri: {
|
|
570
|
+
label: 'AIP Resource URI'
|
|
571
|
+
},
|
|
572
|
+
dip_resource_uri: {
|
|
573
|
+
label: 'DIP Resource URI'
|
|
574
|
+
},
|
|
575
|
+
origin_pipeline: {
|
|
576
|
+
label: 'Origin Pipeline'
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
end
|
|
580
|
+
end
|
|
581
|
+
end
|
|
582
|
+
|
|
583
|
+
# rubocop:enable Metrics/LineLength
|
|
584
|
+
# rubocop:enable Metrics/MethodLength
|
|
585
|
+
# rubocop:enable Metrics/ModuleLength
|