md-pickers
md-pickers copied to clipboard
minDate/maxDate parsing error
The date format seems to be ignored when passing minDate/maxDate as string instead of date object:
The date format is DD-MM-YYYY, but the date is parsed as MM-DD-YYYY.
To reproduce: Change the following in demo/index.html
@@ -151,8 +151,8 @@
<mdp-date-picker
ng-model="custom.date3"
mdp-placeholder="{{ custom.datePlaceholder3 }}"
- mdp-min-date="custom.minDate3"
- mdp-max-date="custom.maxDate3"
+ mdp-min-date="custom.minDateStr3"
+ mdp-max-date="custom.maxDateStr3"
mdp-ok-label="{{ custom.okLabel3 }}"
mdp-cancel-label="{{ custom.cancelLabel3 }}"
mdp-date-filter="custom.dateFilter3"
The minTime/maxTime parsing seems to be okay
Confirmed. I think this is because when the dialog is called we don't convert the min / max dates to dates but haven't checked yet