You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 29, 2019. It is now read-only.
When using date-picker-popup with an ng-model-optionstimezone set, the minDate and maxDate don't seem to be working properly. For example, if I set minDate to be 2016-12-31T00:00:00Z it allows selection of Dec 30th 2015. If I set maxDate to be 2016-01-15T00:00:00Z it only allows selection up to Jan 14th 2016.
Link to minimally-working plunker that reproduces the issue:
After further investigation it seems that the ngModelOptions isn't propagating from the popup to the picker. The workaround would be to put the ngModelOptions on a parent of the input field (the <div class="col-md-6"... in the linked plnkr) in which case Angular propagates that down to all child models.
Unfortunately this work-around doesn't work in uibs v1.3.3. I cannot upgrade to 2.1.3 because the timezone calculation seems to be broken for the model. In the plunker if you select a date after the initial load, it sets the time to 10AM and not midnight.
Bug description:
When using date-picker-popup with an
ng-model-options
timezone
set, theminDate
andmaxDate
don't seem to be working properly. For example, if I setminDate
to be2016-12-31T00:00:00Z
it allows selection of Dec 30th 2015. If I setmaxDate
to be2016-01-15T00:00:00Z
it only allows selection up to Jan 14th 2016.Link to minimally-working plunker that reproduces the issue:
http://plnkr.co/edit/NheeTWdqKf4eFDNPV5uT?p=preview
Notice how you are allowed to select outside of the
minDate
andmaxDate
that is set.Version of Angular, UIBS, and Bootstrap
Angular: 1.5.x
UIBS: 2.1.3 (originally encountered on 1.3.3)
Bootstrap: 3.x
The text was updated successfully, but these errors were encountered: