mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Merge pull request #2145 from SchrodingersGat/revert-1fb76b9
Revert 1fb76b9
This commit is contained in:
commit
384d268534
@ -793,44 +793,6 @@ class InvenTreeSetting(BaseInvenTreeSetting):
|
||||
'default': 'PO',
|
||||
},
|
||||
|
||||
# enable/diable ui elements
|
||||
'BUILD_FUNCTION_ENABLE': {
|
||||
'name': _('Enable build'),
|
||||
'description': _('Enable build functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
'BUY_FUNCTION_ENABLE': {
|
||||
'name': _('Enable buy'),
|
||||
'description': _('Enable buy functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
'SELL_FUNCTION_ENABLE': {
|
||||
'name': _('Enable sell'),
|
||||
'description': _('Enable sell functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
'STOCK_FUNCTION_ENABLE': {
|
||||
'name': _('Enable stock'),
|
||||
'description': _('Enable stock functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
'SO_FUNCTION_ENABLE': {
|
||||
'name': _('Enable SO'),
|
||||
'description': _('Enable SO functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
'PO_FUNCTION_ENABLE': {
|
||||
'name': _('Enable PO'),
|
||||
'description': _('Enable PO functionality in InvenTree interface'),
|
||||
'default': True,
|
||||
'validator': bool,
|
||||
},
|
||||
|
||||
# login / SSO
|
||||
'LOGIN_ENABLE_PWD_FORGOT': {
|
||||
'name': _('Enable password forgot'),
|
||||
|
@ -2,10 +2,6 @@
|
||||
{% load static %}
|
||||
{% load inventree_extras %}
|
||||
|
||||
{% settings_value 'STOCK_FUNCTION_ENABLE' as enable_stock %}
|
||||
{% settings_value 'SO_FUNCTION_ENABLE' as enable_so %}
|
||||
{% settings_value 'PO_FUNCTION_ENABLE' as enable_po %}
|
||||
|
||||
<ul class='list-group'>
|
||||
<li class='list-group-item'>
|
||||
<a href='#' id='company-menu-toggle'>
|
||||
@ -32,7 +28,6 @@
|
||||
{% endif %}
|
||||
|
||||
{% if company.is_manufacturer or company.is_supplier %}
|
||||
{% if enable_stock %}
|
||||
<li class='list-group-item' title='{% trans "Stock Items" %}'>
|
||||
<a href='#' id='select-company-stock' class='nav-toggle'>
|
||||
<span class='fas fa-boxes sidebar-icon'></span>
|
||||
@ -40,9 +35,8 @@
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if company.is_supplier and enable_po %}
|
||||
{% if company.is_supplier %}
|
||||
<li class='list-group-item' title='{% trans "Purchase Orders" %}'>
|
||||
<a href='#' id='select-purchase-orders' class='nav-toggle'>
|
||||
<span class='fas fa-shopping-cart sidebar-icon'></span>
|
||||
@ -51,7 +45,7 @@
|
||||
</li>
|
||||
{% endif %}
|
||||
|
||||
{% if company.is_customer and enable_so %}
|
||||
{% if company.is_customer %}
|
||||
<li class='list-group-item' title='{% trans "Sales Orders" %}'>
|
||||
<a href='#' id='select-sales-orders' class='nav-toggle'>
|
||||
<span class='fas fa-truck sidebar-icon'></span>
|
||||
|
@ -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'>
|
||||
|
@ -13,8 +13,6 @@
|
||||
<table class='table table-striped table-condensed'>
|
||||
{% include "InvenTree/settings/header.html" %}
|
||||
<tbody>
|
||||
{% include "InvenTree/settings/setting.html" with key="BUILD_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
<tr><td colspan='5'></td></tr>
|
||||
{% include "InvenTree/settings/setting.html" with key="BUILDORDER_REFERENCE_PREFIX" %}
|
||||
{% include "InvenTree/settings/setting.html" with key="BUILDORDER_REFERENCE_REGEX" %}
|
||||
</tbody>
|
||||
|
@ -11,9 +11,6 @@
|
||||
<table class='table table-striped table-condensed'>
|
||||
{% include "InvenTree/settings/header.html" %}
|
||||
<tbody>
|
||||
{% include "InvenTree/settings/setting.html" with key="PO_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
{% include "InvenTree/settings/setting.html" with key="BUY_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
<tr><td colspan='5'></td></tr>
|
||||
{% include "InvenTree/settings/setting.html" with key="PURCHASEORDER_REFERENCE_PREFIX" %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
@ -12,9 +12,6 @@
|
||||
<table class='table table-striped table-condensed'>
|
||||
{% include "InvenTree/settings/header.html" %}
|
||||
<tbody>
|
||||
{% include "InvenTree/settings/setting.html" with key="SO_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
{% include "InvenTree/settings/setting.html" with key="SELL_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
<tr><td colspan='5'></td></tr>
|
||||
{% include "InvenTree/settings/setting.html" with key="SALESORDER_REFERENCE_PREFIX" %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
@ -12,8 +12,6 @@
|
||||
<table class='table table-striped table-condensed'>
|
||||
{% include "InvenTree/settings/header.html" %}
|
||||
<tbody>
|
||||
{% include "InvenTree/settings/setting.html" with key="STOCK_FUNCTION_ENABLE" icon="fa-check" %}
|
||||
<tr><td colspan='5'></td></tr>
|
||||
{% include "InvenTree/settings/setting.html" with key="STOCK_GROUP_BY_PART" icon="fa-layer-group" %}
|
||||
{% include "InvenTree/settings/setting.html" with key="STOCK_ENABLE_EXPIRY" icon="fa-stopwatch" %}
|
||||
{% include "InvenTree/settings/setting.html" with key="STOCK_STALE_DAYS" icon="fa-calendar" %}
|
||||
|
@ -3,12 +3,6 @@
|
||||
{% load i18n %}
|
||||
|
||||
{% settings_value 'BARCODE_ENABLE' as barcodes %}
|
||||
{% settings_value 'BUILD_FUNCTION_ENABLE' as enable_build %}
|
||||
{% settings_value 'BUY_FUNCTION_ENABLE' as enable_buy %}
|
||||
{% settings_value 'SELL_FUNCTION_ENABLE' as enable_sell %}
|
||||
{% settings_value 'STOCK_FUNCTION_ENABLE' as enable_stock %}
|
||||
{% settings_value 'SO_FUNCTION_ENABLE' as enable_so %}
|
||||
{% settings_value 'PO_FUNCTION_ENABLE' as enable_po %}
|
||||
|
||||
<nav class="navbar navbar-xs navbar-default navbar-fixed-top ">
|
||||
<div class="container-fluid">
|
||||
@ -28,32 +22,28 @@
|
||||
{% if roles.part.view %}
|
||||
<li><a href="{% url 'part-index' %}"><span class='fas fa-shapes icon-header'></span>{% trans "Parts" %}</a></li>
|
||||
{% endif %}
|
||||
{% if roles.stock.view and enable_stock %}
|
||||
{% if roles.stock.view %}
|
||||
<li><a href="{% url 'stock-index' %}"><span class='fas fa-boxes icon-header'></span>{% trans "Stock" %}</a></li>
|
||||
{% endif %}
|
||||
{% if roles.build.view and enable_build %}
|
||||
{% if roles.build.view %}
|
||||
<li><a href="{% url 'build-index' %}"><span class='fas fa-tools icon-header'></span>{% trans "Build" %}</a></li>
|
||||
{% endif %}
|
||||
{% if roles.purchase_order.view and enable_buy %}
|
||||
{% if roles.purchase_order.view %}
|
||||
<li class='nav navbar-nav'>
|
||||
<a class='dropdown-toggle' data-toggle='dropdown' href='#'><span class='fas fa-shopping-cart icon-header'></span>{% trans "Buy" %}</a>
|
||||
<ul class='dropdown-menu'>
|
||||
<li><a href="{% url 'supplier-index' %}"><span class='fas fa-building icon-header'></span>{% trans "Suppliers" %}</a></li>
|
||||
<li><a href="{% url 'manufacturer-index' %}"><span class='fas fa-industry icon-header'></span>{% trans "Manufacturers" %}</a></li>
|
||||
{% if enable_po %}
|
||||
<li><a href="{% url 'po-index' %}"><span class='fas fa-list icon-header'></span>{% trans "Purchase Orders" %}</a></li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if roles.sales_order.view and enable_sell %}
|
||||
{% if roles.sales_order.view %}
|
||||
<li class='nav navbar-nav'>
|
||||
<a class='dropdown-toggle' data-toggle='dropdown' href='#'><span class='fas fa-truck icon-header'></span>{% trans "Sell" %}</a>
|
||||
<ul class='dropdown-menu'>
|
||||
<li><a href="{% url 'customer-index' %}"><span class='fas fa-user-tie icon-header'></span>{% trans "Customers" %}</a>
|
||||
{% if enable_so %}
|
||||
<li><a href="{% url 'so-index' %}"><span class='fas fa-list icon-header'></span>{% trans "Sales Orders" %}</a></li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
</li>
|
||||
{% endif %}
|
||||
|
Loading…
Reference in New Issue
Block a user