feat(admin): preserve list return target for back and close actions

This commit is contained in:
2026-03-11 23:32:11 +01:00
parent bc9506866f
commit 277168f7e8
24 changed files with 525 additions and 96 deletions

View File

@@ -1,7 +1,7 @@
import { initStandardListPage } from '../core/app-grid-factory.js';
import { readPageConfig } from '../core/app-page-config.js';
import { warnOnce } from '../core/app-dom.js';
import { getAppBase } from './app-list-utils.js';
import { getAppBase, withCurrentListReturn } from './app-list-utils.js';
const config = readPageConfig('admin-api-audit-index');
if (config) {
@@ -60,7 +60,7 @@ if (config) {
if (!cell.uuid) {
return gridjs.html(label);
}
const url = new URL(`admin/users/edit/${cell.uuid}`, appBase).toString();
const url = withCurrentListReturn(new URL(`admin/users/edit/${cell.uuid}`, appBase).toString());
return gridjs.html(`<a href="${url}">${label}</a>`);
},
},
@@ -75,7 +75,7 @@ if (config) {
if (!cell.uuid) {
return gridjs.html(label);
}
const url = new URL(`admin/tenants/edit/${cell.uuid}`, appBase).toString();
const url = withCurrentListReturn(new URL(`admin/tenants/edit/${cell.uuid}`, appBase).toString());
return gridjs.html(`<a href="${url}">${label}</a>`);
},
},