From 1a21576f28f010be3a71fdfba8b018381d9c2959 Mon Sep 17 00:00:00 2001 From: Oliver Date: Wed, 8 Sep 2021 12:57:42 +1000 Subject: [PATCH] Adds separate option for "prevent_new_stock" to stock_table --- InvenTree/order/templates/order/purchase_order_detail.html | 2 +- InvenTree/templates/stock_table.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/InvenTree/order/templates/order/purchase_order_detail.html b/InvenTree/order/templates/order/purchase_order_detail.html index 02a4cd35f1..2bdff60ebe 100644 --- a/InvenTree/order/templates/order/purchase_order_detail.html +++ b/InvenTree/order/templates/order/purchase_order_detail.html @@ -38,7 +38,7 @@

{% trans "Received Items" %}

- {% include "stock_table.html" with read_only=True %} + {% include "stock_table.html" with prevent_new_stock=True %}
diff --git a/InvenTree/templates/stock_table.html b/InvenTree/templates/stock_table.html index 583f4db893..ae1f7c1a9b 100644 --- a/InvenTree/templates/stock_table.html +++ b/InvenTree/templates/stock_table.html @@ -16,7 +16,7 @@ {% if owner_control.value == "True" and user in owners or user.is_superuser or owner_control.value == "False" %} - {% if not read_only and roles.stock.add %} + {% if not read_only and not prevent_new_stock and roles.stock.add %}