i have an input type Date in my HTML.(i'm working with angularjs )
i used it like this :
< input ng-model="voyage.dateRetour" type="date">
{{voyage.dateRetour}}
i created a pdf with jsPDF and i use the inputs form the complete the pdf so i did :
$scope.createPDFs= function (filename) {
var doc = new jsPDF();
doc.text(13, 95, 'Retour : '+$scope.voyage.dateRetour );
and it gives me : Fri Aug 21 2015 00:00:00 GMT+0200 (Paris, Madrid (heure d’été))
i dont know how to change the format to short format like DD-MM-YYYY .
i tried to do a filter like :
$filter('date')($scope.voyage.dateRetour, "dd/MM/yyyy");
Thank you for helping.