Merge lp:~openerp-dev/openobject-addons/trunk-opw-576447-port-mma into lp:openobject-addons

Proposed by Mayur Maheshwari(OpenERP)
Status: Merged
Merged at revision: 8001
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-opw-576447-port-mma
Merge into: lp:openobject-addons
Diff against target: 13 lines (+3/-0)
1 file modified
account_voucher/account_voucher.py (+3/-0)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-opw-576447-port-mma
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+132488@code.launchpad.net

Description of the change

Hello,

"[FIX]: while paying the invoice of selected journal in voucher has inactive sequence that will throw the traceback it should raise warning"

Stpes to reproduce:

1). Goto : Accounting/Configuration/Financial Accounting/Journals/Journals, Select "Bank Journal - (test)" journal
2). Open Entry sequence of above journal ,inactive it and save it.
3). Create invoice, validate and click on payment button the voucher will be opened.
4). Now select the above journal which has inactive sequence and try to validate the voucher

   You will get the trace-back it should raise the warning message.
   Code is forward port from 6.1

Thanks
Mayur

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'account_voucher/account_voucher.py'
--- account_voucher/account_voucher.py 2012-10-29 09:17:13 +0000
+++ account_voucher/account_voucher.py 2012-11-01 09:55:23 +0000
@@ -953,6 +953,9 @@
953 if voucher_brw.number:953 if voucher_brw.number:
954 name = voucher_brw.number954 name = voucher_brw.number
955 elif voucher_brw.journal_id.sequence_id:955 elif voucher_brw.journal_id.sequence_id:
956 if not voucher_brw.journal_id.sequence_id.active:
957 raise osv.except_osv(_('Configuration Error !'),
958 _('Please activate the sequence of selected journal !'))
956 name = seq_obj.next_by_id(cr, uid, voucher_brw.journal_id.sequence_id.id, context=context)959 name = seq_obj.next_by_id(cr, uid, voucher_brw.journal_id.sequence_id.id, context=context)
957 else:960 else:
958 raise osv.except_osv(_('Error!'),961 raise osv.except_osv(_('Error!'),

Subscribers

People subscribed via source and target branches

to all changes: