I have a page on a grid displaying data one field of which is a Date data type in SQL. The grid is displaying the dates in UK format (dd/MM/yyyy) with no time displayed:
The formatting done by this template:
When I open an edit dialog, the information is displayed but, the year seems to be doubled up and the date not in the format I want as it is displaying month name:
I've tried various things but, can't seem to get it to display correctly using this DateFormat?
Any suggestions how to correct this or can you see any silly mistakes on my part?
This is an oddity of the PrimeNG date picker. The date format it uses isn't the standard Angular one. For example yy is year with four digits and mm is month with two digits. I think you need dd/mm/yy. Here is the full list of formats that the PrimeNG datepicker supports: