Class: C2eCore::Drops::CreditsRewardDrop
- Defined in:
- /build/app/mailers/c2e_core/drops/credits_reward_drop.rb
Instance Method Summary collapse
-
#amount ⇒ Float
-
Amount.
-
-
#cash_payment_decimals ⇒ Integer
-
The number of decimal places the ‘amount` should be rounded to.
-
-
#formatted_amount ⇒ String
-
Formatted value of ‘amount`.
-
-
#initialize(reward) ⇒ CreditsRewardDrop
constructor
A new instance of CreditsRewardDrop.
Constructor Details
#initialize(reward) ⇒ CreditsRewardDrop
Returns a new instance of CreditsRewardDrop.
6 7 8 9 |
# File '/build/app/mailers/c2e_core/drops/credits_reward_drop.rb', line 6 def initialize(reward) super() @reward = reward end |
Instance Method Details
#amount ⇒ Float
Returns - Amount.
12 13 14 |
# File '/build/app/mailers/c2e_core/drops/credits_reward_drop.rb', line 12 def amount @reward.amount end |
#cash_payment_decimals ⇒ Integer
Returns - The number of decimal places the ‘amount` should be rounded to.
22 23 24 |
# File '/build/app/mailers/c2e_core/drops/credits_reward_drop.rb', line 22 def cash_payment_decimals @reward.cash_payment_decimals end |
#formatted_amount ⇒ String
Returns - Formatted value of ‘amount`.
17 18 19 |
# File '/build/app/mailers/c2e_core/drops/credits_reward_drop.rb', line 17 def formatted_amount @reward.formatted_amount end |