Merge pull request #2129 from SchrodingersGat/sub-part-from-bom

Add option to BomItem form to create a new part
This commit is contained in:
Oliver 2021-10-11 10:59:30 +11:00 committed by GitHub
commit 8d33ee6298
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -35,6 +35,18 @@ function bomItemFields() {
hidden: true,
},
sub_part: {
secondary: {
title: '{% trans "New Part" %}',
fields: function() {
var fields = partFields();
// Set to a "component" part
fields.component.value = true;
return fields;
},
groups: partGroups(),
}
},
quantity: {},
reference: {},