← Back to team overview

banking-addons-team team mailing list archive

lp:~akretion-team/banking-addons/bank-statement-reconcile-70-easy-reconcile-multi-company into lp:banking-addons/bank-statement-reconcile-7.0

 

Sébastien BEAU - http://www.akretion.com has proposed merging lp:~akretion-team/banking-addons/bank-statement-reconcile-70-easy-reconcile-multi-company into lp:banking-addons/bank-statement-reconcile-7.0.

Requested reviews:
  Banking Addons Core Editors (banking-addons-team)

For more details, see:
https://code.launchpad.net/~akretion-team/banking-addons/bank-statement-reconcile-70-easy-reconcile-multi-company/+merge/199592

Just adding a default value for the company id 
-- 
https://code.launchpad.net/~akretion-team/banking-addons/bank-statement-reconcile-70-easy-reconcile-multi-company/+merge/199592
Your team Banking Addons Core Editors is requested to review the proposed merge of lp:~akretion-team/banking-addons/bank-statement-reconcile-70-easy-reconcile-multi-company into lp:banking-addons/bank-statement-reconcile-7.0.
=== modified file 'account_easy_reconcile/easy_reconcile.py'
--- account_easy_reconcile/easy_reconcile.py	2013-02-13 15:54:48 +0000
+++ account_easy_reconcile/easy_reconcile.py	2013-12-19 00:02:04 +0000
@@ -191,6 +191,11 @@
         'company_id': fields.many2one('res.company', 'Company'),
     }
 
+    _default = {
+        'company_id': lambda s,cr,uid,c: s.pool.get('res.company').\
+            _company_default_get(cr, uid, 'prestashop.backend', context=c),
+    }
+
     def _prepare_run_transient(self, cr, uid, rec_method, context=None):
         return {'account_id': rec_method.task_id.account.id,
                 'write_off': rec_method.write_off,