mirror of
https://github.com/inventree/InvenTree.git
synced 2025-08-14 07:31:10 +00:00
Added views for part and part category
- Worked out simple linking - Category path displaying correctly - Category page lists parts in category
This commit is contained in:
17
InvenTree/part/templates/part/category.html
Normal file
17
InvenTree/part/templates/part/category.html
Normal file
@@ -0,0 +1,17 @@
|
||||
<h1>Category: {{ category.name }}</h1>
|
||||
|
||||
<h2>Path: {{ category }}</h2>
|
||||
|
||||
<br>
|
||||
Path<br>
|
||||
|
||||
{# Construct the category path #}
|
||||
{% for path_item in category.path %}
|
||||
<a href="../{{path_item.pk}}">{{path_item.name}}</a>/
|
||||
{% endfor %}
|
||||
|
||||
<br>Parts:<br>
|
||||
|
||||
{% for part in category.part_set.all %}
|
||||
<a href="/part/{{part.pk}}">{{part.name}}</a><br>
|
||||
{% endfor %}
|
1
InvenTree/part/templates/part/detail.html
Normal file
1
InvenTree/part/templates/part/detail.html
Normal file
@@ -0,0 +1 @@
|
||||
{{part}}
|
Reference in New Issue
Block a user