mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Fix for potential NoReverseMatch error (#5440)
- Check that the database model really does exist in the template code
This commit is contained in:
parent
9a8c8961e4
commit
a8118ed406
@ -368,7 +368,11 @@
|
||||
<tr>
|
||||
<td><span class='fas fa-th-list'></span></td>
|
||||
<td>{% trans "Sales Order" %}</td>
|
||||
<td><a href="{% url 'so-detail' item.sales_order.id %}">{{ item.sales_order.reference }}</a> - <a href="{% url 'company-detail' item.sales_order.customer.id %}">{{ item.sales_order.customer.name }}</a></td>
|
||||
<td>
|
||||
<a href="{% url 'so-detail' item.sales_order.id %}">{{ item.sales_order.reference }}</a>
|
||||
{% if item.sales_order.customer %}
|
||||
- <a href="{% url 'company-detail' item.sales_order.customer.id %}">{{ item.sales_order.customer.name }}</a></td>
|
||||
{% endif %}
|
||||
</tr>
|
||||
{% else %}
|
||||
{% if allocated_to_sales_orders %}
|
||||
|
Loading…
Reference in New Issue
Block a user