Replace mklint with djlint (#4746)

* remove markuplint

* remove dedicated html step - will be done by pre-commit

* add djlint for django template linting

* Fix T003: Endblock should have name

* Fix H013: Img tag should have an alt attribute

* Fix H014: Found extra blank lines

* Fix T003: Endblock should have name

* Fix H013: Img tag should have an alt attribute

* small fixes

* Fix T001: Variables should be wrapped in a single whitespace

* Fix T003: Endblock should have name

* small fixes

* fix form method

* add entry to contributing

* fix template changes

* another fix

* use current version
This commit is contained in:
Matthias Mair 2023-05-02 12:03:52 +02:00 committed by GitHub
parent 09fabff551
commit 10c3d101e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
145 changed files with 510 additions and 2589 deletions

3
.djlintrc Normal file
View File

@ -0,0 +1,3 @@
{
"ignore": "D018,H006,H008,H020,H021,H023,H025,H030,H031,T002"
}

View File

@ -76,22 +76,6 @@ jobs:
python InvenTree/manage.py prerender python InvenTree/manage.py prerender
npx eslint InvenTree/InvenTree/static_i18n/i18n/*.js npx eslint InvenTree/InvenTree/static_i18n/i18n/*.js
html:
name: Style [HTML]
runs-on: ubuntu-20.04
needs: pep_style
steps:
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # pin@v3.1.0
- name: Enviroment Setup
uses: ./.github/actions/setup
with:
npm: true
install: true
- name: Check HTML Files
run: npx markuplint **/templates/*.html
pre-commit: pre-commit:
name: Style [pre-commit] name: Style [pre-commit]
runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
@ -194,7 +178,7 @@ jobs:
name: Tests - DB [SQLite] + Coverage name: Tests - DB [SQLite] + Coverage
runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
needs: [ 'javascript', 'html', 'pre-commit' ] needs: [ 'javascript', 'pre-commit' ]
continue-on-error: true # continue if a step fails so that coverage gets pushed continue-on-error: true # continue if a step fails so that coverage gets pushed
env: env:
@ -227,7 +211,7 @@ jobs:
postgres: postgres:
name: Tests - DB [PostgreSQL] name: Tests - DB [PostgreSQL]
runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
needs: [ 'javascript', 'html', 'pre-commit' ] needs: [ 'javascript', 'pre-commit' ]
env: env:
INVENTREE_DB_ENGINE: django.db.backends.postgresql INVENTREE_DB_ENGINE: django.db.backends.postgresql
@ -271,7 +255,7 @@ jobs:
name: Tests - DB [MySQL] name: Tests - DB [MySQL]
runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
needs: [ 'javascript', 'html', 'pre-commit' ] needs: [ 'javascript', 'pre-commit' ]
if: github.event_name == 'push' if: github.event_name == 'push'
env: env:

View File

@ -1,9 +0,0 @@
{
"overrides": {
"**/templates/*.html": {
"rules": {
"[[character-reference]]": false
}
}
}
}

View File

@ -40,3 +40,7 @@ repos:
name: pip-compile requirements.txt name: pip-compile requirements.txt
args: [requirements.in, -o, requirements.txt] args: [requirements.in, -o, requirements.txt]
files: ^requirements\.(in|txt)$ files: ^requirements\.(in|txt)$
- repo: https://github.com/Riverside-Healthcare/djLint
rev: v1.25.0
hooks:
- id: djlint-django

View File

@ -128,6 +128,24 @@ The various github actions can be found in the `./github/workflows` directory
Sumbitted Python code is automatically checked against PEP style guidelines. Locally you can run `invoke style` to ensure the style checks will pass, before submitting the PR. Sumbitted Python code is automatically checked against PEP style guidelines. Locally you can run `invoke style` to ensure the style checks will pass, before submitting the PR.
Please write docstrings for each function and class - we follow the [google doc-style](https://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings) for python. Docstrings for general javascript code is encouraged! Docstyles are checked by `invoke style`. Please write docstrings for each function and class - we follow the [google doc-style](https://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings) for python. Docstrings for general javascript code is encouraged! Docstyles are checked by `invoke style`.
### Django templates
Django are checked by [djlint](https://github.com/Riverside-Healthcare/djlint) through pre-commit.
The following rules out of the [default set](https://djlint.com/docs/linter/) are not applied:
```bash
D018: (Django) Internal links should use the {% url ... %} pattern
H006: Img tag should have height and width attributes
H008: Attributes should be double quoted
H021: Inline styles should be avoided
H023: Do not use entity references
H025: Tag seems to be an orphan
H030: Consider adding a meta description
H031: Consider adding meta keywords
T002: Double quotes should be used in tags
```
## Documentation ## Documentation
New features or updates to existing features should be accompanied by user documentation. New features or updates to existing features should be accompanied by user documentation.

View File

@ -7,7 +7,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Build Order" %} - {{ build }} {% inventree_title %} | {% trans "Build Order" %} - {{ build }}
{% endblock %} {% endblock page_title %}
{% block breadcrumbs %} {% block breadcrumbs %}
<li class='breadcrumb-item'><a href='{% url "build-index" %}'>{% trans "Build Orders" %}</a></li> <li class='breadcrumb-item'><a href='{% url "build-index" %}'>{% trans "Build Orders" %}</a></li>
@ -25,7 +25,7 @@ src="{% static 'img/blank_image.png' %}"
{% block heading %} {% block heading %}
{% trans "Build Order" %} {{ build }} {% trans "Build Order" %} {{ build }}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<!-- Admin Display --> <!-- Admin Display -->
@ -147,7 +147,7 @@ src="{% static 'img/blank_image.png' %}"
{% endif %} {% endif %}
{% endif %} {% endif %}
</div> </div>
{% endblock %} {% endblock details %}
{% block details_right %} {% block details_right %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -219,7 +219,7 @@ src="{% static 'img/blank_image.png' %}"
</tr> </tr>
{% endif %} {% endif %}
</table> </table>
{% endblock %} {% endblock details_right %}
{% block page_data %} {% block page_data %}
<h3> <h3>
@ -231,8 +231,7 @@ src="{% static 'img/blank_image.png' %}"
<hr> <hr>
<p>{{ build.title }}</p> <p>{{ build.title }}</p>
{% endblock page_data %}
{% endblock %}
{% block js_ready %} {% block js_ready %}
@ -312,4 +311,4 @@ src="{% static 'img/blank_image.png' %}"
{% endif %} {% endif %}
{% endif %} {% endif %}
{% endblock %} {% endblock js_ready %}

View File

@ -6,7 +6,7 @@
{% block sidebar %} {% block sidebar %}
{% include "build/sidebar.html" %} {% include "build/sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block page_content %} {% block page_content %}
@ -319,8 +319,7 @@
</div> </div>
</div> </div>
{% endblock page_content %}
{% endblock %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -519,4 +518,4 @@ $('#allocate-selected-items').click(function() {
enableSidebar('buildorder'); enableSidebar('buildorder');
{% endblock %} {% endblock js_ready %}

View File

@ -6,11 +6,11 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Build Orders" %} {% inventree_title %} | {% trans "Build Orders" %}
{% endblock %} {% endblock page_title %}
{% block heading %} {% block heading %}
{% trans "Build Orders" %} {% trans "Build Orders" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if roles.build.add %} {% if roles.build.add %}
@ -18,7 +18,7 @@
<span class='fas fa-tools'></span> {% trans "New Build Order" %} <span class='fas fa-tools'></span> {% trans "New Build Order" %}
</button> </button>
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block page_info %} {% block page_info %}
@ -35,7 +35,7 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock page_info %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -48,4 +48,4 @@ loadBuildTable($("#build-table"), {
locale: '{{ request.LANGUAGE_CODE }}', locale: '{{ request.LANGUAGE_CODE }}',
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -6,11 +6,11 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Company" %} - {{ company.name }} {% inventree_title %} | {% trans "Company" %} - {{ company.name }}
{% endblock %} {% endblock page_title %}
{% block heading %} {% block heading %}
{% trans "Company" %}: {{ company.name }} {% trans "Company" %}: {{ company.name }}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<!-- Admin View --> <!-- Admin View -->
@ -45,7 +45,7 @@
{% block thumbnail %} {% block thumbnail %}
<div class='dropzone part-thumb-container' id='company-thumb'> <div class='dropzone part-thumb-container' id='company-thumb'>
<img class="part-thumb" id='company-image' <img class="part-thumb" id='company-image' alt="{% trans 'Part image' %}"
{% if company.image %} {% if company.image %}
src="{{ company.image.preview.url }}" src="{{ company.image.preview.url }}"
{% else %} {% else %}
@ -62,7 +62,7 @@
</div> </div>
</div> </div>
</div> </div>
{% endblock %} {% endblock thumbnail %}
{% block details %} {% block details %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -89,7 +89,7 @@
</tr> </tr>
</table> </table>
{% endblock %} {% endblock details %}
{% block details_right %} {% block details_right %}
@ -142,7 +142,7 @@
</tr> </tr>
{% endif %} {% endif %}
</table> </table>
{% endblock %} {% endblock details_right %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -262,4 +262,4 @@
}); });
} }
{% endblock %} {% endblock js_ready %}

View File

@ -5,7 +5,7 @@
{% block sidebar %} {% block sidebar %}
{% include 'company/sidebar.html' %} {% include 'company/sidebar.html' %}
{% endblock %} {% endblock sidebar %}
{% block page_content %} {% block page_content %}
@ -270,7 +270,7 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -542,4 +542,4 @@
enableSidebar('company'); enableSidebar('company');
{% endblock %} {% endblock js_ready %}

View File

@ -6,11 +6,11 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Supplier List" %} {% inventree_title %} | {% trans "Supplier List" %}
{% endblock %} {% endblock page_title %}
{% block heading %} {% block heading %}
{{ title }} {{ title }}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if pagetype == 'manufacturers' and roles.purchase_order.add or pagetype == 'suppliers' and roles.purchase_order.add or pagetype == 'customers' and roles.sales_order.add %} {% if pagetype == 'manufacturers' and roles.purchase_order.add or pagetype == 'suppliers' and roles.purchase_order.add or pagetype == 'customers' and roles.sales_order.add %}
@ -18,7 +18,7 @@
<span class='fas fa-plus-circle'></span> {{ button_text }} <span class='fas fa-plus-circle'></span> {{ button_text }}
</button> </button>
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block page_info %} {% block page_info %}
@ -32,7 +32,7 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock page_info %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -59,4 +59,4 @@
} }
); );
{% endblock %} {% endblock js_ready %}

View File

@ -5,7 +5,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Manufacturer Part" %} {% inventree_title %} | {% trans "Manufacturer Part" %}
{% endblock %} {% endblock page_title %}
{% block sidebar %} {% block sidebar %}
{% include "company/manufacturer_part_sidebar.html" %} {% include "company/manufacturer_part_sidebar.html" %}
@ -48,7 +48,7 @@
{% endblock actions %} {% endblock actions %}
{% block thumbnail %} {% block thumbnail %}
<img class='part-thumb' <img class='part-thumb' alt="{% trans 'Part image' %}"
{% if part.part.image %} {% if part.part.image %}
src='{{ part.part.image.preview.url }}' src='{{ part.part.image.preview.url }}'
{% else %} {% else %}
@ -191,8 +191,7 @@ src="{% static 'img/blank_image.png' %}"
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -338,4 +337,4 @@ $('#delete-part').click(function() {
enableSidebar('manufacturerpart'); enableSidebar('manufacturerpart');
{% endblock %} {% endblock js_ready %}

View File

@ -81,13 +81,13 @@
{% endblock actions %} {% endblock actions %}
{% block thumbnail %} {% block thumbnail %}
<img class='part-thumb' <img class='part-thumb' alt="{% trans 'Part image' %}"
{% if part.part.image %} {% if part.part.image %}
src='{{ part.part.image.preview.url }}' src='{{ part.part.image.preview.url }}'
{% else %} {% else %}
src="{% static 'img/blank_image.png' %}" src="{% static 'img/blank_image.png' %}"
{% endif %}/> {% endif %}/>
{% endblock %} {% endblock thumbnail %}
{% block details %} {% block details %}
@ -184,7 +184,7 @@ src="{% static 'img/blank_image.png' %}"
</tr> </tr>
{% endif %} {% endif %}
</table> </table>
{% endblock %} {% endblock details_right %}
{% block page_content %} {% block page_content %}
@ -256,7 +256,7 @@ src="{% static 'img/blank_image.png' %}"
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -397,4 +397,4 @@ $('#delete-part').click(function() {
enableSidebar('supplierpart'); enableSidebar('supplierpart');
{% endblock %} {% endblock js_ready %}

View File

@ -10,7 +10,7 @@
{% endlocalize %} {% endlocalize %}
{% block margin %} {% block margin %}
margin: 0mm; margin: 0mm;
{% endblock %} {% endblock margin %}
} }
body { body {
@ -35,7 +35,7 @@
{% block style %} {% block style %}
/* User-defined styles can go here */ /* User-defined styles can go here */
{% endblock %} {% endblock style %}
</style> </style>
</head> </head>
@ -44,6 +44,6 @@
<div class='content'> <div class='content'>
{% block content %} {% block content %}
<!-- Label data rendered here! --> <!-- Label data rendered here! -->
{% endblock %} {% endblock content %}
</div> </div>
</body> </body>

View File

@ -1,7 +1,6 @@
{% extends "label/label_base.html" %} {% extends "label/label_base.html" %}
{% load l10n %} {% load l10n i18n barcode %}
{% load barcode %}
{% block style %} {% block style %}
@ -25,14 +24,14 @@
top: 2mm; top: 2mm;
} }
{% endblock %} {% endblock style %}
{% block content %} {% block content %}
<img class='qr' src='{% qrcode qr_data %}'> <img class='qr' alt="{% trans 'QC Code' %}" src='{% qrcode qr_data %}'>
<div class='part'> <div class='part'>
{{ part.full_name }} {{ part.full_name }}
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -1,7 +1,6 @@
{% extends "label/label_base.html" %} {% extends "label/label_base.html" %}
{% load l10n %} {% load l10n i18n barcode %}
{% load barcode %}
{% block style %} {% block style %}
@ -25,14 +24,14 @@
top: 2mm; top: 2mm;
} }
{% endblock %} {% endblock style %}
{% block content %} {% block content %}
<img class='qr' src='{% barcode qr_data %}'> <img class='qr' alt='{% trans "QR code" %}' src='{% barcode qr_data %}'>
<div class='part'> <div class='part'>
{{ part.full_name }} {{ part.full_name }}
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -1,7 +1,6 @@
{% extends "label/label_base.html" %} {% extends "label/label_base.html" %}
{% load l10n %} {% load l10n i18n barcode %}
{% load barcode %}
{% block style %} {% block style %}
@ -15,9 +14,9 @@
{% endlocalize %} {% endlocalize %}
} }
{% endblock %} {% endblock style %}
{% block content %} {% block content %}
<img class='qr' src='{% qrcode qr_data %}'> <img class='qr' alt="{% trans 'QC Code' %}" src='{% qrcode qr_data %}'>
{% endblock %} {% endblock content %}

