Reputation: 127
Is it possible to set a null value to an md-datepicker ?
<md-datepicker ng-model="vm.activity.myDate" md-placeholder="myDate" />
in my controller I tried to set date to null but it always show 1/1/1901
if (row.entity.DataSchedulazione == '')
row.entity.DataSchedulazione = null;
Any help?
Upvotes: 0
Views: 3247
Reputation: 240
I tried it and it doesn't show 1/1/1901. CodePen link
Your code is setting null to
row.entity.DataSchedulazione
, instead of vm.activity.myDate though.
Upvotes: 1