mirror of
https://github.com/aclindsa/ofxgo.git
synced 2025-06-14 13:58:37 -04:00
Bank Transactions: Use Currency structs, not CurrSymbol directly
This commit is contained in:
@ -78,9 +78,9 @@ func bankTransactions() {
|
||||
func printTransaction(defCurrency ofxgo.CurrSymbol, tran *ofxgo.Transaction) {
|
||||
currency := defCurrency
|
||||
if ok, _ := tran.Currency.Valid(); ok {
|
||||
currency = tran.Currency
|
||||
currency = tran.Currency.CurSym
|
||||
} else if ok, _ := tran.OrigCurrency.Valid(); ok {
|
||||
currency = tran.OrigCurrency
|
||||
currency = tran.OrigCurrency.CurSym
|
||||
}
|
||||
|
||||
var name string
|
||||
|
@ -61,9 +61,9 @@ func ccTransactions() {
|
||||
for _, tran := range stmt.BankTranList.Transactions {
|
||||
currency := stmt.CurDef
|
||||
if ok, _ := tran.Currency.Valid(); ok {
|
||||
currency = tran.Currency
|
||||
currency = tran.Currency.CurSym
|
||||
} else if ok, _ := tran.OrigCurrency.Valid(); ok {
|
||||
currency = tran.OrigCurrency
|
||||
currency = tran.OrigCurrency.CurSym
|
||||
}
|
||||
|
||||
var name string
|
||||
|
Reference in New Issue
Block a user