From 43f81f87e32cf072d89f1a5eab8f428ceb768ee9 Mon Sep 17 00:00:00 2001 From: Pierre Donias Date: Tue, 8 Sep 2026 16:38:00 +0200 Subject: [PATCH] feat(xo-web/vm/tab-backups): open edit form in same tab (#10342) Opening the form in a new tab reloaded the whole app, so every object was fetched again from scratch. Until that fetch finished, the form could not be properly auto-filled. Navigating in the same tab reuses the already loaded objects, so the form is populated right away. --- CHANGELOG.unreleased.md | 2 ++ packages/xo-web/src/xo-app/backup/overview/tab-jobs.js | 8 +------- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.unreleased.md b/CHANGELOG.unreleased.md index 6e82f44486..3fde97fd56 100644 --- a/CHANGELOG.unreleased.md +++ b/CHANGELOG.unreleased.md @@ -15,6 +15,7 @@ - [XO6] Allow changing which PIF a host uses for its management interface, without deleting and recreating the network config (PR [#10110](https://github.com/vatesfr/xen-orchestra/pull/10110)) - [XO6/SR] Add dedicated Storage Repository page hosts sidepanel (PR [#10140](https://github.com/vatesfr/xen-orchestra/pull/10140)) - [Rolling pool update/reboot] A pool can now skip the phase which brings the VMs back to the host they were running on, which halves the migrations of the run (PR [#10295](https://github.com/vatesfr/xen-orchestra/pull/10295)) +- [XO5/Backups] Open the backup job edition form in the same tab when editing a backup job from the VM page (PR [#10342](https://github.com/vatesfr/xen-orchestra/pull/10342)) ### Bug fixes @@ -50,5 +51,6 @@ - @xen-orchestra/web minor - @xen-orchestra/web-core minor - xo-server minor +- xo-web minor diff --git a/packages/xo-web/src/xo-app/backup/overview/tab-jobs.js b/packages/xo-web/src/xo-app/backup/overview/tab-jobs.js index e7ac24f3c3..eeb27b6d9a 100644 --- a/packages/xo-web/src/xo-app/backup/overview/tab-jobs.js +++ b/packages/xo-web/src/xo-app/backup/overview/tab-jobs.js @@ -407,7 +407,7 @@ class JobsTable extends React.Component { icon: 'preview', }, { - handler: (job, { goTo, goToNewTab, main }) => (main ? goTo : goToNewTab)(`/backup/${job.id}/edit`), + handler: (job, { goTo }) => goTo(`/backup/${job.id}/edit`), label: _('formEdit'), icon: 'edit', level: 'primary', @@ -434,10 +434,6 @@ class JobsTable extends React.Component { this.context.router.push(path) } - _goToNewTab = path => { - window.open(this.context.router.createHref(path)) - } - _getCollection = createFilter( createSelector( () => this.props.jobs, @@ -455,8 +451,6 @@ class JobsTable extends React.Component { actions={this._getActions()} collection={this._getCollection()} data-goTo={this._goTo} - data-goToNewTab={this._goToNewTab} - data-main={this.props.main} data-schedulesByJob={this.props.schedulesByJob} data-scrollIntoLogs={this.props.scrollIntoLogs} stateUrlParam='s'