From 9c6df537515c7299eef03f5c00a633aae05d5ec1 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 20 Sep 2022 12:30:56 +0530 Subject: [PATCH] timezone related issue code updated --- .../report/project_revenue_custom_report3.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/project_report/report/project_revenue_custom_report3.py b/project_report/report/project_revenue_custom_report3.py index d8617d7..835bb8e 100644 --- a/project_report/report/project_revenue_custom_report3.py +++ b/project_report/report/project_revenue_custom_report3.py @@ -153,9 +153,9 @@ data1 as ( left join pro_data on pro_data.pproject_id = drange_data1.project_id left join tsheet_data1 on tsheet_data1.project_id=drange_data1.project_id and tsheet_data1.employee_id=drange_data1.employee_id left join account_analytic_line AAL on AAL.project_id=tsheet_data1.project_id and AAL.employee_id=tsheet_data1.employee_id - and AAL.start_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.start_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) >= drange_data1.start_date::date + '00:00:00'::time - and AAL.end_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.end_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) <= drange_data1.end_date::date + '23:59:59'::time where pro_data.pricing_type = 'fixed_rate' and COALESCE(pro_data.is_sub_project, FALSE) = False group by @@ -247,9 +247,9 @@ SELECT FROM drange_data1 left join pro_data on pro_data.pproject_id = drange_data1.project_id left join account_analytic_line AAL on AAL.project_id=drange_data1.project_id and AAL.employee_id=drange_data1.employee_id - and AAL.start_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.start_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) >= drange_data1.start_date::date + '00:00:00'::time - and AAL.end_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.end_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) <= drange_data1.end_date::date + '23:59:59'::time WHERE pro_data.pricing_type='employee_rate' and pro_data.project_type='hours_no_limit' and COALESCE(pro_data.is_sub_project, FALSE) = False group by @@ -399,14 +399,14 @@ SELECT left join pro_data on pro_data.pproject_id = drange_data1.project_id left join tsheet_data1 on tsheet_data1.project_id=drange_data1.project_id and tsheet_data1.employee_id=drange_data1.employee_id left join account_analytic_line AAL on AAL.project_id=tsheet_data1.project_id and AAL.employee_id=tsheet_data1.employee_id - and AAL.start_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.start_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) >= drange_data1.start_date::date + '00:00:00'::time - and AAL.end_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.end_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) <= drange_data1.end_date::date + '23:59:59'::time left join cons_data1 on cons_data1.project_id=drange_data1.project_id and cons_data1.employee_id=drange_data1.employee_id - and AAL.start_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.start_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) >= cons_data1.start_date::date + '00:00:00'::time - and AAL.end_datetime at time zone 'utc' at time zone (select tz from res_partner where id=3) + and AAL.end_datetime --at time zone 'utc' at time zone (select tz from res_partner where id=3) <= cons_data1.end_date::date + '23:59:59'::time where pro_data.pricing_type='employee_rate' and pro_data.project_type='hours_in_consultant' and COALESCE(pro_data.is_sub_project, FALSE) = False group by