Sha256: 6283116cea827135a23be46af5f605e5658b9ed183393a9af332350440844ed1

Contents?: true

Size: 215 Bytes

Versions: 8

Compression:

Stored size: 215 Bytes

Contents

module Tramway::Core::Concerns::AttributesDecoratorHelper
  def datetime_view(value)
    I18n.l value
  end

  def state_machine_view(object, attribute_name)
    object.send "human_#{attribute_name}_name"
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
tramway-core-1.10.1 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.10 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.9.3 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.9.2 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.9.1 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.9 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.8.1 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb
tramway-core-1.9.8 app/decorators/tramway/core/concerns/attributes_decorator_helper.rb