Skip to content
This repository has been archived by the owner. It is now read-only.

Week-view is not ordered correctly by event's time #443

Closed
sirtawast opened this Issue Sep 5, 2016 · 7 comments

Comments

Projects
None yet
3 participants
@sirtawast
Copy link
Contributor

sirtawast commented Sep 5, 2016

Hello and thank you for a plug-in which was an ease to start using and is the best calendar plug-in I've found so far for Angular.

I've got this weird week-view bug (or might there be something I'm just missing?).

Everything is fine in the 'month' view, the data seems to be ordered by time but once I switch to the 'week' view, something weird happens. And the funny thing is that the events have proper $id's set on them. You can see this by opening dev tools and clicking each event and it will console.log() the event.

My data is already order by date and time in the backend and is basically just data from a reservation calendar. You can find a snapshot of a requests from 'data.json', I've also validated it.

I'm currently toggling moment to a Finnish locale (though the problem persists if the locale is not changed).

Anyways, here's the plunker as requested

@mattlewis92

This comment has been minimized.

Copy link
Owner

mattlewis92 commented Sep 5, 2016

Thanks for the detailed bug report, that's really helpful to see what's going on. I'll get that fixed up in the next release asap! 😄

@mattlewis92 mattlewis92 added this to the 0.24.x milestone Sep 5, 2016

@sirtawast

This comment has been minimized.

Copy link
Contributor Author

sirtawast commented Sep 5, 2016

Actually, I couldn't get this to work with Firefox or IE 11. No errors though.

@sirtawast

This comment has been minimized.

Copy link
Contributor Author

sirtawast commented Sep 5, 2016

Ok, I figured it out -- the other browsers gave me a clue. It's the date format from the backend. For some reason Chrome is ok with YYYY-MM-DD 00:00:00 but parses it a bit off. If I change the dates to YYYY/MM/DD 00:00:00 it's working in FF and IE AND order is correct in Chrome. That's what you get when you develop Chrome-first 😃

Here's a working plunker

@sirtawast sirtawast closed this Sep 5, 2016

@sirtawast sirtawast reopened this Sep 5, 2016

@sirtawast

This comment has been minimized.

Copy link
Contributor Author

sirtawast commented Sep 5, 2016

Oops! I talked too soon. Ordering is off in Chrome but FF and IE is getting it right.

@eh-am

This comment has been minimized.

Copy link

eh-am commented Oct 10, 2016

Hey, I see it's going to be fixed in 0.24, is there a clean way I could use this fix right now? When are you going to release this version? Maybe I can wait :-)

Sorry for the dumb question.

@mattlewis92

This comment has been minimized.

Copy link
Owner

mattlewis92 commented Oct 10, 2016

I was going to cut a new release yesterday but I found a regression when testing this against our app at work which I'm fixing as we speak and then I'll cut a new release :)

You can grab a pre-release from npm, it's under the 0.24.0-beta.0 tag: https://npmcdn.com/angular-bootstrap-calendar@0.24.0-beta.0

@mattlewis92

This comment has been minimized.

Copy link
Owner

mattlewis92 commented Oct 10, 2016

@eh-am 0.24.0 is published now :)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.