{% extends "kbforums/base.html" %} {% from "layout/errorlist.html" import errorlist %} {% from "includes/common_macros.html" import content_editor with context %} {% from "kbforums/includes/macros.html" import kbforums_warning with context %} {# L10n: {t} is the title of the thread. {d} is the name of the document. #} {% set title = _('{t} | {d} Discussion | Knowledge Base')|f(t=thread.title, d=document.title) %} {% set crumbs = [(document.get_absolute_url(), document.title), ((url('wiki.discuss.threads', document.slug), 'rel="ugc nofollow"'), _('Discuss')), (None, thread.title)] %} {% set scripts = ('forums',) %} {% block side_top_top %} {% endblock %} {% block content %}
{{ kbforums_warning(document, user) }}

{{ thread.title }}

{% if user.is_authenticated %}
{% csrf_token %} {% if is_watching_thread %} {% set watch = _('Stop watching this thread') %} {% else %} {% set watch = _('Watch this thread') %} {% endif %}
{% endif %} {% if posts %}
    {% for post in posts.object_list %}
  1. {% include "kbforums/includes/post.html" %}
  2. {% endfor %}
{{ posts|paginator }} {% else %}

{{ _('Oh, no! Looks like there are no posts!') }}

{% endif %} {% if user.is_authenticated and not thread.is_locked %}
{% csrf_token %}

{{ _('Post a reply') }}

{{ errorlist(form) }} {% if request.limited %}
{{ _('You have exceeded the number of threads and replies that can be posted in a given amount of time. Please try again shortly.') }}
{% endif %}
{{ content_editor(form.content) }}
{% elif user.is_authenticated and thread.is_locked %}

{{ _('This thread has been locked. It is no longer possible to post new replies.') }}

{% endif %}
{% if post_preview %} {% include "kbforums/includes/post_preview.html" %} {% endif %}
{% endblock %}