view: view_chart,
container: self.element_id+"-"+self.chart+"chart",
value:"#"+group_list[0].group+"#",
- gradient: "3d",
+ gradient: (self.chart == "bar") ? "3d" : "light",
+ alpha: (self.chart == "area") ? 0.6 : 1,
border: false,
width: 1024,
tooltip:{
self.abscissa, group_list[0].text, group_list[0].group)
},
radius: 0,
- color:group_list[0].color,
+ color: (self.chart != "line") ? group_list[0].color : "",
+ item: (self.chart == "line") ? {
+ borderColor: group_list[0].color,
+ color: "#000000"
+ } : "",
+ line: (self.chart == "line") ? {
+ color: group_list[0].color,
+ width: 3
+ } : "",
origin:0,
xAxis: x_axis,
yAxis: y_axis,
}
}
});
- if (self.chart == 'line'){
- charts.define("item",{
- borderColor: group_list[0].color,
- color: "#000000"
- });
- charts.define("line",{
- color: group_list[0].color,
- width: 3
- });
- }
+
for (var m = 1; m<group_list.length;m++){
var column = group_list[m];
if (column.group === self.group_field) { continue; }
template: _.str.sprintf("#%s#, %s=#%s#",
self.abscissa, column.text, column.group)
},
- color: column.color
+ color: (self.chart != "line") ? column.color : "",
+ item: (self.chart == "line") ? {
+ borderColor: column.color,
+ color: "#000000"
+ } : "",
+ line: (self.chart == "line") ? {
+ color: column.color,
+ width: 3
+ } : ""
});
- if (self.chart == 'line'){
- charts.define("item",{
- borderColor: column.color,
- color: "#000000"
- });
- charts.define("line",{
- color: column.color,
- width: 3
- });
- }
}
charts.parse(results, "json");
self.$element.find("#"+self.element_id+"-"+self.chart+"chart").height(