This repository has been archived by the owner on Feb 8, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 308
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor team and community listings
- Loading branch information
Showing
4 changed files
with
39 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,21 @@ | ||
{% if communities %} | ||
<h2>{{ _("Communities") }}</h2> | ||
<ul class="community memberships"> | ||
{% for community in communities %} | ||
<li> | ||
<a href="/for/{{ community.slug }}/">{{ community.name }}</a> | ||
<div class="fine">{{ with_others(community) }}</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% if user.participant == participant %} | ||
<h2>{{ ngettext("You are in {n} community", "You are in {n} communities", | ||
len(communities)) }}</h2> | ||
{% else %} | ||
<h2>{{ _("Communities") }}</h2> | ||
{% endif %} | ||
<ul class="community memberships"> | ||
{% for community in communities %} | ||
<li> | ||
<a href="/for/{{ community.slug }}/">{{ community.name }}</a> | ||
<div class="fine">{{ with_others(community) }}</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% elif user.participant == participant %} | ||
<h2>{{ _("You haven't joined any community") }}</h2> | ||
{% endif %} | ||
{% if user.participant == participant %} | ||
<p><a href="/for/">{{ _("Join Communities") }}</a></p> | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,23 @@ | ||
{% set teams = participant.get_teams() %} | ||
{% if teams %} | ||
<h2>{{ _('Teams') }}</h2> | ||
<ul class="team memberships"> | ||
{% for team in teams %} | ||
<li> | ||
<a href="/{{ team.name }}/">{{ team.name }}</a> | ||
<div class="fine">{{ with_others(team) }}</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% if user.participant == participant %} | ||
<h2>{{ ngettext("You are in {n} team", "You are in {n} teams", | ||
len(teams)) }}</h2> | ||
{% else %} | ||
<h2>{{ _("Teams") }}</h2> | ||
{% endif %} | ||
<ul class="team memberships"> | ||
{% for team in teams %} | ||
<li> | ||
<a href="/{{ team.name }}/">{{ team.name }}</a> | ||
<div class="fine">{{ with_others(team) }}</div> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% if user.participant == participant %} | ||
<p><a href="/about/teams/">{{ _("Learn more about how teams work") }}</a></p> | ||
{% endif %} | ||
{% elif user.participant == participant %} | ||
<h2>{{ _('You are not in any team') }}</h2> | ||
<p><a href="/about/teams/">{{ _('What are Teams?') }}</a></p> | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters