Skip to content

Commit

Permalink
fix: #41 add 'payment' to ofx transaction types
Browse files Browse the repository at this point in the history
for investment accounts with banking features
  • Loading branch information
redstreet committed Jan 1, 2023
1 parent 75c269c commit 71a0114
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions beancount_reds_importers/libtransactionbuilder/investments.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ def generate_transfer_entry(self, ot, file, counter):
try:
if ot.type in ['transfer']:
units = ot.units
elif ot.type in ['other', 'credit', 'debit', 'dep', 'cash']:
elif ot.type in ['other', 'credit', 'debit', 'dep', 'cash', 'payment']:
units = ot.amount
else:
units = ot.total
Expand Down Expand Up @@ -315,7 +315,7 @@ def extract_transactions(self, file, counter):
if ot.type in ['buymf', 'sellmf', 'buystock', 'sellstock', 'buyother', 'sellother', 'reinvest']:
entry = self.generate_trade_entry(ot, file, counter)
elif ot.type in ['other', 'credit', 'debit', 'transfer', 'dep', 'income',
'dividends', 'capgainsd_st', 'capgainsd_lt', 'cash']:
'dividends', 'capgainsd_st', 'capgainsd_lt', 'cash', 'payment']:
entry = self.generate_transfer_entry(ot, file, counter)
else:
print("ERROR: unknown entry type:", ot.type)
Expand Down

0 comments on commit 71a0114

Please sign in to comment.