Couple min and max value in date range selection, cleanup + bug fixes.