fix date passed to view