Make admin activity widget date range parsing a little bit more robust.

It was possible to cause the activity widget in the admin to generate requests
to the server that would generate a 500 response. The issue here was that we
didn't properly sanitize dates unless both the start and end range were
provided.

I've changed it to convert the request parameters to datetimes individually
instead of if they're both necessary, and changed the if/elif/etc block to
verify that the necessary data was provided in request.GET before trying to use
it.

Testing done:
Checked out the admin UI a bit.

Fixes bug 3068.

Reviewed at https://reviews.reviewboard.org/r/5101/