Group-by, time-series, crosstab and pivot reports — each a small Python class, each chartable with a single line in Highcharts or Chart.js — or plug in any JS charting library you like (ApexCharts shown as an example).
Simple aggregates, group-by, time-series, crosstab/pivot — and combinations of them.
Bar, column, line, area, pie — stacked or totalled — from one Chart(...) line. Not a Highcharts/Chart.js fan? Bring your own JS charting library instead.
Embed any report as a self-contained widget with a single template tag.
Optimized queries, model-optional (even raw SQL), and hooks for everything.
class ProductSales(ReportView):
report_model = SalesTransaction
date_field = "date"
group_by = "product"
columns = [
"name",
ComputationField.create(
Sum, "value", name="value__sum",
verbose_name="Total sold $",
),
]
chart_settings = [
Chart("Total sold $", Chart.BAR, # try Chart.PIE, Chart.LINE …
data_source=["value__sum"],
title_source=["name"]),
]
The same data renders through the engine you choose — just set chart_engine. Highcharts (default) and Chart.js ship built-in; ApexCharts below shows how to plug in any JS charting library of your own.