{{! Copyright (c) HashiCorp, Inc. SPDX-License-Identifier: MPL-2.0 }}

{{t 'resources.auth-method.title_plural'}}

{{t 'resources.auth-method.description'}}

{{#if (can 'create model' this.scopeModel collection='auth-methods')}} {{#if (feature-flag 'ldap-auth-methods')}} {{/if}} {{/if}} {{#if @model}} {{#unless this.hasPrimaryAuthMethod}} {{t 'resources.auth-method.messages.no-primary-auth-method.title'}} {{t 'resources.auth-method.messages.no-primary-auth-method.description' }} {{/unless}} {{/if}} {{#if (or @model (has-resource-filter-selections 'scopes.scope.auth-methods' 'type') ) }} {{#let (resource-filter 'scopes.scope.auth-methods' 'type') as |filter| }} {{/let}} {{#if (has-resource-filter-selections 'scopes.scope.auth-methods' 'type') }} {{t 'actions.clear-all-filters'}} {{/if}} {{/if}} {{#if @model}} <:body as |B|> {{#if (can 'read auth-method' B.data)}} {{B.data.displayName}} {{else}} {{B.data.displayName}} {{/if}}

{{B.data.description}}

{{#if B.data.isPrimary}} {{/if}} {{#if (can 'makePrimary auth-method' B.data)}} {{#unless B.data.isPrimary}} {{/unless}} {{#if B.data.isPrimary}} {{/if}} {{/if}}
{{else if (has-resource-filter-selections 'scopes.scope.auth-methods' 'type') }} {{t 'descriptions.no-results'}} {{else}} {{#if (can 'list model' this.scopeModel collection='auth-methods')}} {{! can list (at least): show default welcome message}} {{t 'resources.auth-method.messages.welcome.description'}} {{else if (can 'create model' this.scopeModel collection='auth-methods') }} {{! can create (only): show create-but-not-list welcome message}} {{t 'descriptions.create-but-not-list' resource=(t 'resources.auth-method.title_plural') }} {{else}} {{! can neither list nor create }} {{t 'descriptions.neither-list-nor-create' resource=(t 'resources.auth-method.title_plural') }} {{/if}} {{/if}}