diff --git a/myproject/inventory/templates/inventory/incoming_document/incoming_document_detail.html b/myproject/inventory/templates/inventory/incoming_document/incoming_document_detail.html index 84c9d18..11e8d13 100644 --- a/myproject/inventory/templates/inventory/incoming_document/incoming_document_detail.html +++ b/myproject/inventory/templates/inventory/incoming_document/incoming_document_detail.html @@ -188,6 +188,7 @@ Закупочная цена Сумма Примечания + Текущая цена продажи {% if document.can_edit %} {% endif %} @@ -200,18 +201,26 @@ {{ item.product.name }} - {{ item.quantity|smart_quantity }} {% if document.can_edit %} - + + {{ item.quantity|smart_quantity }} + + + {% else %} + {{ item.quantity|smart_quantity }} {% endif %} {{ item.cost_price|floatformat:2 }} {% if document.can_edit %} - {% endif %} @@ -221,11 +230,45 @@ {% if item.notes %}{{ item.notes|truncatechars:50 }}{% else %}-{% endif %} {% if document.can_edit %} - {% endif %} + + {% if item.product.sale_price %} +
{{ item.product.price|floatformat:2 }} руб.
+ {% if user.is_superuser or user.tenant_role.role.code == 'owner' or user.tenant_role.role.code == 'manager' %} + + {{ item.product.sale_price|floatformat:2 }} руб. + + {% else %} + + {{ item.product.sale_price|floatformat:2 }} руб. + + {% endif %} + {% else %} + {% if user.is_superuser or user.tenant_role.role.code == 'owner' or user.tenant_role.role.code == 'manager' %} + + {{ item.product.price|floatformat:2 }} руб. + + {% else %} + + {{ item.product.price|floatformat:2 }} руб. + + {% endif %} + {% endif %} + {% if document.can_edit %}
@@ -256,7 +299,7 @@ {% empty %} - + Позиций пока нет @@ -268,7 +311,7 @@ Итого: {{ document.total_quantity|smart_quantity }} - {{ document.total_cost|floatformat:2 }} + {{ document.total_cost|floatformat:2 }} @@ -283,6 +326,7 @@ + + + {% endblock %}