We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 49c2fde commit 86feae9Copy full SHA for 86feae9
echarts/chart.go
@@ -2,7 +2,10 @@ package echarts
2
3
import (
4
"bytes"
5
+ "encoding/json"
6
"github.com/go-echarts/go-echarts/charts"
7
+ "github.com/go-echarts/go-echarts/datasets"
8
+ "github.com/go-echarts/go-echarts/templates"
9
"html/template"
10
"strings"
11
)
@@ -12,6 +15,16 @@ type Chart struct {
12
15
}
13
16
14
17
func NewChart() *Chart {
18
+
19
+ templates.BaseTpl = List["base"]
20
+ templates.ChartTpl = List["chart"]
21
+ templates.HeaderTpl = List["header"]
22
+ templates.PageTpl = List["page"]
23
+ templates.RoutersTpl = List["routes"]
24
25
+ _ = json.Unmarshal([]byte(coorJson), &datasets.Coordinates)
26
+ _ = json.Unmarshal([]byte(mapfileName), &datasets.MapFileNames)
27
28
return new(Chart)
29
30
0 commit comments