Skip to content
This repository has been archived by the owner on Jun 23, 2019. It is now read-only.

What happen to 'toDate' parameter in didselect date method in Delegate? #23

Open
stshelton opened this issue Feb 14, 2017 · 3 comments
Open

Comments

@stshelton
Copy link

Having trouble getting end date when using the selection mode "sequence". I had a previous version of this library on a different project and the "didSelect date" method in delegate had a "toDate" parameter that would provide the last date in sequence. Currently, that delegate method only has "didSelect date" which only returns the first date in the sequence even after the user clicked another date to complete sequence. Am I missing another function in the delegate, if not what would be the best method of retrieving the end date of the sequence of dates?

Also, I had an issue with Sat column disappearing when collection view is the same size of the screen. Once I added a trailing and leading constraint of 5 Sat column came back

@v1ntage
Copy link

v1ntage commented Feb 14, 2017

I'm having these exact two issues too.

  • Sat disappears at bounds.width unless you make it eg. width + 1 and then it's fine.
  • Swift 2.3 version at least: Selecting date prints wrong date (always 1 date behind). Even in the project example this is the case. Eg. Feb 7 shows as Feb 6 when print in console.
  • As described by stshelton, Sequence only captures the first selection. Not only this, but if you select a sequence of dates going forwards, both selects are the same date. But going backwards, it's fine. Eg. Feb 2 (First) and then Feb 7 (second) show as Feb 1 on both clicks (due to the error I outlined before this one). But if you select it the other way, Feb 7 (first) and then Feb 2 (second) then the two selects are different.

Overall these issues make it unusable in its current state, unfortunately, as this is a great lightweight solution.

@zhangbool
Copy link

Same issues with the two guys before, the end selected time is not right

@danparnella
Copy link

I would agree that the "toDate" parameter should be included again in the "didSelect" method, but as a workaround for now you can use the "shouldSelectDates" method which does include both "date" and "toDate".

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants