Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
x649585723
incubator-echarts
提交
b3c0e1fd
I
incubator-echarts
项目概览
x649585723
/
incubator-echarts
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
I
incubator-echarts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
b3c0e1fd
编写于
1月 02, 2016
作者:
L
lang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
geoLine => lines
上级
d61d53c2
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
30 addition
and
25 deletion
+30
-25
build/config.js
build/config.js
+1
-1
src/chart/lines.js
src/chart/lines.js
+4
-6
src/chart/lines/LinesSeries.js
src/chart/lines/LinesSeries.js
+10
-6
src/chart/lines/LinesView.js
src/chart/lines/LinesView.js
+1
-1
src/chart/lines/linesLayout.js
src/chart/lines/linesLayout.js
+6
-5
src/preprocessor/backwardCompat.js
src/preprocessor/backwardCompat.js
+1
-1
test/funnel.html
test/funnel.html
+3
-1
test/geoLine.html
test/geoLine.html
+4
-4
未找到文件。
build/config.js
浏览文件 @
b3c0e1fd
...
...
@@ -37,7 +37,7 @@
'
echarts/chart/boxplot
'
,
'
echarts/chart/candlestick
'
,
'
echarts/chart/effectScatter
'
,
'
echarts/chart/
geoLine
'
,
'
echarts/chart/
lines
'
,
'
echarts/chart/heatmap
'
,
'
echarts/component/geo
'
,
...
...
src/chart/
geoLine
.js
→
src/chart/
lines
.js
浏览文件 @
b3c0e1fd
define
(
function
(
require
)
{
require
(
'
./geoLine/GeoLineSeries
'
);
require
(
'
./geoLine/GeoLineView
'
);
require
(
'
../component/geo
'
);
require
(
'
./lines/LinesSeries
'
);
require
(
'
./lines/LinesView
'
);
var
zrUtil
=
require
(
'
zrender/core/util
'
);
var
echarts
=
require
(
'
../echarts
'
);
echarts
.
registerLayout
(
require
(
'
./
geoLine/geoLine
Layout
'
)
require
(
'
./
lines/lines
Layout
'
)
);
echarts
.
registerVisualCoding
(
'
chart
'
,
zrUtil
.
curry
(
require
(
'
../visual/seriesColor
'
),
'
geoLine
'
,
'
lineStyle
'
)
'
chart
'
,
zrUtil
.
curry
(
require
(
'
../visual/seriesColor
'
),
'
lines
'
,
'
lineStyle
'
)
);
});
\ No newline at end of file
src/chart/
geoLine/GeoLine
Series.js
→
src/chart/
lines/Lines
Series.js
浏览文件 @
b3c0e1fd
...
...
@@ -8,7 +8,7 @@ define(function (require) {
return
SeriesModel
.
extend
({
type
:
'
series.
geoLine
'
,
type
:
'
series.
lines
'
,
dependencies
:
[
'
grid
'
,
'
polar
'
],
...
...
@@ -25,8 +25,15 @@ define(function (require) {
));
});
var
fromData
=
new
List
([
'
lng
'
,
'
lat
'
],
this
);
var
toData
=
new
List
([
'
lng
'
,
'
lat
'
],
this
);
var
coordSys
=
option
.
coordinateSystem
;
if
(
coordSys
!==
'
cartesian2d
'
&&
coordSys
!==
'
geo
'
)
{
throw
new
Error
(
'
Coordinate system can only be cartesian2d or geo in lines
'
);
}
var
dimensions
=
coordSys
===
'
geo
'
?
[
'
lng
'
,
'
lat
'
]
:
[
'
x
'
,
'
y
'
];
var
fromData
=
new
List
(
dimensions
,
this
);
var
toData
=
new
List
(
dimensions
,
this
);
var
lineData
=
new
List
([
'
value
'
],
this
);
function
geoCoordGetter
(
item
,
dim
,
dataIndex
,
dimIndex
)
{
...
...
@@ -54,9 +61,6 @@ define(function (require) {
xAxisIndex
:
0
,
yAxisIndex
:
0
,
// Polar coordinate system
polarIndex
:
0
,
// Geo coordinate system
geoIndex
:
0
,
...
...
src/chart/
geoLine/GeoLine
View.js
→
src/chart/
lines/Lines
View.js
浏览文件 @
b3c0e1fd
...
...
@@ -6,7 +6,7 @@ define(function (require) {
require
(
'
../../echarts
'
).
extendChartView
({
type
:
'
geoLine
'
,
type
:
'
lines
'
,
init
:
function
()
{},
...
...
src/chart/
geoLine/geoLine
Layout.js
→
src/chart/
lines/lines
Layout.js
浏览文件 @
b3c0e1fd
define
(
function
(
require
)
{
return
function
(
ecModel
)
{
ecModel
.
eachSeriesByType
(
'
geoLine
'
,
function
(
seriesModel
)
{
ecModel
.
eachSeriesByType
(
'
lines
'
,
function
(
seriesModel
)
{
var
coordSys
=
seriesModel
.
coordinateSystem
;
var
fromData
=
seriesModel
.
fromData
;
var
toData
=
seriesModel
.
toData
;
var
lineData
=
seriesModel
.
getData
();
fromData
.
each
([
'
lng
'
,
'
lat
'
],
function
(
lng
,
lat
,
idx
)
{
fromData
.
setItemLayout
(
idx
,
coordSys
.
dataToPoint
([
lng
,
lat
]));
var
dims
=
coordSys
.
dimensions
;
fromData
.
each
(
dims
,
function
(
x
,
y
,
idx
)
{
fromData
.
setItemLayout
(
idx
,
coordSys
.
dataToPoint
([
x
,
y
]));
});
toData
.
each
(
[
'
lng
'
,
'
lat
'
],
function
(
lng
,
lat
,
idx
)
{
toData
.
setItemLayout
(
idx
,
coordSys
.
dataToPoint
([
lng
,
lat
]));
toData
.
each
(
dims
,
function
(
x
,
y
,
idx
)
{
toData
.
setItemLayout
(
idx
,
coordSys
.
dataToPoint
([
x
,
y
]));
});
lineData
.
each
(
function
(
idx
)
{
var
p1
=
fromData
.
getItemLayout
(
idx
);
...
...
src/preprocessor/backwardCompat.js
浏览文件 @
b3c0e1fd
...
...
@@ -50,7 +50,7 @@ define(function (require) {
var
COMPATITABLE_SERIES
=
[
'
bar
'
,
'
boxplot
'
,
'
candlestick
'
,
'
chord
'
,
'
effectScatter
'
,
'
funnel
'
,
'
gauge
'
,
'
geoLine
'
,
'
graph
'
,
'
heatmap
'
,
'
line
'
,
'
map
'
,
'
parallel
'
,
'
funnel
'
,
'
gauge
'
,
'
lines
'
,
'
graph
'
,
'
heatmap
'
,
'
line
'
,
'
map
'
,
'
parallel
'
,
'
pie
'
,
'
radar
'
,
'
sankey
'
,
'
scatter
'
,
'
treemap
'
];
...
...
test/funnel.html
浏览文件 @
b3c0e1fd
...
...
@@ -96,7 +96,9 @@
}
},
labelLine
:
{
length
:
config
.
labelLineLen
normal
:
{
length
:
config
.
labelLineLen
}
}
}]
});
...
...
test/geoLine.html
浏览文件 @
b3c0e1fd
...
...
@@ -20,7 +20,7 @@
require
([
'
echarts
'
,
'
echarts/chart/
geoLine
'
,
'
echarts/chart/
lines
'
,
'
echarts/chart/effectScatter
'
,
'
echarts/component/legend
'
,
'
echarts/component/geo
'
...
...
@@ -209,7 +209,7 @@
[[
'
北京
'
,
BJData
],
[
'
上海
'
,
SHData
],
[
'
广州
'
,
GZData
]].
forEach
(
function
(
item
,
i
)
{
series
.
push
({
name
:
item
[
0
]
+
'
Top10
'
,
type
:
'
geoLine
'
,
type
:
'
lines
'
,
zlevel
:
1
,
effect
:
{
show
:
true
,
...
...
@@ -229,7 +229,7 @@
},
{
name
:
item
[
0
]
+
'
Top10
'
,
type
:
'
geoLine
'
,
type
:
'
lines
'
,
zlevel
:
2
,
effect
:
{
show
:
true
,
...
...
@@ -275,7 +275,7 @@
return
{
name
:
dataItem
[
1
].
name
,
value
:
geoCoordMap
[
dataItem
[
1
].
name
].
concat
([
dataItem
[
1
].
value
])
}
}
;
})
});
});
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录