mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
#6372: Updating “per page” count does not refresh list
This commit is contained in:
@@ -265,6 +265,19 @@ function initSelectAll() {
|
||||
}
|
||||
}
|
||||
|
||||
function handlePerPageSelect(event: Event) {
|
||||
const select = event.currentTarget as HTMLSelectElement;
|
||||
if (select.form !== null) {
|
||||
select.form.submit();
|
||||
}
|
||||
}
|
||||
|
||||
function initPerPage() {
|
||||
for (const element of getElements<HTMLSelectElement>('select.per-page')) {
|
||||
element.addEventListener('change', handlePerPageSelect);
|
||||
}
|
||||
}
|
||||
|
||||
export function initButtons() {
|
||||
for (const func of [
|
||||
initRackElevation,
|
||||
@@ -272,6 +285,7 @@ export function initButtons() {
|
||||
initReslug,
|
||||
initSelectAll,
|
||||
initPreferenceUpdate,
|
||||
initPerPage,
|
||||
]) {
|
||||
func();
|
||||
}
|
||||
|
Reference in New Issue
Block a user