зеркало из https://github.com/mozilla/batucada.git
wired up 'member actions' (un/follow, message OR edit profile) for project lead
This commit is contained in:
Родитель
05052b256f
Коммит
2825250043
|
@ -103,9 +103,23 @@
|
|||
</h3>
|
||||
|
||||
<div class="member-actions">
|
||||
<a class="button" href="#">{{ _('Follow User') }}</a>
|
||||
<a class="button" href="#">{{ _('Message') }}</a>
|
||||
</div>
|
||||
{% if project.created_by == user.get_profile %}
|
||||
<a class="button" href="{% locale_url users_profile_edit %}">{{ _('Edit Profile') }}</a>
|
||||
{% else %}
|
||||
{% if project.created_by in user.get_profile.following %}
|
||||
<form action="{% locale_url relationships_unfollow object_type='user' slug=project.created_by.username %}" method="post">
|
||||
{% csrf_token %}
|
||||
<button id="unfollow-user" >Unfollow User</button>
|
||||
</form>
|
||||
{% else %}
|
||||
<form action="{% locale_url relationships_follow object_type='user' slug=project.created_by.username %}" method="post">
|
||||
{% csrf_token %}
|
||||
<button id="follow-user">Follow User</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
<a class="button" href="{% locale_url drumbeatmail_compose_to username=project.created_by.username %}">{{ _('Private Message')}}</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
</div> <!-- /.member-details -->
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче