Mercurial > public > sg101
comparison gpp/templates/forums/topic.html @ 232:a46788862737
Implement a forum favorites feature for #82
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sun, 01 Aug 2010 21:26:12 +0000 |
parents | 6a5549c2efb5 |
children | 6dde069debd4 |
comparison
equal
deleted
inserted
replaced
231:a2d388ed106e | 232:a46788862737 |
---|---|
57 <a name="forum-reply-form"></a> | 57 <a name="forum-reply-form"></a> |
58 {% show_form "Reply to Topic" form "Submit Reply" 1 MEDIA_URL %} | 58 {% show_form "Reply to Topic" form "Submit Reply" 1 MEDIA_URL %} |
59 {% endif %} | 59 {% endif %} |
60 | 60 |
61 {% if user.is_authenticated %} | 61 {% if user.is_authenticated %} |
62 <form action={% if is_bookmarked %}"{% url forums-unfavorite_topic topic.id %}"{% else %}"{% url forums-favorite_topic topic.id %}"{% endif %} method="post">{% csrf_token %} | |
63 <fieldset> | |
64 <legend>Favorite Options</legend> | |
65 <p> | |
66 {% if is_favorite %} | |
67 <img src="{{ MEDIA_URL }}icons/delete.png" alt="Favorite" /> | |
68 You currently have saved this topic in your list of favorites. | |
69 <input type="submit" value="Remove from favorites" /> | |
70 {% else %} | |
71 <img src="{{ MEDIA_URL }}icons/add.png" alt="Favorite" /> | |
72 Would you like to save this topic to your favorites list? | |
73 <input type="submit" value="Save to favorites" /> | |
74 {% endif %} | |
75 </p> | |
76 <p> | |
77 To manage all your forum topic favorites, please visit your | |
78 <a href="{% url forums-manage_favorites %}">favorites page</a>. | |
79 </p> | |
80 </fieldset> | |
81 </form> | |
82 | |
62 <form action={% if is_subscribed %}"{% url forums-unsubscribe_topic topic.id %}"{% else %}"{% url forums-subscribe_topic topic.id %}"{% endif %} method="post">{% csrf_token %} | 83 <form action={% if is_subscribed %}"{% url forums-unsubscribe_topic topic.id %}"{% else %}"{% url forums-subscribe_topic topic.id %}"{% endif %} method="post">{% csrf_token %} |
63 <fieldset> | 84 <fieldset> |
64 <legend>Subscription Options</legend> | 85 <legend>Subscription Options</legend> |
65 <p> | 86 <p> |
66 {% if is_subscribed %} | 87 {% if is_subscribed %} |