global method for format dates in ISO format (y-m-d)