annotate gpp/templates/forums/topic.html @ 557:7247a406f92b

Merging change to requirements.txt made on production server.
author Brian Neal <bgneal@gmail.com>
date Sun, 29 Jan 2012 14:45:09 -0600
parents 70722b7d10af
children
rev   line source
bgneal@86 1 {% extends 'base.html' %}
bgneal@310 2 {% load url from future %}
bgneal@127 3 {% load forum_tags %}
bgneal@556 4 {% load core_tags %}
bgneal@86 5 {% block title %}Forums: {{ topic.name }}{% endblock %}
bgneal@556 6 {% block custom_meta %}
bgneal@556 7 {% open_graph_meta_tags topic %}
bgneal@556 8 {% endblock %}
bgneal@358 9 {% block custom_js %}
bgneal@358 10 {{ form.media }}
bgneal@358 11 {% include "forums/jump_box.js" %}
bgneal@358 12 {% endblock %}
bgneal@86 13 {% block content %}
bgneal@283 14 {% forum_navigation topic %}
bgneal@86 15
bgneal@86 16 <div class="forum-block">
bgneal@104 17 {% if topic.sticky %}
bgneal@312 18 <img src="{{ STATIC_URL }}icons/asterisk_orange.png" alt="Sticky" title="Sticky" />
bgneal@104 19 {% endif %}
bgneal@102 20 {% if topic.locked %}
bgneal@312 21 <img src="{{ STATIC_URL }}icons/lock.png" alt="Lock" title="This topic is locked" />
bgneal@104 22 {% endif %}
bgneal@104 23 {% if can_reply %}
bgneal@104 24 {% if topic.locked or topic.sticky %}&bull;{% endif %}
bgneal@87 25 {% if last_page %}
bgneal@102 26 <a href="#forum-reply-form">New Reply</a>
bgneal@87 27 {% else %}
bgneal@102 28 <a href="./?page={{ page.paginator.num_pages }}#forum-reply-form">New Reply</a>
bgneal@87 29 {% endif %}
bgneal@102 30 {% endif %}
bgneal@310 31 &bull; <a href="{% url 'forums-new_topic' slug=forum.slug %}">New Topic</a>
bgneal@97 32 {{ page_nav }}
bgneal@86 33
bgneal@89 34 <table class="forum-topic" id="forum-topic">
bgneal@90 35 {% for post in page.object_list %}
bgneal@394 36 {% cycle 'odd' 'even' as rowcolors silent %}
bgneal@377 37 {% include 'forums/display_post.html' %}
bgneal@86 38 {% endfor %}
bgneal@86 39 </table>
bgneal@97 40 {{ page_nav }}
bgneal@358 41 {% include 'forums/jump_box.html' %}
bgneal@109 42 {% if can_moderate %}
bgneal@109 43 <div class="forum-mod-controls">
bgneal@310 44 <form action="{% url 'forums-mod_topic_stick' topic.id %}" method="post">{% csrf_token %}
bgneal@109 45 <input type="submit" value="{% if topic.sticky %}Unstick{% else %}Stick{% endif %} Topic" />
bgneal@109 46 </form>
bgneal@310 47 <form action="{% url 'forums-mod_topic_lock' topic.id %}" method="post">{% csrf_token %}
bgneal@109 48 <input type="submit" value="{% if topic.locked %}Unlock{% else %}Lock{% endif %} Topic" />
bgneal@109 49 </form>
bgneal@310 50 <form action="{% url 'forums-mod_topic_delete' topic.id %}" method="post">{% csrf_token %}
bgneal@109 51 <input type="submit" value="Delete Topic" id="forum-mod-del-topic" />
bgneal@109 52 </form>
bgneal@312 53 <a href="{% url 'forums-mod_topic_move' topic.id %}"><img src="{{ STATIC_URL }}icons/application_go.png" alt="Move Topic" title="Move Topic" /></a>
bgneal@310 54 <a href="{% url 'forums-mod_topic_move' topic.id %}">Move this topic</a>
bgneal@312 55 <a href="{% url 'forums-mod_topic_split' topic.id %}"><img src="{{ STATIC_URL }}icons/arrow_branch.png" alt="Split Topic" title="Split Topic" /></a>
bgneal@310 56 <a href="{% url 'forums-mod_topic_split' topic.id %}">Split this topic</a>
bgneal@109 57 </div>
bgneal@109 58 {% endif %}
bgneal@90 59
bgneal@104 60 {% if last_page and can_reply %}
bgneal@87 61 <a name="forum-reply-form"></a>
bgneal@285 62 {% show_form "Reply to Topic" form "Submit Reply" 1 %}
bgneal@86 63 {% endif %}
bgneal@181 64
bgneal@181 65 {% if user.is_authenticated %}
bgneal@310 66 <form action={% if is_favorite %}"{% url 'forums-unfavorite_topic' topic.id %}"{% else %}"{% url 'forums-favorite_topic' topic.id %}"{% endif %} method="post">{% csrf_token %}
bgneal@232 67 <fieldset>
bgneal@232 68 <legend>Favorite Options</legend>
bgneal@232 69 <p>
bgneal@232 70 {% if is_favorite %}
bgneal@312 71 <img src="{{ STATIC_URL }}icons/delete.png" alt="Favorite" />
bgneal@232 72 You currently have saved this topic in your list of favorites.
bgneal@232 73 <input type="submit" value="Remove from favorites" />
bgneal@232 74 {% else %}
bgneal@312 75 <img src="{{ STATIC_URL }}icons/add.png" alt="Favorite" />
bgneal@232 76 Would you like to save this topic to your favorites list?
bgneal@232 77 <input type="submit" value="Save to favorites" />
bgneal@232 78 {% endif %}
bgneal@232 79 </p>
bgneal@232 80 <p>
bgneal@232 81 To manage all your forum topic favorites, please visit your
bgneal@310 82 <a href="{% url 'forums-manage_favorites' %}">favorites page</a>.
bgneal@232 83 </p>
bgneal@232 84 </fieldset>
bgneal@232 85 </form>
bgneal@232 86
bgneal@310 87 <form action={% if is_subscribed %}"{% url 'forums-unsubscribe_topic' topic.id %}"{% else %}"{% url 'forums-subscribe_topic' topic.id %}"{% endif %} method="post">{% csrf_token %}
bgneal@181 88 <fieldset>
bgneal@181 89 <legend>Subscription Options</legend>
bgneal@181 90 <p>
bgneal@181 91 {% if is_subscribed %}
bgneal@312 92 <img src="{{ STATIC_URL }}icons/email_delete.png" alt="Email" />
bgneal@181 93 You are currently subscribed to this topic and will receive an email when new replies are posted.
bgneal@181 94 <input type="submit" value="Unsubscribe Me" />
bgneal@181 95 {% else %}
bgneal@312 96 <img src="{{ STATIC_URL }}icons/email_add.png" alt="Email" />
bgneal@181 97 Would you like to receive an email when someone replies to this topic?
bgneal@181 98 <input type="submit" value="Subscribe via Email" />
bgneal@181 99 {% endif %}
bgneal@181 100 </p>
bgneal@181 101 <p>
bgneal@181 102 To manage all your forum topic subscriptions, please visit your
bgneal@310 103 <a href="{% url 'forums-manage_subscriptions' %}">subscriptions page</a>.
bgneal@181 104 </p>
bgneal@181 105 </fieldset>
bgneal@181 106 </form>
bgneal@181 107 {% endif %}
bgneal@343 108 <a href="#top" class="quiet" title="Goto top of the page">Top</a>
bgneal@86 109 </div>
bgneal@86 110 {% endblock %}