[FIX]hr_timesheet: Problems printing timesheet reports

lp bug: https://launchpad.net/bugs/695960 fixed

bzr revid: ara@tinyerp.com-20110117090955-ofb3iiabb99e3zqt
This commit is contained in:
ARA (OpenERP) 2011-01-17 14:39:55 +05:30
parent e0c3983eb6
commit 2ee52c73f3
2 changed files with 4 additions and 2 deletions

View File

@ -27,6 +27,7 @@ from tools.translate import _
import time
import pooler
from report import report_sxw
from tools import ustr
def lengthmonth(year, month):
if month == 2 and ((year % 4 == 0) and ((year % 100 != 0) or (year % 400 == 0))):
@ -109,7 +110,7 @@ class report_custom(report_rml):
<employee>%s</employee>
%s
</report>
''' % (header_xml,toxml(empl_name), '\n'.join(date_xml) + '\n'.join(account_xml))
''' % (header_xml, ustr(empl_name), '\n'.join(date_xml) + '\n'.join(account_xml))
return xml
report_custom('report.hr.analytical.timesheet', 'hr.employee', '', 'addons/hr_timesheet/report/user_timesheet.xsl')

View File

@ -26,6 +26,7 @@ import time
import pooler
from tools.translate import _
from report import report_sxw
from tools import ustr
def lengthmonth(year, month):
@ -111,7 +112,7 @@ class report_custom(report_rml):
%s
%s
</report>
''' % (header_xml,date_xml, emp_xml)
''' % (header_xml,date_xml, ustr(emp_xml))
return xml
report_custom('report.hr.analytical.timesheet_users', 'hr.employee', '', 'addons/hr_timesheet/report/users_timesheet.xsl')