mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-19 21:45:39 +00:00
Revert 1fb76b9
Removes global functions to enable / disable entire sections of functionality
This commit is contained in:
@ -4,12 +4,6 @@
|
||||
|
||||
{% settings_value "PART_INTERNAL_PRICE" as show_internal_price %}
|
||||
{% settings_value 'PART_SHOW_RELATED' as show_related %}
|
||||
{% settings_value 'BUILD_FUNCTION_ENABLE' as enable_build %}
|
||||
{% settings_value 'STOCK_FUNCTION_ENABLE' as enable_stock %}
|
||||
{% settings_value 'PO_FUNCTION_ENABLE' as enable_po %}
|
||||
{% settings_value 'SO_FUNCTION_ENABLE' as enable_so %}
|
||||
{% settings_value 'BUY_FUNCTION_ENABLE' as enable_buy %}
|
||||
{% settings_value 'SELL_FUNCTION_ENABLE' as enable_sell %}
|
||||
|
||||
<ul class='list-group'>
|
||||
<li class='list-group-item'>
|
||||
@ -31,14 +25,12 @@
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if enable_stock %}
|
||||
<li class='list-group-item' title='{% trans "Stock Items" %}'>
|
||||
<a href='#' id='select-part-stock' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-boxes sidebar-icon'></span>
|
||||
{% trans "Stock" %}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if part.assembly %}
|
||||
<li class='list-group-item' title='{% trans "Bill of Materials" %}'>
|
||||
<a href='#' id='select-bom' class='nav-toggle'>
|
||||
@ -46,7 +38,7 @@
|
||||
{% trans "Bill of Materials" %}
|
||||
</a>
|
||||
</li>
|
||||
{% if roles.build.view and enable_build %}
|
||||
{% if roles.build.view %}
|
||||
<li class='list-group-item ' title='{% trans "Build Orders" %}'>
|
||||
<a href='#' id='select-build-orders' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-tools sidebar-icon'></span>
|
||||
@ -63,22 +55,19 @@
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if enable_buy or enable_sell %}
|
||||
<li class='list-group-item' title='{% trans "Pricing Information" %}'>
|
||||
<a href='#' id='select-pricing' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-dollar-sign sidebar-icon'></span>
|
||||
{% trans "Prices" %}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if part.purchaseable and roles.purchase_order.view and enable_buy %}
|
||||
{% if part.purchaseable and roles.purchase_order.view %}
|
||||
<li class='list-group-item' title='{% trans "Suppliers" %}'>
|
||||
<a href='#' id='select-suppliers' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-building sidebar-icon'></span>
|
||||
{% trans "Suppliers" %}
|
||||
</a>
|
||||
</li>
|
||||
{% if enable_po %}
|
||||
<li class='list-group-item' title='{% trans "Purchase Orders" %}'>
|
||||
<a href='#' id='select-purchase-orders' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-shopping-cart sidebar-icon'></span>
|
||||
@ -86,8 +75,7 @@
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% if part.salable and roles.sales_order.view and enable_sell and enable_so %}
|
||||
{% if part.salable and roles.sales_order.view %}
|
||||
<li class='list-group-item' title='{% trans "Sales Orders" %}'>
|
||||
<a href='#' id='select-sales-orders' class='nav-toggle'>
|
||||
<span class='menu-tab-icon fas fa-truck sidebar-icon'></span>
|
||||
|
@ -10,11 +10,6 @@
|
||||
|
||||
{% block content %}
|
||||
|
||||
{% settings_value 'BUY_FUNCTION_ENABLE' as enable_buy %}
|
||||
{% settings_value 'SELL_FUNCTION_ENABLE' as enable_sell %}
|
||||
{% settings_value 'PO_FUNCTION_ENABLE' as enable_po %}
|
||||
{% settings_value 'STOCK_FUNCTION_ENABLE' as enable_stock %}
|
||||
|
||||
<div class="panel panel-default panel-inventree">
|
||||
<!-- Default panel contents -->
|
||||
<div class="panel-heading"><h3>{{ part.full_name }}</h3></div>
|
||||
@ -85,12 +80,10 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if part.active %}
|
||||
{% if enable_buy or enable_sell %}
|
||||
<button type='button' class='btn btn-default' id='price-button' title='{% trans "Show pricing information" %}'>
|
||||
<span id='part-price-icon' class='fas fa-dollar-sign'/>
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if roles.stock.change and enable_stock %}
|
||||
{% if roles.stock.change %}
|
||||
<div class='btn-group'>
|
||||
<button id='stock-actions' title='{% trans "Stock actions" %}' class='btn btn-default dropdown-toggle' type='button' data-toggle='dropdown'>
|
||||
<span class='fas fa-boxes'></span> <span class='caret'></span>
|
||||
@ -112,13 +105,11 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if part.purchaseable and roles.purchase_order.add %}
|
||||
{% if enable_buy and enable_po %}
|
||||
<button type='button' class='btn btn-default' id='part-order' title='{% trans "Order part" %}'>
|
||||
<span id='part-order-icon' class='fas fa-shopping-cart'/>
|
||||
</button>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
<!-- Part actions -->
|
||||
{% if roles.part.add or roles.part.change or roles.part.delete %}
|
||||
<div class='btn-group'>
|
||||
|
Reference in New Issue
Block a user