feat: Trigger update to host catalog type
This commit is contained in:
2 files changed
+11
No files matched your search
@@ -1,4 +1,5 @@
|
||||
import Route from '@ember/routing/route';
|
||||
import { action } from '@ember/object';
|
||||
|
||||
export default class ScopesScopeHostCatalogsNewRoute extends Route {
|
||||
// =attributes
|
||||
@@ -25,4 +26,13 @@ export default class ScopesScopeHostCatalogsNewRoute extends Route {
|
||||
scopeModel,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Update type of host catalog
|
||||
* @param {string} type
|
||||
*/
|
||||
@action
|
||||
async changeType(type) {
|
||||
await this.router.replaceWith({ type });
|
||||
}
|
||||
}
|
||||
@@ -18,6 +18,7 @@
|
||||
@model={{@model}}
|
||||
@submit={{route-action 'save' @model}}
|
||||
@cancel={{route-action 'cancel' @model}}
|
||||
@changeType={{route-action 'changeType' @model.type}}
|
||||
/>
|
||||
</page.body>
|
||||
|
||||
|
||||
Reference in new issue
Block a user