Module: C2eCore::Drops::Helpers::FinancialReportConversions
- Includes:
- ActionView::Helpers::NumberHelper
- Included in:
- FinancialReportCreditTransferDrop, FinancialReportDrop, FinancialReportPaymentTypeDrop, FinancialReportVatDrop
- Defined in:
- /build/app/mailers/c2e_core/drops/helpers/financial_report_conversions.rb
Instance Method Summary collapse
-
#converted_price(value) ⇒ Object
include only to classes with @financial_report variable.
- #format_price(value) ⇒ Object
Instance Method Details
#converted_price(value) ⇒ Object
include only to classes with @financial_report variable
10 11 12 |
# File '/build/app/mailers/c2e_core/drops/helpers/financial_report_conversions.rb', line 10 def converted_price(value) @financial_report.currency.convert_and_round(Currency.internal, value) end |
#format_price(value) ⇒ Object
14 15 16 |
# File '/build/app/mailers/c2e_core/drops/helpers/financial_report_conversions.rb', line 14 def format_price(value) number_to_currency(value, unit: @financial_report.currency.to_s) end |