diff --git a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets.js b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets.js index 36d341bc4..d70b5dab0 100644 --- a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets.js +++ b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets.js @@ -59,10 +59,16 @@ export default class ScopesScopeHostCatalogsHostCatalogHostSetsRoute extends Rou ) async save(hostSet) { await hostSet.save(); - await this.transitionTo( - 'scopes.scope.host-catalogs.host-catalog.host-sets.host-set', - hostSet - ); + if (this.can.can('read model', hostSet)) { + await this.transitionTo( + 'scopes.scope.host-catalogs.host-catalog.host-sets.host-set', + hostSet + ); + } else { + await this.transitionTo( + 'scopes.scope.host-catalogs.host-catalog.host-sets' + ); + } this.refresh(); } diff --git a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/hosts.js b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/hosts.js index 5969a8b67..cb91be6ed 100644 --- a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/hosts.js +++ b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/hosts.js @@ -58,10 +58,14 @@ export default class ScopesScopeHostCatalogsHostCatalogHostsRoute extends Route ) async save(host) { await host.save(); - await this.transitionTo( - 'scopes.scope.host-catalogs.host-catalog.hosts.host', - host - ); + if (this.can.can('read model', host)) { + await this.transitionTo( + 'scopes.scope.host-catalogs.host-catalog.hosts.host', + host + ); + } else { + await this.transitionTo('scopes.scope.host-catalogs.host-catalog.hosts'); + } this.refresh(); }