mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-29 20:16:44 +00:00
Cleanup
This commit is contained in:
parent
32fafc76d7
commit
28bccea57b
@ -899,8 +899,6 @@ function handleFormErrors(errors, fields, options) {
|
||||
}
|
||||
}
|
||||
|
||||
var offset = 0;
|
||||
|
||||
if (first_error_field) {
|
||||
// Ensure that the field in question is visible
|
||||
document.querySelector(`#div_id_${field_name}`).scrollIntoView({
|
||||
@ -908,7 +906,7 @@ function handleFormErrors(errors, fields, options) {
|
||||
});
|
||||
} else {
|
||||
// Scroll to the top of the form
|
||||
$(options.modal).find('.modal-form-content-wrapper').scrollTop(offset);
|
||||
$(options.modal).find('.modal-form-content-wrapper').scrollTop(0);
|
||||
}
|
||||
|
||||
$(options.modal).find('.modal-content').addClass('modal-error');
|
||||
|
Loading…
x
Reference in New Issue
Block a user