mirror of
https://github.com/gwenhael-le-moine/ledgerrb.git
synced 2025-01-28 07:58:29 +01:00
percentage and amounts as numbers
This commit is contained in:
parent
b6b1f30ccf
commit
39c77c4333
1 changed files with 3 additions and 3 deletions
|
@ -85,9 +85,9 @@ module Ledger
|
|||
ary = line.split
|
||||
|
||||
{ currency: ary[1],
|
||||
amount: ary[0],
|
||||
budget: ary[2],
|
||||
percentage: ary.last( 2 ).first,
|
||||
amount: ary[0].to_f,
|
||||
budget: ary[2].to_f,
|
||||
percentage: ary.last( 2 ).first.gsub( /%/, '' ).to_f,
|
||||
account: ary.last }
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue