[FIX] account : Move lines take the Journal and Period from the Move itself(Maintenance Case 5598)

bzr revid: ach@tinyerp.com-20110512122212-hzr9u49p4w4b2133
This commit is contained in:
Anup (OpenERP)
2011-05-12 17:52:12 +05:30
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -553,7 +553,7 @@ class account_move_line(osv.osv):
'date_created': lambda *a: time.strftime('%Y-%m-%d'),
'state': 'draft',
'currency_id': _get_currency,
'journal_id': lambda self, cr, uid, c: c.get('journal_id', False),
'journal_id': lambda self, cr, uid, c: c.get('journal_id', c.get('journal',False)),
'account_id': lambda self, cr, uid, c: c.get('account_id', False),
'period_id': lambda self, cr, uid, c: c.get('period_id', False),
'company_id': lambda self, cr, uid, c: self.pool.get('res.company')._company_default_get(cr, uid, 'account.move.line', context=c)
+1 -1
View File
@@ -1326,7 +1326,7 @@
</group>
<notebook colspan="4">
<page string="Journal Items">
<field colspan="4" name="line_id" nolabel="1" height="250" widget="one2many_list" default_get="{'lines':line_id ,'journal':journal_id }">
<field colspan="4" name="line_id" nolabel="1" height="250" widget="one2many_list" default_get="{'lines':line_id , 'journal':journal_id, 'period_id':period_id}">
<form string="Journal Item">
<group col="6" colspan="4">
<field name="name"/>