Add support for yAxis on chart exp/imp
This commit is contained in:
@@ -651,6 +651,10 @@ func expCharts(charts types.ChartSet, modules types.ModuleSet) (o map[string]Cha
|
||||
"renderer": r.Renderer,
|
||||
}
|
||||
|
||||
if r.YAxis != nil {
|
||||
rOut["yAxis"] = r.YAxis
|
||||
}
|
||||
|
||||
if r.ModuleID > 0 {
|
||||
module := modules.FindByID(r.ModuleID)
|
||||
rOut["module"] = makeHandleFromName(module.Name, module.Handle, "module-%d", module.ID)
|
||||
|
||||
@@ -158,6 +158,10 @@ func (cImp *Chart) castConfigReports(chart *types.Chart, def interface{}) ([]*ty
|
||||
r.Metrics = deinterfacer.ToSliceOfStringToInterfaceMap(val)
|
||||
case "dimensions":
|
||||
r.Dimensions = deinterfacer.ToSliceOfStringToInterfaceMap(val)
|
||||
case "yAxis":
|
||||
if YAxis, ok := deinterfacer.Simplify(val).(map[string]interface{}); ok {
|
||||
r.YAxis = YAxis
|
||||
}
|
||||
case "renderer":
|
||||
// @todo implement renderer decoding
|
||||
// r.Renderer.Version
|
||||
|
||||
Reference in New Issue
Block a user