Added a date format method for the datepicker: