fragaria / angular-daterangepicker

Angular.js wrapper for dangrossman/bootstrap-daterangepicker
MIT License
519 stars 372 forks source link

How to disable initial date (today) ? #154

Closed ShlomoRosenheimer closed 5 years ago

ShlomoRosenheimer commented 8 years ago

My datepicker should be initalized with no inital dates. Using singleDatePicker: true

$scope.datePicker = {
      date: {}
    };

Everything works fine, setting the date etc. However, initially, the date picker displays the current date (today). How to disable it, so the input field is blank until I select a date?

Using autoUpdateInput: false does not work

If I set my model to null, (datePicker.date = null) it says:

TypeError: Cannot read property 'startDate' of null

fahadcv commented 8 years ago

did you try to set ""

thomastardy commented 8 years ago

Any update on this?

vincez commented 8 years ago

+1. I have the exact same issue

parker789 commented 8 years ago

Fixed with my commit on issue #183