[IMP] account_chart_update: Whole refactoring

* Fix calculated field when showing inactives + add field to view
* Migrated to new API.
* Provided hooks for detecting changes and for adding update/create values.
* Purge dead error detection code (not applying).
* Use global mapping dictionaries stored on class instead of passing arguments down to top and viceversa.
* Number fields computed by a function field instead of being computed by hand.
* Use recordsets as indexes instead of ids to avoid repetitive browses.
* Re-enable local cache variables
* README + authors
This commit is contained in:
Pedro M. Baeza
2015-03-28 14:56:47 +01:00
committed by Luis J. Salvatierra
parent ef73f5ad50
commit bc483a106f
7 changed files with 1041 additions and 1558 deletions

View File

@@ -25,3 +25,13 @@ class AccountTaxCode(models.Model):
_inherit = 'account.tax.code'
active = fields.Boolean('Active', default=True)
def _sum(self, cr, uid, ids, name, args, context, where='',
where_params=()):
try:
return super(AccountTaxCode, self)._sum(
cr, uid, ids, name, args, context, where=where,
where_params=where_params)
except:
cr.rollback()
return dict.fromkeys(ids, 0.0)