View File

@ -1,7 +1,6 @@
{% extends "label/label_base.html" %} {% extends "label/label_base.html" %}
{% load l10n %} {% load l10n i18n barcode %}
{% load barcode %}
{% block style %} {% block style %}
@ -15,9 +14,9 @@
{% endlocalize %} {% endlocalize %}
} }
{% endblock %} {% endblock style %}
{% block content %} {% block content %}
<img class='qr' src='{% qrcode qr_data %}'> <img class='qr' alt="{% trans 'QC Code' %}" src='{% qrcode qr_data %}'>
{% endblock %} {% endblock content %}

View File

@ -1,7 +1,6 @@
{% extends "label/label_base.html" %} {% extends "label/label_base.html" %}
{% load l10n %} {% load l10n i18n barcode %}
{% load barcode %}
{% block style %} {% block style %}
@ -25,14 +24,14 @@
top: 2mm; top: 2mm;
} }
{% endblock %} {% endblock style %}
{% block content %} {% block content %}
<img class='qr' src='{% qrcode qr_data %}'> <img class='qr' alt="{% trans 'QR code' %}" src='{% qrcode qr_data %}'>
<div class='loc'> <div class='loc'>
{{ location.name }} {{ location.name }}
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -96,4 +96,4 @@ $('.fieldselect').select2({
matcher: partialMatcher, matcher: partialMatcher,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -44,7 +44,7 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
<tr></tr> {% comment %} Dummy row for javascript del_row method {% endcomment %} <tr>{% comment %} Dummy row for javascript del_row method {% endcomment %}</tr>
{% for row in rows %} {% for row in rows %}
<tr {% if row.errors %} style='background: #ffeaea;'{% endif %} part-select='#select_part_{{ row.index }}'> <tr {% if row.errors %} style='background: #ffeaea;'{% endif %} part-select='#select_part_{{ row.index }}'>
<td> <td>
@ -123,4 +123,4 @@ $('.currencyselect').select2({
dropdownAutoWidth: true, dropdownAutoWidth: true,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -7,7 +7,7 @@
{% url "po-detail" order.id as url %} {% url "po-detail" order.id as url %}
{% trans "Return to Orders" as text %} {% trans "Return to Orders" as text %}
{% include "sidebar_item.html" with url=url text=text icon="fa-undo" %} {% include "sidebar_item.html" with url=url text=text icon="fa-undo" %}
{% endblock %} {% endblock sidebar %}
{% block page_content %} {% block page_content %}
{% trans "Upload File for Purchase Order" as header_text %} {% trans "Upload File for Purchase Order" as header_text %}
@ -60,9 +60,9 @@
</div> </div>
</div> </div>
{% endwith %} {% endwith %}
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock js_ready %}

View File

@ -5,7 +5,6 @@
{% load i18n %} {% load i18n %}
{% load static %} {% load static %}
{% block sidebar %} {% block sidebar %}
{% include 'order/po_sidebar.html' %} {% include 'order/po_sidebar.html' %}
{% endblock sidebar %} {% endblock sidebar %}
@ -264,4 +263,4 @@ loadOrderTotal(
enableSidebar('purchaseorder'); enableSidebar('purchaseorder');
{% endblock %} {% endblock js_ready %}

View File

@ -6,11 +6,11 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Purchase Orders" %} {% inventree_title %} | {% trans "Purchase Orders" %}
{% endblock %} {% endblock page_title %}
{% block heading %} {% block heading %}
{% trans "Purchase Orders" %} {% trans "Purchase Orders" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if roles.purchase_order.add %} {% if roles.purchase_order.add %}
@ -18,7 +18,7 @@
<span class='fas fa-plus-circle'></span> {% trans "New Purchase Order" %} <span class='fas fa-plus-circle'></span> {% trans "New Purchase Order" %}
</button> </button>
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block page_info %} {% block page_info %}
@ -38,12 +38,12 @@
</div> </div>
{% endblock %} {% endblock page_info %}
{% block js_load %} {% block js_load %}
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock js_load %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -56,4 +56,4 @@ loadPurchaseOrderTable("#purchase-order-table", {
url: "{% url 'api-po-list' %}", url: "{% url 'api-po-list' %}",
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -6,15 +6,14 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Return Orders" %} {% inventree_title %} | {% trans "Return Orders" %}
{% endblock %} {% endblock page_title %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block heading %} {% block heading %}
{% trans "Return Orders" %} {% trans "Return Orders" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if roles.return_order.add %} {% if roles.return_order.add %}

View File

@ -7,12 +7,12 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Sales Order" %} {% inventree_title %} | {% trans "Sales Order" %}
{% endblock %} {% endblock page_title %}
{% block breadcrumbs %} {% block breadcrumbs %}
<li class='breadcrumb-item'><a href='{% url "sales-order-index" %}'>{% trans "Sales Orders" %}</a></li> <li class='breadcrumb-item'><a href='{% url "sales-order-index" %}'>{% trans "Sales Orders" %}</a></li>
<li class="breadcrumb-item active" aria-current="page"><a href='{% url "so-detail" order.id %}'>{{ order }}</a></li> <li class="breadcrumb-item active" aria-current="page"><a href='{% url "so-detail" order.id %}'>{{ order }}</a></li>
{% endblock %} {% endblock breadcrumbs %}
{% block thumbnail %} {% block thumbnail %}
<img class='part-thumb' <img class='part-thumb'
@ -22,11 +22,11 @@ src="{{ order.customer.image.url }}"
src="{% static 'img/blank_image.png' %}" src="{% static 'img/blank_image.png' %}"
{% endif %} {% endif %}
/> />
{% endblock %} {% endblock thumbnail %}
{% block heading %} {% block heading %}
{% trans "Sales Order" %} {{ order.reference }} {% trans "Sales Order" %} {{ order.reference }}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if user.is_staff and roles.sales_order.change %} {% if user.is_staff and roles.sales_order.change %}
@ -134,7 +134,7 @@ src="{% static 'img/blank_image.png' %}"
{% endif %} {% endif %}
</div> </div>
{% endblock %} {% endblock details %}
{% block details_right %} {% block details_right %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -238,7 +238,7 @@ src="{% static 'img/blank_image.png' %}"
</td> </td>
</tr> </tr>
</table> </table>
{% endblock %} {% endblock details_right %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -332,4 +332,4 @@ $('#export-order').click(function() {
exportOrder('{% url "so-export" order.id %}'); exportOrder('{% url "so-export" order.id %}');
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -7,7 +7,7 @@
{% block sidebar %} {% block sidebar %}
{% include "order/so_sidebar.html" %} {% include "order/so_sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block page_content %} {% block page_content %}
{% settings_value "SALESORDER_EDIT_COMPLETED_ORDERS" as allow_extra_editing %} {% settings_value "SALESORDER_EDIT_COMPLETED_ORDERS" as allow_extra_editing %}
@ -158,7 +158,7 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -297,7 +297,6 @@
}); });
}); });
loadOrderTotal( loadOrderTotal(
'#soTotalPrice', '#soTotalPrice',
{ {
@ -307,4 +306,4 @@
enableSidebar('salesorder'); enableSidebar('salesorder');
{% endblock %} {% endblock js_ready %}

View File

@ -6,14 +6,14 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Sales Orders" %} {% inventree_title %} | {% trans "Sales Orders" %}
{% endblock %} {% endblock page_title %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block heading %} {% block heading %}
{% trans "Sales Orders" %} {% trans "Sales Orders" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if roles.sales_order.add %} {% if roles.sales_order.add %}
@ -21,7 +21,7 @@
<span class='fas fa-plus-circle'></span> {% trans "New Sales Order" %} <span class='fas fa-plus-circle'></span> {% trans "New Sales Order" %}
</button> </button>
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block page_info %} {% block page_info %}
@ -40,7 +40,7 @@
<div id='sales-order-calendar'></div> <div id='sales-order-calendar'></div>
</div> </div>
{% endblock %} {% endblock page_info %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -53,4 +53,4 @@ $("#so-create").click(function() {
createSalesOrder(); createSalesOrder();
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -5,7 +5,7 @@
{% block sidebar %} {% block sidebar %}
{% include 'part/category_sidebar.html' %} {% include 'part/category_sidebar.html' %}
{% endblock %} {% endblock sidebar %}
{% block breadcrumb_tree %} {% block breadcrumb_tree %}
<div id="breadcrumb-tree"></div> <div id="breadcrumb-tree"></div>
@ -22,7 +22,7 @@
{% else %} {% else %}
{% trans "Parts" %} {% trans "Parts" %}
{% endif %} {% endif %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% if category and user.is_staff and roles.part_category.change %} {% if category and user.is_staff and roles.part_category.change %}
@ -69,7 +69,7 @@
</div> </div>
{% endif %} {% endif %}
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block details_left %} {% block details_left %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -245,11 +245,11 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_load %} {% block js_load %}
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock js_load %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -352,7 +352,6 @@
editCategory({{ category.pk }}); editCategory({{ category.pk }});
}); });
$('#cat-delete').click(function() { $('#cat-delete').click(function() {
deletePartCategory({{ category.pk }}, { deletePartCategory({{ category.pk }}, {
{% if category.parent %} {% if category.parent %}
@ -384,4 +383,4 @@
// Enable left-hand navigation sidebar // Enable left-hand navigation sidebar
enableSidebar('category'); enableSidebar('category');
{% endblock %} {% endblock js_ready %}

View File

@ -22,4 +22,4 @@
</ul> </ul>
{% endif %} {% endif %}
{% endblock %} {% endblock pre_form_content %}

View File

@ -21,4 +21,4 @@
</div> </div>
{% endif %} {% endif %}
{% endblock %} {% endblock pre_form_content %}

View File

@ -6,7 +6,7 @@
{% block sidebar %} {% block sidebar %}
{% include 'part/part_sidebar.html' %} {% include 'part/part_sidebar.html' %}
{% endblock %} {% endblock sidebar %}
{% block breadcrumb_tree %} {% block breadcrumb_tree %}
<div id="breadcrumb-tree"></div> <div id="breadcrumb-tree"></div>
@ -431,11 +431,11 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_load %} {% block js_load %}
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock js_load %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -757,7 +757,6 @@
}); });
}); });
$("#part-order2").click(function() { $("#part-order2").click(function() {
inventreeGet( inventreeGet(
'{% url "api-part-detail" part.pk %}', '{% url "api-part-detail" part.pk %}',
@ -926,4 +925,4 @@
} }
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -86,4 +86,4 @@ $('.fieldselect').select2({
matcher: partialMatcher, matcher: partialMatcher,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -81,4 +81,4 @@ $('.currencyselect').select2({
dropdownAutoWidth: true, dropdownAutoWidth: true,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -30,4 +30,4 @@
</div> </div>
{% endif %} {% endif %}
</div> </div>
{% endblock %} {% endblock form %}

View File

@ -96,4 +96,4 @@ $('.fieldselect').select2({
matcher: partialMatcher, matcher: partialMatcher,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -88,4 +88,4 @@ $('.currencyselect').select2({
dropdownAutoWidth: true, dropdownAutoWidth: true,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -7,7 +7,7 @@
{% url 'part-index' as url %} {% url 'part-index' as url %}
{% trans "Return to Parts" as text %} {% trans "Return to Parts" as text %}
{% include "sidebar_link.html" with url=url text=text icon="fa-undo" %} {% include "sidebar_link.html" with url=url text=text icon="fa-undo" %}
{% endblock %} {% endblock sidebar %}
{% block content %} {% block content %}
{% trans "Import Parts from File" as header_text %} {% trans "Import Parts from File" as header_text %}
@ -66,7 +66,7 @@
{% endif %} {% endif %}
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -113,4 +113,4 @@ function downloadPartImportTemplate(options={}) {
}); });
} }
{% endblock %} {% endblock js_ready %}

View File

@ -11,7 +11,7 @@
{% else %} {% else %}
{% inventree_title %} | {% trans "Part List" %} {% inventree_title %} | {% trans "Part List" %}
{% endif %} {% endif %}
{% endblock %} {% endblock page_title %}
{% block breadcrumbs %} {% block breadcrumbs %}
<a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a> <a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a>

View File

@ -6,15 +6,15 @@
{% block sidebar %} {% block sidebar %}
{% include "part/part_sidebar.html" %} {% include "part/part_sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block thumbnail %} {% block thumbnail %}
{% include "part/part_thumb.html" %} {% include "part/part_thumb.html" %}
{% endblock %} {% endblock thumbnail %}
{% block heading %} {% block heading %}
{{ part.full_name }} {{ part.full_name }}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<!-- Admin View --> <!-- Admin View -->
@ -104,7 +104,7 @@
</ul> </ul>
</div> </div>
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block details %} {% block details %}
@ -567,7 +567,6 @@
) )
}); });
function onSelectImage(response) { function onSelectImage(response) {
// Callback when the image-selection modal form is displayed // Callback when the image-selection modal form is displayed
// Populate the form with image data (requested via AJAX) // Populate the form with image data (requested via AJAX)
@ -591,7 +590,7 @@
title: 'Image', title: 'Image',
searchable: true, searchable: true,
formatter: function(value, row, index, field) { formatter: function(value, row, index, field) {
return "<img src='/media/" + value + "' class='grid-image'/>" return "<img src='/media/" + value + "' alt='image' class='grid-image'/>"
} }
} }
], ],
@ -694,4 +693,4 @@
findStockItemBySerialNumber({{ part.pk }}); findStockItemBySerialNumber({{ part.pk }});
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -124,4 +124,4 @@
</div> </div>
{% endif %} {% endif %}
<hr> <hr>
{% endblock %} {% endblock pre_form_content %}

View File

@ -17,7 +17,7 @@
</div> </div>
</div> </div>
{% endif %} {% endif %}
<img class="part-thumb" id='part-image' <img class="part-thumb" id='part-image' alt="{% trans 'Part image' %}"
{% if part.image %} {% if part.image %}
src="{{ part.image.preview.url }}" src="{{ part.image.preview.url }}"
{% else %} {% else %}

View File

@ -233,7 +233,6 @@
</div> </div>
{% endif %} {% endif %}
{% if part.assembly and part.has_bom %} {% if part.assembly and part.has_bom %}
<a class="anchor" id="bom-cost"></a> <a class="anchor" id="bom-cost"></a>
<div class='panel-heading'> <div class='panel-heading'>

View File

@ -4,8 +4,7 @@
{{ block.super }} {{ block.super }}
{% endblock pre_form_content %}
{% endblock %}
{% block form %} {% block form %}
<form method='post' action='' class='js-modal-form' enctype='multipart/form-data'> <form method='post' action='' class='js-modal-form' enctype='multipart/form-data'>
@ -18,4 +17,4 @@
</table> </table>
</form> </form>
{% endblock %} {% endblock form %}

View File

@ -7,11 +7,11 @@
{% url "part-detail" part.id as url %} {% url "part-detail" part.id as url %}
{% trans "Return to BOM" as text %} {% trans "Return to BOM" as text %}
{% include "sidebar_link.html" with url=url text=text icon="fa-undo" %} {% include "sidebar_link.html" with url=url text=text icon="fa-undo" %}
{% endblock %} {% endblock sidebar %}
{% block heading %} {% block heading %}
{% trans "Upload Bill of Materials" %} {% trans "Upload Bill of Materials" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<!-- <!--
@ -28,7 +28,7 @@
<button type='button' class='btn btn-success' id='bom-submit' style='display: none;'> <button type='button' class='btn btn-success' id='bom-submit' style='display: none;'>
<span class='fas fa-sign-in-alt' id='bom-submit-icon'></span> {% trans "Submit BOM Data" %} <span class='fas fa-sign-in-alt' id='bom-submit-icon'></span> {% trans "Submit BOM Data" %}
</button> </button>
{% endblock %} {% endblock actions %}
{% block page_info %} {% block page_info %}
<div class='panel-content'> <div class='panel-content'>

View File

@ -10,4 +10,4 @@
{% trans "Create a new variant part from this template" %} {% trans "Create a new variant part from this template" %}
</div> </div>
{% endblock %} {% endblock pre_form_content %}

View File

@ -8,15 +8,15 @@
{% block page_margin %} {% block page_margin %}
margin: 2cm; margin: 2cm;
margin-top: 4cm; margin-top: 4cm;
{% endblock %} {% endblock page_margin %}
{% block bottom_left %} {% block bottom_left %}
content: "v{{ report_revision }} - {{ date.isoformat }}"; content: "v{{ report_revision }} - {{ date.isoformat }}";
{% endblock %} {% endblock bottom_left %}
{% block bottom_center %} {% block bottom_center %}
content: "{% inventree_version shortstring=True %}"; content: "{% inventree_version shortstring=True %}";
{% endblock %} {% endblock bottom_center %}
{% block style %} {% block style %}
@ -90,7 +90,7 @@ table td.expand {
display: inline; display: inline;
} }
{% endblock %} {% endblock style %}
{% block header_content %} {% block header_content %}
@ -100,7 +100,7 @@ table td.expand {
<h3>{% trans "Bill of Materials" %}</h3> <h3>{% trans "Bill of Materials" %}</h3>
</div> </div>
{% endblock %} {% endblock header_content %}
{% block page_content %} {% block page_content %}
@ -123,7 +123,7 @@ table td.expand {
</td> </td>
<td> <td>
<div class='part-logo'> <div class='part-logo'>
<img src='{% part_image part %}' class='part-logo'> <img src='{% part_image part %}' alt='{% trans "Image" %}' class='part-logo'>
</div> </div>
</td> </td>
</tr> </tr>
@ -145,7 +145,7 @@ table td.expand {
<tr> <tr>
<td> <td>
<div class='thumb-container'> <div class='thumb-container'>
<img src='{% part_image line.sub_part %}' class='part-thumb'> <img src='{% part_image line.sub_part %}' alt='{% trans "Image" %}' class='part-thumb'>
</div> </div>
<div class='part-text'> <div class='part-text'>
{{ line.sub_part.full_name }} {{ line.sub_part.full_name }}
@ -159,4 +159,4 @@ table td.expand {
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock page_content %}

View File

@ -9,7 +9,7 @@
{% block page_margin %} {% block page_margin %}
margin: 2cm; margin: 2cm;
margin-top: 4cm; margin-top: 4cm;
{% endblock %} {% endblock page_margin %}
{% block style %} {% block style %}
@ -71,11 +71,11 @@ margin-top: 4cm;
border-bottom: 1px solid #555; border-bottom: 1px solid #555;
} }
{% endblock %} {% endblock style %}
{% block bottom_left %} {% block bottom_left %}
content: "v{{ report_revision }} - {{ date.isoformat }}"; content: "v{{ report_revision }} - {{ date.isoformat }}";
{% endblock %} {% endblock bottom_left %}
{% block header_content %} {% block header_content %}
<img class='logo' src="{% logo_image %}" alt="logo" width="150"> <img class='logo' src="{% logo_image %}" alt="logo" width="150">
@ -89,13 +89,13 @@ content: "v{{report_revision}} - {{ date.isoformat }}";
</div> </div>
<hr> <hr>
{% endblock %} {% endblock header_content %}
{% block page_content %} {% block page_content %}
<div class='details'> <div class='details'>
<div class='details-image'> <div class='details-image'>
<img class='part-image' src="{% part_image part %}"> <img class='part-image' alt="{% trans 'Part image' %}" src="{% part_image part %}">
</div> </div>
<div class='details-container'> <div class='details-container'>
@ -175,4 +175,4 @@ content: "v{{report_revision}} - {{ date.isoformat }}";
{{ build.notes|markdownify }} {{ build.notes|markdownify }}
{% endif %} {% endif %}
{% endblock %} {% endblock page_content %}

View File

@ -9,15 +9,15 @@
{% block page_margin %} {% block page_margin %}
margin: 2cm; margin: 2cm;
margin-top: 4cm; margin-top: 4cm;
{% endblock %} {% endblock page_margin %}
{% block bottom_left %} {% block bottom_left %}
content: "v{{ report_revision }} - {{ date.isoformat }}"; content: "v{{ report_revision }} - {{ date.isoformat }}";
{% endblock %} {% endblock bottom_left %}
{% block bottom_center %} {% block bottom_center %}
content: "{% inventree_version shortstring=True %}"; content: "{% inventree_version shortstring=True %}";
{% endblock %} {% endblock bottom_center %}
{% block style %} {% block style %}
@ -36,7 +36,6 @@ content: "{% inventree_version shortstring=True %}";
display: inline; display: inline;
} }
.part-thumb { .part-thumb {
max-width: 32px; max-width: 32px;
max-height: 32px; max-height: 32px;
@ -67,4 +66,4 @@ table td.expand {
width: 99% width: 99%
} }
{% endblock %} {% endblock style %}

View File

@ -15,7 +15,7 @@
{% if supplier %}{{ supplier.name }}{% else %}{% trans "Supplier was deleted" %}{% endif %} {% if supplier %}{{ supplier.name }}{% else %}{% trans "Supplier was deleted" %}{% endif %}
</div> </div>
{% endblock %} {% endblock header_content %}
{% block page_content %} {% block page_content %}
@ -37,7 +37,7 @@
<tr> <tr>
<td> <td>
<div class='thumb-container'> <div class='thumb-container'>
<img src='{% part_image line.part.part %}' class='part-thumb'> <img src='{% part_image line.part.part %}' class='part-thumb' alt="{% trans 'Part image' %}">
</div> </div>
<div class='part-text'> <div class='part-text'>
{{ line.part.part.full_name }} {{ line.part.part.full_name }}
@ -77,5 +77,4 @@
</tbody> </tbody>
</table> </table>
{% endblock page_content %}
{% endblock %}

View File

@ -91,17 +91,17 @@
<div class='header'> <div class='header'>
{% block header_content %} {% block header_content %}
{% endblock %} {% endblock header_content %}
</div> </div>
<div class='content'> <div class='content'>
{% block page_content %} {% block page_content %}
{% endblock %} {% endblock page_content %}
</div> </div>
<div class='footer'> <div class='footer'>
{% block footer_content %} {% block footer_content %}
{% endblock %} {% endblock footer_content %}
</div> </div>
</body> </body>

View File

@ -32,7 +32,7 @@
<tr> <tr>
<td> <td>
<div class='thumb-container'> <div class='thumb-container'>
<img src='{% part_image line.item.part %}' class='part-thumb'> <img src='{% part_image line.item.part %}' alt='{% trans "Image" %}' class='part-thumb'>
</div> </div>
<div class='part-text'> <div class='part-text'>
{{ line.item.part.full_name }} {{ line.item.part.full_name }}

View File

@ -15,7 +15,7 @@
{{ customer.name }} {{ customer.name }}
</div> </div>
{% endblock %} {% endblock header_content %}
{% block page_content %} {% block page_content %}
@ -37,7 +37,7 @@
<tr> <tr>
<td> <td>
<div class='thumb-container'> <div class='thumb-container'>
<img src='{% part_image line.part %}' class='part-thumb'> <img src='{% part_image line.part %}' alt='{% trans "Part image" %}' class='part-thumb'>
</div> </div>
<div class='part-text'> <div class='part-text'>
{{ line.part.full_name }} {{ line.part.full_name }}
@ -76,5 +76,4 @@
</tbody> </tbody>
</table> </table>
{% endblock page_content %}
{% endblock %}

View File

@ -11,15 +11,15 @@
{% block bottom_left %} {% block bottom_left %}
content: "{{ date.isoformat }}"; content: "{{ date.isoformat }}";
{% endblock %} {% endblock bottom_left %}
{% block bottom_center %} {% block bottom_center %}
content: "{% inventree_version shortstring=True %}"; content: "{% inventree_version shortstring=True %}";
{% endblock %} {% endblock bottom_center %}
{% block top_center %} {% block top_center %}
content: "{% trans 'Stock Item Test Report' %}"; content: "{% trans 'Stock Item Test Report' %}";
{% endblock %} {% endblock top_center %}
.test-row { .test-row {
padding: 3px; padding: 3px;
@ -63,11 +63,11 @@ content: "{% trans 'Stock Item Test Report' %}";
height: 4cm; height: 4cm;
} }
{% endblock %} {% endblock style %}
{% block pre_page_content %} {% block pre_page_content %}
{% endblock %} {% endblock pre_page_content %}
{% block page_content %} {% block page_content %}
@ -81,7 +81,7 @@ content: "{% trans 'Stock Item Test Report' %}";
<p><em>Stock Item ID: {{ stock_item.pk }}</em></p> <p><em>Stock Item ID: {{ stock_item.pk }}</em></p>
</div> </div>
<div class='img-right'> <div class='img-right'>
<img class='part-img' src="{% part_image part %}"> <img class='part-img' alt='{% trans "Part image" %}' src="{% part_image part %}">
<hr> <hr>
<h4> <h4>
{% if stock_item.is_serialized %} {% if stock_item.is_serialized %}
@ -160,7 +160,7 @@ content: "{% trans 'Stock Item Test Report' %}";
{% for sub_item in installed_items %} {% for sub_item in installed_items %}
<tr> <tr>
<td> <td>
<img src='{% part_image sub_item.part %}' class='part-img' style='max-width: 24px; max-height: 24px;'> <img src='{% part_image sub_item.part %}' class='part-img' alt='{% trans "Part image" %}' style='max-width: 24px; max-height: 24px;'>
{{ sub_item.part.full_name }} {{ sub_item.part.full_name }}
</td> </td>
<td> <td>
@ -177,8 +177,8 @@ content: "{% trans 'Stock Item Test Report' %}";
{% endif %} {% endif %}
{% endblock %} {% endblock page_content %}
{% block post_page_content %} {% block post_page_content %}
{% endblock %} {% endblock post_page_content %}

View File

@ -7,7 +7,7 @@
{% block sidebar %} {% block sidebar %}
{% include "stock/stock_sidebar.html" %} {% include "stock/stock_sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block page_content %} {% block page_content %}
@ -165,7 +165,7 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -334,4 +334,4 @@
enableSidebar('stockitem'); enableSidebar('stockitem');
{% endblock %} {% endblock js_ready %}

View File

@ -8,12 +8,12 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Stock Item" %} - {{ item }} {% inventree_title %} | {% trans "Stock Item" %} - {{ item }}
{% endblock %} {% endblock page_title %}
{% block breadcrumbs %} {% block breadcrumbs %}
<a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a> <a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a>
{% include 'stock/loc_link.html' with location=item.location %} {% include 'stock/loc_link.html' with location=item.location %}
{% endblock %} {% endblock breadcrumbs %}
{% block breadcrumb_tree %} {% block breadcrumb_tree %}
<div id="breadcrumb-tree"></div> <div id="breadcrumb-tree"></div>
@ -131,7 +131,7 @@
{% endblock actions %} {% endblock actions %}
{% block thumbnail %} {% block thumbnail %}
<img class='part-thumb' {% if item.part.image %}src="{{ item.part.image.preview.url }}"{% else %}src="{% static 'img/blank_image.png' %}"{% endif %}/> <img class='part-thumb' alt='{% trans "Image" %}' {% if item.part.image %}src="{{ item.part.image.preview.url }}"{% else %}src="{% static 'img/blank_image.png' %}"{% endif %}/>
{% endblock thumbnail %} {% endblock thumbnail %}
{% block details %} {% block details %}
@ -446,11 +446,9 @@
{% endif %} {% endif %}
</tr> </tr>
</table> </table>
{% endblock details_right %} {% endblock details_right %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -704,4 +702,4 @@ enableBreadcrumbTree({
} }
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -5,4 +5,4 @@
{% trans "Create serialized items from this stock item." %} {% trans "Create serialized items from this stock item." %}
<br> <br>
{% trans "Select quantity to serialize, and unique serial numbers." %} {% trans "Select quantity to serialize, and unique serial numbers." %}
{% endblock %} {% endblock pre_form_content %}

View File

@ -6,7 +6,7 @@
{% block sidebar %} {% block sidebar %}
{% include "stock/location_sidebar.html" %} {% include "stock/location_sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block breadcrumb_tree %} {% block breadcrumb_tree %}
<div id="breadcrumb-tree"></div> <div id="breadcrumb-tree"></div>
@ -23,7 +23,7 @@
{% else %} {% else %}
{% trans "Stock" %} {% trans "Stock" %}
{% endif %} {% endif %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
@ -111,7 +111,7 @@
{% endif %} {% endif %}
{% endif %} {% endif %}
{% endif %} {% endif %}
{% endblock %} {% endblock actions %}
{% block details_left %} {% block details_left %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -230,7 +230,7 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock page_content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -396,7 +396,6 @@
}); });
}); });
{% endif %} {% endif %}
{% endif %} {% endif %}
@ -446,4 +445,4 @@
defaultIcon: global_settings.STOCK_LOCATION_DEFAULT_ICON, defaultIcon: global_settings.STOCK_LOCATION_DEFAULT_ICON,
}); });
{% endblock %} {% endblock js_ready %}

View File

@ -9,13 +9,13 @@
{% else %} {% else %}
{% inventree_title %} | {% trans "Stock" %} {% inventree_title %} | {% trans "Stock" %}
{% endif %} {% endif %}
{% endblock %} {% endblock page_title %}
{% block sidenav %} {% block sidenav %}
<div id='stock-tree'> <div id='stock-tree'>
{% trans "Loading..." %} {% trans "Loading..." %}
</div> </div>
{% endblock %} {% endblock sidenav %}
{% block breadcrumbs %} {% block breadcrumbs %}
<a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a> <a href='#' id='breadcrumb-tree-toggle' class="breadcrumb-item"><span class="fas fa-bars"></span></a>

View File

@ -4,7 +4,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Permission Denied" %} {% inventree_title %} | {% trans "Permission Denied" %}
{% endblock %} {% endblock page_title %}
{% block content %} {% block content %}
@ -16,4 +16,4 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -5,7 +5,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Permission Denied" %} {% inventree_title %} | {% trans "Permission Denied" %}
{% endblock %} {% endblock page_title %}
{% block content %} {% block content %}
<h3>{% trans "Authentication Failure" %}</h3> <h3>{% trans "Authentication Failure" %}</h3>
@ -20,4 +20,4 @@
</a> </a>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -4,7 +4,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Page Not Found" %} {% inventree_title %} | {% trans "Page Not Found" %}
{% endblock %} {% endblock page_title %}
{% block content %} {% block content %}
@ -16,4 +16,4 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -4,7 +4,7 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Internal Server Error" %} {% inventree_title %} | {% trans "Internal Server Error" %}
{% endblock %} {% endblock page_title %}
{% block content %} {% block content %}
@ -17,4 +17,4 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -5,13 +5,13 @@
{% block head %} {% block head %}
<meta http-equiv="refresh" content="30"> <meta http-equiv="refresh" content="30">
{% endblock %} {% endblock head %}
{% block page_title %} {% block page_title %}
{% trans 'Site is in Maintenance' %} {% trans 'Site is in Maintenance' %}
{% endblock %} {% endblock page_title %}
{% block body_class %}login-screen' style='background: url({% inventree_splash %}); background-size: cover;{% endblock %} {% block body_class %}login-screen' style='background: url({% inventree_splash %}); background-size: cover;{% endblock body_class %}
{% block body %} {% block body %}
@ -23,30 +23,29 @@
<div class='main body-wrapper login-screen d-flex'> <div class='main body-wrapper login-screen d-flex'>
<div class='login-container'> <div class='login-container'>
<div class="row"> <div class="row">
<div class='container-fluid'> <div class='container-fluid'>
<div class='clearfix content-heading login-header d-flex flex-wrap'> <div class='clearfix content-heading login-header d-flex flex-wrap'>
<img class="pull-left" src="{% inventree_logo %}" width="60" height="60"/> <img class="pull-left" alt='{% trans "Image" %}' src="{% inventree_logo %}" width="60" height="60"/>
{% include "spacer.html" %} {% include "spacer.html" %}
<span class='float-right'><h3>{% block body_title %}{% trans 'Site is in Maintenance' %}{% endblock %}</h3></span> <span class='float-right'><h3>{% block body_title %}{% trans 'Site is in Maintenance' %}{% endblock body_title %}</h3></span>
</div> </div>
</div> </div>
<div class='container-fluid'> <div class='container-fluid'>
<hr> <hr>
{% block content %} {% block content %}
{% trans 'The site is currently in maintenance and should be up again soon!' %} {% trans 'The site is currently in maintenance and should be up again soon!' %}
{% endblock %} {% endblock content %}
</div> </div>
</div> </div>
</div> </div>
{% block extra_body %} {% block extra_body %}
{% endblock %} {% endblock extra_body %}
</div> </div>
{% endblock %} {% endblock body %}
{% block js_base %} {% block js_base %}
<script type='text/javascript'> <script type='text/javascript'>
@ -67,6 +66,6 @@ $(document).ready(function () {
inventreeDocReady(); inventreeDocReady();
}); });
</script> </script>
{% endblock %} {% endblock js_base %}
</body> </body>
</html> </html>

