wip charts

This commit is contained in:
2023-12-25 23:38:13 +01:00
parent e7e5ec9586
commit db7655c4f8
2 changed files with 84 additions and 22 deletions

View File

@ -44,25 +44,7 @@
{{ end }}
{{ end }}
],
datasets: [
{{ range split (.Get "datasets") "$" }}
{
label: {{ index (split . "|") 0 }},
data: [
{{ range split (index (split . "|") 1) "," }}
{{ . }},
{{ end }}
],
{{ if $c := index (split . "|") 2 }}
borderColor: {{ $c }},
backgroundColor: {{ $c }},
{{ end }}
{{ if $.Get "stacked" }}
fill: true,
{{ end }}
},
{{ end }}
]
datasets: {{ .Inner | safeJS }}
}
{{ else }}
{{ .Inner | safeJS }}