mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Add secondary modal to create a new supplier part
This commit is contained in:
parent
aee1ea9e35
commit
8aa5452dd4
@ -70,8 +70,12 @@ InvenTree | {{ order }}
|
||||
{% for line in order.lines.all %}
|
||||
<tr>
|
||||
<td>{{ forloop.counter }}</td>
|
||||
{% if line.part %}
|
||||
<td><a href="{% url 'part-detail' line.part.part.id %}">{{ line.part.part.full_name }}</a></td>
|
||||
<td><a href="{% url 'supplier-part-detail' line.part.id %}">{{ line.part.SKU }}</a></td>
|
||||
{% else %}
|
||||
<td colspan='2'><strong>Warning: Part has been deleted.</strong></td>
|
||||
{% endif %}
|
||||
<td>{{ line.reference }}</td>
|
||||
<td>{{ line.quantity }}</td>
|
||||
<td>{{ line.received }}</td>
|
||||
@ -98,6 +102,17 @@ $('#new-po-line').click(function() {
|
||||
data: {
|
||||
order: {{ order.id }},
|
||||
},
|
||||
secondary: [
|
||||
{
|
||||
field: 'part',
|
||||
label: 'New Supplier Part',
|
||||
title: 'Create new supplier part',
|
||||
url: "{% url 'supplier-part-create' %}",
|
||||
data: {
|
||||
supplier: {{ order.supplier.id }},
|
||||
},
|
||||
},
|
||||
],
|
||||
}
|
||||
);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user