Update Stripe importer to rename tax field
This reflects the current CSV output from the "Export" button.
This commit is contained in:
parent
950c7fd644
commit
5f1315b4e4
1 changed files with 3 additions and 4 deletions
|
@ -1,15 +1,14 @@
|
||||||
import decimal
|
|
||||||
|
|
||||||
from . import _csv
|
from . import _csv
|
||||||
from .. import strparse
|
from .. import strparse
|
||||||
|
|
||||||
|
|
||||||
class PaymentImporter(_csv.CSVImporterBase):
|
class PaymentImporter(_csv.CSVImporterBase):
|
||||||
NEEDED_FIELDS = frozenset([
|
NEEDED_FIELDS = frozenset([
|
||||||
'Converted Currency',
|
'Converted Currency',
|
||||||
'Created (UTC)',
|
'Created (UTC)',
|
||||||
'Fee',
|
'Fee',
|
||||||
'Status',
|
'Status',
|
||||||
'Tax',
|
'Taxes On Fee',
|
||||||
])
|
])
|
||||||
COPIED_FIELDS = {
|
COPIED_FIELDS = {
|
||||||
'Card Name': 'payee',
|
'Card Name': 'payee',
|
||||||
|
@ -31,7 +30,7 @@ class PaymentImporter(_csv.CSVImporterBase):
|
||||||
'currency': row['Converted Currency'].upper(),
|
'currency': row['Converted Currency'].upper(),
|
||||||
'date': strparse.date(date_s, self.DATE_FMT),
|
'date': strparse.date(date_s, self.DATE_FMT),
|
||||||
'fee': strparse.currency_decimal(row['Fee']),
|
'fee': strparse.currency_decimal(row['Fee']),
|
||||||
'tax': strparse.currency_decimal(row['Tax']),
|
'tax': strparse.currency_decimal(row['Taxes On Fee']),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue