diff --git a/InvenTree/part/templates/part/part_base.html b/InvenTree/part/templates/part/part_base.html index 413f761cb9..8e1b60b31b 100644 --- a/InvenTree/part/templates/part/part_base.html +++ b/InvenTree/part/templates/part/part_base.html @@ -49,9 +49,25 @@ {% if roles.stock.change %} - +
+ + +
{% endif %} {% if part.purchaseable %} {% if roles.purchase_order.add %} @@ -272,7 +288,7 @@ printPartLabels([{{ part.pk }}]); }); - $("#part-count").click(function() { + function adjustPartStock(action) { inventreeGet( '{% url "api-stock-list" %}', { @@ -284,7 +300,7 @@ }, { success: function(items) { - adjustStock('count', items, { + adjustStock(action, items, { onSuccess: function() { location.reload(); } @@ -292,6 +308,14 @@ }, } ); + } + + $("#part-move").click(function() { + adjustPartStock('move'); + }); + + $("#part-count").click(function() { + adjustPartStock('count'); }); $("#price-button").click(function() { diff --git a/InvenTree/stock/templates/stock/location.html b/InvenTree/stock/templates/stock/location.html index 889e7a2c98..8230de473c 100644 --- a/InvenTree/stock/templates/stock/location.html +++ b/InvenTree/stock/templates/stock/location.html @@ -59,11 +59,17 @@ {% if owner_control.value == "False" or owner_control.value == "True" and user in owners or user.is_superuser %} {% if roles.stock.change %}
- + +
  • + + + {% trans "Count stock" %} + +
  • +
    {% endif %} {% if roles.stock_location.change %}