supporters/python/supporters
Denver Gingerich 4d3b8b0673 models: flexible returning supporter mth count API
Rename months_expired() to months_expired_at_return() and have the
method return an integer representing the month count rather than an
enum-like so that the API user has more flexibility with respect to
what they then do with the result.  Thanks to Brett for the review
that suggested this, and for much of the clever math in this change.

The results produced by returning_report.py (which is updated here to
use the new API) are almost identical to the results produced before
the change.  In rare cases (about 2-5% of the time) a supporter's
lapsed month count will fall into an adjacent bucket instead of the
one it fell into before, usually because the previous result was wrong
to begin with (due to the ugly days-per-3-months table that we used
previously, which this change thankfully eliminates).
2018-01-25 17:03:09 -05:00
..
__init__.py python: Start Django project. 2017-01-24 13:31:30 -05:00
models.py models: flexible returning supporter mth count API 2018-01-25 17:03:09 -05:00
settings.py python: Start Django project. 2017-01-24 13:31:30 -05:00