Skip to content

Conversation

@gabrielgaliaso
Copy link

This fix Daylight Saving Time.

On 2012-10-20 was rendering twice.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's probably better to have it as is, than 'sort of' fixed. http://stackoverflow.com/questions/2532729/daylight-saving-time-and-timezone-best-practices touches on some of the things you need to think about. Adding 2 hours isn't really an appropriate fix - in all likelyhood it should probably be addressed in the date labelling code.

@usmonster
Copy link
Collaborator

I can't seem to reproduce the problem, though I don't know if it requires changing the system date & time/time zone to see it.

@gabrielgaliaso , can you check to see if this is still an issue in the current version of the plugin? If so, please make a jsfiddle to show the bug in action, or at least list the steps to reproduce the behavior you describe. If it's no longer an issue, we can close this issue. Thanks!

@usmonster
Copy link
Collaborator

Still an issue -- see #95 and linked fiddle (set system time zone to Brasilia time to reproduce the bug).

@maxanalista
Copy link

Hello Gentlemen, okay with you?
Next, on rendering the date of October 19 here worked perfectly. However, the pattern of activity in Gantt was not right. What I could see is that when I have an activity that runs through the 19th of October, rendering the activity is designed with 1 day less. For example, if I have a date with activity beginning October 10 and ending October 21 date in Gantt, the design of it is from October 10 to October 20. How can I fix this? If you do not have the solution, can tell me which function determines the size of the activities in the chart?

[
 {
  "name":" ",
  "desc":"\"INTEGRAÇÃO COM FORPONTO\"",
  "values":[{
    "id":"\"\"",
    "from":"\"2013-10-10 00:00:00.000\"",
    "to":"\"2013-08-21 00:00:00.000\"",
    "label":"\"INTEGRAÇÃO COM FORPONTO\"",
    "customClass":"ganttGreen"
  }]
 },
 {
  "name":" ",
  "desc":"\"TESTE\"",
  "values":[{
    "id":"\"\"",
    "from":"\"2013-10-20 00:00:00.000\"",
    "to":"\"2013-08-22 00:00:00.000\"",
    "label":"\"TESTE\"",
    "customClass":"ganttGreen"
  }]
 }
]

asasasa

@usmonster
Copy link
Collaborator

@maxanalista , you can start by looking at the parseDateRange and parseTimeRange functions. An example and explanation of the bug can be seen here:
ebf84ca#diff-68db7efe596172a1806bc03207a052a6R1537

@maxanalista
Copy link

Did not quite understand the topic ebf84ca. There is a new version that understands the Brasilia time zone that I can receive email [email protected] or download here? The code you see here is a bit different from what I downloaded. I made some changes and stopped working.

@maxanalista
Copy link

So, I downloaded the current version and the problem persisted in the rendering of the activities that have the time passing by October 19.

@usmonster
Copy link
Collaborator

@maxanalista , there is no fix yet in the current version, the commit line and comment that I linked to is where at least part of the bug (or a related one) is.

@maxanalista
Copy link

@usmonster , I have not had time to study all the code but I will. What I have in mind as a partial solution to the problem is to verify through a condition that the activity belongs to a period which goes through October 19. If so, it adds some extra pixels in the width of the activity. I'll try to do it here.

@usmonster
Copy link
Collaborator

@maxanalista , in this case, I would suggest the simpler workaround of changing your input's end times to 23:59 (instead of 00:00). This should work without any modifications to the code.

@Abhishek92rai
Copy link

Has anyone found solution for this issue?
Need help because change in time to 23:59 (instead of 00:00) is causing change in date one day back but i need date to be same (End of one task on 25th October,2015 and Start of new task on 26th October,2015).

@alexturgeon
Copy link

Hi,

I work for a company in Canada, and we use this plugin for one of our clients; they offer yacht rental. The Gantt diagram shows when each boat is available, and their schedule.

Everything works fine, except when Daylight Saving Time starts (March 13th, 2016) and ends (November 6th, 2016).

When DST starts, the tasks including that date are one day shorter.
dst_start

When it ends, the tasks are split in two.
dst_end

Is there a way to fix this issue?

If it helps, my time zone is GMT -5.

Thank you, and have a nice day!

usmonster added a commit to usmonster/jQuery.Gantt that referenced this pull request Mar 6, 2018
@usmonster usmonster mentioned this pull request Mar 6, 2018
@usmonster
Copy link
Collaborator

Hello from 2019! :)

This pull request is unfortunately outdated, but the issue should be fixed in a cleaner way in #226.

Please feel free to review and/or test out the code before it's merged and report back if you see any regressions or other problems.

(This PR will be auto-closed once the other one is merged.)

@usmonster usmonster closed this in 9930ecc Jan 30, 2019
@usmonster usmonster modified the milestones: n+2, v1.2.0 Feb 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants