Sha256: 79cd3e5f104c1a6e9705fad5f856904481bd67abde65e1454ecff78fb44a9af9

Contents?: true

Size: 514 Bytes

Versions: 8

Compression:

Stored size: 514 Bytes

Contents

# frozen_string_literal: true

class ModelMoney < ActiveRecord::Base
  normalizy :text                    , with: :money
  normalizy :cents_type              , with: { money: { type: :cents } }
  normalizy :cast_to_i               , with: { money: { cast: :to_i } }
  normalizy :cast_to_d               , with: { money: { cast: :to_d } }
  normalizy :cents_type_and_cast_to_f, with: { money: { cast: :to_f, type: :cents } }
  normalizy :cents_type_and_cast_to_i, with: { money: { cast: :to_i, type: :cents } }
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
normalizy-1.5.0 spec/support/models/model_money.rb
normalizy-1.4.0 spec/support/models/model_money.rb
normalizy-1.3.0 spec/support/models/model_money.rb
normalizy-1.2.0 spec/support/models/model_money.rb
normalizy-1.1.1 spec/support/models/model_money.rb
normalizy-1.1.0 spec/support/models/model_money.rb
normalizy-1.0.1 spec/support/models/model_money.rb
normalizy-1.0.0 spec/support/models/model_money.rb