Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
holmes
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
QA
holmes
Commits
c7ffd697
Commit
c7ffd697
authored
Jan 28, 2022
by
黎博
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
关闭项目时,将对应的项目部署状态也改成0
parent
3523c7d6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
PipelineController.java
...va/cn/qg/holmes/controller/gitlab/PipelineController.java
+12
-0
No files found.
src/main/java/cn/qg/holmes/controller/gitlab/PipelineController.java
View file @
c7ffd697
...
@@ -312,6 +312,18 @@ public class PipelineController {
...
@@ -312,6 +312,18 @@ public class PipelineController {
if
(!
dingRobotService
.
updateById
(
dingRobot
))
{
if
(!
dingRobotService
.
updateById
(
dingRobot
))
{
return
JsonResult
.
buildErrorStateResult
(
"更新状态失败!"
,
false
);
return
JsonResult
.
buildErrorStateResult
(
"更新状态失败!"
,
false
);
}
}
// 同时将pipline里的项目置为不可用
if
(
status
==
2
)
{
QueryWrapper
<
Pipeline
>
pipelineQueryWrapper
=
new
QueryWrapper
<>();
pipelineQueryWrapper
.
eq
(
"ding_robot_id"
,
dingRobotId
);
List
<
Pipeline
>
pipelineList
=
pipelineService
.
list
(
pipelineQueryWrapper
);
if
(
pipelineList
.
size
()
>
0
)
{
for
(
Pipeline
pipeline:
pipelineList
)
{
pipeline
.
setEnable
(
0
);
pipelineService
.
updateById
(
pipeline
);
}
}
}
return
JsonResult
.
buildSuccessResult
(
"更新状态成功!"
,
true
);
return
JsonResult
.
buildSuccessResult
(
"更新状态成功!"
,
true
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
return
JsonResult
.
buildErrorStateResult
(
"更新状态失败!"
,
false
);
return
JsonResult
.
buildErrorStateResult
(
"更新状态失败!"
,
false
);
...
...
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