Class: Hyrax::FormMetadataService
- Inherits:
-
HydraEditor::FieldMetadataService
- Object
- HydraEditor::FieldMetadataService
- Hyrax::FormMetadataService
- Defined in:
- app/services/hyrax/form_metadata_service.rb
Overview
Answers queries about the cardinality of each field on the form.
Class Method Summary collapse
-
.multiple?(model_class, field) ⇒ Boolean
True if the passed in field is a multivalued field.
Class Method Details
.multiple?(model_class, field) ⇒ Boolean
Returns true if the passed in field is a multivalued field.
7 8 9 10 11 12 13 14 15 16 17 |
# File 'app/services/hyrax/form_metadata_service.rb', line 7 def self.multiple?(model_class, field) case field.to_s when 'rights_statement' false when 'ordered_member_ids', 'in_works_ids', 'member_of_collection_ids' true else # Inquire at the model level super end end |