Skip to content

Conversation

Vavooon
Copy link

@Vavooon Vavooon commented Apr 28, 2017

This pull request add possibility to specify min and max allowed dates (including also time) for selection using options or setters.

@joews
Copy link
Member

joews commented Apr 28, 2017

Thanks for the contribution!

I'm short on reviewing time at the moment. To help me get started quickly can you describe the change in more detail - what exactly do the startDate and stopDate options do? How can I check they are working correctly?

Can you add some tests ? Test coverage is low so far but I would like to raise it, starting with new features like this.

Thanks!

@Vavooon
Copy link
Author

Vavooon commented Apr 29, 2017

Hello. Sorry for such short description.

These options deny users to select date earlier than startDate and later than stopDate. So if you specify these options, all UI controls (day, hour and minute pickers) which allow to select date not from specified interval will be disabled. You can set only one of the options. Setters are implemented for on-the-fly timepicker updates, for example if a user is denied to select a time greater than current but timepicker stays opened for a few minutes, stopDate can be updated to allow next five minutes or new hour selection and UI will be also updated.

Regarding tests, I'll try to write them (I've never done it before :) ), but I can't promise that since I'm currently busy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants