sfbrigade / sf-crime-data

Search SFPD incidents from SF OpenData with focus on campus safety.
http://sfcrimedata.org
MIT License
26 stars 39 forks source link

As a user, I want meaningful initial default values for Time Period, so that my search results are valid. #63

Closed paulhennings closed 7 years ago

paulhennings commented 7 years ago

Expected behavior

On the initial page load, the "To Date" should not be any later than the "Data available through" Date. Change the default so that the "To Date" is set equal to the "Data available through" Date. Change the default so that the "From Date" is set equal to "Data available through" Date minus 30 days.

Actual behavior

Dates default to "Last 30 Days" This is misleading when results are returned, as data is generally not available for the preceding week.

Steps to reproduce

Click http://sfcrimedata.org Observe default dates

steveny2k commented 7 years ago

I can take a look at this. I am new to this project though.

paulhennings commented 7 years ago

Change to original request:

If "To Date" is greater than Today, change the font on the "Data available through..." message to RED, else set BLACK(default).

That should be sufficient to alert the user to the fact that data is not yet available for the time period selected (and also not give the user unexpected results for relative time periods like "Last Year" or "This Quarter").