Skip to content

Commit

Permalink
fix #190
Browse files Browse the repository at this point in the history
  • Loading branch information
kener committed Jan 17, 2014
1 parent af12408 commit 9b97ca1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/component/categoryAxis.js
Original file line number Diff line number Diff line change
Expand Up @@ -668,11 +668,13 @@ define(function (require) {

// 根据类目轴数据索引换算类目轴名称
function getNameByIndex(dataIndex) {
if (typeof option.data[dataIndex].value != 'undefined') {
return option.data[dataIndex].value;
var data = option.data[dataIndex];
if (typeof data != 'undefined' && typeof data.value != 'undefined')
{
return data.value;
}
else {
return option.data[dataIndex];
return data;
}
}

Expand Down

0 comments on commit 9b97ca1

Please sign in to comment.