Added endpoints to allow downloading reports as CSV.
Some reports need their data to be slightly transformed, eg. balances-due view requires accounting for different units, the coupon_uses view requires accounting for nested values.
Notes:
Works with query parameters.
Tried the content-type approach with the request header sending Accept:text/csv but that didn't work with DRF, I think it could work with a custom CSV renderer.
Added #289 here because it uses the Mixin created in #288 and #290 was a minor change. Not sure if the download views/URLs belong with the API views/URLs, let me know if you want them moved to 'urls/views'.
Added endpoints to allow downloading reports as CSV.
Some reports need their data to be slightly transformed, eg. balances-due view requires accounting for different units, the coupon_uses view requires accounting for nested values.
Notes: