banking-addons-team team mailing list archive
-
banking-addons-team team
-
Mailing list archive
-
Message #00366
lp:~camptocamp/banking-addons/bank-statement-reconcile-70-fix-on-change-voucher into lp:banking-addons/bank-statement-reconcile-70
Joël Grand-Guillaume @ camptocamp has proposed merging lp:~camptocamp/banking-addons/bank-statement-reconcile-70-fix-on-change-voucher into lp:banking-addons/bank-statement-reconcile-70.
Requested reviews:
Alexandre Fayolle - camptocamp (alexandre-fayolle-c2c): code review, no test
Joël Grand-Guillaume @ camptocamp (jgrandguillaume-c2c)
For more details, see:
https://code.launchpad.net/~camptocamp/banking-addons/bank-statement-reconcile-70-fix-on-change-voucher/+merge/146066
Statement ext collide with voucher for some on change. As it almost impossible to have a finance installation without voucher, we may add voucher as a dependence on statement ext in order to fix on change, and silent unwanted voucher behavior.
We also add the right periode computation for each line in the voucher, as it was previously done in the account_statement_ext_voucher. We mark also this one as deprecated.
--
https://code.launchpad.net/~camptocamp/banking-addons/bank-statement-reconcile-70-fix-on-change-voucher/+merge/146066
Your team Banking Addons Team is subscribed to branch lp:banking-addons/bank-statement-reconcile-70.
=== modified file 'account_statement_ext/__init__.py'
--- account_statement_ext/__init__.py 2012-12-20 13:37:01 +0000
+++ account_statement_ext/__init__.py 2013-02-01 08:47:20 +0000
@@ -22,3 +22,4 @@
import statement
import report
import account
+import voucher
\ No newline at end of file
=== modified file 'account_statement_ext/__openerp__.py'
--- account_statement_ext/__openerp__.py 2012-12-20 13:37:01 +0000
+++ account_statement_ext/__openerp__.py 2013-02-01 08:47:20 +0000
@@ -27,7 +27,8 @@
'complexity': 'normal',
'depends': [
'account',
- 'report_webkit'
+ 'report_webkit',
+ 'account_voucher'
],
'description': """
Improve the basic bank statement, by adding various new features,
@@ -62,6 +63,8 @@
all the erronous line in a same popup instead of raising and crashing on every step.
4) Remove the period on the bank statement, and compute it for each line based on their date instead.
+ It also add this feature in the voucher in order to compute the period correctly.
+
5) Cancelling a bank statement is much more easy and will cancel all related entries, unreconcile them,
and finally delete them.
=== modified file 'account_statement_ext/statement.py'
--- account_statement_ext/statement.py 2013-01-28 09:48:10 +0000
+++ account_statement_ext/statement.py 2013-02-01 08:47:20 +0000
@@ -551,7 +551,7 @@
res['account_id'] = receiv_account
return res
- def onchange_partner_id(self, cr, uid, ids, partner_id, profile_id, context=None):
+ def onchange_partner_id(self, cr, uid, ids, partner_id, profile_id=None, context=None):
"""
Override of the basic method as we need to pass the profile_id in the on_change_type
call.
@@ -571,7 +571,9 @@
type = 'customer'
res_type = self.onchange_type(cr, uid, ids, partner_id, type, profile_id, context=context) # Chg
if res_type['value'] and res_type['value'].get('account_id', False):
- return {'value': {'type': type, 'account_id': res_type['value']['account_id']}}
+ return {'value': {'type': type,
+ 'account_id': res_type['value']['account_id'],
+ 'voucher_id': False}}
return {'value': {'type': type}}
def onchange_type(self, cr, uid, line_id, partner_id, type, profile_id, context=None):
=== modified file 'account_statement_ext_voucher/__init__.py'
--- account_statement_ext_voucher/__init__.py 2012-06-20 14:10:01 +0000
+++ account_statement_ext_voucher/__init__.py 2013-02-01 08:47:20 +0000
@@ -18,5 +18,3 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
-
-import statement_voucher
=== modified file 'account_statement_ext_voucher/__openerp__.py'
--- account_statement_ext_voucher/__openerp__.py 2013-01-10 15:09:55 +0000
+++ account_statement_ext_voucher/__openerp__.py 2013-02-01 08:47:20 +0000
@@ -30,8 +30,12 @@
'account_voucher'
],
'description': """
- This module is only needed when using account_bank_statement_ext with voucher in order to compute the period
+ This module is deprecated. It was only needed when using account_bank_statement_ext with voucher in order to compute the period
correctly. This is mainly because with account_bank_statement_ext, the period is computed for each line.
+
+ Now, we include this in the account_statement_ext module and added a dependencies on account_voucher (mainly cause we can't get
+ rid of the voucher in version 7.0).
+
""",
'website': 'http://www.camptocamp.com',
'init_xml': [],
@@ -40,9 +44,9 @@
],
'demo_xml': [],
'test': [],
- 'installable': True,
+ 'installable': False,
'images': [],
- 'auto_install': True,
+ 'auto_install': False,
'license': 'AGPL-3',
}
=== removed file 'account_statement_ext_voucher/statement_voucher_view.xml'
--- account_statement_ext_voucher/statement_voucher_view.xml 2012-07-04 11:51:39 +0000
+++ account_statement_ext_voucher/statement_voucher_view.xml 1970-01-01 00:00:00 +0000
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<openerp>
- <data>
-
- <record id="account_voucher.view_bank_statement_form_invoice" model="ir.ui.view">
- <field name="name">account.bank.statement.invoice.form.inherit</field>
- <field name="model">account.bank.statement</field>
- <field name="type">form</field>
- <field name="inherit_id" ref="account.view_bank_statement_form"/>
- <field name="arch" type="xml">
- <field name="currency" invisible="1" position="after">
- </field>
- </field>
- </record>
-
- </data>
-</openerp>
Follow ups