[REM] commission computation, this has to be done by account_statement_commission

This commit is contained in:
Yannick Vaucher
2013-11-06 16:23:49 +01:00
parent e9840da124
commit 112a4b5b85

View File

@@ -78,14 +78,3 @@ class TransactionIDFileParser(FileParser):
'label': line.get('label', ''), 'label': line.get('label', ''),
'transaction_id': line.get('transaction_id', '/'), 'transaction_id': line.get('transaction_id', '/'),
'commission_amount': line.get('commission_amount', 0.0)} 'commission_amount': line.get('commission_amount', 0.0)}
def _post(self, *args, **kwargs):
"""
Compute the commission from value of each line
"""
res = super(TransactionIDFileParser, self)._post(*args, **kwargs)
val = 0.0
for row in self.result_row_list:
val += row.get('commission_amount', 0.0)
self.commission_global_amount = val
return res