Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
dataease
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
njgzx
dataease
Commits
b8f4a819
提交
b8f4a819
authored
8月 16, 2021
作者:
taojinlong
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'dev' of github.com:dataease/dataease into dev
上级
4c8e061e
9a505743
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
36 行增加
和
23 行删除
+36
-23
V19__area_mapping.sql
...end/src/main/resources/db/migration/V19__area_mapping.sql
+18
-18
ChartComponent.vue
frontend/src/views/chart/components/ChartComponent.vue
+6
-2
ChartEdit.vue
frontend/src/views/chart/view/ChartEdit.vue
+12
-3
没有找到文件。
backend/src/main/resources/db/migration/V19__area_mapping.sql
浏览文件 @
b8f4a819
...
@@ -3182,24 +3182,24 @@ INSERT INTO `area_mapping` VALUES (3011, '台湾省', '710000', '台湾省', '71
...
@@ -3182,24 +3182,24 @@ INSERT INTO `area_mapping` VALUES (3011, '台湾省', '710000', '台湾省', '71
INSERT
INTO
`area_mapping`
VALUES
(
3012
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'苗栗县'
,
'717000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3012
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'苗栗县'
,
'717000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3013
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'南投县'
,
'718000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3013
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'南投县'
,
'718000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3014
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'台北市'
,
'719000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3014
,
'台湾省'
,
'710000'
,
'台湾省'
,
'710000'
,
'台北市'
,
'719000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3015
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'中西区'
,
'810
1
01'
);
INSERT
INTO
`area_mapping`
VALUES
(
3015
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'中西区'
,
'810
0
01'
);
INSERT
INTO
`area_mapping`
VALUES
(
3016
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
东区'
,
'8101
02'
);
INSERT
INTO
`area_mapping`
VALUES
(
3016
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
湾仔区'
,
'8100
02'
);
INSERT
INTO
`area_mapping`
VALUES
(
3017
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
九龙城区'
,
'8101
03'
);
INSERT
INTO
`area_mapping`
VALUES
(
3017
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
东区'
,
'8100
03'
);
INSERT
INTO
`area_mapping`
VALUES
(
3018
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
观塘区'
,
'8101
04'
);
INSERT
INTO
`area_mapping`
VALUES
(
3018
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
南区'
,
'8100
04'
);
INSERT
INTO
`area_mapping`
VALUES
(
3019
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
南区'
,
'8101
05'
);
INSERT
INTO
`area_mapping`
VALUES
(
3019
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
油尖旺区'
,
'8100
05'
);
INSERT
INTO
`area_mapping`
VALUES
(
3020
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'深水埗区'
,
'810
1
06'
);
INSERT
INTO
`area_mapping`
VALUES
(
3020
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'深水埗区'
,
'810
0
06'
);
INSERT
INTO
`area_mapping`
VALUES
(
3021
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
湾仔区'
,
'8101
07'
);
INSERT
INTO
`area_mapping`
VALUES
(
3021
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
九龙城区'
,
'8100
07'
);
INSERT
INTO
`area_mapping`
VALUES
(
3022
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'黄大仙区'
,
'810
1
08'
);
INSERT
INTO
`area_mapping`
VALUES
(
3022
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'黄大仙区'
,
'810
0
08'
);
INSERT
INTO
`area_mapping`
VALUES
(
3023
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
油尖旺区'
,
'8101
09'
);
INSERT
INTO
`area_mapping`
VALUES
(
3023
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
观塘区'
,
'8100
09'
);
INSERT
INTO
`area_mapping`
VALUES
(
3024
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
离岛区'
,
'8101
10'
);
INSERT
INTO
`area_mapping`
VALUES
(
3024
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
荃湾区'
,
'8100
10'
);
INSERT
INTO
`area_mapping`
VALUES
(
3025
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
葵青区'
,
'8101
11'
);
INSERT
INTO
`area_mapping`
VALUES
(
3025
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
屯门区'
,
'8100
11'
);
INSERT
INTO
`area_mapping`
VALUES
(
3026
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
北区'
,
'8101
12'
);
INSERT
INTO
`area_mapping`
VALUES
(
3026
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
元朗区'
,
'8100
12'
);
INSERT
INTO
`area_mapping`
VALUES
(
3027
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
西贡区'
,
'8101
13'
);
INSERT
INTO
`area_mapping`
VALUES
(
3027
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
北区'
,
'8100
13'
);
INSERT
INTO
`area_mapping`
VALUES
(
3028
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
沙田区'
,
'8101
14'
);
INSERT
INTO
`area_mapping`
VALUES
(
3028
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
大埔区'
,
'8100
14'
);
INSERT
INTO
`area_mapping`
VALUES
(
3029
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
屯门区'
,
'8101
15'
);
INSERT
INTO
`area_mapping`
VALUES
(
3029
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
西贡区'
,
'8100
15'
);
INSERT
INTO
`area_mapping`
VALUES
(
3030
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
大埔区'
,
'8101
16'
);
INSERT
INTO
`area_mapping`
VALUES
(
3030
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
沙田区'
,
'8100
16'
);
INSERT
INTO
`area_mapping`
VALUES
(
3031
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
荃湾区'
,
'8101
17'
);
INSERT
INTO
`area_mapping`
VALUES
(
3031
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
葵青区'
,
'8100
17'
);
INSERT
INTO
`area_mapping`
VALUES
(
3032
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
元朗区'
,
'8101
18'
);
INSERT
INTO
`area_mapping`
VALUES
(
3032
,
'香港特别行政区'
,
'810000'
,
'香港特别行政区'
,
'810100'
,
'
离岛区'
,
'8100
18'
);
INSERT
INTO
`area_mapping`
VALUES
(
3033
,
'澳门特别行政区'
,
'820000'
,
'澳门特别行政区'
,
'820000'
,
'澳门特别行政区'
,
'820000'
);
INSERT
INTO
`area_mapping`
VALUES
(
3033
,
'澳门特别行政区'
,
'820000'
,
'澳门特别行政区'
,
'820000'
,
'澳门特别行政区'
,
'820000'
);
COMMIT
;
COMMIT
;
...
...
frontend/src/views/chart/components/ChartComponent.vue
浏览文件 @
b8f4a819
...
@@ -166,24 +166,28 @@ export default {
...
@@ -166,24 +166,28 @@ export default {
this
.
myEcharts
(
chart_option
)
this
.
myEcharts
(
chart_option
)
},
},
registerDynamicMap
(
areaCode
)
{
registerDynamicMap
(
areaCode
)
{
this
.
downOrUp
=
true
if
(
this
.
$store
.
getters
.
geoMap
[
areaCode
])
{
if
(
this
.
$store
.
getters
.
geoMap
[
areaCode
])
{
this
.
downOrUp
=
true
const
json
=
this
.
$store
.
getters
.
geoMap
[
areaCode
]
const
json
=
this
.
$store
.
getters
.
geoMap
[
areaCode
]
this
.
$echarts
.
registerMap
(
'MAP'
,
json
)
this
.
$echarts
.
registerMap
(
'MAP'
,
json
)
console
.
log
(
'开始切换地图:'
+
areaCode
)
return
return
}
}
geoJson
(
areaCode
).
then
(
res
=>
{
geoJson
(
areaCode
).
then
(
res
=>
{
this
.
downOrUp
=
true
this
.
$echarts
.
registerMap
(
'MAP'
,
res
)
this
.
$echarts
.
registerMap
(
'MAP'
,
res
)
console
.
log
(
'开始切换地图:'
+
areaCode
)
this
.
$store
.
dispatch
(
'map/setGeo'
,
{
this
.
$store
.
dispatch
(
'map/setGeo'
,
{
key
:
areaCode
,
key
:
areaCode
,
value
:
res
value
:
res
})
})
}).
catch
(()
=>
{
this
.
downOrUp
=
true
})
})
},
},
initMapChart
(
geoJson
,
chart
)
{
initMapChart
(
geoJson
,
chart
)
{
if
(
!
this
.
$echarts
.
getMap
(
'MAP'
)
||
!
this
.
downOrUp
)
{
if
(
!
this
.
$echarts
.
getMap
(
'MAP'
)
||
!
this
.
downOrUp
)
{
console
.
log
(
'开始初始化地图:'
)
this
.
$echarts
.
registerMap
(
'MAP'
,
geoJson
)
this
.
$echarts
.
registerMap
(
'MAP'
,
geoJson
)
}
}
// this.$echarts.getMap('MAP') || this.$echarts.registerMap('MAP', geoJson)
// this.$echarts.getMap('MAP') || this.$echarts.registerMap('MAP', geoJson)
...
...
frontend/src/views/chart/view/ChartEdit.vue
浏览文件 @
b8f4a819
...
@@ -1406,9 +1406,16 @@ export default {
...
@@ -1406,9 +1406,16 @@ export default {
chartClick
(
param
)
{
chartClick
(
param
)
{
if
(
this
.
drillClickDimensionList
.
length
<
this
.
view
.
drillFields
.
length
-
1
)
{
if
(
this
.
drillClickDimensionList
.
length
<
this
.
view
.
drillFields
.
length
-
1
)
{
this
.
chart
.
type
===
'map'
&&
this
.
sendToChildren
(
param
)
// const isSwitch = (this.chart.type === 'map' && this.sendToChildren(param))
this
.
drillClickDimensionList
.
push
({
dimensionList
:
param
.
data
.
dimensionList
})
if
(
this
.
chart
.
type
===
'map'
)
{
this
.
getData
(
this
.
param
.
id
)
if
(
this
.
sendToChildren
(
param
))
{
this
.
drillClickDimensionList
.
push
({
dimensionList
:
param
.
data
.
dimensionList
})
this
.
getData
(
this
.
param
.
id
)
}
}
else
{
this
.
drillClickDimensionList
.
push
({
dimensionList
:
param
.
data
.
dimensionList
})
this
.
getData
(
this
.
param
.
id
)
}
}
}
},
},
...
@@ -1457,9 +1464,11 @@ export default {
...
@@ -1457,9 +1464,11 @@ export default {
const
currentNode
=
this
.
findEntityByCode
(
aCode
||
this
.
view
.
customAttr
.
areaCode
,
this
.
places
)
const
currentNode
=
this
.
findEntityByCode
(
aCode
||
this
.
view
.
customAttr
.
areaCode
,
this
.
places
)
if
(
currentNode
&&
currentNode
.
children
&&
currentNode
.
children
.
length
>
0
)
{
if
(
currentNode
&&
currentNode
.
children
&&
currentNode
.
children
.
length
>
0
)
{
const
nextNode
=
currentNode
.
children
.
find
(
item
=>
item
.
name
===
name
)
const
nextNode
=
currentNode
.
children
.
find
(
item
=>
item
.
name
===
name
)
if
(
!
nextNode
||
!
nextNode
.
code
)
return
null
// this.view.customAttr.areaCode = nextNode.code
// this.view.customAttr.areaCode = nextNode.code
this
.
currentAcreaNode
=
nextNode
this
.
currentAcreaNode
=
nextNode
this
.
$refs
.
dynamicChart
&&
this
.
$refs
.
dynamicChart
.
registerDynamicMap
&&
this
.
$refs
.
dynamicChart
.
registerDynamicMap
(
nextNode
.
code
)
this
.
$refs
.
dynamicChart
&&
this
.
$refs
.
dynamicChart
.
registerDynamicMap
&&
this
.
$refs
.
dynamicChart
.
registerDynamicMap
(
nextNode
.
code
)
return
nextNode
}
}
},
},
// 根据地名获取areaCode
// 根据地名获取areaCode
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论