mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-25 01:12:16 +00:00
Added crud for suppliers
This commit is contained in:
6
templates/supplier_detail.html
Normal file
6
templates/supplier_detail.html
Normal file
@@ -0,0 +1,6 @@
|
||||
{% extends 'base.html' %}
|
||||
{% block title %}Detail{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
{{ object }}
|
||||
{% endblock %}
|
||||
29
templates/supplier_list.html
Normal file
29
templates/supplier_list.html
Normal file
@@ -0,0 +1,29 @@
|
||||
{% extends 'base.html' %}
|
||||
{% block title %}List{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
|
||||
<h4>Supplier List</h4>
|
||||
|
||||
<table class="striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Supplier</th>
|
||||
<th>Quick Links</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody id="asset_table_body">
|
||||
{% for item in object_list %}
|
||||
<tr>
|
||||
<td>{{ item.name }}</td>
|
||||
<td>
|
||||
<a href="{% url 'supplier_update' item.pk %}"><i class="material-icons">edit</i></a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
{% include 'helpers/paginator.html' %}
|
||||
|
||||
{% endblock %}
|
||||
24
templates/supplier_update.html
Normal file
24
templates/supplier_update.html
Normal file
@@ -0,0 +1,24 @@
|
||||
{% extends 'base.html' %}
|
||||
{% block title %}Edit{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
|
||||
<h4>
|
||||
Supplier
|
||||
{% if object %}
|
||||
Edit | {{ object.name }}
|
||||
{% else %}
|
||||
Create
|
||||
{% endif %}
|
||||
</h4>
|
||||
|
||||
<div class="divider"></div>
|
||||
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
|
||||
{{ form }}
|
||||
|
||||
<input type="submit" value="Save" class="btn">
|
||||
</form>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user