Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tagManager
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanmw
tagManager
Commits
01603ffe
Commit
01603ffe
authored
Jun 09, 2020
by
zhangkb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加获取所有维度标签和所有标签关系接口
parent
b341b53c
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
23 additions
and
0 deletions
+23
-0
TagCtrl.java
src/main/java/com/keymobile/tagmanager/api/TagCtrl.java
+5
-0
TagRelCtrl.java
src/main/java/com/keymobile/tagmanager/api/TagRelCtrl.java
+6
-0
TagRelService.java
.../java/com/keymobile/tagmanager/service/TagRelService.java
+4
-0
TagService.java
...ain/java/com/keymobile/tagmanager/service/TagService.java
+8
-0
No files found.
src/main/java/com/keymobile/tagmanager/api/TagCtrl.java
View file @
01603ffe
...
...
@@ -297,6 +297,11 @@ public class TagCtrl {
startDate
,
endDate
,
modelPath
,
pageNum
,
pageSize
,
tagType
);
}
@ApiOperation
(
value
=
"(2020-6-9)获取所有维度标签数据"
,
notes
=
"(2020-6-9)获取所有维度标签数据"
)
@PostMapping
(
value
=
"/getAllDimensionTag"
)
public
List
<
Tag
>
getAllDimensionTag
(){
return
tagService
.
getAllDimensionTag
();
}
//---------------以下为导入系统的时候用到------------------
@ApiOperation
(
value
=
"查询系统标签"
,
notes
=
"查询系统标签"
)
...
...
src/main/java/com/keymobile/tagmanager/api/TagRelCtrl.java
View file @
01603ffe
...
...
@@ -64,4 +64,10 @@ public class TagRelCtrl {
public
List
<
TagRelation
>
getTargetTags
(
@RequestParam
String
tagId
){
return
tagRelService
.
getTarget
(
tagId
);
}
@ApiOperation
(
value
=
"(2020-6-9)获取所有标签关系"
,
notes
=
"(2020-6-9)获取所有标签关系"
)
@PostMapping
(
value
=
"/getAll"
)
public
List
<
TagRelation
>
getAll
(){
return
tagRelService
.
getAll
();
}
}
src/main/java/com/keymobile/tagmanager/service/TagRelService.java
View file @
01603ffe
...
...
@@ -40,4 +40,8 @@ public class TagRelService {
public
List
<
TagRelation
>
getTarget
(
String
tagId
){
return
tagRelRepo
.
findBySourceId
(
tagId
);
}
public
List
<
TagRelation
>
getAll
(){
return
tagRelRepo
.
findAll
();
}
}
src/main/java/com/keymobile/tagmanager/service/TagService.java
View file @
01603ffe
...
...
@@ -496,6 +496,14 @@ public class TagService {
return
result
;
}
//获取所有维度标签(不包含权限过滤)
public
List
<
Tag
>
getAllDimensionTag
(){
List
<
Tag
>
result
=
new
ArrayList
<>();
Criteria
criteria
=
Criteria
.
where
(
"dimensionType"
).
is
(
Constants
.
TAG_DIMENSION_TRUE
)
.
and
(
"tagType"
).
is
(
Constants
.
TAG_PERSONAL_TYPE
);
result
=
mongoOperations
.
find
(
Query
.
query
(
criteria
),
Tag
.
class
);
return
result
;
}
//如果标签存在冲突,修改当前标签名字和路径
private
void
changeNameToAvoidConflict
(
Tag
tag
,
String
userName
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment