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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
5a14f5a4
Commit
5a14f5a4
authored
May 05, 2015
by
Douwe Maan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tweak flash messages around license upload/removal.
parent
60323c61
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
app/controllers/admin/licenses_controller.rb
app/controllers/admin/licenses_controller.rb
+10
-2
No files found.
app/controllers/admin/licenses_controller.rb
View file @
5a14f5a4
...
@@ -29,7 +29,7 @@ class Admin::LicensesController < Admin::ApplicationController
...
@@ -29,7 +29,7 @@ class Admin::LicensesController < Admin::ApplicationController
respond_with
(
@license
,
location:
admin_license_path
)
do
respond_with
(
@license
,
location:
admin_license_path
)
do
if
@license
.
save
if
@license
.
save
flash
[
:notice
]
=
"The license was successfully uploaded. You can see the details below."
flash
[
:notice
]
=
"The license was successfully uploaded
and is now active
. You can see the details below."
end
end
end
end
end
end
...
@@ -37,7 +37,14 @@ class Admin::LicensesController < Admin::ApplicationController
...
@@ -37,7 +37,14 @@ class Admin::LicensesController < Admin::ApplicationController
def
destroy
def
destroy
license
.
destroy
license
.
destroy
redirect_to
admin_license_path
,
notice:
"The license was removed."
message
=
"The license was removed. "
if
License
.
current
flash
[
:notice
]
=
"The license was removed. GitLab has fallen back on the previous license."
else
flash
[
:alert
]
=
"The license was removed. GitLab now no longer has a valid license."
end
redirect_to
admin_license_path
end
end
private
private
...
@@ -52,6 +59,7 @@ class Admin::LicensesController < Admin::ApplicationController
...
@@ -52,6 +59,7 @@ class Admin::LicensesController < Admin::ApplicationController
def
require_license
def
require_license
return
if
license
return
if
license
flash
.
keep
redirect_to
new_admin_license_path
redirect_to
new_admin_license_path
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