Chart Block – lines, bars and columns¶
The chart draws one or more series as lines, horizontal bars or vertical columns over a shared x axis. Each series has its own query and calculation. Use it to show a development over time or a comparison across categories.
This page is part of the widget reference.
1. At a glance¶
| Purpose | Shows numbers per x axis value as lines, bars or columns |
| Typical use | Tickets per month, revenue per region, created versus resolved tickets per weekday |
| Related | Accumulation Chart for shares of a whole, Card for one number |
2. Settings¶
In addition, the widget has the settings every widget has.
The chart¶
| Setting | Meaning | Default |
|---|---|---|
| "Title" | The heading above the chart, computed | none |
| "X-Axis" | How every series groups its records along its x axis field (see below) | None – must be set |
| "Series" | The series of the chart; opens a list in which series are added, ordered and removed | none |
| "Min Value", "Max Value" | Intended to fix the ends of the y axis. Currently without effect – the chart scales itself. | – |
A series¶
| Setting | Meaning | Default |
|---|---|---|
| "Label" | The name of the series in the legend | none |
| "Query" | The query whose records the series uses | none – required |
| "X-Axis" | The field whose value places a record on the x axis. With a time unit as x axis type, a date field. | none – required |
| "Function" | The value of each point: NumberRecords counts the records; Minimum, Maximum, Average, Total and the duration functions calculate over a field, as for the Card | None – must be set |
| "Field" / "Start", "End", "Unit" | The fields and the unit of the calculation, as for the card | – |
| "Display Type" | Line, Bar (horizontal) or Column (vertical) | None – must be set |
| "Stacking Type" | None (beside each other), Stacking (added up), Stacking100 (scaled to 100%) | None |
| "Stack ID" | Any text. Series with the same stack id form one stack. Only shown when stacking is chosen. | none |
X axis types¶
| Type | One point per |
|---|---|
| Value, Number | distinct value of the x axis field – a category axis (status, owner, priority). Works with any field. |
| Day | day of the month (1–31), across all months |
| DayOfWeek | weekday, shown by its name, across all weeks |
| Week | ISO week of the year (1–53, weeks start on Monday), across all years |
| Month | month of the year, shown by its name, across all years |
| Quarter | quarter (1–4), across all years |
| Year | calendar year |
| Hour | hour of the day (0–23), across all days |
The time units fold the periods together. "Month" puts March of two different years into the same point. For a timeline of one year, let the query return only the records of that year.
3. Behaviour¶
- Every series runs its own grouped calculation in the database, with the read limits of the viewing user.
- Weekday and month names are shown in the language of the user.
- Order of the points. With a time unit the points follow the order of the date part: hours 0 to 23, days 1 to 31, weeks 1 to 53, months January to December, quarters 1 to 4, years ascending. Weekdays start with the first day of the week as the database counts it - usually Sunday. With Number the values are sorted ascending; text that is no number comes after the numbers. With Value the points are sorted alphabetically by the text shown on the axis.
- Several series share one x axis. The axis shows every value any series has, in the order above. A series that has no records for one of these values has no point there; a line runs on to its next point.
- Stacking only takes effect with a "Stack ID"; without one the series is drawn unstacked.
- A click on a point opens the records behind it in a dialog, shown with the default grid of the entity. The dialog shows exactly the records the point counts or calculates over: the records of the series query whose x axis field has the clicked value or, with a time unit, lies in the clicked part of the date. A click on "March" in a chart with the x axis type Month opens the records of March of every year the query returns, just as the point adds them up.
- The chart takes the height of the widget when one is set in "Size"; a maximum height in pixels is respected as well. Otherwise it keeps a default height.
- "Font Size", "Font Weight" and "Text Color" of the widget apply to the labels of the chart.
- With "Auto Refresh" all series are calculated again; the chart is redrawn once all of them are loaded.
4. Examples¶
Tickets per month. "X-Axis" Month. One series "Created" with the query "Tickets of this year", "X-Axis" field "Created At", "Function" NumberRecords, "Display Type" Column.
Open tickets per status and priority, stacked. "X-Axis" Value. Three series "High", "Medium",
"Low", each with a query for its priority, "X-Axis" field "Status", "Function" NumberRecords,
"Display Type" Column, "Stacking Type" Stacking, "Stack ID" prio.
5. Limitations¶
- Only Line, Bar and Column are drawn. The other display types the editor offers (StepLine, Area, SplineRange, RoundedLine) and None leave the series invisible.
- "Min Value" and "Max Value" have no effect.
- The time units always fold years together (except Year); there is no continuous date axis. The records opened by a click are folded the same way.
- The colours of the series are chosen by the chart; they follow light and dark mode but not the theme.