*** This bug is a duplicate of bug 1208717 ***
https://bugs.launchpad.net/bugs/1208717
** This bug has been marked a duplicate of bug 1208717
Openerp 7.0/trunk Calendar
--
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/1215895
Title:
Wrong week displayed in hr_timesheet_sheet
Status in OpenERP Addons (modules):
Confirmed
Bug description:
When i go to [Human Resources] -> [My Current Timesheet], I see the
wrong week number in the title. For example this week is the 34th of
this year but 33 is displayed.
I found out why: Python starts with 0 (zero) when fetching the current
week by using strftime('%U').
I fixed this by returning the following value in
hr_timesheet_sheet.name_get() instead of the old return value:
[code]return [(r['id'], _('Week ')+str(int(datetime.strptime(r['date_from'],
'%Y-%m-%d').strftime('%U')) + 1)) \
for r in self.read(cr, uid, ids, ['date_from'],
context=context, load='_classic_write')][/code]
I attached a module for fixing this issue.
To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/1215895/+subscriptions
_______________________________________________
Mailing list: https://launchpad.net/~openerp-india
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-india
More help : https://help.launchpad.net/ListHelp