diff --git a/InvenTree/templates/base.html b/InvenTree/templates/base.html index f7ee1b2f19..995cd6929d 100644 --- a/InvenTree/templates/base.html +++ b/InvenTree/templates/base.html @@ -2,6 +2,8 @@ {% load i18n %} {% load inventree_extras %} +{% settings_value 'BARCODE_ENABLE' as barcodes %} +
@@ -145,9 +147,11 @@ $(document).ready(function () { showCachedAlerts(); + {% if barcodes %} $('#barcode-scan').click(function() { barcodeScanDialog(); }); + {% endif %} }); diff --git a/InvenTree/templates/navbar.html b/InvenTree/templates/navbar.html index 9dafd5769e..6e3fe024ca 100644 --- a/InvenTree/templates/navbar.html +++ b/InvenTree/templates/navbar.html @@ -1,5 +1,9 @@ {% load static %} +{% load inventree_extras %} {% load i18n %} + +{% settings_value 'BARCODE_ENABLE' as barcodes %} + \ No newline at end of file +