From 992db6bd6973254bf0dab4ce0e7c3760b20be62d Mon Sep 17 00:00:00 2001 From: Andrey Smakotin Date: Mon, 1 Dec 2025 10:06:51 +0300 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=BE=20=D0=BE=D1=82=D0=BE=D0=B1=D1=80=D0=B0=D0=B6?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D1=81=D0=B5=D0=B1=D0=B5=D1=81=D1=82?= =?UTF-8?q?=D0=BE=D0=B8=D0=BC=D0=BE=D1=81=D1=82=D0=B8=20=D0=B2=20=D1=82?= =?UTF-8?q?=D0=B0=D0=B1=D0=BB=D0=B8=D1=86=D0=B5=20StockBatch?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Проблема: - В шаблоне использовалось несуществующее поле cost_per_unit - Фактическое поле в модели StockBatch называется cost_price Исправление: - Заменено batch.cost_per_unit на batch.cost_price - Теперь закупочная цена партии отображается корректно --- myproject/inventory/templates/inventory/debug_page.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/myproject/inventory/templates/inventory/debug_page.html b/myproject/inventory/templates/inventory/debug_page.html index 011d8d2..ef9d359 100644 --- a/myproject/inventory/templates/inventory/debug_page.html +++ b/myproject/inventory/templates/inventory/debug_page.html @@ -247,7 +247,7 @@ {{ batch.product.name }} {{ batch.warehouse.name }} {{ batch.quantity }} - {{ batch.cost_per_unit|floatformat:2 }} + {{ batch.cost_price|floatformat:2 }} {% if batch.is_active %} Да