{% extends "layout/basic.html" %} {% block content %}
{% include "partials/discussion_list.html" %}
{% if vnode['doc_type'] == vj4.model.document.TYPE_PROBLEM %} {% with pdoc=vnode, owner_udoc=udict[vnode['owner_uid']], owner_dudoc=dudict[vnode['owner_uid']] if dudict %} {% include "partials/problem_sidebar.html" %} {% endwith %} {% elif vnode['doc_type'] == vj4.model.document.TYPE_CONTEST %} {% with tdoc=vnode, owner_udoc=udict[vnode['owner_uid']], owner_dudoc=dudict[vnode['owner_uid']] if dudict %} {% include "partials/contest_sidebar.html" %} {% endwith %} {% elif vnode['doc_type'] == vj4.model.document.TYPE_DISCUSSION_NODE %}
{% if vnode['pic'] %}
{% endif %}

{{ vnode['title'] or _('Create Discussion') }}

{% if vnode %} {% if handler.has_perm(vj4.model.builtin.PERM_CREATE_DISCUSSION) %}

{{ _('Create a Discussion') }}

{% else %} {% if not handler.has_priv(vj4.model.builtin.PRIV_USER_PROFILE) %}

{{ _('Login to Create a Discussion') }}

{% else %}

{{ _('No Permission to Create a Discussion') }}

{% endif %} {% endif %} {% else %}

{{ _('Select a node to create discussion.') }}

{% endif %}
{% endif %} {% include 'discussion_nodes_widget.html' %}
{% endblock %}