-
Notifications
You must be signed in to change notification settings - Fork 1.9k
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Possible to provide minimum and maximum date for calendar? #250
Comments
my bad! just saw it was there in the Swift project. :) thanks! |
User this // FSCalendarDataSource
same for maximum. |
fileprivate lazy var dateFormatter: DateFormatter = {
let formatter = DateFormatter()
formatter.dateFormat = "yyyy-MM-dd"
return formatter
}()
func minimumDate(for calendar: FSCalendar) -> Date {
return self.dateFormatter.date(from: "2018-01-01")!
}
func maximumDate(for calendar: FSCalendar) -> Date {
return self.dateFormatter.date(from: "2018-02-28")!
} |
These two methods are not getting called. Delegate is not nil. All other delegates methods are getting called. |
|
@idevChandra6 |
refs #870 |
the following issues' help WenchaoD#870 WenchaoD#250
the following issues' help refs WenchaoD#870 WenchaoD#250
`fileprivate lazy var dateFormatter: DateFormatter = { func minimumDate(for calendar: FSCalendar) -> Date { func maximumDate(for calendar: FSCalendar) -> Date { this is not working, the dataSource is always nil on the first initial call |
Hi there!
I like you library, and hoping to use it my app, but before I do I just want to know if the following is possible... (I tried to figure it out, but couldnt :( )
Is it possible to set a minimum and maximum date for the calendar selection? For instance I dont want users to select anything in the future, and how many days in the past would have to be configurable based on the context.
I see there is a 'minimumDate' and 'maximumDate' properties, but seem to be readOnly.
Any idea if the above request is possible?
Thanks again!
The text was updated successfully, but these errors were encountered: