[FIX] hr_timesheet: fixed issue in code cleaning, xmlid_to_res_id returns an id,...
authorThibault Delavallée <tde@openerp.com>
Thu, 11 Sep 2014 07:38:43 +0000 (09:38 +0200)
committerThibault Delavallée <tde@openerp.com>
Thu, 11 Sep 2014 07:38:43 +0000 (09:38 +0200)
addons/hr_timesheet/hr_timesheet.py

index c3bea20..633336a 100644 (file)
@@ -224,7 +224,7 @@ class account_analytic_account(osv.osv):
             return {'value': {'to_invoice': False}}
         try:
             to_invoice = self.pool.get('ir.model.data').xmlid_to_res_id(cr, uid, 'hr_timesheet_invoice.timesheet_invoice_factor1')
-            result['to_invoice'] = to_invoice[1]
+            result['to_invoice'] = to_invoice
         except ValueError:
             pass
         return result