BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
590c84c7
Commit
590c84c7
authored
Jun 08, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix determine of layout for group/team
parent
08e52a56
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
5 deletions
+20
-5
groups_controller.rb
app/controllers/groups_controller.rb
+10
-3
teams_controller.rb
app/controllers/teams_controller.rb
+10
-2
No files found.
app/controllers/groups_controller.rb
View file @
590c84c7
class
GroupsController
<
ApplicationController
respond_to
:html
layout
'group'
,
except:
[
:new
,
:create
]
before_filter
:group
,
except:
[
:new
,
:create
]
# Authorize
...
...
@@ -12,7 +10,8 @@ class GroupsController < ApplicationController
# Load group projects
before_filter
:projects
,
except:
[
:new
,
:create
]
layout
'navless'
,
only:
[
:new
,
:create
]
layout
:determine_layout
before_filter
:set_title
,
only:
[
:new
,
:create
]
def
new
...
...
@@ -141,4 +140,12 @@ class GroupsController < ApplicationController
def
set_title
@title
=
'New Group'
end
def
determine_layout
if
[
:new
,
:create
].
include?
(
action_name
.
to_sym
)
'navless'
else
'group'
end
end
end
app/controllers/teams_controller.rb
View file @
590c84c7
...
...
@@ -6,8 +6,8 @@ class TeamsController < ApplicationController
before_filter
:user_team
,
except:
[
:new
,
:create
]
layout
'user_team'
,
except:
[
:new
,
:create
]
layout
'navless'
,
only:
[
:new
,
:create
]
layout
:determine_layout
before_filter
:set_title
,
only:
[
:new
,
:create
]
def
show
...
...
@@ -82,4 +82,12 @@ class TeamsController < ApplicationController
def
set_title
@title
=
'New Team'
end
def
determine_layout
if
[
:new
,
:create
].
include?
(
action_name
.
to_sym
)
'navless'
else
'user_team'
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