app/indexers/work_indexer.rb
# field is a symbol/controlled property
# returns an array of Hyrax::ControlledVocabularies::[field]
field is a symbol/controlled property
returns an array of Hyrax::ControlledVocabularies::[field]
field is a symbol / controlled property returns an array of Hyrax :: ControlledVocabularies :: [ field ]
def to_controlled_vocab(field)
    if field.to_s == "based_near"
      class_name = "Hyrax::ControlledVocabularies::Location".constantize
    else
      class_name = "Hyrax::ControlledVocabularies::#{field.to_s.camelize}".constantize
    end
    object[field] =  object[field].map do |val|
      val.start_with?("http") ? class_name.new(val.strip) : val
    end
  end
def to_controlled_vocab ( field ) if field . to_s == "based_near" class_name = "Hyrax::ControlledVocabularies::Location" . constantize else class_name = "Hyrax::ControlledVocabularies::#{field.to_s.camelize}" . constantize end object [ field ] = object [ field ] . map do | val | val . start_with? ( "http" ) ? class_name . new ( val . strip ) : val end end
field is a symbol/controlled property
returns an array of Hyrax::ControlledVocabularies::[field]
field is a symbol / controlled property returns an array of Hyrax :: ControlledVocabularies :: [ field ]
field
<not_specific>