Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
D
dataease
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
njgzx
dataease
Commits
dd2ed93b
提交
dd2ed93b
authored
2月 20, 2021
作者:
junjie
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat: Dataset 分组 场景
上级
2890e29e
隐藏空白字符变更
内嵌
并排
正在显示
10 个修改的文件
包含
1746 行增加
和
18 行删除
+1746
-18
DatasetGroup.java
...d/src/main/java/io/dataease/base/domain/DatasetGroup.java
+22
-0
DatasetGroupExample.java
...ain/java/io/dataease/base/domain/DatasetGroupExample.java
+601
-0
DatasetScene.java
...d/src/main/java/io/dataease/base/domain/DatasetScene.java
+20
-0
DatasetSceneExample.java
...ain/java/io/dataease/base/domain/DatasetSceneExample.java
+541
-0
DatasetGroupMapper.java
...main/java/io/dataease/base/mapper/DatasetGroupMapper.java
+31
-0
DatasetGroupMapper.xml
.../main/java/io/dataease/base/mapper/DatasetGroupMapper.xml
+229
-0
DatasetSceneMapper.java
...main/java/io/dataease/base/mapper/DatasetSceneMapper.java
+31
-0
DatasetSceneMapper.xml
.../main/java/io/dataease/base/mapper/DatasetSceneMapper.xml
+212
-0
V2__metersphere_ddl.sql
...d/src/main/resources/db/migration/V2__metersphere_ddl.sql
+20
-0
Group.vue
frontend/src/business/components/dataset/group/Group.vue
+39
-18
没有找到文件。
backend/src/main/java/io/dataease/base/domain/DatasetGroup.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
domain
;
import
java.io.Serializable
;
import
lombok.Data
;
@Data
public
class
DatasetGroup
implements
Serializable
{
private
String
id
;
private
String
name
;
private
String
pid
;
private
Integer
level
;
private
String
createBy
;
private
Long
createTime
;
private
static
final
long
serialVersionUID
=
1L
;
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/domain/DatasetGroupExample.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
domain
;
import
java.util.ArrayList
;
import
java.util.List
;
public
class
DatasetGroupExample
{
protected
String
orderByClause
;
protected
boolean
distinct
;
protected
List
<
Criteria
>
oredCriteria
;
public
DatasetGroupExample
()
{
oredCriteria
=
new
ArrayList
<
Criteria
>();
}
public
void
setOrderByClause
(
String
orderByClause
)
{
this
.
orderByClause
=
orderByClause
;
}
public
String
getOrderByClause
()
{
return
orderByClause
;
}
public
void
setDistinct
(
boolean
distinct
)
{
this
.
distinct
=
distinct
;
}
public
boolean
isDistinct
()
{
return
distinct
;
}
public
List
<
Criteria
>
getOredCriteria
()
{
return
oredCriteria
;
}
public
void
or
(
Criteria
criteria
)
{
oredCriteria
.
add
(
criteria
);
}
public
Criteria
or
()
{
Criteria
criteria
=
createCriteriaInternal
();
oredCriteria
.
add
(
criteria
);
return
criteria
;
}
public
Criteria
createCriteria
()
{
Criteria
criteria
=
createCriteriaInternal
();
if
(
oredCriteria
.
size
()
==
0
)
{
oredCriteria
.
add
(
criteria
);
}
return
criteria
;
}
protected
Criteria
createCriteriaInternal
()
{
Criteria
criteria
=
new
Criteria
();
return
criteria
;
}
public
void
clear
()
{
oredCriteria
.
clear
();
orderByClause
=
null
;
distinct
=
false
;
}
protected
abstract
static
class
GeneratedCriteria
{
protected
List
<
Criterion
>
criteria
;
protected
GeneratedCriteria
()
{
super
();
criteria
=
new
ArrayList
<
Criterion
>();
}
public
boolean
isValid
()
{
return
criteria
.
size
()
>
0
;
}
public
List
<
Criterion
>
getAllCriteria
()
{
return
criteria
;
}
public
List
<
Criterion
>
getCriteria
()
{
return
criteria
;
}
protected
void
addCriterion
(
String
condition
)
{
if
(
condition
==
null
)
{
throw
new
RuntimeException
(
"Value for condition cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
));
}
protected
void
addCriterion
(
String
condition
,
Object
value
,
String
property
)
{
if
(
value
==
null
)
{
throw
new
RuntimeException
(
"Value for "
+
property
+
" cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
,
value
));
}
protected
void
addCriterion
(
String
condition
,
Object
value1
,
Object
value2
,
String
property
)
{
if
(
value1
==
null
||
value2
==
null
)
{
throw
new
RuntimeException
(
"Between values for "
+
property
+
" cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
,
value1
,
value2
));
}
public
Criteria
andIdIsNull
()
{
addCriterion
(
"id is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdIsNotNull
()
{
addCriterion
(
"id is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdEqualTo
(
String
value
)
{
addCriterion
(
"id ="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotEqualTo
(
String
value
)
{
addCriterion
(
"id <>"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdGreaterThan
(
String
value
)
{
addCriterion
(
"id >"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"id >="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLessThan
(
String
value
)
{
addCriterion
(
"id <"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"id <="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLike
(
String
value
)
{
addCriterion
(
"id like"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotLike
(
String
value
)
{
addCriterion
(
"id not like"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdIn
(
List
<
String
>
values
)
{
addCriterion
(
"id in"
,
values
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"id not in"
,
values
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"id between"
,
value1
,
value2
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"id not between"
,
value1
,
value2
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIsNull
()
{
addCriterion
(
"`name` is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIsNotNull
()
{
addCriterion
(
"`name` is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameEqualTo
(
String
value
)
{
addCriterion
(
"`name` ="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotEqualTo
(
String
value
)
{
addCriterion
(
"`name` <>"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameGreaterThan
(
String
value
)
{
addCriterion
(
"`name` >"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"`name` >="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLessThan
(
String
value
)
{
addCriterion
(
"`name` <"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"`name` <="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLike
(
String
value
)
{
addCriterion
(
"`name` like"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotLike
(
String
value
)
{
addCriterion
(
"`name` not like"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIn
(
List
<
String
>
values
)
{
addCriterion
(
"`name` in"
,
values
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"`name` not in"
,
values
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"`name` between"
,
value1
,
value2
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"`name` not between"
,
value1
,
value2
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidIsNull
()
{
addCriterion
(
"pid is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidIsNotNull
()
{
addCriterion
(
"pid is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidEqualTo
(
String
value
)
{
addCriterion
(
"pid ="
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidNotEqualTo
(
String
value
)
{
addCriterion
(
"pid <>"
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidGreaterThan
(
String
value
)
{
addCriterion
(
"pid >"
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"pid >="
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidLessThan
(
String
value
)
{
addCriterion
(
"pid <"
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"pid <="
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidLike
(
String
value
)
{
addCriterion
(
"pid like"
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidNotLike
(
String
value
)
{
addCriterion
(
"pid not like"
,
value
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidIn
(
List
<
String
>
values
)
{
addCriterion
(
"pid in"
,
values
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"pid not in"
,
values
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"pid between"
,
value1
,
value2
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andPidNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"pid not between"
,
value1
,
value2
,
"pid"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelIsNull
()
{
addCriterion
(
"`level` is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelIsNotNull
()
{
addCriterion
(
"`level` is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelEqualTo
(
Integer
value
)
{
addCriterion
(
"`level` ="
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelNotEqualTo
(
Integer
value
)
{
addCriterion
(
"`level` <>"
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelGreaterThan
(
Integer
value
)
{
addCriterion
(
"`level` >"
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelGreaterThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"`level` >="
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelLessThan
(
Integer
value
)
{
addCriterion
(
"`level` <"
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelLessThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"`level` <="
,
value
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"`level` in"
,
values
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelNotIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"`level` not in"
,
values
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"`level` between"
,
value1
,
value2
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andLevelNotBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"`level` not between"
,
value1
,
value2
,
"level"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIsNull
()
{
addCriterion
(
"create_by is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIsNotNull
()
{
addCriterion
(
"create_by is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByEqualTo
(
String
value
)
{
addCriterion
(
"create_by ="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotEqualTo
(
String
value
)
{
addCriterion
(
"create_by <>"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByGreaterThan
(
String
value
)
{
addCriterion
(
"create_by >"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"create_by >="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLessThan
(
String
value
)
{
addCriterion
(
"create_by <"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"create_by <="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLike
(
String
value
)
{
addCriterion
(
"create_by like"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotLike
(
String
value
)
{
addCriterion
(
"create_by not like"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIn
(
List
<
String
>
values
)
{
addCriterion
(
"create_by in"
,
values
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"create_by not in"
,
values
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"create_by between"
,
value1
,
value2
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"create_by not between"
,
value1
,
value2
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIsNull
()
{
addCriterion
(
"create_time is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIsNotNull
()
{
addCriterion
(
"create_time is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeEqualTo
(
Long
value
)
{
addCriterion
(
"create_time ="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotEqualTo
(
Long
value
)
{
addCriterion
(
"create_time <>"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeGreaterThan
(
Long
value
)
{
addCriterion
(
"create_time >"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeGreaterThanOrEqualTo
(
Long
value
)
{
addCriterion
(
"create_time >="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeLessThan
(
Long
value
)
{
addCriterion
(
"create_time <"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeLessThanOrEqualTo
(
Long
value
)
{
addCriterion
(
"create_time <="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIn
(
List
<
Long
>
values
)
{
addCriterion
(
"create_time in"
,
values
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotIn
(
List
<
Long
>
values
)
{
addCriterion
(
"create_time not in"
,
values
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeBetween
(
Long
value1
,
Long
value2
)
{
addCriterion
(
"create_time between"
,
value1
,
value2
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotBetween
(
Long
value1
,
Long
value2
)
{
addCriterion
(
"create_time not between"
,
value1
,
value2
,
"createTime"
);
return
(
Criteria
)
this
;
}
}
public
static
class
Criteria
extends
GeneratedCriteria
{
protected
Criteria
()
{
super
();
}
}
public
static
class
Criterion
{
private
String
condition
;
private
Object
value
;
private
Object
secondValue
;
private
boolean
noValue
;
private
boolean
singleValue
;
private
boolean
betweenValue
;
private
boolean
listValue
;
private
String
typeHandler
;
public
String
getCondition
()
{
return
condition
;
}
public
Object
getValue
()
{
return
value
;
}
public
Object
getSecondValue
()
{
return
secondValue
;
}
public
boolean
isNoValue
()
{
return
noValue
;
}
public
boolean
isSingleValue
()
{
return
singleValue
;
}
public
boolean
isBetweenValue
()
{
return
betweenValue
;
}
public
boolean
isListValue
()
{
return
listValue
;
}
public
String
getTypeHandler
()
{
return
typeHandler
;
}
protected
Criterion
(
String
condition
)
{
super
();
this
.
condition
=
condition
;
this
.
typeHandler
=
null
;
this
.
noValue
=
true
;
}
protected
Criterion
(
String
condition
,
Object
value
,
String
typeHandler
)
{
super
();
this
.
condition
=
condition
;
this
.
value
=
value
;
this
.
typeHandler
=
typeHandler
;
if
(
value
instanceof
List
<?>)
{
this
.
listValue
=
true
;
}
else
{
this
.
singleValue
=
true
;
}
}
protected
Criterion
(
String
condition
,
Object
value
)
{
this
(
condition
,
value
,
null
);
}
protected
Criterion
(
String
condition
,
Object
value
,
Object
secondValue
,
String
typeHandler
)
{
super
();
this
.
condition
=
condition
;
this
.
value
=
value
;
this
.
secondValue
=
secondValue
;
this
.
typeHandler
=
typeHandler
;
this
.
betweenValue
=
true
;
}
protected
Criterion
(
String
condition
,
Object
value
,
Object
secondValue
)
{
this
(
condition
,
value
,
secondValue
,
null
);
}
}
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/domain/DatasetScene.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
domain
;
import
java.io.Serializable
;
import
lombok.Data
;
@Data
public
class
DatasetScene
implements
Serializable
{
private
String
id
;
private
String
name
;
private
String
groupId
;
private
String
createBy
;
private
Long
createTime
;
private
static
final
long
serialVersionUID
=
1L
;
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/domain/DatasetSceneExample.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
domain
;
import
java.util.ArrayList
;
import
java.util.List
;
public
class
DatasetSceneExample
{
protected
String
orderByClause
;
protected
boolean
distinct
;
protected
List
<
Criteria
>
oredCriteria
;
public
DatasetSceneExample
()
{
oredCriteria
=
new
ArrayList
<
Criteria
>();
}
public
void
setOrderByClause
(
String
orderByClause
)
{
this
.
orderByClause
=
orderByClause
;
}
public
String
getOrderByClause
()
{
return
orderByClause
;
}
public
void
setDistinct
(
boolean
distinct
)
{
this
.
distinct
=
distinct
;
}
public
boolean
isDistinct
()
{
return
distinct
;
}
public
List
<
Criteria
>
getOredCriteria
()
{
return
oredCriteria
;
}
public
void
or
(
Criteria
criteria
)
{
oredCriteria
.
add
(
criteria
);
}
public
Criteria
or
()
{
Criteria
criteria
=
createCriteriaInternal
();
oredCriteria
.
add
(
criteria
);
return
criteria
;
}
public
Criteria
createCriteria
()
{
Criteria
criteria
=
createCriteriaInternal
();
if
(
oredCriteria
.
size
()
==
0
)
{
oredCriteria
.
add
(
criteria
);
}
return
criteria
;
}
protected
Criteria
createCriteriaInternal
()
{
Criteria
criteria
=
new
Criteria
();
return
criteria
;
}
public
void
clear
()
{
oredCriteria
.
clear
();
orderByClause
=
null
;
distinct
=
false
;
}
protected
abstract
static
class
GeneratedCriteria
{
protected
List
<
Criterion
>
criteria
;
protected
GeneratedCriteria
()
{
super
();
criteria
=
new
ArrayList
<
Criterion
>();
}
public
boolean
isValid
()
{
return
criteria
.
size
()
>
0
;
}
public
List
<
Criterion
>
getAllCriteria
()
{
return
criteria
;
}
public
List
<
Criterion
>
getCriteria
()
{
return
criteria
;
}
protected
void
addCriterion
(
String
condition
)
{
if
(
condition
==
null
)
{
throw
new
RuntimeException
(
"Value for condition cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
));
}
protected
void
addCriterion
(
String
condition
,
Object
value
,
String
property
)
{
if
(
value
==
null
)
{
throw
new
RuntimeException
(
"Value for "
+
property
+
" cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
,
value
));
}
protected
void
addCriterion
(
String
condition
,
Object
value1
,
Object
value2
,
String
property
)
{
if
(
value1
==
null
||
value2
==
null
)
{
throw
new
RuntimeException
(
"Between values for "
+
property
+
" cannot be null"
);
}
criteria
.
add
(
new
Criterion
(
condition
,
value1
,
value2
));
}
public
Criteria
andIdIsNull
()
{
addCriterion
(
"id is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdIsNotNull
()
{
addCriterion
(
"id is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdEqualTo
(
String
value
)
{
addCriterion
(
"id ="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotEqualTo
(
String
value
)
{
addCriterion
(
"id <>"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdGreaterThan
(
String
value
)
{
addCriterion
(
"id >"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"id >="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLessThan
(
String
value
)
{
addCriterion
(
"id <"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"id <="
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdLike
(
String
value
)
{
addCriterion
(
"id like"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotLike
(
String
value
)
{
addCriterion
(
"id not like"
,
value
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdIn
(
List
<
String
>
values
)
{
addCriterion
(
"id in"
,
values
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"id not in"
,
values
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"id between"
,
value1
,
value2
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andIdNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"id not between"
,
value1
,
value2
,
"id"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIsNull
()
{
addCriterion
(
"`name` is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIsNotNull
()
{
addCriterion
(
"`name` is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameEqualTo
(
String
value
)
{
addCriterion
(
"`name` ="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotEqualTo
(
String
value
)
{
addCriterion
(
"`name` <>"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameGreaterThan
(
String
value
)
{
addCriterion
(
"`name` >"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"`name` >="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLessThan
(
String
value
)
{
addCriterion
(
"`name` <"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"`name` <="
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameLike
(
String
value
)
{
addCriterion
(
"`name` like"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotLike
(
String
value
)
{
addCriterion
(
"`name` not like"
,
value
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameIn
(
List
<
String
>
values
)
{
addCriterion
(
"`name` in"
,
values
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"`name` not in"
,
values
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"`name` between"
,
value1
,
value2
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andNameNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"`name` not between"
,
value1
,
value2
,
"name"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdIsNull
()
{
addCriterion
(
"group_id is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdIsNotNull
()
{
addCriterion
(
"group_id is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdEqualTo
(
String
value
)
{
addCriterion
(
"group_id ="
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdNotEqualTo
(
String
value
)
{
addCriterion
(
"group_id <>"
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdGreaterThan
(
String
value
)
{
addCriterion
(
"group_id >"
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"group_id >="
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdLessThan
(
String
value
)
{
addCriterion
(
"group_id <"
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"group_id <="
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdLike
(
String
value
)
{
addCriterion
(
"group_id like"
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdNotLike
(
String
value
)
{
addCriterion
(
"group_id not like"
,
value
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdIn
(
List
<
String
>
values
)
{
addCriterion
(
"group_id in"
,
values
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"group_id not in"
,
values
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"group_id between"
,
value1
,
value2
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andGroupIdNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"group_id not between"
,
value1
,
value2
,
"groupId"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIsNull
()
{
addCriterion
(
"create_by is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIsNotNull
()
{
addCriterion
(
"create_by is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByEqualTo
(
String
value
)
{
addCriterion
(
"create_by ="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotEqualTo
(
String
value
)
{
addCriterion
(
"create_by <>"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByGreaterThan
(
String
value
)
{
addCriterion
(
"create_by >"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByGreaterThanOrEqualTo
(
String
value
)
{
addCriterion
(
"create_by >="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLessThan
(
String
value
)
{
addCriterion
(
"create_by <"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLessThanOrEqualTo
(
String
value
)
{
addCriterion
(
"create_by <="
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByLike
(
String
value
)
{
addCriterion
(
"create_by like"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotLike
(
String
value
)
{
addCriterion
(
"create_by not like"
,
value
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIn
(
List
<
String
>
values
)
{
addCriterion
(
"create_by in"
,
values
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotIn
(
List
<
String
>
values
)
{
addCriterion
(
"create_by not in"
,
values
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"create_by between"
,
value1
,
value2
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByNotBetween
(
String
value1
,
String
value2
)
{
addCriterion
(
"create_by not between"
,
value1
,
value2
,
"createBy"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIsNull
()
{
addCriterion
(
"create_time is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIsNotNull
()
{
addCriterion
(
"create_time is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeEqualTo
(
Long
value
)
{
addCriterion
(
"create_time ="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotEqualTo
(
Long
value
)
{
addCriterion
(
"create_time <>"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeGreaterThan
(
Long
value
)
{
addCriterion
(
"create_time >"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeGreaterThanOrEqualTo
(
Long
value
)
{
addCriterion
(
"create_time >="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeLessThan
(
Long
value
)
{
addCriterion
(
"create_time <"
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeLessThanOrEqualTo
(
Long
value
)
{
addCriterion
(
"create_time <="
,
value
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeIn
(
List
<
Long
>
values
)
{
addCriterion
(
"create_time in"
,
values
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotIn
(
List
<
Long
>
values
)
{
addCriterion
(
"create_time not in"
,
values
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeBetween
(
Long
value1
,
Long
value2
)
{
addCriterion
(
"create_time between"
,
value1
,
value2
,
"createTime"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateTimeNotBetween
(
Long
value1
,
Long
value2
)
{
addCriterion
(
"create_time not between"
,
value1
,
value2
,
"createTime"
);
return
(
Criteria
)
this
;
}
}
public
static
class
Criteria
extends
GeneratedCriteria
{
protected
Criteria
()
{
super
();
}
}
public
static
class
Criterion
{
private
String
condition
;
private
Object
value
;
private
Object
secondValue
;
private
boolean
noValue
;
private
boolean
singleValue
;
private
boolean
betweenValue
;
private
boolean
listValue
;
private
String
typeHandler
;
public
String
getCondition
()
{
return
condition
;
}
public
Object
getValue
()
{
return
value
;
}
public
Object
getSecondValue
()
{
return
secondValue
;
}
public
boolean
isNoValue
()
{
return
noValue
;
}
public
boolean
isSingleValue
()
{
return
singleValue
;
}
public
boolean
isBetweenValue
()
{
return
betweenValue
;
}
public
boolean
isListValue
()
{
return
listValue
;
}
public
String
getTypeHandler
()
{
return
typeHandler
;
}
protected
Criterion
(
String
condition
)
{
super
();
this
.
condition
=
condition
;
this
.
typeHandler
=
null
;
this
.
noValue
=
true
;
}
protected
Criterion
(
String
condition
,
Object
value
,
String
typeHandler
)
{
super
();
this
.
condition
=
condition
;
this
.
value
=
value
;
this
.
typeHandler
=
typeHandler
;
if
(
value
instanceof
List
<?>)
{
this
.
listValue
=
true
;
}
else
{
this
.
singleValue
=
true
;
}
}
protected
Criterion
(
String
condition
,
Object
value
)
{
this
(
condition
,
value
,
null
);
}
protected
Criterion
(
String
condition
,
Object
value
,
Object
secondValue
,
String
typeHandler
)
{
super
();
this
.
condition
=
condition
;
this
.
value
=
value
;
this
.
secondValue
=
secondValue
;
this
.
typeHandler
=
typeHandler
;
this
.
betweenValue
=
true
;
}
protected
Criterion
(
String
condition
,
Object
value
,
Object
secondValue
)
{
this
(
condition
,
value
,
secondValue
,
null
);
}
}
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/mapper/DatasetGroupMapper.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
mapper
;
import
io.dataease.base.domain.DatasetGroup
;
import
io.dataease.base.domain.DatasetGroupExample
;
import
java.util.List
;
import
org.apache.ibatis.annotations.Param
;
public
interface
DatasetGroupMapper
{
long
countByExample
(
DatasetGroupExample
example
);
int
deleteByExample
(
DatasetGroupExample
example
);
int
deleteByPrimaryKey
(
String
id
);
int
insert
(
DatasetGroup
record
);
int
insertSelective
(
DatasetGroup
record
);
List
<
DatasetGroup
>
selectByExample
(
DatasetGroupExample
example
);
DatasetGroup
selectByPrimaryKey
(
String
id
);
int
updateByExampleSelective
(
@Param
(
"record"
)
DatasetGroup
record
,
@Param
(
"example"
)
DatasetGroupExample
example
);
int
updateByExample
(
@Param
(
"record"
)
DatasetGroup
record
,
@Param
(
"example"
)
DatasetGroupExample
example
);
int
updateByPrimaryKeySelective
(
DatasetGroup
record
);
int
updateByPrimaryKey
(
DatasetGroup
record
);
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/mapper/DatasetGroupMapper.xml
0 → 100644
浏览文件 @
dd2ed93b
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"io.dataease.base.mapper.DatasetGroupMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"io.dataease.base.domain.DatasetGroup"
>
<id
column=
"id"
jdbcType=
"VARCHAR"
property=
"id"
/>
<result
column=
"name"
jdbcType=
"VARCHAR"
property=
"name"
/>
<result
column=
"pid"
jdbcType=
"VARCHAR"
property=
"pid"
/>
<result
column=
"level"
jdbcType=
"INTEGER"
property=
"level"
/>
<result
column=
"create_by"
jdbcType=
"VARCHAR"
property=
"createBy"
/>
<result
column=
"create_time"
jdbcType=
"BIGINT"
property=
"createTime"
/>
</resultMap>
<sql
id=
"Example_Where_Clause"
>
<where>
<foreach
collection=
"oredCriteria"
item=
"criteria"
separator=
"or"
>
<if
test=
"criteria.valid"
>
<trim
prefix=
"("
prefixOverrides=
"and"
suffix=
")"
>
<foreach
collection=
"criteria.criteria"
item=
"criterion"
>
<choose>
<when
test=
"criterion.noValue"
>
and ${criterion.condition}
</when>
<when
test=
"criterion.singleValue"
>
and ${criterion.condition} #{criterion.value}
</when>
<when
test=
"criterion.betweenValue"
>
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when
test=
"criterion.listValue"
>
and ${criterion.condition}
<foreach
close=
")"
collection=
"criterion.value"
item=
"listItem"
open=
"("
separator=
","
>
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql
id=
"Update_By_Example_Where_Clause"
>
<where>
<foreach
collection=
"example.oredCriteria"
item=
"criteria"
separator=
"or"
>
<if
test=
"criteria.valid"
>
<trim
prefix=
"("
prefixOverrides=
"and"
suffix=
")"
>
<foreach
collection=
"criteria.criteria"
item=
"criterion"
>
<choose>
<when
test=
"criterion.noValue"
>
and ${criterion.condition}
</when>
<when
test=
"criterion.singleValue"
>
and ${criterion.condition} #{criterion.value}
</when>
<when
test=
"criterion.betweenValue"
>
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when
test=
"criterion.listValue"
>
and ${criterion.condition}
<foreach
close=
")"
collection=
"criterion.value"
item=
"listItem"
open=
"("
separator=
","
>
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql
id=
"Base_Column_List"
>
id, `name`, pid, `level`, create_by, create_time
</sql>
<select
id=
"selectByExample"
parameterType=
"io.dataease.base.domain.DatasetGroupExample"
resultMap=
"BaseResultMap"
>
select
<if
test=
"distinct"
>
distinct
</if>
<include
refid=
"Base_Column_List"
/>
from dataset_group
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
<if
test=
"orderByClause != null"
>
order by ${orderByClause}
</if>
</select>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.String"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from dataset_group
where id = #{id,jdbcType=VARCHAR}
</select>
<delete
id=
"deleteByPrimaryKey"
parameterType=
"java.lang.String"
>
delete from dataset_group
where id = #{id,jdbcType=VARCHAR}
</delete>
<delete
id=
"deleteByExample"
parameterType=
"io.dataease.base.domain.DatasetGroupExample"
>
delete from dataset_group
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
</delete>
<insert
id=
"insert"
parameterType=
"io.dataease.base.domain.DatasetGroup"
>
insert into dataset_group (id, `name`, pid,
`level`, create_by, create_time
)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR},
#{level,jdbcType=INTEGER}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}
)
</insert>
<insert
id=
"insertSelective"
parameterType=
"io.dataease.base.domain.DatasetGroup"
>
insert into dataset_group
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
id,
</if>
<if
test=
"name != null"
>
`name`,
</if>
<if
test=
"pid != null"
>
pid,
</if>
<if
test=
"level != null"
>
`level`,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
#{id,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"pid != null"
>
#{pid,jdbcType=VARCHAR},
</if>
<if
test=
"level != null"
>
#{level,jdbcType=INTEGER},
</if>
<if
test=
"createBy != null"
>
#{createBy,jdbcType=VARCHAR},
</if>
<if
test=
"createTime != null"
>
#{createTime,jdbcType=BIGINT},
</if>
</trim>
</insert>
<select
id=
"countByExample"
parameterType=
"io.dataease.base.domain.DatasetGroupExample"
resultType=
"java.lang.Long"
>
select count(*) from dataset_group
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
</select>
<update
id=
"updateByExampleSelective"
parameterType=
"map"
>
update dataset_group
<set>
<if
test=
"record.id != null"
>
id = #{record.id,jdbcType=VARCHAR},
</if>
<if
test=
"record.name != null"
>
`name` = #{record.name,jdbcType=VARCHAR},
</if>
<if
test=
"record.pid != null"
>
pid = #{record.pid,jdbcType=VARCHAR},
</if>
<if
test=
"record.level != null"
>
`level` = #{record.level,jdbcType=INTEGER},
</if>
<if
test=
"record.createBy != null"
>
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if
test=
"record.createTime != null"
>
create_time = #{record.createTime,jdbcType=BIGINT},
</if>
</set>
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
</if>
</update>
<update
id=
"updateByExample"
parameterType=
"map"
>
update dataset_group
set id = #{record.id,jdbcType=VARCHAR},
`name` = #{record.name,jdbcType=VARCHAR},
pid = #{record.pid,jdbcType=VARCHAR},
`level` = #{record.level,jdbcType=INTEGER},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=BIGINT}
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
</if>
</update>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"io.dataease.base.domain.DatasetGroup"
>
update dataset_group
<set>
<if
test=
"name != null"
>
`name` = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"pid != null"
>
pid = #{pid,jdbcType=VARCHAR},
</if>
<if
test=
"level != null"
>
`level` = #{level,jdbcType=INTEGER},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime,jdbcType=BIGINT},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update
id=
"updateByPrimaryKey"
parameterType=
"io.dataease.base.domain.DatasetGroup"
>
update dataset_group
set `name` = #{name,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR},
`level` = #{level,jdbcType=INTEGER},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=BIGINT}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>
\ No newline at end of file
backend/src/main/java/io/dataease/base/mapper/DatasetSceneMapper.java
0 → 100644
浏览文件 @
dd2ed93b
package
io
.
dataease
.
base
.
mapper
;
import
io.dataease.base.domain.DatasetScene
;
import
io.dataease.base.domain.DatasetSceneExample
;
import
java.util.List
;
import
org.apache.ibatis.annotations.Param
;
public
interface
DatasetSceneMapper
{
long
countByExample
(
DatasetSceneExample
example
);
int
deleteByExample
(
DatasetSceneExample
example
);
int
deleteByPrimaryKey
(
String
id
);
int
insert
(
DatasetScene
record
);
int
insertSelective
(
DatasetScene
record
);
List
<
DatasetScene
>
selectByExample
(
DatasetSceneExample
example
);
DatasetScene
selectByPrimaryKey
(
String
id
);
int
updateByExampleSelective
(
@Param
(
"record"
)
DatasetScene
record
,
@Param
(
"example"
)
DatasetSceneExample
example
);
int
updateByExample
(
@Param
(
"record"
)
DatasetScene
record
,
@Param
(
"example"
)
DatasetSceneExample
example
);
int
updateByPrimaryKeySelective
(
DatasetScene
record
);
int
updateByPrimaryKey
(
DatasetScene
record
);
}
\ No newline at end of file
backend/src/main/java/io/dataease/base/mapper/DatasetSceneMapper.xml
0 → 100644
浏览文件 @
dd2ed93b
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"io.dataease.base.mapper.DatasetSceneMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"io.dataease.base.domain.DatasetScene"
>
<id
column=
"id"
jdbcType=
"VARCHAR"
property=
"id"
/>
<result
column=
"name"
jdbcType=
"VARCHAR"
property=
"name"
/>
<result
column=
"group_id"
jdbcType=
"VARCHAR"
property=
"groupId"
/>
<result
column=
"create_by"
jdbcType=
"VARCHAR"
property=
"createBy"
/>
<result
column=
"create_time"
jdbcType=
"BIGINT"
property=
"createTime"
/>
</resultMap>
<sql
id=
"Example_Where_Clause"
>
<where>
<foreach
collection=
"oredCriteria"
item=
"criteria"
separator=
"or"
>
<if
test=
"criteria.valid"
>
<trim
prefix=
"("
prefixOverrides=
"and"
suffix=
")"
>
<foreach
collection=
"criteria.criteria"
item=
"criterion"
>
<choose>
<when
test=
"criterion.noValue"
>
and ${criterion.condition}
</when>
<when
test=
"criterion.singleValue"
>
and ${criterion.condition} #{criterion.value}
</when>
<when
test=
"criterion.betweenValue"
>
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when
test=
"criterion.listValue"
>
and ${criterion.condition}
<foreach
close=
")"
collection=
"criterion.value"
item=
"listItem"
open=
"("
separator=
","
>
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql
id=
"Update_By_Example_Where_Clause"
>
<where>
<foreach
collection=
"example.oredCriteria"
item=
"criteria"
separator=
"or"
>
<if
test=
"criteria.valid"
>
<trim
prefix=
"("
prefixOverrides=
"and"
suffix=
")"
>
<foreach
collection=
"criteria.criteria"
item=
"criterion"
>
<choose>
<when
test=
"criterion.noValue"
>
and ${criterion.condition}
</when>
<when
test=
"criterion.singleValue"
>
and ${criterion.condition} #{criterion.value}
</when>
<when
test=
"criterion.betweenValue"
>
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when
test=
"criterion.listValue"
>
and ${criterion.condition}
<foreach
close=
")"
collection=
"criterion.value"
item=
"listItem"
open=
"("
separator=
","
>
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql
id=
"Base_Column_List"
>
id, `name`, group_id, create_by, create_time
</sql>
<select
id=
"selectByExample"
parameterType=
"io.dataease.base.domain.DatasetSceneExample"
resultMap=
"BaseResultMap"
>
select
<if
test=
"distinct"
>
distinct
</if>
<include
refid=
"Base_Column_List"
/>
from dataset_scene
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
<if
test=
"orderByClause != null"
>
order by ${orderByClause}
</if>
</select>
<select
id=
"selectByPrimaryKey"
parameterType=
"java.lang.String"
resultMap=
"BaseResultMap"
>
select
<include
refid=
"Base_Column_List"
/>
from dataset_scene
where id = #{id,jdbcType=VARCHAR}
</select>
<delete
id=
"deleteByPrimaryKey"
parameterType=
"java.lang.String"
>
delete from dataset_scene
where id = #{id,jdbcType=VARCHAR}
</delete>
<delete
id=
"deleteByExample"
parameterType=
"io.dataease.base.domain.DatasetSceneExample"
>
delete from dataset_scene
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
</delete>
<insert
id=
"insert"
parameterType=
"io.dataease.base.domain.DatasetScene"
>
insert into dataset_scene (id, `name`, group_id,
create_by, create_time)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{groupId,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT})
</insert>
<insert
id=
"insertSelective"
parameterType=
"io.dataease.base.domain.DatasetScene"
>
insert into dataset_scene
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
id,
</if>
<if
test=
"name != null"
>
`name`,
</if>
<if
test=
"groupId != null"
>
group_id,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
<if
test=
"createTime != null"
>
create_time,
</if>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
#{id,jdbcType=VARCHAR},
</if>
<if
test=
"name != null"
>
#{name,jdbcType=VARCHAR},
</if>
<if
test=
"groupId != null"
>
#{groupId,jdbcType=VARCHAR},
</if>
<if
test=
"createBy != null"
>
#{createBy,jdbcType=VARCHAR},
</if>
<if
test=
"createTime != null"
>
#{createTime,jdbcType=BIGINT},
</if>
</trim>
</insert>
<select
id=
"countByExample"
parameterType=
"io.dataease.base.domain.DatasetSceneExample"
resultType=
"java.lang.Long"
>
select count(*) from dataset_scene
<if
test=
"_parameter != null"
>
<include
refid=
"Example_Where_Clause"
/>
</if>
</select>
<update
id=
"updateByExampleSelective"
parameterType=
"map"
>
update dataset_scene
<set>
<if
test=
"record.id != null"
>
id = #{record.id,jdbcType=VARCHAR},
</if>
<if
test=
"record.name != null"
>
`name` = #{record.name,jdbcType=VARCHAR},
</if>
<if
test=
"record.groupId != null"
>
group_id = #{record.groupId,jdbcType=VARCHAR},
</if>
<if
test=
"record.createBy != null"
>
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if
test=
"record.createTime != null"
>
create_time = #{record.createTime,jdbcType=BIGINT},
</if>
</set>
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
</if>
</update>
<update
id=
"updateByExample"
parameterType=
"map"
>
update dataset_scene
set id = #{record.id,jdbcType=VARCHAR},
`name` = #{record.name,jdbcType=VARCHAR},
group_id = #{record.groupId,jdbcType=VARCHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=BIGINT}
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
</if>
</update>
<update
id=
"updateByPrimaryKeySelective"
parameterType=
"io.dataease.base.domain.DatasetScene"
>
update dataset_scene
<set>
<if
test=
"name != null"
>
`name` = #{name,jdbcType=VARCHAR},
</if>
<if
test=
"groupId != null"
>
group_id = #{groupId,jdbcType=VARCHAR},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if
test=
"createTime != null"
>
create_time = #{createTime,jdbcType=BIGINT},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update
id=
"updateByPrimaryKey"
parameterType=
"io.dataease.base.domain.DatasetScene"
>
update dataset_scene
set `name` = #{name,jdbcType=VARCHAR},
group_id = #{groupId,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=BIGINT}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>
\ No newline at end of file
backend/src/main/resources/db/migration/V2__metersphere_ddl.sql
浏览文件 @
dd2ed93b
...
@@ -334,5 +334,25 @@ CREATE TABLE IF NOT EXISTS `test_case_report` (
...
@@ -334,5 +334,25 @@ CREATE TABLE IF NOT EXISTS `test_case_report` (
-- track end
-- track end
-- dataset start
CREATE
TABLE
IF
NOT
EXISTS
`dataset_group`
(
`id`
varchar
(
50
)
NOT
NULL
COMMENT
'ID'
,
`name`
varchar
(
64
)
NOT
NULL
COMMENT
'名称'
,
`pid`
varchar
(
50
)
COMMENT
'父级ID'
,
`level`
int
(
10
)
COMMENT
'当前分组处于第几级'
,
`create_by`
varchar
(
50
)
COMMENT
'创建人ID'
,
`create_time`
bigint
(
13
)
COMMENT
'创建时间'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
;
CREATE
TABLE
IF
NOT
EXISTS
`dataset_scene`
(
`id`
varchar
(
50
)
NOT
NULL
COMMENT
'ID'
,
`name`
varchar
(
64
)
NOT
NULL
COMMENT
'名称'
,
`group_id`
varchar
(
50
)
COMMENT
'DataSet Group ID'
,
`create_by`
varchar
(
50
)
COMMENT
'创建人ID'
,
`create_time`
bigint
(
13
)
COMMENT
'创建时间'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
;
-- dataset end
frontend/src/business/components/dataset/group/Group.vue
浏览文件 @
dd2ed93b
...
@@ -26,24 +26,34 @@
...
@@ -26,24 +26,34 @@
<el-tree
<el-tree
:data=
"data"
:data=
"data"
node-key=
"id"
node-key=
"id"
:expand-on-click-node=
"true"
>
:expand-on-click-node=
"true"
<span
class=
"custom-tree-node"
slot-scope=
"
{ node, data }">
@
node-click=
"nodeClick"
>
<span>
{{
node
.
label
}}
</span>
<span
class=
"custom-tree-node"
slot-scope=
"
{ node, data }">
<span>
<span>
<el-button
<span
v-if=
"data.show"
>
icon=
"el-icon-plus"
<el-button
type=
"text"
icon=
"el-icon-document"
size=
"mini"
type=
"text"
@
click=
"() => append(data)"
>
size=
"mini"
>
</el-button>
</el-button>
<el-button
</span>
icon=
"el-icon-more"
<span>
{{
data
.
label
}}
</span>
type=
"text"
</span>
size=
"mini"
<span>
@
click=
"() => remove(node, data)"
>
<el-button
</el-button>
icon=
"el-icon-plus"
type=
"text"
size=
"mini"
@
click
.
stop=
"() => append(data)"
>
</el-button>
<el-button
icon=
"el-icon-more"
type=
"text"
size=
"mini"
@
click
.
stop=
"() => remove(node, data)"
>
</el-button>
</span>
</span>
</span>
</span>
</el-tree>
</el-tree>
</div>
</div>
</el-col>
</el-col>
...
@@ -94,6 +104,12 @@
...
@@ -94,6 +104,12 @@
search
:
''
,
search
:
''
,
data
:
JSON
.
parse
(
JSON
.
stringify
(
data
))
data
:
JSON
.
parse
(
JSON
.
stringify
(
data
))
}
}
},
mounted
()
{
},
activated
()
{
},
},
methods
:
{
methods
:
{
addGroup
()
{
addGroup
()
{
...
@@ -114,8 +130,13 @@
...
@@ -114,8 +130,13 @@
)
)
},
},
nodeClick
(
data
,
node
){
console
.
log
(
data
);
console
.
log
(
node
);
},
append
(
data
)
{
append
(
data
)
{
const
newChild
=
{
id
:
id
++
,
label
:
'testtest'
,
children
:
[]};
const
newChild
=
{
id
:
id
++
,
label
:
'testtest'
,
children
:
[]
,
show
:
true
};
if
(
!
data
.
children
)
{
if
(
!
data
.
children
)
{
this
.
$set
(
data
,
'children'
,
[]);
this
.
$set
(
data
,
'children'
,
[]);
}
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论