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
895c3c55
Commit
895c3c55
authored
Aug 05, 2016
by
Adam Niedzielski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Better presentation of member expiration.
parent
671d247e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
2 deletions
+7
-2
members_helper.rb
app/helpers/members_helper.rb
+4
-0
_member.html.haml
app/views/shared/members/_member.html.haml
+3
-2
No files found.
app/helpers/members_helper.rb
View file @
895c3c55
...
...
@@ -42,4 +42,8 @@ module MembersHelper
"Are you sure you want to leave the "
\
"
\"
#{
member_source
.
human_name
}
\"
#{
member_source
.
class
.
to_s
.
humanize
(
capitalize:
false
)
}
?"
end
def
member_expires_soon?
(
member
)
member
.
expires_at
<
7
.
days
.
from_now
end
end
app/views/shared/members/_member.html.haml
View file @
895c3c55
...
...
@@ -60,8 +60,9 @@
-
else
Joined
#{
time_ago_with_tooltip
(
member
.
created_at
)
}
-
if
member
.
expires?
%span
.prepend-left-20
Access expires
#{
member
.
expires_at
.
to_s
(
:medium
)
}
·
%span
{
class:
(
"text-warning"
if
member_expires_soon?
(
member
))
}
Expires in
#{
distance_of_time_in_words_to_now
(
member
.
expires_at
)
}
-
else
=
image_tag
avatar_icon
(
member
.
invite_email
,
40
),
class:
"avatar s40"
,
alt:
''
...
...
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