を使用してこれを達成しましたstacked: false
。
コード例。
チャート:
Ext.define('App.Domain.Chart', {
extend: 'Ext.chart.CartesianChart',
title: 'Chart',
alias: 'widget.appDomainChart',
legend: {
docked: 'bottom'
},
interactions: ['itemhighlight'],
colors: ['blue', 'red'],
axes: [{
type: 'numeric',
position: 'left',
adjustByMajorUnit: true,
grid: true,
fields: ['ActualParameter'],
minimum: 0
}, {
type: 'category',
position: 'bottom',
grid: true,
fields: ['ControlValue'],
}],
series: [{
type: 'bar',
axis: 'left',
title: ['Fact', 'Planned'],
xField: 'ControlValue',
yField: ['ActualParameter', 'PlannedParameter'],
display: 'outside',
stacked: false,
style: {
opacity: 0.80
},
highlight: {
fillStyle: 'green'
},
tooltip: {
style: 'background: #fff',
renderer: function (storeItem, item) {
var browser = item.series.getTitle()[Ext.Array.indexOf(item.series.getYField(), item.field)];
this.setHtml(browser + ': ' + storeItem.get(item.field) + '.');
}
}
}]
});
データ:
{
"data": {
"items": [
{
"Id": 54,
"ObjectName": null,
"StageName": null,
"Result": "Result 1",
"ControlValue": "Control value 1",
"PlannedParameter": 10.0,
"ActualParameter": 10.0,
"Unit": "days",
"Indicator": 1
},
{
"Id": 55,
"ObjectName": null,
"StageName": null,
"Result": "",
"ControlValue": "Control value 2",
"PlannedParameter": 3.0,
"ActualParameter": 3.0,
"Unit": "departments",
"Indicator": 1
},
{
"Id": 56,
"ObjectName": null,
"StageName": null,
"Result": "",
"ControlValue": "Control value 3",
"PlannedParameter": 100.0,
"ActualParameter": 100.0,
"Unit": "%",
"Indicator": 4
}
],
"totalCount": 3
},
"errors": [],
"success": true,
"totalCount": 3,
"globalErrors": []
}
画像としての結果: http://screencast.com/t/ilb0mYZIUJ4