{% extends 'partials/base.html' %} {% load humanize %} {% load thumbnail %} {% load specializtions_tags %} {% load project_tags %} {% block head_css %} {% endblock %} {% block content %} {% include 'partials/header.html' %}

{{ project.name }}

{% if request.user.is_contractor %}

{{ project.budget|intcomma }}

{% endif %} {% if request.user.is_contractor %}
{% endif %}
  • {{ project.created }}
  • {{ project.get_work_type_display }}
{% if project.cro %}

Есть допуск СРО

{% endif %}
{% if project.realty %}
  • Местоположение: {{ project.realty.location.name }}
  • Классификация здания: {{ project.realty.building_classification.name }}
  • Вид строительства: {{ project.realty.construction_type.name }}
{% endif %}

{{ project.text|linebreaksbr }}

{% if request.user.is_contractor and not answer %} Ответить на проект {% if can_answer_as_team %}
{% endif %} {% elif request.user.is_customer and request.user == project.customer %} Редактировать {% if project.state == 'active' %}
{% csrf_token %} Снять с публикации
{% elif project.state == 'trashed' %}
{% csrf_token %} Восстановить из корзины
{% endif %} {% endif %}
{% if request.user.is_contractor %} {% if answer %}
{% if answer.author|class_name == 'User' %}
{% if answer.author.avatar %} {% thumbnail answer.author.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.get_full_name }} [{{ answer.author.username }}]

{% elif answer.author|class_name == 'Team' %}
{% if answer.author.owner.avatar %} {% thumbnail answer.author.owner.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.name }}

{% endif %} {% if answer.author|class_name == 'User' %} {% if answer.author.contractor_status == 'free' %}
Свободен
{% endif %} {% endif %}
{% if answer.author|class_name == 'User' and answer.author.cro %}

Есть допуск СРО

{% elif answer.author|class_name == 'Team' %}

Есть допуск СРО

{% endif %}

Цена: {{ answer.budget|intcomma }}

{% if answer.term_type == 'project' %} Срок: За проект {% elif answer.term and answer.term_type %} Срок: {% morph answer.term TERM_TYPE_MORPHS|get:answer.term_type %} {% endif %}

Опубликован: {{ answer.created|date:'M d, Y' }}

{% csrf_token %} отказ
{% if project.order.contractor and project.order.contractor == answer.author %} Перейти к обсуждению {% elif project.order.team and project.order.team == answer.author %} Перейти к обсуждению {% else %} {% if answer.author|class_name == 'User' %} Перейти к обсуждению {% elif answer.author|class_name == 'Team'%} Перейти к обсуждению {% endif %} {% endif %}
    {% for answer_file in answer.files.all %}
  • {{ answer_file.name }} {{ answer_file.file.size|filesizeformat }}
  • {% endfor %}
{% for portf in answer.portfolios.all %}
{% endfor %}
{% for message in answer.messages.all %}
{% if message.is_sender_customer %}

{% firstof project.customer.get_full_name.strip project.customer.username %}

{% else %}

{% if answer.author|class_name == 'User' %} {% firstof answer.author.get_full_name.strip answer.author.username %} {% elif answer.author|class_name == 'Team' %} {% firstof answer.author.name.strip answer.author.owner.username %} {% endif %}

{% endif %} {{ message.created }}

{{ message.text|linebreaksbr }}

{% endfor %}
{% csrf_token %}
{% else %} {% endif %} {% elif request.user.is_customer and project in request.user.customer_projects.all %} {% if project.answers.exists %} {% if project.candidates.count > 1 %} {% endif %}

Новые исполнители

{% for answer in project|get_new_answers %}
{% if answer.author|class_name == 'User' %}
{% if answer.author.avatar %} {% thumbnail answer.author.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.get_full_name }} [{{ answer.author.username }}]

{% elif answer.author|class_name == 'Team' %}
{% if answer.author.owner.avatar %} {% thumbnail answer.author.owner.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.name }}

{% endif %} {% if answer.author|class_name == 'User' %} {% if answer.author.contractor_status == 'free' %}
Свободен
{% endif %} {% endif %}
{% if answer.author|class_name == 'User' %} {% ratings_widget answer.author.pk 'restList2' %} {% elif answer.author|class_name == 'Team'%} {% ratings_team_widget answer.author.pk 'restList2' %} {% endif %} {% if answer.author|class_name == 'User' and answer.author.cro %}

Есть допуск СРО

{% elif answer.author|class_name == 'Team' %}

Есть допуск СРО

{% endif %}

Цена: {{ answer.budget|intcomma }}

{% if answer.term_type == 'project' %} Срок: За проект {% elif answer.term and answer.term_type %} Срок: {% morph answer.term TERM_TYPE_MORPHS|get:answer.term_type %} {% endif %}

Опубликован: {{ answer.created|date:'M d, Y' }}

{% if answer.author not in project|get_candidates %} Кандидат {% endif %} {% if project.order.contractor and project.order.contractor == answer.author %} Перейти к обсуждению {% elif project.order.team and project.order.team == answer.author %} Перейти к обсуждению {% elif not project.order.contractor and not project.order.team %}
{% csrf_token %} предложить проект
{% else %} {# {% if answer.author|class_name == 'User' %}#} {# Перейти к обсуждению#} {# {% elif answer.author|class_name == 'Team'%}#} {# Перейти к обсуждению#} {# {% endif %}#} {% endif %}
{% csrf_token %} отказ
    {% for answer_file in answer.files.all %}
  • {{ answer_file.name }} {{ answer_file.file.size|filesizeformat }}
  • {% endfor %}
{% for portf in answer.portfolios.all %}
{% endfor %}
{% for message in answer.messages.all %}
{% if message.is_sender_customer %}

{% firstof project.customer.get_full_name.strip project.customer.username %}

{% else %}

{% if answer.author|class_name == 'User' %} {% firstof answer.author.get_full_name.strip answer.author.username %} {% elif answer.author|class_name == 'Team' %} {% firstof answer.author.name.strip answer.author.owner.username %} {% endif %}

{% endif %} {{ message.created }}

{{ message.text|linebreaksbr }}

{% endfor %}
{% csrf_token %}
{% endfor %}

Кандидаты

{% for answer in project|get_candidate_answers %}
{% if answer.author|class_name == 'User' %}
{% if answer.author.avatar %} {% thumbnail answer.author.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.get_full_name }} [{{ answer.author.username }}]

