mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-20 05:46:34 +00:00
Create new stock item from supplierpart stock page
- Allow stock-item-create form to have supplierpart passed as initial data - Add some translations too
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
{% extends "part/part_base.html" %}
|
||||
{% load static %}
|
||||
{% load i18n %}
|
||||
{% block details %}
|
||||
|
||||
{% include 'part/tabs.html' with tab='stock' %}
|
||||
@ -49,7 +50,7 @@
|
||||
|
||||
$("#stock-export").click(function() {
|
||||
launchModalForm("{% url 'stock-export-options' %}", {
|
||||
submit_text: "Export",
|
||||
submit_text: "{% trans 'Export' %}",
|
||||
success: function(response) {
|
||||
var url = "{% url 'stock-export' %}";
|
||||
|
||||
@ -71,14 +72,14 @@
|
||||
secondary: [
|
||||
{
|
||||
field: 'part',
|
||||
label: 'New Part',
|
||||
title: 'Create New Part',
|
||||
label: '{% trans "New Part" %}',
|
||||
title: '{% trans "Create New Part" %}',
|
||||
url: "{% url 'part-create' %}",
|
||||
},
|
||||
{
|
||||
field: 'supplier_part',
|
||||
label: 'New Supplier Part',
|
||||
title: 'Create new Supplier Part',
|
||||
label: '{% trans "New Supplier Part" %}',
|
||||
title: '{% trans "Create new Supplier Part" %}',
|
||||
url: "{% url 'supplier-part-create' %}",
|
||||
data: {
|
||||
part: {{ part.id }}
|
||||
@ -86,8 +87,8 @@
|
||||
},
|
||||
{
|
||||
field: 'location',
|
||||
label: 'New Location',
|
||||
title: 'Create New Location',
|
||||
label: '{% trans "New Location" %}',
|
||||
title: '{% trans "Create New Location" %}',
|
||||
url: "{% url 'stock-location-create' %}",
|
||||
}
|
||||
]
|
||||
|
Reference in New Issue
Block a user