From 720b332f711d938de4b15a3886b9470df8fc34f7 Mon Sep 17 00:00:00 2001 From: Oliver Walters Date: Sat, 7 Aug 2021 23:49:50 +1000 Subject: [PATCH] Adds secondary to manufacturerpart form --- InvenTree/templates/js/translated/company.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/InvenTree/templates/js/translated/company.js b/InvenTree/templates/js/translated/company.js index 2124f5f344..9c73fcc111 100644 --- a/InvenTree/templates/js/translated/company.js +++ b/InvenTree/templates/js/translated/company.js @@ -30,6 +30,17 @@ function createManufacturerPart(options={}) { fields.manufacturer.value = options.manufacturer; } + fields.manufacturer.secondary = { + title: '{% trans "Add Manufacturer" %}', + fields: function(data) { + var company_fields = companyFormFields(); + + company_fields.is_manufacturer.value = true; + + return company_fields; + } + } + constructForm('{% url "api-manufacturer-part-list" %}', { fields: fields, method: 'POST',