← Back to team overview

banking-addons-team team mailing list archive

lp:~akretion-team/banking-addons/bank-statement-reconcile-70-fix-api 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-fix-api into lp:banking-addons/bank-statement-reconcile-7.0.

Requested reviews:
  Nicolas Bessi - Camptocamp (nbessi-c2c)
  Guewen Baconnier @ Camptocamp (gbaconnier-c2c)

For more details, see:
https://code.launchpad.net/~akretion-team/banking-addons/bank-statement-reconcile-70-fix-api/+merge/197776

Just some clean up, not big change
-- 
https://code.launchpad.net/~akretion-team/banking-addons/bank-statement-reconcile-70-fix-api/+merge/197776
Your team Banking Addons Core Editors is subscribed to branch lp:banking-addons/bank-statement-reconcile-7.0.
=== modified file 'account_advanced_reconcile_transaction_ref/account.py'
--- account_advanced_reconcile_transaction_ref/account.py	2013-08-13 15:10:05 +0000
+++ account_advanced_reconcile_transaction_ref/account.py	2013-12-04 18:10:32 +0000
@@ -30,7 +30,7 @@
         'transaction_ref': fields.char('Transaction Ref.', size=128),
     }
     
-class AccountBankSatement(Model):
+class AccountBankStatement(Model):
     """
     Inherit account.bank.statement class in order to set transaction_ref info on account.move.line
     """
@@ -43,7 +43,7 @@
 
         if context is None:
             context = {}
-        res = super(AccountBankSatement, self)._prepare_move_line_vals(
+        res = super(AccountBankStatement, self)._prepare_move_line_vals(
                 cr, uid, st_line, move_id, debit, credit,
                 currency_id=currency_id,
                 amount_currency=amount_currency,

=== modified file 'account_statement_base_completion/statement.py'
--- account_statement_base_completion/statement.py	2013-10-16 08:58:12 +0000
+++ account_statement_base_completion/statement.py	2013-12-04 18:10:32 +0000
@@ -511,7 +511,7 @@
                                  sql_err.pgerror)
 
 
-class AccountBankSatement(orm.Model):
+class AccountBankStatement(orm.Model):
     """
     We add a basic button and stuff to support the auto-completion
     of the bank statement once line have been imported or manually fullfill.

=== 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-04 18:10:32 +0000
@@ -85,7 +85,12 @@
                           context=context)
         return True
 
-    def prepare_statetement_lines_vals(
+    #Deprecated remove on V8
+    def prepare_statetement_lines_vals(self, *args, **kwargs):
+        return super(self, AccountStatementProfil).\
+                prepare_statetement_lines_vals(*args, **kwargs)
+
+    def prepare_statement_lines_vals(
             self, cr, uid, parser_vals, account_payable, account_receivable,
             statement_id, context):
         """
@@ -172,7 +177,7 @@
             statement_store = []
             for line in result_row_list:
                 parser_vals = parser.get_st_line_vals(line)
-                values = self.prepare_statetement_lines_vals(
+                values = self.prepare_statement_lines_vals(
                     cr, uid, parser_vals, account_payable, account_receivable, statement_id,
                     context)
                 statement_store.append(values)
@@ -207,7 +212,6 @@
                                          context)
 
         except Exception:
-            statement_obj.unlink(cr, uid, [statement_id], context=context)
             error_type, error_value, trbk = sys.exc_info()
             st = "Error: %s\nDescription: %s\nTraceback:" % (error_type.__name__, error_value)
             st += ''.join(traceback.format_tb(trbk, 30))

=== modified file 'account_statement_ext/statement.py'
--- account_statement_ext/statement.py	2013-10-16 08:58:12 +0000
+++ account_statement_ext/statement.py	2013-12-04 18:10:32 +0000
@@ -113,7 +113,7 @@
     ]
 
 
-class AccountBankSatement(Model):
+class AccountBankStatement(Model):
     """
     We improve the bank statement class mostly for :
     - Removing the period and compute it from the date of each line.
@@ -202,7 +202,7 @@
             profile_obj = self.pool.get('account.statement.profile')
             profile = profile_obj.browse(cr, uid, vals['profile_id'], context=context)
             vals['journal_id'] = profile.journal_id.id
-        return super(AccountBankSatement, self).create(cr, uid, vals, context=context)
+        return super(AccountBankStatement, self).create(cr, uid, vals, context=context)
 
     def _get_period(self, cr, uid, date, context=None):
         """
@@ -243,7 +243,7 @@
         """
         if context is None:
             context = {}
-        res = super(AccountBankSatement, self)._prepare_move(
+        res = super(AccountBankStatement, self)._prepare_move(
                 cr, uid, st_line, st_line_number, context=context)
         ctx = context.copy()
         ctx['company_id'] = st_line.company_id.id
@@ -273,7 +273,7 @@
         """
         if context is None:
             context = {}
-        res = super(AccountBankSatement, self)._prepare_move_line_vals(
+        res = super(AccountBankStatement, self)._prepare_move_line_vals(
                 cr, uid, st_line, move_id, debit, credit,
                 currency_id=currency_id,
                 amount_currency=amount_currency,
@@ -297,7 +297,7 @@
                   create the move from.
            :return: int/long of the res.partner to use as counterpart
         """
-        bank_partner_id = super(AccountBankSatement, self)._get_counter_part_partner(cr,
+        bank_partner_id = super(AccountBankStatement, self)._get_counter_part_partner(cr,
                                                                                      uid,
                                                                                      st_line,
                                                                                      context=context)
@@ -530,7 +530,7 @@
         """
         st = self.browse(cr, uid, st_id, context=context)
         if st.balance_check:
-            return super(AccountBankSatement, self).balance_check(
+            return super(AccountBankStatement, self).balance_check(
                     cr, uid, st_id, journal_type, context=context)
         else:
             return True
@@ -555,7 +555,7 @@
                           'credit_partner_id': credit_partner_id}}
 
 
-class AccountBankSatementLine(Model):
+class AccountBankStatementLine(Model):
     """
     Override to compute the period from the date of the line, add a method to retrieve
     the values for a line from the profile. Override the on_change method to take care of
@@ -684,7 +684,7 @@
         Keep the same features as in standard and call super. If an account is returned,
         call the method to compute line values.
         """
-        res = super(AccountBankSatementLine, self).onchange_type(cr, uid,
+        res = super(AccountBankStatementLine, self).onchange_type(cr, uid,
                                                                  line_id,
                                                                  partner_id,
                                                                  line_type,