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
765c1b27
Commit
765c1b27
authored
Jun 03, 2012
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #886 from avakarev/clean-up-tab_helper
Clean up tab_helper.rb code
parents
cbea0af2
fb4b571f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
10 deletions
+4
-10
app/helpers/tab_helper.rb
app/helpers/tab_helper.rb
+4
-10
No files found.
app/helpers/tab_helper.rb
View file @
765c1b27
...
...
@@ -12,23 +12,17 @@ module TabHelper
return
"current"
if
current_page?
(
:controller
=>
"projects"
,
:action
=>
action
,
:id
=>
@project
)
end
if
controller
.
controller_name
==
"snippets"
||
controller
.
controller_name
==
"hooks"
||
controller
.
controller_name
==
"deploy_keys"
||
controller
.
controller_name
==
"team_members"
if
[
'snippets'
,
'hooks'
,
'deploy_keys'
,
'team_members'
].
include?
controller
.
controller_name
"current"
end
end
def
tree_tab_class
controller
.
controller_name
==
"refs"
?
"current"
:
nil
controller
.
controller_name
==
"refs"
?
"current"
:
nil
end
def
commit_tab_class
if
controller
.
controller_name
==
"commits"
||
controller
.
controller_name
==
"repositories"
||
controller
.
controller_name
==
"protected_branches"
if
[
'commits'
,
'repositories'
,
'protected_branches'
].
include?
controller
.
controller_name
"current"
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