banking-addons-team team mailing list archive
-
banking-addons-team team
-
Mailing list archive
-
Message #01227
lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
Pedro Manuel Baeza has proposed merging lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp 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/~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp/+merge/200022
Improved system to inherit selection of the different import types, because as it was, you have to redefine the field on each extension module, due to OpenERP doesn't allow direct inheritance on selection methods.
Now, the selection method calls another private method that can be inherited without problems.
--
https://code.launchpad.net/~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp/+merge/200022
Your team Banking Addons Core Editors is requested to review the proposed merge of lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0.
=== modified file 'account_statement_base_import/statement.py'
--- account_statement_base_import/statement.py 2013-09-12 09:05:01 +0000
+++ account_statement_base_import/statement.py 2013-12-24 18:21:26 +0000
@@ -31,11 +31,12 @@
class AccountStatementProfil(Model):
_inherit = "account.statement.profile"
+ def _get_import_type_selection(self, cr, uid, context=None):
+ """This is the method to be inherited for adding the parser"""
+ return [('generic_csvxls_so', 'Generic .csv/.xls based on SO Name')]
+
def get_import_type_selection(self, cr, uid, context=None):
- """
- Has to be inherited to add parser
- """
- return [('generic_csvxls_so', 'Generic .csv/.xls based on SO Name')]
+ return _get_import_type selection(cr, uid, context=context)
_columns = {
'launch_import_completion': fields.boolean(
=== modified file 'account_statement_ofx_import/statement.py'
--- account_statement_ofx_import/statement.py 2013-11-04 12:22:39 +0000
+++ account_statement_ofx_import/statement.py 2013-12-24 18:21:26 +0000
@@ -24,7 +24,7 @@
class AccountStatementProfil(orm.Model):
_inherit = "account.statement.profile"
- def get_import_type_selection(self, cr, uid, context=None):
+ def _get_import_type_selection(self, cr, uid, context=None):
"""
Inherited from parent to add parser.
"""
@@ -33,14 +33,3 @@
context=context)
selection.append(('ofx_so', _('OFX - Open Financial Exchange')))
return selection
-
- _columns = {
- 'import_type': fields.selection(
- get_import_type_selection,
- 'Type of import',
- required=True,
- help="Choose here the method by which you want to import bank"
- "statement for this profile."),
-
- }
-
Follow ups
-
[Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: noreply, 2014-02-28
-
[Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Guewen Baconnier @ Camptocamp, 2014-02-28
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Joël Grand-Guillaume, 2014-02-25
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Pedro Manuel Baeza, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Christophe Combelles, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Pedro Manuel Baeza, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Christophe Combelles, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Pedro Manuel Baeza, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Christophe Combelles, 2014-02-24
-
Re: [Merge] lp:~pedro.baeza/banking-addons/bank-statement-reconcile-70-import_imp into lp:banking-addons/bank-statement-reconcile-7.0
From: Guewen Baconnier @ Camptocamp, 2014-01-31