Browse Source

camt: crop datetime into date when importing

CreDtTm typically looks like `2014-01-06T16:20:26.673Z`, but odoo expects
just `2014-01-06`.
pull/112/head
Louis Bettens 8 years ago
parent
commit
450baf6093
  1. 1
      account_bank_statement_import_camt/camt.py

1
account_bank_statement_import_camt/camt.py

@ -170,6 +170,7 @@ class CamtParser(object):
ns, node, './ns:Id', result, 'name') ns, node, './ns:Id', result, 'name')
self.add_value_from_node( self.add_value_from_node(
ns, node, './ns:CreDtTm', result, 'date') ns, node, './ns:CreDtTm', result, 'date')
result['date'] = result['date'].split('T')[0]
self.add_value_from_node( self.add_value_from_node(
ns, node, './ns:Acct/ns:Ccy', result, 'currency') ns, node, './ns:Acct/ns:Ccy', result, 'currency')
result['balance_start'], result['balance_end_real'] = ( result['balance_start'], result['balance_end_real'] = (

Loading…
Cancel
Save