Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
alon@wen
echarts
提交
c326e50f
E
echarts
项目概览
alon@wen
/
echarts
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
echarts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
c326e50f
编写于
8月 27, 2015
作者:
L
lang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
空数据处理
上级
ee0824e7
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
39 addition
and
5 deletion
+39
-5
ecn.todo
ecn.todo
+1
-0
src/chart/bar/BarView.js
src/chart/bar/BarView.js
+10
-0
src/chart/bar/barLayoutGrid.js
src/chart/bar/barLayoutGrid.js
+7
-0
src/coord/cartesian/Axis.js
src/coord/cartesian/Axis.js
+5
-0
src/coord/cartesian/Grid.js
src/coord/cartesian/Grid.js
+3
-1
src/data/List.js
src/data/List.js
+9
-2
src/scale/Interval.js
src/scale/Interval.js
+4
-2
未找到文件。
ecn.todo
0 → 100644
浏览文件 @
c326e50f
Default Option
\ No newline at end of file
src/chart/bar/BarView.js
浏览文件 @
c326e50f
...
...
@@ -20,6 +20,11 @@ define(function (require) {
data
.
diff
(
this
.
data
)
.
add
(
function
(
dataItem
,
idx
)
{
// 空数据
if
(
dataItem
.
getValue
()
==
null
)
{
return
;
}
var
layout
=
dataItem
.
layout
;
var
normalItemStyle
=
dataItem
.
getModel
(
'
itemStyle.normal
'
);
var
rect
=
new
api
.
Rect
({
...
...
@@ -47,6 +52,11 @@ define(function (require) {
.
start
(
'
cubicOut
'
);
})
.
update
(
function
(
newData
,
oldData
)
{
// 空数据
if
(
newData
.
getValue
()
==
null
)
{
group
.
remove
(
oldData
.
__el
);
return
;
}
// TODO DONT ANIMATE WHEN PROPERTIES ARE EQUAL
oldData
.
__el
.
animateShape
()
.
when
(
500
,
newData
.
layout
)
...
...
src/chart/bar/barLayoutGrid.js
浏览文件 @
c326e50f
...
...
@@ -144,6 +144,13 @@ define(function(require) {
var
coords
=
cartesian
.
dataToCoords
(
data
);
lastStackCoords
[
stackId
]
=
lastStackCoords
[
stackId
]
||
[];
data
.
each
(
function
(
dataItem
,
dataIndex
)
{
var
value
=
dataItem
.
getValue
();
// 空数据
if
(
value
==
null
)
{
return
;
}
var
coord
=
coords
[
dataIndex
];
var
lastCoord
=
lastStackCoords
[
stackId
][
dataIndex
]
||
projectAxis
.
otherCoord
;
var
x
,
y
,
width
,
height
;
...
...
src/coord/cartesian/Axis.js
浏览文件 @
c326e50f
...
...
@@ -61,6 +61,11 @@ define(function (require) {
* @return {number}
*/
dataToCoord
:
function
(
data
,
clamp
)
{
// PENDING
if
(
data
==
null
||
data
===
'
-
'
)
{
return
NaN
;
}
data
=
this
.
scale
.
normalize
(
data
);
return
linearMap
(
data
,
[
0
,
1
],
this
.
_coordExtent
,
clamp
);
...
...
src/coord/cartesian/Grid.js
浏览文件 @
c326e50f
...
...
@@ -255,7 +255,9 @@ define(function(require, factory) {
}
else
{
data
.
eachValue
(
function
(
value
)
{
axisData
[
categoryAxis
.
dim
==
'
y
'
?
'
x
'
:
'
y
'
].
push
(
value
);
if
(
value
!=
null
)
{
axisData
[
categoryAxis
.
dim
==
'
y
'
?
'
x
'
:
'
y
'
].
push
(
value
);
}
});
}
}
...
...
src/data/List.js
浏览文件 @
c326e50f
...
...
@@ -119,12 +119,19 @@ define(function(require) {
* @return {number}
*/
getValue
:
function
()
{
var
value
;
// PENDING
// Value is a single number if data is 1d
if
(
this
.
dimension
===
1
)
{
return
this
.
_value
;
value
=
this
.
_value
;
}
return
this
.
_value
[
this
.
dimension
];
else
{
value
=
this
.
_value
[
this
.
dimension
];
}
if
(
value
===
'
-
'
)
{
value
=
null
;
}
return
value
;
},
/**
...
...
src/scale/Interval.js
浏览文件 @
c326e50f
...
...
@@ -67,8 +67,10 @@ define(function (require) {
setExtentFromData
:
function
(
data
)
{
var
max
=
-
Infinity
;
var
min
=
Infinity
;
var
i
=
0
;
for
(;
i
<
data
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
if
(
data
[
i
]
==
null
||
data
[
i
]
===
'
-
'
)
{
continue
;
}
max
=
Math
.
max
(
data
[
i
],
max
);
min
=
Math
.
min
(
data
[
i
],
min
);
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录