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
cf31f289
Commit
cf31f289
authored
Dec 29, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move project_last_activity to ProjectsHelper
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
231b91d0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
8 deletions
+8
-8
app/helpers/application_helper.rb
app/helpers/application_helper.rb
+0
-8
app/helpers/projects_helper.rb
app/helpers/projects_helper.rb
+8
-0
No files found.
app/helpers/application_helper.rb
View file @
cf31f289
...
...
@@ -136,14 +136,6 @@ module ApplicationHelper
Digest
::
SHA1
.
hexdigest
string
end
def
project_last_activity
(
project
)
if
project
.
last_activity_at
time_ago_with_tooltip
(
project
.
last_activity_at
,
'bottom'
,
'last_activity_time_ago'
)
+
" ago"
else
"Never"
end
end
def
authbutton
(
provider
,
size
=
64
)
file_name
=
"
#{
provider
.
to_s
.
split
(
'_'
).
first
}
_
#{
size
}
.png"
image_tag
(
"authbuttons/
#{
file_name
}
"
,
...
...
app/helpers/projects_helper.rb
View file @
cf31f289
...
...
@@ -187,4 +187,12 @@ module ProjectsHelper
def
default_clone_protocol
current_user
?
"ssh"
:
"http"
end
def
project_last_activity
(
project
)
if
project
.
last_activity_at
time_ago_with_tooltip
(
project
.
last_activity_at
,
'bottom'
,
'last_activity_time_ago'
)
+
" ago"
else
"Never"
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