Commit 56ab13c5 authored by Bruno Chabrier's avatar Bruno Chabrier

Ofx formatter now uses ACCTTYPE string instead of numeric

Closes #208
parent 066952a1
Pipeline #1951 passed with stages
in 15 minutes and 20 seconds
......@@ -32,7 +32,7 @@ from weboob.exceptions import BrowserHTTPError, CaptchaQuestion
from weboob.core.bcall import CallErrors
from weboob.capabilities.base import empty, find_object
from weboob.capabilities.bank import (
Account, Transaction,
Account, AccountType, Transaction,
Transfer, TransferStep, Recipient, AddRecipientStep,
CapBank, CapBankTransfer, CapBankWealth, CapBankPockets,
TransferInvalidLabel, TransferInvalidAmount, TransferInvalidDate,
......@@ -105,7 +105,7 @@ class OfxFormatter(IFormatter):
self.output(u'<BANKID>null')
self.output(u'<BRANCHID>null')
self.output(u'<ACCTID>%s' % account.id)
self.output(u'<ACCTTYPE>%s' % self.account_type)
self.output(u'<ACCTTYPE>%s' % AccountType._keys[self.account_type])
self.output(u'<ACCTKEY>null')
self.output('</CCACCTFROM>')
else:
......@@ -115,7 +115,7 @@ class OfxFormatter(IFormatter):
self.output(u'<BANKID>null')
self.output(u'<BRANCHID>null')
self.output(u'<ACCTID>%s' % account.id)
self.output(u'<ACCTTYPE>%s' % self.account_type)
self.output(u'<ACCTTYPE>%s' % AccountType._keys[self.account_type])
self.output(u'<ACCTKEY>null')
self.output('</BANKACCTFROM>')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment