2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-01 03:00:54 +00:00

add user setting to select a default label printer (#4349) (#4362)

This commit is contained in:
simonkuehling
2023-02-20 21:24:11 +01:00
committed by GitHub
parent 75ca325892
commit 17bfea4428
3 changed files with 23 additions and 1 deletions

View File

@ -262,7 +262,11 @@ function selectLabel(labels, items, options={}) {
`;
plugins.forEach(function(plugin) {
plugin_selection += `<option value='${plugin.key}' title='${plugin.meta.human_name}'>${plugin.name} - <small>${plugin.meta.human_name}</small></option>`;
var selected = '';
if (user_settings['LABEL_DEFAULT_PRINTER'] == plugin.key) {
selected = ' selected';
}
plugin_selection += `<option value='${plugin.key}' title='${plugin.meta.human_name}'${selected}>${plugin.name} - <small>${plugin.meta.human_name}</small></option>`;
});
plugin_selection += `