{% elif answer.author|class_name == 'Team' %}
{% if answer.author.owner.avatar %} {% thumbnail answer.author.owner.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.name }}

{% endif %} {% if answer.author|class_name == 'User' %} {% if answer.author.contractor_status == 'free' %}
Свободен
{% endif %} {% endif %}
{% if answer.author|class_name == 'User' %} {% ratings_widget answer.author.pk 'restList2' %} {% elif answer.author|class_name == 'Team'%} {% ratings_team_widget answer.author.pk 'restList2' %} {% endif %} {% if answer.author|class_name == 'User' and answer.author.cro %}

Есть допуск СРО

{% elif answer.author|class_name == 'Team' %}

Есть допуск СРО

{% endif %}

Цена: {{ answer.budget|intcomma }}

{% if answer.term_type == 'project' %} Срок: За проект {% elif answer.term and answer.term_type %} Срок: {% morph answer.term TERM_TYPE_MORPHS|get:answer.term_type %} {% endif %}

Опубликован: {{ answer.created|date:'M d, Y' }}

{% if TESTING %} Кандидат {% endif %} {% if project.order.contractor and project.order.contractor == answer.author %} Перейти к обсуждению {% elif project.order.team and project.order.team == answer.author %} Перейти к обсуждению {% elif not project.order.contractor and not project.order.team %}
{% csrf_token %} предложить проект
{% else %} {% if answer.author|class_name == 'User' %} Перейти к обсуждению {% elif answer.author|class_name == 'Team'%} Перейти к обсуждению {% endif %} {% endif %}
{% csrf_token %} отказ
    {% for answer_file in answer.files.all %}
  • {{ answer_file.name }} {{ answer_file.file.size|filesizeformat }}
  • {% endfor %}
{% for portf in answer.portfolios.all %}
{% endfor %}
{% for message in answer.messages.all %}
{% if message.is_sender_customer %}

{% firstof project.customer.get_full_name.strip project.customer.username %}

{% else %}

{% if answer.author|class_name == 'User' %} {% firstof answer.author.get_full_name.strip answer.author.username %} {% elif answer.author|class_name == 'Team' %} {% firstof answer.author.name.strip answer.author.owner.username %} {% endif %}

{% endif %} {{ message.created }}

{{ message.text|linebreaksbr }}

{% endfor %}
{% csrf_token %}
{% endfor %}

Отказы

{% for answer in project|get_rejected_answers %}
{% if answer.author|class_name == 'User' %}
{% if answer.author.avatar %} {% thumbnail answer.author.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.get_full_name }} [{{ answer.author.username }}]

{% elif answer.author|class_name == 'Team' %}
{% if answer.author.owner.avatar %} {% thumbnail answer.author.owner.avatar "125x125" crop="center" as avatar %} execitor-image {% endthumbnail %} {% else %} execitor-image {% endif %}

{{ answer.author.name }}

{% endif %} {% if answer.author|class_name == 'User' %} {% if answer.author.contractor_status == 'free' %}
Свободен
{% endif %} {% endif %}
{% if answer.author|class_name == 'User' %} {% ratings_widget answer.author.pk 'restList2' %} {% elif answer.author|class_name == 'Team'%} {% ratings_team_widget answer.author.pk 'restList2' %} {% endif %} {% if answer.author|class_name == 'User' and answer.author.cro %}

Есть допуск СРО

{% elif answer.author|class_name == 'Team' %}

Есть допуск СРО

{% endif %}

Цена: {{ answer.budget|intcomma }}

{% if answer.term_type == 'project' %} Срок: За проект {% elif answer.term and answer.term_type %} Срок: {% morph answer.term TERM_TYPE_MORPHS|get:answer.term_type %} {% endif %}

Опубликован: {{ answer.created|date:'M d, Y' }}

{% csrf_token %} Восстановить
{# {% if answer.author|class_name == 'User' %}#} {# Перейти к обсуждению#} {# {% elif answer.author|class_name == 'Team'%}#} {# Перейти к обсуждению#} {# {% endif %}#}
    {% for answer_file in answer.files.all %}
  • {{ answer_file.name }} {{ answer_file.file.size|filesizeformat }}
  • {% endfor %}
{% for portf in answer.portfolios.all %}
{% endfor %}
{% for message in answer.messages.all %}
{% if message.is_sender_customer %}

{% firstof project.customer.get_full_name.strip project.customer.username %}

{% else %}

{% if answer.author|class_name == 'User' %} {% firstof answer.author.get_full_name.strip answer.author.username %} {% elif answer.author|class_name == 'Team' %} {% firstof answer.author.name.strip answer.author.owner.username %} {% endif %}

{% endif %} {{ message.created }}

{{ message.text|linebreaksbr }}

{% endfor %}
{% endfor %}
{% endif %} {% endif %} {% include 'partials/footer.html' %}
{% endblock %} {% block js_block %} {% endblock %}