Replace end_date references in queries for ExpirableModels

We had several StudentRegistration queries that expected valid
registrations to have an end date far in the future (e.g. 1/1/9999). Now
that StudentRegistration subclasses ExpirableModel, the currently open
registrations have an end date of None.  This is reflected in the static
methods ExpirableModel.valid_objects() and is_valid_qobject() that
StudentRegistration inherits.

This change updates all queries of StudentRegistration objects that tried
to filter on the end date (e.g. end_date__gte=datetime.now()) to use the
ExpirableModel static methods instead.  The nest_Q function comes in very
handy here.
Fix import mistakes in users __init__.py
Fold Q objects into same filter() expression

This avoids the potential for different-than-expected query results due to
having named query options in one .filter() statement and the
StudentRegistration related Q object in a second .filter().
Fix chained .filter() on Permission.program_by_perm()
Add 'now' argument to valid_objects()

Fixes a bug involving different lines of code using different values
of "now" in close proximity.
Fix name error in ClassSubject.is_nearly_full()
Fix catalog SQL queries to check for null start and end dates
Remove unnecessary import
Merge pull request #741 from learning-unlimited/end-date-fixes

StudentRegistration end date fixes