Class: CFONB::OperationDetails::FEE
- Defined in:
- lib/cfonb/operation_details/fee.rb
Constant Summary collapse
- ATTRIBUTES =
%i[fee fee_currency].freeze
Class Method Summary collapse
Methods inherited from Base
Class Method Details
.apply(details, line) ⇒ Object
8 9 10 11 12 13 |
# File 'lib/cfonb/operation_details/fee.rb', line 8 def self.apply(details, line) details.fee_currency = line.detail[0..2] scale = line.detail[3].to_i details.fee = BigDecimal(line.detail[4..17]) / (10**scale) end |