mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Improve form rendering for part parameter template
This commit is contained in:
parent
807dfebb03
commit
335f0ceb79
@ -312,7 +312,13 @@ function renderPartCategory(name, data, parameters, options) {
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
function renderPartParameterTemplate(name, data, parameters, options) {
|
||||
|
||||
var html = `<span>${data.name} - [${data.units}]</span>`;
|
||||
var units = '';
|
||||
|
||||
if (data.units) {
|
||||
units = ` [${data.units}]`;
|
||||
}
|
||||
|
||||
var html = `<span>${data.name}${units}</span>`;
|
||||
|
||||
return html;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user