Merge lp:~openerp-dev/openobject-addons/trunk-opw-575774-port-mma into lp:openobject-addons

Proposed by Mayur Maheshwari(OpenERP)
Status: Merged
Merged at revision: 8332
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-opw-575774-port-mma
Merge into: lp:openobject-addons
Diff against target: 27 lines (+3/-3)
1 file modified
project_timesheet/report/task_report.py (+3/-3)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-opw-575774-port-mma
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+136911@code.launchpad.net

Description of the change

Hello,

To reproduce the issue:-

=>Create a task at Project/Project/Tasks and start it.
=>Enter a task work line of the current date and save the task.
=>Open Human Resources/Reporting/Timesheet/Task Hours Per Month view, there's no error.
=>In the same task create a new task work line of the same month, but different year.
=>Open "Task Hours Per Month" view, error occurs.

=>Code is forward port from 6.1

Thanks,
Mayur

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'project_timesheet/report/task_report.py'
2--- project_timesheet/report/task_report.py 2012-10-02 10:29:15 +0000
3+++ project_timesheet/report/task_report.py 2012-11-29 11:29:21 +0000
4@@ -56,7 +56,7 @@
5 tools.drop_view_if_exists(cr, 'report_timesheet_task_user')
6 cr.execute(""" create or replace view report_timesheet_task_user as (
7 select
8- ((r.id*12)+to_number(months.m_id,'99'))::integer as id,
9+ ((r.id*12)+to_number(months.m_id,'999999'))::integer as id,
10 months.name as name,
11 r.id as user_id,
12 to_char(to_date(months.name, 'YYYY/MM/DD'),'YYYY') as year,
13@@ -65,12 +65,12 @@
14 interval '1 day') ) as task_hrs
15 from res_users r,
16 (select to_char(p.date,'YYYY-MM-01') as name,
17- to_char(p.date,'MM') as m_id
18+ to_char(p.date,'YYYYMM') as m_id
19 from project_task_work p
20
21 union
22 select to_char(h.name,'YYYY-MM-01') as name,
23- to_char(h.name,'MM') as m_id
24+ to_char(h.name,'YYYYMM') as m_id
25 from hr_timesheet_sheet_sheet_day h) as months
26
27 group by

Subscribers

People subscribed via source and target branches

to all changes: