Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

last week of year bug (week zoom view) #73

Closed
naterg opened this issue Apr 12, 2013 · 8 comments
Closed

last week of year bug (week zoom view) #73

naterg opened this issue Apr 12, 2013 · 8 comments
Labels
Milestone

Comments

@naterg
Copy link

naterg commented Apr 12, 2013

If you attempt to display an item with a to date of 12/31/13 the bar width will not render properly in the week zoom scale. It appears to be an oversight in the getDayForWeek function concerning weeks that span years?

-Nate

@chuliang
Copy link

Solution:
mbielanczuk#32 (comment)

@usmonster
Copy link
Collaborator

Anyone want to put that solution into a pull request? @julbuel ?

@taitems
Copy link
Owner

taitems commented Jun 28, 2013

Guys I'm really keen to add collaborators to this project because the code base has gotten so out of control. Anything to get this stable (currently the hour view in particular is the most buggered) and close some of those pull requests.

@usmonster
Copy link
Collaborator

@taitems If you need help, I can sweep through some low-hanging-fruit issues and probably close a bunch. Would you also want to organize them in a certain way? Might be useful to have a couple categories/labels like "bug", "feature request", etc.. Lemme know.

@usmonster
Copy link
Collaborator

@naterg, according to the comment for that function (which seems rather convoluted in the first place), it looks like we want the equivalent of Moment.js's startOf('week').

If this is the case, we can pretty much replace the current function with something much simpler, something along the lines of return new Date(this.valueOf() - (8.64e7 * this.getDay()) ); // 1 day === 8.64e7 ms.

Untested and not sure if it's any more correct (would still have to account for DST), but it's a whole lot simpler in terms of approach. Thoughts? Anyone with more time want to test it out and maybe put it in a pull request? Otherwise I might do it, someday..

@naterg
Copy link
Author

naterg commented Sep 5, 2013

@usmonster, I've actually pulled off the project that was using jQuery.Gantt so I haven't even tested chuliang's solution. Appreciate the responses though and I'll notify if I jump back to using this!

@croftman
Copy link

croftman commented May 6, 2014

I'v another bug with the weeks, if I have an event from 2014-12-29 to 2015-01-02, it put 2 weeks, from week 52 of 2014 to week 1 of 2015, but the first week of 2015 is 2014-12-29 to 2015-01-02 !

It's because my first day of week is monday ?

Ok I think it's the same issuer than #61

@usmonster
Copy link
Collaborator

@croftman I agree that your issue is the same as #61. Both issues are towards the top of the priority queue.

@usmonster usmonster added this to the v1.3.0 milestone Dec 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants