fix date format in templates