mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-01 03:00:54 +00:00
Added global setting and updated stock item templates
This commit is contained in:
@ -11,7 +11,9 @@
|
||||
<h4>{% trans "Stock Tracking Information" %}</h4>
|
||||
<hr>
|
||||
|
||||
{% if roles.stock.change %}
|
||||
<!-- Check permissions and owner -->
|
||||
{% setting_object 'STOCK_OWNER' as owner_enable %}
|
||||
{% if user.is_superuser or roles.stock.change and item.owner == user and owner_enable.value == "True" %}
|
||||
<div id='table-toolbar'>
|
||||
<div class='btn-group'>
|
||||
<button class='btn btn-success' type='button' title='New tracking entry' id='new-entry'>
|
||||
|
@ -112,7 +112,10 @@ InvenTree | {% trans "Stock Item" %} - {{ item }}
|
||||
</ul>
|
||||
</div>
|
||||
<!-- Stock adjustment menu -->
|
||||
{% if roles.stock.change and not item.is_building %}
|
||||
<!-- Check permissions and owner -->
|
||||
{% setting_object 'STOCK_OWNER' as owner_enable %}
|
||||
{% if user.is_superuser or roles.stock.change and item.owner == user and owner_enable.value == "True" %}
|
||||
{% if not item.is_building %}
|
||||
<div class='btn-group'>
|
||||
<button id='stock-options' title='{% trans "Stock adjustment actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'><span class='fas fa-boxes'></span> <span class='caret'></span></button>
|
||||
<ul class='dropdown-menu' role='menu'>
|
||||
@ -161,6 +164,8 @@ InvenTree | {% trans "Stock Item" %} - {{ item }}
|
||||
</ul>
|
||||
</div>
|
||||
{% endif %}
|
||||
<!-- Check permissions and owner -->
|
||||
{% endif %}
|
||||
<button type='button' class='btn btn-default' id='stock-test-report' title='{% trans "Generate test report" %}'>
|
||||
<span class='fas fa-file-invoice'/>
|
||||
</button>
|
||||
|
Reference in New Issue
Block a user