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

Serial number autofill (#4091)

* Add global setting to control seiral number auto-fill

* Auto fill serial number field
This commit is contained in:
Oliver
2022-12-21 22:09:21 +11:00
committed by GitHub
parent d4341e81f2
commit 17b0399d26
3 changed files with 14 additions and 0 deletions

View File

@ -240,6 +240,12 @@ function stockItemFields(options={}) {
}
setFormInputPlaceholder('serial_numbers', placeholder, opts);
if (global_settings.SERIAL_NUMBER_AUTOFILL) {
if (data.next) {
updateFieldValue('serial_numbers', `${data.next}+`, {}, opts);
}
}
}
});