Hesk 2.6.5 Run Report Time Zone Bug

Helpdesk for my helpdesk software

Moderator: mkoch227

Post Reply
shobzz87
Posts: 5
Joined: Sat Sep 12, 2015 3:00 am

Hesk 2.6.5 Run Report Time Zone Bug

Post by shobzz87 »

There is a Bug in "Run Report".

I am using hesk in NZ , My server time zone is US .
after increasing 17 Hours in hesk settings. New ticket goes to latest date eg 12 Sep right time.
But if you will "Run Reports" it will show into 11 Sep according to server US time Zone.

In other words, Ticket entered on 12 Sep will show in 11 Sep in Run Reports.

Friday, September 11, 2015 1 1 0 16:00:09

How to fix that??
mkoch227
Posts: 666
Joined: Wed Jul 04, 2012 3:37 pm

Re: Hesk 2.6.5 Run Report Time Zone Bug

Post by mkoch227 »

I can reproduce this issue as well in a clean installation of HESK. The following workaround worked for me:

1. Open admin/reports.php
2. Find, around line 881:

Code: Select all

<td><?php echo hesk_dateToString($k); ?></td>
3. Replace that line with:

Code: Select all

<td><?php echo hesk_dateToString($k, 1, 0, 0, true); ?></td>
Mike, Lead Developer of Image HESK: A surprisingly simple, user-friendly and FREE help desk software with integrated knowledgebase.
shobzz87
Posts: 5
Joined: Sat Sep 12, 2015 3:00 am

Re: Hesk 2.6.5 Run Report Time Zone Bug

Post by shobzz87 »

I have modified the line 953 on server . But no change.
after entering a job today on 13 sep, it still going to 12 sep report.
Klemen
Site Admin
Posts: 10167
Joined: Fri Feb 11, 2005 4:04 pm

Re: Hesk 2.6.5 Run Report Time Zone Bug

Post by Klemen »

I can confirm this is happening. This will probably require code rewrite to use MySQL CONVERT_TZ function to query dates.

I will see if I can come up with a solution that doesn't complicate the queries too much for the next update.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Post Reply