Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
b76ef40e
Commit
b76ef40e
authored
Sep 04, 2016
by
Airat Shigapov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix missing flash messages on service edit page
parent
beb0b666
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
3 deletions
+19
-3
CHANGELOG
CHANGELOG
+1
-0
app/controllers/projects/services_controller.rb
app/controllers/projects/services_controller.rb
+2
-3
spec/controllers/projects/services_controller_spec.rb
spec/controllers/projects/services_controller_spec.rb
+16
-0
No files found.
CHANGELOG
View file @
b76ef40e
...
@@ -40,6 +40,7 @@ v 8.12.0 (unreleased)
...
@@ -40,6 +40,7 @@ v 8.12.0 (unreleased)
- Fix markdown help references (ClemMakesApps)
- Fix markdown help references (ClemMakesApps)
- Add last commit time to repo view (ClemMakesApps)
- Add last commit time to repo view (ClemMakesApps)
- Fix accessibility and visibility of project list dropdown button !6140
- Fix accessibility and visibility of project list dropdown button !6140
- Fix missing flash messages on service edit page (airatshigapov)
- Added project specific enable/disable setting for LFS !5997
- Added project specific enable/disable setting for LFS !5997
- Don't expose a user's token in the `/api/v3/user` API (!6047)
- Don't expose a user's token in the `/api/v3/user` API (!6047)
- Remove redundant js-timeago-pending from user activity log (ClemMakesApps)
- Remove redundant js-timeago-pending from user activity log (ClemMakesApps)
...
...
app/controllers/projects/services_controller.rb
View file @
b76ef40e
...
@@ -20,9 +20,8 @@ class Projects::ServicesController < Projects::ApplicationController
...
@@ -20,9 +20,8 @@ class Projects::ServicesController < Projects::ApplicationController
def
update
def
update
if
@service
.
update_attributes
(
service_params
[
:service
])
if
@service
.
update_attributes
(
service_params
[
:service
])
redirect_to
(
redirect_to
(
edit_namespace_project_service_path
(
@project
.
namespace
,
@project
,
edit_namespace_project_service_path
(
@project
.
namespace
,
@project
,
@service
.
to_param
),
@service
.
to_param
,
notice:
notice:
'Successfully updated.'
'Successfully updated.'
)
)
)
else
else
render
'edit'
render
'edit'
...
...
spec/controllers/projects/services_controller_spec.rb
View file @
b76ef40e
...
@@ -49,4 +49,20 @@ describe Projects::ServicesController do
...
@@ -49,4 +49,20 @@ describe Projects::ServicesController do
let!
(
:referrer
)
{
nil
}
let!
(
:referrer
)
{
nil
}
end
end
end
end
describe
'PUT #update'
do
context
'on successful update'
do
it
'sets the flash'
do
expect
(
service
).
to
receive
(
:to_param
).
and_return
(
'hipchat'
)
put
:update
,
namespace_id:
project
.
namespace
.
id
,
project_id:
project
.
id
,
id:
service
.
id
,
service:
{
active:
false
}
expect
(
flash
[
:notice
]).
to
eq
'Successfully updated.'
end
end
end
end
end
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