Merge lp:~camptocamp/ocb-addons/7.0-fix-bug-1180803 into lp:ocb-addons

Proposed by Nicolas Bessi - Camptocamp
Status: Merged
Merged at revision: 9182
Proposed branch: lp:~camptocamp/ocb-addons/7.0-fix-bug-1180803
Merge into: lp:ocb-addons
Diff against target: 32 lines (+3/-1)
2 files modified
account/account.py (+2/-1)
account/account_view.xml (+1/-0)
To merge this branch: bzr merge lp:~camptocamp/ocb-addons/7.0-fix-bug-1180803
Reviewer Review Type Date Requested Status
Stefan Rijnhart (Opener) Approve
Review via email: mp+165076@code.launchpad.net

Description of the change

Fix bug 1180803 add active fields on account.journal

To post a comment you must log in.
Revision history for this message
Stefan Rijnhart (Opener) (stefan-opener) wrote :

LGMT

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'account/account.py'
2--- account/account.py 2013-05-07 11:57:18 +0000
3+++ account/account.py 2013-05-22 11:14:43 +0000
4@@ -725,7 +725,7 @@
5 'entry_posted': fields.boolean('Skip \'Draft\' State for Manual Entries', help='Check this box if you don\'t want new journal entries to pass through the \'draft\' state and instead goes directly to the \'posted state\' without any manual validation. \nNote that journal entries that are automatically created by the system are always skipping that state.'),
6 'company_id': fields.many2one('res.company', 'Company', required=True, select=1, help="Company related to this journal"),
7 'allow_date':fields.boolean('Check Date in Period', help= 'If set to True then do not accept the entry if the entry date is not into the period dates'),
8-
9+ 'active': fields.boolean('Active', select=True),
10 'profit_account_id' : fields.many2one('account.account', 'Profit Account'),
11 'loss_account_id' : fields.many2one('account.account', 'Loss Account'),
12 'internal_account_id' : fields.many2one('account.account', 'Internal Transfers Account', select=1),
13@@ -737,6 +737,7 @@
14 'with_last_closing_balance' : False,
15 'user_id': lambda self, cr, uid, context: uid,
16 'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id,
17+ 'active': True,
18 }
19 _sql_constraints = [
20 ('code_company_uniq', 'unique (code, company_id)', 'The code of the journal must be unique per company !'),
21
22=== modified file 'account/account_view.xml'
23--- account/account_view.xml 2013-04-25 12:06:04 +0000
24+++ account/account_view.xml 2013-05-22 11:14:43 +0000
25@@ -407,6 +407,7 @@
26 <field name="default_credit_account_id" attrs="{'required':[('type','in',('cash', 'bank'))]}" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
27 <field name="currency" groups="base.group_multi_currency"/>
28 <field name="company_id" groups="base.group_multi_company"/>
29+ <field name="active"/>
30 </group>
31 </group>
32 <notebook>