Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
dataease
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
zhu
dataease
Commits
6fe0f5f1
提交
6fe0f5f1
authored
6月 09, 2021
作者:
taojinlong
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'main' of github.com:dataease/dataease into main
上级
08a193d4
9de3b8fc
隐藏空白字符变更
内嵌
并排
正在显示
17 个修改的文件
包含
426 行增加
和
47 行删除
+426
-47
DataSetTableService.java
...java/io/dataease/service/dataset/DataSetTableService.java
+15
-4
V6__alter_table.sql
backend/src/main/resources/db/migration/V6__alter_table.sql
+32
-0
dynamic.js
frontend/src/api/system/dynamic.js
+2
-1
UserView.vue
frontend/src/components/canvas/custom-component/UserView.vue
+1
-0
en.js
frontend/src/lang/en.js
+8
-3
tw.js
frontend/src/lang/tw.js
+8
-3
zh.js
frontend/src/lang/zh.js
+8
-3
TitleSelector.vue
.../views/chart/components/component-style/TitleSelector.vue
+5
-0
Group.vue
frontend/src/views/chart/group/Group.vue
+25
-11
ChartEdit.vue
frontend/src/views/chart/view/ChartEdit.vue
+3
-3
AddCustom.vue
frontend/src/views/dataset/add/AddCustom.vue
+1
-1
AddExcel.vue
frontend/src/views/dataset/add/AddExcel.vue
+1
-1
AddSQL.vue
frontend/src/views/dataset/add/AddSQL.vue
+1
-1
DsMoveSelector.vue
frontend/src/views/dataset/group/DsMoveSelector.vue
+85
-0
Group.vue
frontend/src/views/dataset/group/Group.vue
+138
-16
GroupMoveSelector.vue
frontend/src/views/dataset/group/GroupMoveSelector.vue
+92
-0
index.vue
frontend/src/views/panel/edit/index.vue
+1
-0
没有找到文件。
backend/src/main/java/io/dataease/service/dataset/DataSetTableService.java
浏览文件 @
6fe0f5f1
...
@@ -719,10 +719,14 @@ public class DataSetTableService {
...
@@ -719,10 +719,14 @@ public class DataSetTableService {
}
else
{
}
else
{
rows
=
sheet0
.
getPhysicalNumberOfRows
();
rows
=
sheet0
.
getPhysicalNumberOfRows
();
}
}
int
columnNum
=
0
;
for
(
int
i
=
0
;
i
<
rows
;
i
++)
{
for
(
int
i
=
0
;
i
<
rows
;
i
++)
{
HSSFRow
row
=
sheet0
.
getRow
(
i
);
HSSFRow
row
=
sheet0
.
getRow
(
i
);
String
[]
r
=
new
String
[
row
.
getPhysicalNumberOfCells
()];
if
(
i
==
0
)
{
for
(
int
j
=
0
;
j
<
row
.
getPhysicalNumberOfCells
();
j
++)
{
columnNum
=
row
.
getPhysicalNumberOfCells
();
}
String
[]
r
=
new
String
[
columnNum
];
for
(
int
j
=
0
;
j
<
columnNum
;
j
++)
{
if
(
i
==
0
)
{
if
(
i
==
0
)
{
TableFiled
tableFiled
=
new
TableFiled
();
TableFiled
tableFiled
=
new
TableFiled
();
tableFiled
.
setFieldType
(
"TEXT"
);
tableFiled
.
setFieldType
(
"TEXT"
);
...
@@ -759,10 +763,14 @@ public class DataSetTableService {
...
@@ -759,10 +763,14 @@ public class DataSetTableService {
}
else
{
}
else
{
rows
=
sheet0
.
getPhysicalNumberOfRows
();
rows
=
sheet0
.
getPhysicalNumberOfRows
();
}
}
int
columnNum
=
0
;
for
(
int
i
=
0
;
i
<
rows
;
i
++)
{
for
(
int
i
=
0
;
i
<
rows
;
i
++)
{
XSSFRow
row
=
sheet0
.
getRow
(
i
);
XSSFRow
row
=
sheet0
.
getRow
(
i
);
String
[]
r
=
new
String
[
row
.
getPhysicalNumberOfCells
()];
if
(
i
==
0
)
{
for
(
int
j
=
0
;
j
<
row
.
getPhysicalNumberOfCells
();
j
++)
{
columnNum
=
row
.
getPhysicalNumberOfCells
();
}
String
[]
r
=
new
String
[
columnNum
];
for
(
int
j
=
0
;
j
<
columnNum
;
j
++)
{
if
(
i
==
0
)
{
if
(
i
==
0
)
{
TableFiled
tableFiled
=
new
TableFiled
();
TableFiled
tableFiled
=
new
TableFiled
();
tableFiled
.
setFieldType
(
"TEXT"
);
tableFiled
.
setFieldType
(
"TEXT"
);
...
@@ -828,6 +836,9 @@ public class DataSetTableService {
...
@@ -828,6 +836,9 @@ public class DataSetTableService {
}
}
private
String
readCell
(
Cell
cell
,
boolean
cellType
,
TableFiled
tableFiled
)
{
private
String
readCell
(
Cell
cell
,
boolean
cellType
,
TableFiled
tableFiled
)
{
if
(
cell
==
null
)
{
return
""
;
}
CellType
cellTypeEnum
=
cell
.
getCellTypeEnum
();
CellType
cellTypeEnum
=
cell
.
getCellTypeEnum
();
if
(
cellTypeEnum
.
equals
(
CellType
.
STRING
))
{
if
(
cellTypeEnum
.
equals
(
CellType
.
STRING
))
{
if
(
cellType
)
{
if
(
cellType
)
{
...
...
backend/src/main/resources/db/migration/V6__alter_table.sql
浏览文件 @
6fe0f5f1
ALTER
TABLE
`dataset_table`
ADD
COLUMN
`sync_status`
VARCHAR
(
45
)
NULL
AFTER
`create_time`
;
ALTER
TABLE
`dataset_table`
ADD
COLUMN
`sync_status`
VARCHAR
(
45
)
NULL
AFTER
`create_time`
;
ALTER
TABLE
`dataset_table`
ADD
COLUMN
`qrtz_instance`
VARCHAR
(
1024
)
NULL
AFTER
`create_time`
;
ALTER
TABLE
`dataset_table`
ADD
COLUMN
`qrtz_instance`
VARCHAR
(
1024
)
NULL
AFTER
`create_time`
;
BEGIN
;
INSERT
INTO
`sys_auth`
VALUES
(
'05e5440f-b9c1-4998-bb7e-cabdb293183f'
,
'25'
,
'menu'
,
'2'
,
'role'
,
1622713311975
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'19569764-ad2e-4d7b-b575-508913495ccf'
,
'8'
,
'menu'
,
'2'
,
'role'
,
1622713307681
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'4541d582-b532-47b1-9e64-b4937c7b614f'
,
'30'
,
'menu'
,
'2'
,
'role'
,
1622713299688
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'45dacd42-e9a4-4ce5-a03c-61c8850cf5b1'
,
'10'
,
'menu'
,
'2'
,
'role'
,
1622713304841
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'8b1e1e02-b6c2-49dc-9118-10ab31f78b46'
,
'34'
,
'menu'
,
'2'
,
'role'
,
1623142236719
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'a11f5705-887d-403b-9a9d-d3a1317ed91f'
,
'24'
,
'menu'
,
'2'
,
'role'
,
1622713311583
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'c318d302-457d-43d8-bb01-96a7cbbf6cb7'
,
'27'
,
'menu'
,
'2'
,
'role'
,
1622713313044
,
NULL
,
'admin'
,
NULL
);
INSERT
INTO
`sys_auth`
VALUES
(
'c3349d14-1433-41e6-9ddc-ba947c3b523c'
,
'26'
,
'menu'
,
'2'
,
'role'
,
1622713312606
,
NULL
,
'admin'
,
NULL
);
COMMIT
;
BEGIN
;
INSERT
INTO
`sys_auth_detail`
VALUES
(
'980c14e1-c836-11eb-bbcc-00163e0c8d3f'
,
'8b1e1e02-b6c2-49dc-9118-10ab31f78b46'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1623142236000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'980c1674-c836-11eb-bbcc-00163e0c8d3f'
,
'8b1e1e02-b6c2-49dc-9118-10ab31f78b46'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1623142236000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'e59001d3-c44f-11eb-bbcc-00163e0c8d3f'
,
'4541d582-b532-47b1-9e64-b4937c7b614f'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713299000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'e59003a0-c44f-11eb-bbcc-00163e0c8d3f'
,
'4541d582-b532-47b1-9e64-b4937c7b614f'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713299000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'e8a4bdbf-c44f-11eb-bbcc-00163e0c8d3f'
,
'45dacd42-e9a4-4ce5-a03c-61c8850cf5b1'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713304000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'e8a4bf70-c44f-11eb-bbcc-00163e0c8d3f'
,
'45dacd42-e9a4-4ce5-a03c-61c8850cf5b1'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713304000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ea536049-c44f-11eb-bbcc-00163e0c8d3f'
,
'19569764-ad2e-4d7b-b575-508913495ccf'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713307000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ea5361d6-c44f-11eb-bbcc-00163e0c8d3f'
,
'19569764-ad2e-4d7b-b575-508913495ccf'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713307000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'eca67ad0-c44f-11eb-bbcc-00163e0c8d3f'
,
'a11f5705-887d-403b-9a9d-d3a1317ed91f'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713311000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'eca67c74-c44f-11eb-bbcc-00163e0c8d3f'
,
'a11f5705-887d-403b-9a9d-d3a1317ed91f'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713311000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ece430b9-c44f-11eb-bbcc-00163e0c8d3f'
,
'05e5440f-b9c1-4998-bb7e-cabdb293183f'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713312000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ece4330e-c44f-11eb-bbcc-00163e0c8d3f'
,
'05e5440f-b9c1-4998-bb7e-cabdb293183f'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713312000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ed4328d0-c44f-11eb-bbcc-00163e0c8d3f'
,
'c3349d14-1433-41e6-9ddc-ba947c3b523c'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713312000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ed432abc-c44f-11eb-bbcc-00163e0c8d3f'
,
'c3349d14-1433-41e6-9ddc-ba947c3b523c'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713312000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ed8722a7-c44f-11eb-bbcc-00163e0c8d3f'
,
'c318d302-457d-43d8-bb01-96a7cbbf6cb7'
,
'i18n_auth_grant'
,
15
,
0
,
'grant'
,
'基础权限-授权'
,
'admin'
,
1622713313000
,
NULL
);
INSERT
INTO
`sys_auth_detail`
VALUES
(
'ed872435-c44f-11eb-bbcc-00163e0c8d3f'
,
'c318d302-457d-43d8-bb01-96a7cbbf6cb7'
,
'i18n_auth_use'
,
1
,
1
,
'use'
,
'基础权限-使用'
,
'admin'
,
1622713313000
,
NULL
);
COMMIT
;
\ No newline at end of file
frontend/src/api/system/dynamic.js
浏览文件 @
6fe0f5f1
...
@@ -3,7 +3,8 @@ import request from '@/utils/request'
...
@@ -3,7 +3,8 @@ import request from '@/utils/request'
export
function
get
(
url
)
{
export
function
get
(
url
)
{
return
request
({
return
request
({
url
:
url
,
url
:
url
,
method
:
'get'
method
:
'get'
,
loading
:
true
})
})
}
}
...
...
frontend/src/components/canvas/custom-component/UserView.vue
浏览文件 @
6fe0f5f1
...
@@ -93,6 +93,7 @@ export default {
...
@@ -93,6 +93,7 @@ export default {
},
},
filters
()
{
filters
()
{
// 必要 勿删勿该 watch数组,哪怕发生变化 oldValue等于newValue ,深拷贝解决
// 必要 勿删勿该 watch数组,哪怕发生变化 oldValue等于newValue ,深拷贝解决
if
(
!
this
.
element
.
filters
)
return
[]
return
JSON
.
parse
(
JSON
.
stringify
(
this
.
element
.
filters
))
return
JSON
.
parse
(
JSON
.
stringify
(
this
.
element
.
filters
))
},
},
...
mapState
([
...
mapState
([
...
...
frontend/src/lang/en.js
浏览文件 @
6fe0f5f1
...
@@ -663,7 +663,7 @@ export default {
...
@@ -663,7 +663,7 @@ export default {
radius_mode
:
'Radius'
,
radius_mode
:
'Radius'
,
area_mode
:
'Area'
,
area_mode
:
'Area'
,
rose_radius
:
'Fillet'
,
rose_radius
:
'Fillet'
,
view_name
:
'Chart
Nam
e'
,
view_name
:
'Chart
Titl
e'
,
name_can_not_empty
:
'Name cannot be empty'
,
name_can_not_empty
:
'Name cannot be empty'
,
template_can_not_empty
:
'Please check a Template'
,
template_can_not_empty
:
'Please check a Template'
,
custom_count
:
'Number of records'
,
custom_count
:
'Number of records'
,
...
@@ -715,7 +715,8 @@ export default {
...
@@ -715,7 +715,8 @@ export default {
date_split
:
'yyyy/MM/dd'
,
date_split
:
'yyyy/MM/dd'
,
chartName
:
'New Chart'
,
chartName
:
'New Chart'
,
chart_show_error
:
'can not show normal'
,
chart_show_error
:
'can not show normal'
,
chart_error_tips
:
'Please contact admin '
chart_error_tips
:
'Please contact admin '
,
title_cannot_empty
:
'Title can not be empty'
},
},
dataset
:
{
dataset
:
{
sheet_warn
:
'There are multiple sheet pages, and the first one is extracted by default'
,
sheet_warn
:
'There are multiple sheet pages, and the first one is extracted by default'
,
...
@@ -834,7 +835,11 @@ export default {
...
@@ -834,7 +835,11 @@ export default {
edit_excel_table
:
'Edit Excel Dataset'
,
edit_excel_table
:
'Edit Excel Dataset'
,
edit_excel
:
'Edit Excel'
,
edit_excel
:
'Edit Excel'
,
excel_replace
:
'Replace'
,
excel_replace
:
'Replace'
,
excel_add
:
'Add'
excel_add
:
'Add'
,
dataset_group
:
'Dataset Group'
,
m1
:
'Move '
,
m2
:
' To'
,
char_can_not_more_50
:
'Dataset name can not more 50'
},
},
datasource
:
{
datasource
:
{
datasource
:
'Data Source'
,
datasource
:
'Data Source'
,
...
...
frontend/src/lang/tw.js
浏览文件 @
6fe0f5f1
...
@@ -663,7 +663,7 @@ export default {
...
@@ -663,7 +663,7 @@ export default {
radius_mode
:
'半徑'
,
radius_mode
:
'半徑'
,
area_mode
:
'面積'
,
area_mode
:
'面積'
,
rose_radius
:
'園角'
,
rose_radius
:
'園角'
,
view_name
:
'視圖
名稱
'
,
view_name
:
'視圖
標題
'
,
name_can_not_empty
:
'名稱不能為空'
,
name_can_not_empty
:
'名稱不能為空'
,
template_can_not_empty
:
'请选择仪表板'
,
template_can_not_empty
:
'请选择仪表板'
,
custom_count
:
'記錄數'
,
custom_count
:
'記錄數'
,
...
@@ -715,7 +715,8 @@ export default {
...
@@ -715,7 +715,8 @@ export default {
date_split
:
'yyyy/MM/dd'
,
date_split
:
'yyyy/MM/dd'
,
chartName
:
'新建視圖'
,
chartName
:
'新建視圖'
,
chart_show_error
:
'無法正常顯示'
,
chart_show_error
:
'無法正常顯示'
,
chart_error_tips
:
'如有疑問請聯系管理員'
chart_error_tips
:
'如有疑問請聯系管理員'
,
title_cannot_empty
:
'標題不能為空'
},
},
dataset
:
{
dataset
:
{
sheet_warn
:
'有多個sheet頁面,默認抽取第一個'
,
sheet_warn
:
'有多個sheet頁面,默認抽取第一個'
,
...
@@ -834,7 +835,11 @@ export default {
...
@@ -834,7 +835,11 @@ export default {
edit_excel_table
:
'編輯Excel數據集'
,
edit_excel_table
:
'編輯Excel數據集'
,
edit_excel
:
'編輯Excel'
,
edit_excel
:
'編輯Excel'
,
excel_replace
:
'替換'
,
excel_replace
:
'替換'
,
excel_add
:
'追加'
excel_add
:
'追加'
,
dataset_group
:
'數據集分組'
,
m1
:
'將 '
,
m2
:
' 移動到'
,
char_can_not_more_50
:
'數據集名稱不能超過50個字符'
},
},
datasource
:
{
datasource
:
{
datasource
:
'數據源'
,
datasource
:
'數據源'
,
...
...
frontend/src/lang/zh.js
浏览文件 @
6fe0f5f1
...
@@ -663,7 +663,7 @@ export default {
...
@@ -663,7 +663,7 @@ export default {
radius_mode
:
'半径'
,
radius_mode
:
'半径'
,
area_mode
:
'面积'
,
area_mode
:
'面积'
,
rose_radius
:
'圆角'
,
rose_radius
:
'圆角'
,
view_name
:
'视图
名称
'
,
view_name
:
'视图
标题
'
,
name_can_not_empty
:
'名称不能为空'
,
name_can_not_empty
:
'名称不能为空'
,
template_can_not_empty
:
'请选择仪表版'
,
template_can_not_empty
:
'请选择仪表版'
,
custom_count
:
'记录数'
,
custom_count
:
'记录数'
,
...
@@ -715,7 +715,8 @@ export default {
...
@@ -715,7 +715,8 @@ export default {
date_split
:
'yyyy/MM/dd'
,
date_split
:
'yyyy/MM/dd'
,
chartName
:
'新建视图'
,
chartName
:
'新建视图'
,
chart_show_error
:
'无法正常显示'
,
chart_show_error
:
'无法正常显示'
,
chart_error_tips
:
'如有疑问请联系管理员'
chart_error_tips
:
'如有疑问请联系管理员'
,
title_cannot_empty
:
'标题不能为空'
},
},
dataset
:
{
dataset
:
{
sheet_warn
:
'有多个 Sheet 页,默认抽取第一个'
,
sheet_warn
:
'有多个 Sheet 页,默认抽取第一个'
,
...
@@ -834,7 +835,11 @@ export default {
...
@@ -834,7 +835,11 @@ export default {
edit_excel_table
:
'编辑Excel数据集'
,
edit_excel_table
:
'编辑Excel数据集'
,
edit_excel
:
'编辑Excel'
,
edit_excel
:
'编辑Excel'
,
excel_replace
:
'替换'
,
excel_replace
:
'替换'
,
excel_add
:
'追加'
excel_add
:
'追加'
,
dataset_group
:
'数据集分组'
,
m1
:
'将 '
,
m2
:
' 移动到'
,
char_can_not_more_50
:
'数据集名称不能超过50个字符'
},
},
datasource
:
{
datasource
:
{
datasource
:
'数据源'
,
datasource
:
'数据源'
,
...
...
frontend/src/views/chart/components/component-style/TitleSelector.vue
浏览文件 @
6fe0f5f1
...
@@ -115,6 +115,11 @@ export default {
...
@@ -115,6 +115,11 @@ export default {
this
.
fontSize
=
arr
this
.
fontSize
=
arr
},
},
changeTitleStyle
()
{
changeTitleStyle
()
{
if
(
this
.
titleForm
.
title
.
length
<
1
)
{
this
.
$error
(
this
.
$t
(
'chart.title_cannot_empty'
))
this
.
titleForm
.
title
=
this
.
chart
.
title
return
}
if
(
!
this
.
titleForm
.
show
)
{
if
(
!
this
.
titleForm
.
show
)
{
this
.
isSetting
=
false
this
.
isSetting
=
false
}
}
...
...
frontend/src/views/chart/group/Group.vue
浏览文件 @
6fe0f5f1
...
@@ -40,6 +40,8 @@
...
@@ -40,6 +40,8 @@
node-key=
"id"
node-key=
"id"
:expand-on-click-node=
"true"
:expand-on-click-node=
"true"
@
node-click=
"nodeClick"
@
node-click=
"nodeClick"
@
node-expand=
"nodeExpand"
@
node-collapse=
"nodeCollapse"
>
>
<span
slot-scope=
"
{ node, data }" class="custom-tree-node father">
<span
slot-scope=
"
{ node, data }" class="custom-tree-node father">
<span
style=
"display: flex;flex: 1;width: 0;"
>
<span
style=
"display: flex;flex: 1;width: 0;"
>
...
@@ -166,9 +168,9 @@
...
@@ -166,9 +168,9 @@
/>
/>
</span>
</span>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-menu
slot=
"dropdown"
>
<
el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('renameChart',data,node)"
>
<
!--
<el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('renameChart',data,node)"
>
--
>
{{
$t
(
'chart.rename'
)
}}
<!--
{{
$t
(
'chart.rename'
)
}}
-->
<
/el-dropdown-item
>
<
!--
</el-dropdown-item>
--
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('deleteChart',data,node)"
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('deleteChart',data,node)"
>
{{
$t
(
'chart.delete'
)
}}
{{
$t
(
'chart.delete'
)
}}
</el-dropdown-item>
</el-dropdown-item>
...
@@ -491,14 +493,14 @@ export default {
...
@@ -491,14 +493,14 @@ export default {
this
.
$store
.
dispatch
(
'chart/setSceneId'
,
this
.
currGroup
.
id
)
this
.
$store
.
dispatch
(
'chart/setSceneId'
,
this
.
currGroup
.
id
)
this
.
chartTree
()
this
.
chartTree
()
}
}
if
(
node
.
expanded
)
{
//
if (node.expanded) {
this
.
expandedArray
.
push
(
data
.
id
)
//
this.expandedArray.push(data.id)
}
else
{
//
} else {
const
index
=
this
.
expandedArray
.
indexOf
(
data
.
id
)
//
const index = this.expandedArray.indexOf(data.id)
if
(
index
>
-
1
)
{
//
if (index > -1) {
this
.
expandedArray
.
splice
(
index
,
1
)
//
this.expandedArray.splice(index, 1)
}
//
}
}
//
}
},
},
back
()
{
back
()
{
...
@@ -534,6 +536,7 @@ export default {
...
@@ -534,6 +536,7 @@ export default {
this
.
chartData
.
forEach
(
function
(
ele
)
{
this
.
chartData
.
forEach
(
function
(
ele
)
{
if
(
ele
.
id
===
that
.
$store
.
state
.
chart
.
chartSceneData
.
id
)
{
if
(
ele
.
id
===
that
.
$store
.
state
.
chart
.
chartSceneData
.
id
)
{
ele
.
type
=
that
.
$store
.
state
.
chart
.
chartSceneData
.
type
ele
.
type
=
that
.
$store
.
state
.
chart
.
chartSceneData
.
type
ele
.
name
=
that
.
$store
.
state
.
chart
.
chartSceneData
.
name
}
}
})
})
}
}
...
@@ -609,6 +612,17 @@ export default {
...
@@ -609,6 +612,17 @@ export default {
this
.
currGroup
=
response
.
data
this
.
currGroup
=
response
.
data
})
})
}
}
},
nodeExpand
(
data
)
{
if
(
data
.
id
)
{
this
.
expandedArray
.
push
(
data
.
id
)
}
},
nodeCollapse
(
data
)
{
if
(
data
.
id
)
{
this
.
expandedArray
.
splice
(
this
.
expandedArray
.
indexOf
(
data
.
id
),
1
)
}
}
}
}
}
}
}
...
...
frontend/src/views/chart/view/ChartEdit.vue
浏览文件 @
6fe0f5f1
...
@@ -486,9 +486,9 @@ export default {
...
@@ -486,9 +486,9 @@ export default {
const
view
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
view
))
const
view
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
view
))
view
.
id
=
this
.
view
.
id
view
.
id
=
this
.
view
.
id
view
.
sceneId
=
this
.
view
.
sceneId
view
.
sceneId
=
this
.
view
.
sceneId
view
.
name
=
this
.
view
.
name
?
this
.
view
.
nam
e
:
this
.
table
.
name
view
.
name
=
this
.
view
.
title
?
this
.
view
.
titl
e
:
this
.
table
.
name
if
(
view
.
title
.
length
>
50
)
{
if
(
view
.
title
.
length
>
50
)
{
this
.
$
warning
(
this
.
$t
(
'chart.title_limit'
))
this
.
$
error
(
this
.
$t
(
'chart.title_limit'
))
return
return
}
}
view
.
tableId
=
this
.
view
.
tableId
view
.
tableId
=
this
.
view
.
tableId
...
@@ -623,7 +623,7 @@ export default {
...
@@ -623,7 +623,7 @@ export default {
}
}
// 从仪表板入口关闭
// 从仪表板入口关闭
bus
.
$emit
(
'PanelSwitchComponent'
,
{
name
:
'PanelEdit'
})
bus
.
$emit
(
'PanelSwitchComponent'
,
{
name
:
'PanelEdit'
})
this
.
$emit
(
'switchComponent'
,
{
name
:
''
})
//
this.$emit('switchComponent', { name: '' })
},
},
getData
(
id
)
{
getData
(
id
)
{
if
(
id
)
{
if
(
id
)
{
...
...
frontend/src/views/dataset/add/AddCustom.vue
浏览文件 @
6fe0f5f1
...
@@ -192,7 +192,7 @@ export default {
...
@@ -192,7 +192,7 @@ export default {
if
(
this
.
name
.
length
>
50
)
{
if
(
this
.
name
.
length
>
50
)
{
this
.
$message
({
this
.
$message
({
showClose
:
true
,
showClose
:
true
,
message
:
this
.
$t
(
'
commons
.char_can_not_more_50'
),
message
:
this
.
$t
(
'
dataset
.char_can_not_more_50'
),
type
:
'error'
type
:
'error'
})
})
return
return
...
...
frontend/src/views/dataset/add/AddExcel.vue
浏览文件 @
6fe0f5f1
...
@@ -171,7 +171,7 @@ export default {
...
@@ -171,7 +171,7 @@ export default {
if
(
this
.
name
.
length
>
50
)
{
if
(
this
.
name
.
length
>
50
)
{
this
.
$message
({
this
.
$message
({
showClose
:
true
,
showClose
:
true
,
message
:
this
.
$t
(
'
commons
.char_can_not_more_50'
),
message
:
this
.
$t
(
'
dataset
.char_can_not_more_50'
),
type
:
'error'
type
:
'error'
})
})
return
return
...
...
frontend/src/views/dataset/add/AddSQL.vue
浏览文件 @
6fe0f5f1
...
@@ -248,7 +248,7 @@ export default {
...
@@ -248,7 +248,7 @@ export default {
if
(
this
.
name
.
length
>
50
)
{
if
(
this
.
name
.
length
>
50
)
{
this
.
$message
({
this
.
$message
({
showClose
:
true
,
showClose
:
true
,
message
:
this
.
$t
(
'
commons
.char_can_not_more_50'
),
message
:
this
.
$t
(
'
dataset
.char_can_not_more_50'
),
type
:
'error'
type
:
'error'
})
})
return
return
...
...
frontend/src/views/dataset/group/DsMoveSelector.vue
0 → 100644
浏览文件 @
6fe0f5f1
<
template
>
<el-col
style=
"height: 400px;overflow-y: auto;margin-bottom: 10px;"
>
<el-tree
:data=
"tData"
node-key=
"id"
:expand-on-click-node=
"false"
highlight-current
@
node-click=
"nodeClick"
>
<span
slot-scope=
"
{ node, data }" :class="treeClass(data,node)">
<span
style=
"display: flex;flex: 1;width: 0;"
>
<span
v-if=
"data.type === 'scene'"
>
<svg-icon
icon-class=
"scene"
class=
"ds-icon-scene"
/>
</span>
<span
style=
"margin-left: 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;"
:title=
"data.name"
>
{{
data
.
name
}}
</span>
</span>
</span>
</el-tree>
</el-col>
</
template
>
<
script
>
import
{
groupTree
}
from
'@/api/dataset/dataset'
export
default
{
name
:
'DsMoveSelector'
,
props
:
{
item
:
{
type
:
Object
,
required
:
true
}
},
data
()
{
return
{
tData
:
[],
currGroup
:
''
,
groupForm
:
{
name
:
''
,
pid
:
null
,
level
:
0
,
type
:
''
,
children
:
[],
sort
:
'type desc,name asc'
},
targetGroup
:
{}
}
},
watch
:
{
'item'
:
function
()
{
this
.
tree
(
this
.
groupForm
)
}
},
mounted
()
{
this
.
tree
(
this
.
groupForm
)
},
methods
:
{
tree
(
group
)
{
groupTree
(
group
).
then
(
res
=>
{
this
.
tData
=
res
.
data
})
},
nodeClick
(
data
,
node
)
{
this
.
targetGroup
=
data
this
.
$emit
(
'targetDs'
,
data
)
},
treeClass
(
data
,
node
)
{
if
(
data
.
id
===
this
.
item
.
id
)
{
node
.
visible
=
false
}
return
'custom-tree-node'
},
}
}
</
script
>
<
style
scoped
>
.custom-tree-node
{
flex
:
1
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
font-size
:
14px
;
padding-right
:
8px
;
}
</
style
>
frontend/src/views/dataset/group/Group.vue
浏览文件 @
6fe0f5f1
...
@@ -40,6 +40,8 @@
...
@@ -40,6 +40,8 @@
node-key=
"id"
node-key=
"id"
:expand-on-click-node=
"true"
:expand-on-click-node=
"true"
@
node-click=
"nodeClick"
@
node-click=
"nodeClick"
@
node-expand=
"nodeExpand"
@
node-collapse=
"nodeCollapse"
>
>
<span
slot-scope=
"
{ node, data }" class="custom-tree-node father">
<span
slot-scope=
"
{ node, data }" class="custom-tree-node father">
<span
style=
"display: flex;flex: 1;width: 0;"
>
<span
style=
"display: flex;flex: 1;width: 0;"
>
...
@@ -86,9 +88,9 @@
...
@@ -86,9 +88,9 @@
<el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('rename',data,node)"
>
<el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('rename',data,node)"
>
{{
$t
(
'dataset.rename'
)
}}
{{
$t
(
'dataset.rename'
)
}}
</el-dropdown-item>
</el-dropdown-item>
<
!--
<el-dropdown-item
icon=
"el-icon-right"
:command=
"beforeClickMore('move',data,node)"
>
--
>
<
el-dropdown-item
icon=
"el-icon-right"
:command=
"beforeClickMore('move',data,node)"
>
<!--
{{
$t
(
'dataset.move_to'
)
}}
-->
{{
$t
(
'dataset.move_to'
)
}}
<
!--
</el-dropdown-item>
--
>
<
/el-dropdown-item
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('delete',data,node)"
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('delete',data,node)"
>
{{
$t
(
'dataset.delete'
)
}}
{{
$t
(
'dataset.delete'
)
}}
</el-dropdown-item>
</el-dropdown-item>
...
@@ -207,9 +209,9 @@
...
@@ -207,9 +209,9 @@
<el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('editTable',data,node)"
>
<el-dropdown-item
icon=
"el-icon-edit-outline"
:command=
"beforeClickMore('editTable',data,node)"
>
{{
$t
(
'dataset.rename'
)
}}
{{
$t
(
'dataset.rename'
)
}}
</el-dropdown-item>
</el-dropdown-item>
<
!--
<el-dropdown-item
icon=
"el-icon-right"
:command=
"beforeClickMore('move',data,node)"
>
--
>
<
el-dropdown-item
icon=
"el-icon-right"
:command=
"beforeClickMore('moveDs',data,node)"
>
<!--
{{
$t
(
'dataset.move_to'
)
}}
-->
{{
$t
(
'dataset.move_to'
)
}}
<
!--
</el-dropdown-item>
--
>
<
/el-dropdown-item
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('deleteTable',data,node)"
>
<el-dropdown-item
icon=
"el-icon-delete"
:command=
"beforeClickMore('deleteTable',data,node)"
>
{{
$t
(
'dataset.delete'
)
}}
{{
$t
(
'dataset.delete'
)
}}
</el-dropdown-item>
</el-dropdown-item>
...
@@ -238,14 +240,37 @@
...
@@ -238,14 +240,37 @@
</el-dialog>
</el-dialog>
</el-col>
</el-col>
<!--移动分组、场景-->
<el-dialog
v-dialogDrag
:title=
"moveDialogTitle"
:visible=
"moveGroup"
:show-close=
"false"
width=
"30%"
class=
"dialog-css"
>
<group-move-selector
:item=
"groupForm"
@
targetGroup=
"targetGroup"
/>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
size=
"mini"
@
click=
"closeMoveGroup()"
>
{{
$t
(
'dataset.cancel'
)
}}
</el-button>
<el-button
:disabled=
"groupMoveConfirmDisabled"
type=
"primary"
size=
"mini"
@
click=
"saveMoveGroup(tGroup)"
>
{{
$t
(
'dataset.confirm'
)
}}
</el-button>
</div>
</el-dialog>
<!--移动数据集-->
<el-dialog
v-dialogDrag
:title=
"moveDialogTitle"
:visible=
"moveDs"
:show-close=
"false"
width=
"30%"
class=
"dialog-css"
>
<ds-move-selector
:item=
"dsForm"
@
targetDs=
"targetDs"
/>
<div
slot=
"footer"
class=
"dialog-footer"
>
<el-button
size=
"mini"
@
click=
"closeMoveDs()"
>
{{
$t
(
'dataset.cancel'
)
}}
</el-button>
<el-button
:disabled=
"dsMoveConfirmDisabled"
type=
"primary"
size=
"mini"
@
click=
"saveMoveDs(tDs)"
>
{{
$t
(
'dataset.confirm'
)
}}
</el-button>
</div>
</el-dialog>
</el-col>
</el-col>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
loadTable
,
getScene
,
addGroup
,
delGroup
,
addTable
,
delTable
,
groupTree
}
from
'@/api/dataset/dataset'
import
{
loadTable
,
getScene
,
addGroup
,
delGroup
,
addTable
,
delTable
,
groupTree
}
from
'@/api/dataset/dataset'
import
GroupMoveSelector
from
'./GroupMoveSelector'
import
DsMoveSelector
from
'./DsMoveSelector'
export
default
{
export
default
{
name
:
'Group'
,
name
:
'Group'
,
components
:
{
GroupMoveSelector
,
DsMoveSelector
},
data
()
{
data
()
{
return
{
return
{
sceneMode
:
false
,
sceneMode
:
false
,
...
@@ -266,6 +291,14 @@ export default {
...
@@ -266,6 +291,14 @@ export default {
children
:
[],
children
:
[],
sort
:
'type desc,name asc'
sort
:
'type desc,name asc'
},
},
dsForm
:
{
name
:
''
,
pid
:
null
,
level
:
0
,
type
:
''
,
children
:
[],
sort
:
'type desc,name asc'
},
tableForm
:
{
tableForm
:
{
name
:
''
,
name
:
''
,
mode
:
''
,
mode
:
''
,
...
@@ -282,7 +315,14 @@ export default {
...
@@ -282,7 +315,14 @@ export default {
{
required
:
true
,
message
:
this
.
$t
(
'commons.input_content'
),
trigger
:
'change'
},
{
required
:
true
,
message
:
this
.
$t
(
'commons.input_content'
),
trigger
:
'change'
},
{
max
:
50
,
message
:
this
.
$t
(
'commons.char_can_not_more_50'
),
trigger
:
'change'
}
{
max
:
50
,
message
:
this
.
$t
(
'commons.char_can_not_more_50'
),
trigger
:
'change'
}
]
]
}
},
moveGroup
:
false
,
tGroup
:
{},
moveDs
:
false
,
tDs
:
{},
groupMoveConfirmDisabled
:
true
,
dsMoveConfirmDisabled
:
true
,
moveDialogTitle
:
''
}
}
},
},
computed
:
{
computed
:
{
...
@@ -329,7 +369,12 @@ export default {
...
@@ -329,7 +369,12 @@ export default {
this
.
groupForm
=
JSON
.
parse
(
JSON
.
stringify
(
param
.
data
))
this
.
groupForm
=
JSON
.
parse
(
JSON
.
stringify
(
param
.
data
))
break
break
case
'move'
:
case
'move'
:
this
.
moveTo
(
param
.
data
)
this
.
groupForm
=
JSON
.
parse
(
JSON
.
stringify
(
param
.
data
))
break
case
'moveDs'
:
this
.
moveToDs
(
param
.
data
)
this
.
dsForm
=
JSON
.
parse
(
JSON
.
stringify
(
param
.
data
))
break
break
case
'delete'
:
case
'delete'
:
this
.
delete
(
param
.
data
)
this
.
delete
(
param
.
data
)
...
@@ -506,14 +551,14 @@ export default {
...
@@ -506,14 +551,14 @@ export default {
this
.
currGroup
=
data
this
.
currGroup
=
data
this
.
$store
.
dispatch
(
'dataset/setSceneData'
,
this
.
currGroup
.
id
)
this
.
$store
.
dispatch
(
'dataset/setSceneData'
,
this
.
currGroup
.
id
)
}
}
if
(
node
.
expanded
)
{
//
if (node.expanded) {
this
.
expandedArray
.
push
(
data
.
id
)
//
this.expandedArray.push(data.id)
}
else
{
//
} else {
const
index
=
this
.
expandedArray
.
indexOf
(
data
.
id
)
//
const index = this.expandedArray.indexOf(data.id)
if
(
index
>
-
1
)
{
//
if (index > -1) {
this
.
expandedArray
.
splice
(
index
,
1
)
//
this.expandedArray.splice(index, 1)
}
//
}
}
//
}
// console.log(this.expandedArray);
// console.log(this.expandedArray);
},
},
...
@@ -563,6 +608,79 @@ export default {
...
@@ -563,6 +608,79 @@ export default {
this
.
currGroup
=
res
.
data
this
.
currGroup
=
res
.
data
})
})
}
}
},
nodeExpand
(
data
)
{
if
(
data
.
id
)
{
this
.
expandedArray
.
push
(
data
.
id
)
}
},
nodeCollapse
(
data
)
{
if
(
data
.
id
)
{
this
.
expandedArray
.
splice
(
this
.
expandedArray
.
indexOf
(
data
.
id
),
1
)
}
},
moveTo
(
data
)
{
this
.
moveGroup
=
true
this
.
moveDialogTitle
=
this
.
$t
(
'dataset.m1'
)
+
(
data
.
name
.
length
>
10
?
(
data
.
name
.
substr
(
0
,
10
)
+
'...'
)
:
data
.
name
)
+
this
.
$t
(
'dataset.m2'
)
},
closeMoveGroup
()
{
this
.
moveGroup
=
false
this
.
groupForm
=
{
name
:
''
,
pid
:
null
,
level
:
0
,
type
:
''
,
children
:
[],
sort
:
'type desc,name asc'
}
},
saveMoveGroup
()
{
this
.
groupForm
.
pid
=
this
.
tGroup
.
id
addGroup
(
this
.
groupForm
).
then
(
res
=>
{
this
.
closeMoveGroup
()
this
.
tree
(
this
.
groupForm
)
})
},
targetGroup
(
val
)
{
this
.
tGroup
=
val
this
.
groupMoveConfirmDisabled
=
false
},
moveToDs
(
data
)
{
this
.
moveDs
=
true
this
.
moveDialogTitle
=
this
.
$t
(
'dataset.m1'
)
+
(
data
.
name
.
length
>
10
?
(
data
.
name
.
substr
(
0
,
10
)
+
'...'
)
:
data
.
name
)
+
this
.
$t
(
'dataset.m2'
)
},
closeMoveDs
()
{
this
.
moveDs
=
false
this
.
dsForm
=
{
name
:
''
,
pid
:
null
,
level
:
0
,
type
:
''
,
children
:
[],
sort
:
'type desc,name asc'
}
},
saveMoveDs
()
{
if
(
this
.
tDs
&&
this
.
tDs
.
type
===
'group'
)
{
return
}
this
.
dsForm
.
sceneId
=
this
.
tDs
.
id
this
.
dsForm
.
isRename
=
true
addTable
(
this
.
dsForm
).
then
(
res
=>
{
this
.
closeMoveDs
()
this
.
tableTree
()
})
},
targetDs
(
val
)
{
this
.
tDs
=
val
if
(
this
.
tDs
.
type
===
'group'
)
{
this
.
dsMoveConfirmDisabled
=
true
}
else
{
this
.
dsMoveConfirmDisabled
=
false
}
}
}
}
}
}
}
...
@@ -640,4 +758,8 @@ export default {
...
@@ -640,4 +758,8 @@ export default {
.father
:hover
.child
{
.father
:hover
.child
{
display
:
inline
;
display
:
inline
;
}
}
.dialog-css
>>>
.el-dialog__body
{
padding
:
10px
20px
20px
;
}
</
style
>
</
style
>
frontend/src/views/dataset/group/GroupMoveSelector.vue
0 → 100644
浏览文件 @
6fe0f5f1
<
template
>
<el-col
style=
"height: 400px;overflow-y: auto;margin-bottom: 10px;"
>
<el-tree
:data=
"tData"
node-key=
"id"
:expand-on-click-node=
"false"
highlight-current
@
node-click=
"nodeClick"
>
<span
slot-scope=
"
{ node, data }" :class="treeClass(data,node)">
<span
style=
"display: flex;flex: 1;width: 0;"
>
<span
v-if=
"data.type === 'scene'"
>
<svg-icon
icon-class=
"scene"
class=
"ds-icon-scene"
/>
</span>
<span
style=
"margin-left: 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;"
:title=
"data.name"
>
{{
data
.
name
}}
</span>
</span>
</span>
</el-tree>
</el-col>
</
template
>
<
script
>
import
{
groupTree
}
from
'@/api/dataset/dataset'
export
default
{
name
:
'GroupMoveSelector'
,
props
:
{
item
:
{
type
:
Object
,
required
:
true
}
},
data
()
{
return
{
tData
:
[],
currGroup
:
''
,
groupForm
:
{
name
:
''
,
pid
:
null
,
level
:
0
,
type
:
'group'
,
children
:
[],
sort
:
'type desc,name asc'
},
targetGroup
:
{}
}
},
watch
:
{
'item'
:
function
()
{
this
.
tree
(
this
.
groupForm
)
}
},
mounted
()
{
this
.
tree
(
this
.
groupForm
)
},
methods
:
{
tree
(
group
)
{
groupTree
(
group
).
then
(
res
=>
{
this
.
tData
=
[{
id
:
'0'
,
name
:
this
.
$t
(
'dataset.dataset_group'
),
pid
:
'0'
,
privileges
:
'grant,manage,use'
,
type
:
'group'
,
children
:
res
.
data
}]
})
},
nodeClick
(
data
,
node
)
{
this
.
targetGroup
=
data
this
.
$emit
(
'targetGroup'
,
data
)
},
treeClass
(
data
,
node
)
{
if
(
data
.
id
===
this
.
item
.
id
)
{
node
.
visible
=
false
}
return
'custom-tree-node'
}
}
}
</
script
>
<
style
scoped
>
.custom-tree-node
{
flex
:
1
;
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
font-size
:
14px
;
padding-right
:
8px
;
}
</
style
>
frontend/src/views/panel/edit/index.vue
浏览文件 @
6fe0f5f1
...
@@ -390,6 +390,7 @@ export default {
...
@@ -390,6 +390,7 @@ export default {
viewId
:
componentInfo
.
id
viewId
:
componentInfo
.
id
}
}
component
.
propValue
=
propValue
component
.
propValue
=
propValue
component
.
filters
=
[]
}
}
})
})
}
else
{
}
else
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论