angularjs - Angular Material Date Picker Filter -


i have formatted angular material date picker below:

$mddatelocaleprovider.formatdate = function(date) {         return moment(date).format('yyyy-mm-dd');     }; 

but when want use date picker filter, it's not working:

<md-datepicker ng-model="search.date""></md-datepicker> 

with <input ng-model="search.date"> date filter working.

how make angular material date picker working filter?

edit : datepicker output : tue jun 21 2016 00:00:00 gmt+0300 (eest), want 2016-06-21

you have 2 double quotes in there.

<md-datepicker ng-model="search.date""></md-datepicker> 

here working code.

$mddatelocaleprovider.formatdate = function(date) {         return moment(date).format('yyyy-mm-dd');     }; }) 

Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo