Module: Hyrax::HumanReadableType::ClassMethods

Defined in:
app/models/concerns/hyrax/human_readable_type.rb

Instance Method Summary collapse

Instance Method Details

#human_readable_typeObject



6
7
8
9
# File 'app/models/concerns/hyrax/human_readable_type.rb', line 6

def human_readable_type
  default = @_human_readable_type || name.demodulize.titleize
  I18n.translate("activefedora.models.#{model_name.i18n_key}", default: default)
end

#human_readable_type=(val) ⇒ Object



11
12
13
# File 'app/models/concerns/hyrax/human_readable_type.rb', line 11

def human_readable_type=(val)
  @_human_readable_type = val
end