View File

@ -5,21 +5,21 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Index" %} {% inventree_title %} | {% trans "Index" %}
{% endblock %} {% endblock page_title %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block sidebar %} {% block sidebar %}
<!-- Sidebar data is filled dynamically for the index page--> <!-- Sidebar data is filled dynamically for the index page-->
{% endblock %} {% endblock sidebar %}
{% block content %} {% block content %}
<div id='detail-panels'> <div id='detail-panels'>
</div> </div>
{% endblock %} {% endblock content %}
{% block js_ready %} {% block js_ready %}
@ -203,7 +203,6 @@ loadSimplePartTable("#table-stock-to-build", "{% url 'api-part-list' %}", {
}); });
{% endif %} {% endif %}
{% if expiry %} {% if expiry %}
{% if setting_stock_expired %} {% if setting_stock_expired %}
@ -349,4 +348,4 @@ enableSidebar(
} }
); );
{% endblock %} {% endblock js_ready %}

View File

@ -3,17 +3,17 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}history{% endblock %} {% block label %}history{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Notification History" %} {% trans "Notification History" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<div class='btn btn-danger' type='button' id='history-delete' title='{% trans "Delete Notifications" %}'> <div class='btn btn-danger' type='button' id='history-delete' title='{% trans "Delete Notifications" %}'>
<span class='fas fa-trash-alt'></span> {% trans "Delete Notifications" %} <span class='fas fa-trash-alt'></span> {% trans "Delete Notifications" %}
</div> </div>
{% endblock %} {% endblock actions %}
{% block content %} {% block content %}
@ -29,4 +29,4 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,17 +3,17 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}inbox{% endblock %} {% block label %}inbox{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Pending Notifications" %} {% trans "Pending Notifications" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<div class='btn btn-outline-secondary' type='button' id='mark-all' title='{% trans "Mark all as read" %}'> <div class='btn btn-outline-secondary' type='button' id='mark-all' title='{% trans "Mark all as read" %}'>
<span class='fa fa-bookmark'></span> {% trans "Mark all as read" %} <span class='fa fa-bookmark'></span> {% trans "Mark all as read" %}
</div> </div>
{% endblock %} {% endblock actions %}
{% block content %} {% block content %}
@ -28,4 +28,4 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -4,20 +4,20 @@
{% load inventree_extras %} {% load inventree_extras %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Notifications" %} {% inventree_title %} | {% trans "Notifications" %}
{% endblock %} {% endblock page_title %}
{% block sidebar %} {% block sidebar %}
{% include "InvenTree/notifications/sidebar.html" %} {% include "InvenTree/notifications/sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block content %} {% block content %}
{% include "InvenTree/notifications/inbox.html" %} {% include "InvenTree/notifications/inbox.html" %}
{% include "InvenTree/notifications/history.html" %} {% include "InvenTree/notifications/history.html" %}
{% endblock %} {% endblock content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -29,7 +29,6 @@ function updateNotificationTables() {
// this allows the global notification panel to update the tables // this allows the global notification panel to update the tables
window.updateNotifications = updateNotificationTables window.updateNotifications = updateNotificationTables
loadNotificationTable("#inbox-table", { loadNotificationTable("#inbox-table", {
name: 'inbox', name: 'inbox',
url: '{% url 'api-notifications-list' %}', url: '{% url 'api-notifications-list' %}',
@ -59,7 +58,6 @@ loadNotificationTable("#history-table", {
no_matches: function() { return '{% trans "No notification history found" %}'; }, no_matches: function() { return '{% trans "No notification history found" %}'; },
}, true); }, true);
$('#history-delete').click(function() { $('#history-delete').click(function() {
var html = ` var html = `
@ -96,4 +94,4 @@ $("#history-table").on('click', '.notification-delete', function() {
}); });
enableSidebar('notifications'); enableSidebar('notifications');
{% endblock %} {% endblock js_ready %}

View File

@ -4,4 +4,4 @@
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock pre_form_content %}

View File

@ -6,10 +6,10 @@
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Search Results" %} {% inventree_title %} | {% trans "Search Results" %}
{% endblock %} {% endblock page_title %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block content %} {% block content %}
@ -22,7 +22,7 @@
<div id='detail-panels'> <div id='detail-panels'>
</div> </div>
{% endblock %} {% endblock content %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -236,4 +236,4 @@
} }
); );
{% endblock %} {% endblock js_ready %}

View File

@ -2,11 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}barcodes{% endblock %} {% block label %}barcodes{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Barcode Settings" %} {% trans "Barcode Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -18,4 +18,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -2,11 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}build-order{% endblock %} {% block label %}build-order{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Build Order Settings" %} {% trans "Build Order Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -16,4 +16,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,17 +1,17 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}category{% endblock %} {% block label %}category{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Category Settings" %} {% trans "Category Settings" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
<button class='btn btn-success' id='new-cat-param'> <button class='btn btn-success' id='new-cat-param'>
<div class='fas fa-plus-circle'></div> {% trans "New Parameter" %} <div class='fas fa-plus-circle'></div> {% trans "New Parameter" %}
</button> </button>
{% endblock %} {% endblock actions %}
{% block content %} {% block content %}
@ -30,4 +30,4 @@
<table class='table table-striped table-condensed' id='cat-param-table' data-toolbar='#cat-param-buttons'> <table class='table table-striped table-condensed' id='cat-param-table' data-toolbar='#cat-param-buttons'>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -2,12 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}server{% endblock %} {% block label %}server{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Server Settings" %} {% trans "Server Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -34,4 +33,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -2,11 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}labels{% endblock %} {% block label %}labels{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Label Settings" %} {% trans "Label Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -17,4 +17,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -2,12 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}login{% endblock %} {% block label %}login{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Login Settings" %} {% trans "Login Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -41,4 +40,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}parts{% endblock %} {% block label %}parts{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Part Settings" %} {% trans "Part Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -70,4 +70,4 @@
<table class='table table-striped table-condensed' id='param-table' data-toolbar='#param-buttons'> <table class='table table-striped table-condensed' id='param-table' data-toolbar='#param-buttons'>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}stocktake{% endblock %} {% block label %}stocktake{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Stocktake Settings" %} {% trans "Stocktake Settings" %}
{% endblock %} {% endblock heading %}
{% block panel_content %} {% block panel_content %}

View File

@ -3,12 +3,11 @@
{% load inventree_extras %} {% load inventree_extras %}
{% load plugin_extras %} {% load plugin_extras %}
{% block label %}plugin{% endblock %} {% block label %}plugin{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Plugin Settings" %} {% trans "Plugin Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -86,7 +85,6 @@
</table> </table>
</div> </div>
{% plugin_errors as pl_errors %} {% plugin_errors as pl_errors %}
{% if pl_errors %} {% if pl_errors %}
<div class='panel-heading'> <div class='panel-heading'>
@ -123,4 +121,4 @@
</div> </div>
{% endif %} {% endif %}
{% endblock %} {% endblock content %}

View File

@ -3,12 +3,11 @@
{% load inventree_extras %} {% load inventree_extras %}
{% load plugin_extras %} {% load plugin_extras %}
{% block label %}plugin-{{plugin_key}}{% endblock %} {% block label %}plugin-{{ plugin_key }}{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Plugin" %}: <em>{{ plugin.human_name }}</em> {% trans "Plugin" %}: <em>{{ plugin.human_name }}</em>
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -150,4 +149,4 @@
{% include 'InvenTree/settings/mixins/settings_content.html' %} {% include 'InvenTree/settings/mixins/settings_content.html' %}
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}purchase-order{% endblock %} {% block label %}purchase-order{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Purchase Order Settings" %} {% trans "Purchase Order Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
<table class='table table-striped table-condensed'> <table class='table table-striped table-condensed'>
@ -14,4 +14,4 @@
{% include "InvenTree/settings/setting.html" with key="PURCHASEORDER_EDIT_COMPLETED_ORDERS" icon='fa-edit' %} {% include "InvenTree/settings/setting.html" with key="PURCHASEORDER_EDIT_COMPLETED_ORDERS" icon='fa-edit' %}
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}pricing{% endblock %} {% block label %}pricing{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Pricing Settings" %} {% trans "Pricing Settings" %}
{% endblock %} {% endblock heading %}
{% block panel_content %} {% block panel_content %}
<div class='panel-content'> <div class='panel-content'>

View File

@ -7,8 +7,6 @@
{% block heading %}{% trans "Project Code Settings" %}{% endblock heading %} {% block heading %}{% trans "Project Code Settings" %}{% endblock heading %}
{% block content %} {% block content %}
<!-- Project code settings --> <!-- Project code settings -->

View File

@ -2,11 +2,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}reporting{% endblock %} {% block label %}reporting{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Report Settings" %} {% trans "Report Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -20,4 +20,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}return-order{% endblock %} {% block label %}return-order{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Return Order Settings" %} {% trans "Return Order Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -17,4 +17,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -6,15 +6,15 @@
{% load plugin_extras %} {% load plugin_extras %}
{% block breadcrumb_list %} {% block breadcrumb_list %}
{% endblock %} {% endblock breadcrumb_list %}
{% block page_title %} {% block page_title %}
{% inventree_title %} | {% trans "Settings" %} {% inventree_title %} | {% trans "Settings" %}
{% endblock %} {% endblock page_title %}
{% block sidebar %} {% block sidebar %}
{% include "InvenTree/settings/sidebar.html" %} {% include "InvenTree/settings/sidebar.html" %}
{% endblock %} {% endblock sidebar %}
{% block content %} {% block content %}
@ -55,11 +55,11 @@
{% endif %} {% endif %}
{% endblock %} {% endblock content %}
{% block js_load %} {% block js_load %}
{{ block.super }} {{ block.super }}
{% endblock %} {% endblock js_load %}
{% block js_ready %} {% block js_ready %}
{{ block.super }} {{ block.super }}
@ -78,4 +78,4 @@
enableSidebar('settings'); enableSidebar('settings');
{% endblock %} {% endblock js_ready %}

View File

@ -272,7 +272,6 @@ onPanelLoad('category', function() {
}); });
} }
// Initially load table with *all* categories // Initially load table with *all* categories
loadTemplateTable(); loadTemplateTable();
@ -303,7 +302,6 @@ onPanelLoad('category', function() {
}); });
}); });
// Javascript for the Part settings panel // Javascript for the Part settings panel
onPanelLoad('parts', function() { onPanelLoad('parts', function() {
$("#param-table").inventreeTable({ $("#param-table").inventreeTable({
@ -405,7 +403,6 @@ onPanelLoad('parts', function() {
}); });
}); });
// Javascript for the Stocktake settings panel // Javascript for the Stocktake settings panel
onPanelLoad('stocktake', function() { onPanelLoad('stocktake', function() {

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}sales-order{% endblock %} {% block label %}sales-order{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Sales Order Settings" %} {% trans "Sales Order Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -17,4 +17,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -1,11 +1,11 @@
{% extends "panel.html" %} {% extends "panel.html" %}
{% load i18n %} {% load i18n %}
{% block label %}stock{% endblock %} {% block label %}stock{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Stock Settings" %} {% trans "Stock Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -24,4 +24,4 @@
</tbody> </tbody>
</table> </table>
{% endblock %} {% endblock content %}

View File

@ -6,11 +6,11 @@
{% load crispy_forms_tags %} {% load crispy_forms_tags %}
{% load user_sessions i18n %} {% load user_sessions i18n %}
{% block label %}account{% endblock %} {% block label %}account{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Account Settings" %} {% trans "Account Settings" %}
{% endblock %} {% endblock heading %}
{% block actions %} {% block actions %}
{% inventree_customize 'hide_password_reset' as hide_password_reset %} {% inventree_customize 'hide_password_reset' as hide_password_reset %}
@ -22,7 +22,7 @@
<div class='btn btn-primary' type='button' id='edit-user' title='{% trans "Edit User Information" %}'> <div class='btn btn-primary' type='button' id='edit-user' title='{% trans "Edit User Information" %}'>
<span class='fas fa-user-cog'></span> {% trans "Edit" %} <span class='fas fa-user-cog'></span> {% trans "Edit" %}
</div> </div>
{% endblock %} {% endblock actions %}
{% block content %} {% block content %}
{% mail_configured as mail_conf %} {% mail_configured as mail_conf %}
@ -265,7 +265,7 @@
</table> </table>
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}
{% block js_ready %} {% block js_ready %}
(function() { (function() {
@ -279,4 +279,4 @@ e.preventDefault();
}); });
} }
})(); })();
{% endblock %} {% endblock js_ready %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-display{% endblock %} {% block label %}user-display{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Display Settings" %} {% trans "Display Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -110,4 +110,4 @@
</div> </div>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-home{% endblock %} {% block label %}user-home{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Home Page Settings" %} {% trans "Home Page Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -42,4 +42,4 @@
</tbody> </tbody>
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-labels{% endblock %} {% block label %}user-labels{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Label Settings" %} {% trans "Label Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -20,4 +20,4 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-reports{% endblock %} {% block label %}user-reports{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Report Settings" %} {% trans "Report Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -21,4 +21,4 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-search{% endblock %} {% block label %}user-search{% endblock label %}
{% block heading %} {% block heading %}
{% trans "Search Settings" %} {% trans "Search Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -34,9 +34,8 @@
{% include "InvenTree/settings/setting.html" with key="SEARCH_PREVIEW_SHOW_RETURN_ORDERS" user_setting=True icon='fa-truck' %} {% include "InvenTree/settings/setting.html" with key="SEARCH_PREVIEW_SHOW_RETURN_ORDERS" user_setting=True icon='fa-truck' %}
{% include "InvenTree/settings/setting.html" with key="SEARCH_PREVIEW_EXCLUDE_INACTIVE_RETURN_ORDERS" user_setting=True icon='fa-eye-slash' %} {% include "InvenTree/settings/setting.html" with key="SEARCH_PREVIEW_EXCLUDE_INACTIVE_RETURN_ORDERS" user_setting=True icon='fa-eye-slash' %}
</tbody> </tbody>
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -3,11 +3,11 @@
{% load i18n %} {% load i18n %}
{% load inventree_extras %} {% load inventree_extras %}
{% block label %}user-settings{% endblock %} {% block label %}user-settings{% endblock label %}
{% block heading %} {% block heading %}
{% trans "User Settings" %} {% trans "User Settings" %}
{% endblock %} {% endblock heading %}
{% block content %} {% block content %}
@ -17,4 +17,4 @@
</table> </table>
</div> </div>
{% endblock %} {% endblock content %}

View File

@ -40,13 +40,12 @@
<link rel="stylesheet" href="{% get_color_theme_css user.get_username %}"> <link rel="stylesheet" href="{% get_color_theme_css user.get_username %}">
<title> <title>
{% inventree_title %} | {% block head_title %}{% endblock %} {% inventree_title %} | {% block head_title %}{% endblock head_title %}
</title> </title>
{% block extra_head %} {% block extra_head %}
{% endblock %} {% endblock extra_head %}
</head> </head>
<body class='login-screen' style='background: url({% inventree_splash %}); background-size: cover;'> <body class='login-screen' style='background: url({% inventree_splash %}); background-size: cover;'>
@ -59,13 +58,12 @@
<div class='main body-wrapper login-screen d-flex'> <div class='main body-wrapper login-screen d-flex'>
<div class='login-container'> <div class='login-container'>
<div class="row"> <div class="row">
<div class='container-fluid'> <div class='container-fluid'>
<div class='clearfix content-heading login-header d-flex flex-wrap'> <div class='clearfix content-heading login-header d-flex flex-wrap'>
<img class="pull-left" src="{% inventree_logo %}" width="60" height="60"/> <img class="pull-left" src="{% inventree_logo %}" alt='{% trans "InvenTree logo" %}' width="60" height="60"/>
{% include "spacer.html" %} {% include "spacer.html" %}
<span class='float-right'><h3>{% inventree_title %}</h3></span> <span class='float-right'><h3>{% inventree_title %}</h3></span>
</div> </div>
@ -73,14 +71,14 @@
<div class='container-fluid'> <div class='container-fluid'>
<hr> <hr>
{% block content %} {% block content %}
{% endblock %} {% endblock content %}
</div> </div>
</div> </div>
</div> </div>
{% block extra_body %} {% block extra_body %}
{% endblock %} {% endblock extra_body %}
</div> </div>

View File

@ -3,8 +3,7 @@
{% load i18n %} {% load i18n %}
{% load account %} {% load account %}
{% block head_title %}{% trans "Confirm Email Address" %}{% endblock %} {% block head_title %}{% trans "Confirm Email Address" %}{% endblock head_title %}
{% block content %} {% block content %}
<h1>{% trans "Confirm Email Address" %}</h1> <h1>{% trans "Confirm Email Address" %}</h1>
@ -31,4 +30,4 @@
{% endif %} {% endif %}
{% endblock %} {% endblock content %}

View File

@ -3,7 +3,7 @@
{% load inventree_extras %} {% load inventree_extras %}
{% load i18n account socialaccount crispy_forms_tags inventree_extras %} {% load i18n account socialaccount crispy_forms_tags inventree_extras %}
{% block head_title %}{% trans "Sign In" %}{% endblock %} {% block head_title %}{% trans "Sign In" %}{% endblock head_title %}
{% block content %} {% block content %}
@ -26,7 +26,7 @@
{% endif %} {% endif %}
</div> </div>
<form class="login" method="POST" action="{% url 'account_login' %}"> <form class="login" method="post" action="{% url 'account_login' %}">
{% csrf_token %} {% csrf_token %}
{{ form|crispy }} {{ form|crispy }}
{% if redirect_field_value %} {% if redirect_field_value %}
@ -42,7 +42,7 @@
<div>{{ login_message | safe }}<hr></div> <div>{{ login_message | safe }}<hr></div>
{% endif %} {% endif %}
{% if mail_conf and enable_pwd_forgot %} {% if mail_conf and enable_pwd_forgot %}
<a class="" href="{% url 'account_reset_password' %}"><small>{% trans "Forgot Password?" %}</small></a> <a href="{% url 'account_reset_password' %}"><small>{% trans "Forgot Password?" %}</small></a>
{% endif %} {% endif %}
</form> </form>
@ -60,4 +60,4 @@
{% include "socialaccount/snippets/login_extra.html" %} {% include "socialaccount/snippets/login_extra.html" %}
{% endif %} {% endif %}
{% endblock %} {% endblock content %}

View File

@ -2,7 +2,7 @@
{% load i18n %} {% load i18n %}
{% block head_title %}{% trans "Sign Out" %}{% endblock %} {% block head_title %}{% trans "Sign Out" %}{% endblock head_title %}
{% block content %} {% block content %}
<h3>{% trans "Sign Out" %}</h3> <h3>{% trans "Sign Out" %}</h3>
@ -28,4 +28,4 @@
</a> </a>
</div> </div>
{% endblock %} {% endblock content %}

Some files were not shown because too many files have changed in this diff Show More