Separate queryset determination out into a get_queryset() method.

Allows the same queryset to be used by render_setup() (which also needs to
pass it to generate_headers()) and generate_data.
Pass a real QuerySet instead of a fake one to render_excel_response.

It needs something that it can call .model() on.
Pass the model, rather than the data, to generate_headers().

It used to just extract the model from the data, but this makes testing harder
because you can't add a 'model' attribute to a plain list(). And it
unnecessarily hides the fact that we actually need a model to calculate the
headers, and we don't care about what's in the rest of the data.

Also make the 'fields' parameter of generate_headers required, not optional.
If you don't know what fields to use, call get_fields(). I don't think anyone
is actually using this, because nobody should really be calling
generate_headers() directly.
Convert generate_data() to a generator.

Allows us to process the data without having it all loaded into memory first.
Add support for calculated fields.

Pass a callable name (a view method or global function) as a field, and
give it a 'fields' attribute which is a list of fields that it requires from
the database. These fields will be passed to values_list(), and the method
will be called with the values, once per row, to return a calculated value
based on them, which goes into the exported (Excel/CSV) output.