diff --git a/ui/admin/app/templates/scopes/scope/auth-methods/index.hbs b/ui/admin/app/templates/scopes/scope/auth-methods/index.hbs index a2f2d0860..500beb452 100644 --- a/ui/admin/app/templates/scopes/scope/auth-methods/index.hbs +++ b/ui/admin/app/templates/scopes/scope/auth-methods/index.hbs @@ -12,28 +12,25 @@ - {{#if (can 'create collection' this.scopeModel collection='auth-methods')}} - {{#if @model}} - + - - {{t 'resources.auth-method.types.password'}} - - - {{t 'resources.auth-method.types.oidc'}} - - - {{/if}} + {{t 'resources.auth-method.types.password'}} + + + {{t 'resources.auth-method.types.oidc'}} + + {{/if}} @@ -168,11 +165,13 @@ as |message| > - {{#if (can 'list collection' this.scope collection='auth-methods')}} + {{#if + (can 'list collection' this.scopeModel collection='auth-methods') + }} {{! can list (at least): show default welcome message}} {{t 'resources.auth-method.messages.welcome.description'}} {{else if (can - 'create collection' this.scope collection='auth-methods' + 'create collection' this.scopeModel collection='auth-methods' )}} {{! can create (only): show create-but-not-list welcome message}} {{t @@ -187,15 +186,6 @@ }} {{/if}} - {{#if (can 'create collection' this.scope collection='auth-methods')}} - - - {{t 'titles.new'}} - - {{/if}} diff --git a/ui/admin/app/templates/scopes/scope/scopes/index.hbs b/ui/admin/app/templates/scopes/scope/scopes/index.hbs index 18134a990..4194cdc24 100644 --- a/ui/admin/app/templates/scopes/scope/scopes/index.hbs +++ b/ui/admin/app/templates/scopes/scope/scopes/index.hbs @@ -67,10 +67,14 @@ {{t 'resources.org.description'}} - - - {{t 'titles.new'}} - + {{#if + (can 'create collection' @model.currentScope collection='scopes') + }} + + + {{t 'titles.new'}} + + {{/if}} {{/if}}