BxWebManager Home Widgets

Add or Modify Widgets on BxWM Home

BxWM uses a query called "widgets" to get a list of widgets to display.
The widgets can define a widget type, title and width. Dependent on widget type other properties can be applied, like color, icon, value or query.
When using query a second query is run to get the actual values for the widget.

Enable widgets

For older installations, widgets needs to be enabled, and configured, in BxAdmin.

Under Configuration => ClientProfile. Add or enable property widgets under area webmanager, set value to true.

Sample config that could be copy/pasted to Client Profile:

[{"profileid":1,"routine":"webmanager","name":"widgets","value":"true","id":18153,"comment":null}]

Widgets properties

title

A string title/header of the widget

type

Type of widget, see widget types

width

Widget area is a relative width of 12. A widget width of 4 would take 1/3 of the available space. On smaller screen the configured widget width is doubled, and on very small screens ignored, to improve user experience and prevent many horizonal widgets on small screens.

value

Optional - used for widget type SUMMARY, expects a number

icon

Optional - used for widget type SUMMARY, expects a font-awesome id, from the solid-font set, e.g.: fa-solid fa-box

color

Optional - used for widget type SUMMARY, expects either 'default' | 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'error' to use a theme color, or a hex-color code, like '#ffaaaa'

query

Optional - used for widget types LINE and CAKE, expects a name of the custom query used for fetching the data. Prefer using query names prefixed with stats, like: stats_myquery

Widget Types

SUMMARY

Single value widget, getting it's value from the "value" property
Summary

CAKE

Multi value widget, requires usage of the query property, and expects a query returning name and value.
Cake

LINE

Multi value widget required usage of the query property and expects a query returning name, type, label and value. Type must be either column, line or area. Label is the labels for the X-axis, and name is the name of the series.
Line

HEADER

Header type to provide a grouping header for other widgets

Header

LIST

A list of item fetched from a query containing title and optional subtitle
List-1

PICKINGSUMMARY

A special type what will display the standard picking widgets used when custom no custom widgets are configured.

PickingSummary

RECEIVINGSUMMARY

A special type what will display the standard receiving widgets used when custom no custom widgets are configured.
ReceivingSummary

Sample

Query creating 5 widgets, with 3 of type SUMMARY on the first line, and then a single CAKE and a single LINE on the second line.

Widgets query

select
'My Stats' as title,
123 as value,
'SUMMARY' as type,
'fa-solid fa-indent' as icon,
3 width,
'#4632a8' color,
null as query

union all

select
'Other Stats' as title,
12123 as value,
'SUMMARY' as type,
'fa-solid fa-tree-palm' as icon,
6 width,
'#f5426c' color,
null as query

union all

select
'Last Stats' as title,
123 as value,
'SUMMARY' as type,
'fa-solid fa-indent' as icon,
3 width,
'success' color,
null as query

union all

select
'Stats divided pr employee' as title,
null as value,
'CAKE' as type,
'fa-solid fa-indent' as icon,
6 width,
null color,
'stats_PrEmp' as query

union all

select
'Stats over time' as title,
null as value,
'LINE' as type,
'fa-solid fa-indent' as icon,
6 width,
null color,
'stats_OverTime' as query

stats_PrEmp

select 'Martine' as name, 4234 as value
union all
select 'Nilsen' as name, 3244 as value
union all
select 'Ola Kari' as name, 2900 as value
union all
select 'Haugen' as name, 1900 as value

stats_OverTime

select
123 as value,
'January' as label,
'column' as type,
'Current' as name

union all

select
100 as value,
'February' as label,
'column' as type,
'Current' as name

union all

select
900 as value,
'March' as label,
'column' as type,
'Current' as name

union all

select
123 as value,
'April' as label,
'column' as type,
'Current' as name

union all

select
155 as value,
'May' as label,
'column' as type,
'Current' as name



union all

select
123 as value,
'January' as label,
'area' as type,
'Previous period' as name

union all

select
125 as value,
'February' as label,
'area' as type,
'Previous period' as name

union all

select
1500 as value,
'March' as label,
'area' as type,
'Previous period' as name

union all

select
320 as value,
'April' as label,
'area' as type,
'Previous period' as name

union all

select
190 as value,
'May' as label,
'area' as type,
'Previous period' as name