[FIX] hr_expence

bzr revid: mra@tinyerp.com-20100519095243-0k5xcz5q7bnrs0bs
This commit is contained in:
mra (Open ERP) 2010-05-19 15:22:43 +05:30
parent d43fc2378b
commit 22ba7bca40
1 changed files with 2 additions and 2 deletions

View File

@ -120,9 +120,9 @@ class hr_expense_expense(osv.osv):
for l in exp.line_ids:
tax_id = []
if l.product_id:
acc = l.product_id.product_tmpl_id.property_account_expense.id
acc = l.product_id.product_tmpl_id.property_account_expense
if not acc:
acc = l.product_id.categ_id.property_account_expense_categ.id
acc = l.product_id.categ_id.property_account_expense_categ
tax_id = [x.id for x in l.product_id.supplier_taxes_id]
else:
acc = self.pool.get('ir.property').get(cr, uid, 'property_account_expense_categ', 'product.category')