2019-07-01 20:35:18 +00:00
|
|
|
<PageHeader as |p|>
|
|
|
|
<p.top>
|
2021-12-17 03:44:29 +00:00
|
|
|
<KeyValueHeader @path="vault.cluster.access.methods">
|
2019-07-01 20:35:18 +00:00
|
|
|
<li>
|
|
|
|
<span class="sep">
|
|
|
|
/
|
|
|
|
</span>
|
2021-12-17 03:44:29 +00:00
|
|
|
<LinkTo @route="vault.cluster.access.methods">
|
2019-07-01 20:35:18 +00:00
|
|
|
methods
|
2021-12-17 03:44:29 +00:00
|
|
|
</LinkTo>
|
2019-07-01 20:35:18 +00:00
|
|
|
</li>
|
2021-12-17 03:44:29 +00:00
|
|
|
</KeyValueHeader>
|
2019-07-01 20:35:18 +00:00
|
|
|
</p.top>
|
|
|
|
<p.levelLeft>
|
|
|
|
<h1 class="title is-3">
|
2021-12-17 03:44:29 +00:00
|
|
|
{{this.methodModel.id}}
|
2019-07-01 20:35:18 +00:00
|
|
|
</h1>
|
|
|
|
</p.levelLeft>
|
|
|
|
</PageHeader>
|
2021-12-17 03:44:29 +00:00
|
|
|
{{#with (tabs-for-auth-section this.methodModel "authConfig" this.paths) as |tabs|}}
|
2019-10-17 23:19:14 +00:00
|
|
|
{{#if tabs.length}}
|
|
|
|
<div class="tabs-container box is-sideless is-fullwidth is-paddingless is-marginless">
|
|
|
|
<nav class="tabs">
|
|
|
|
<ul>
|
|
|
|
{{#each tabs as |tab|}}
|
2021-12-17 03:44:29 +00:00
|
|
|
{{! template-lint-configure no-curly-component-invocation "warn" }}
|
|
|
|
{{#link-to params=tab.routeParams tagName="li" data-test-auth-section-tab=true}}
|
2019-10-17 23:19:14 +00:00
|
|
|
{{#link-to params=tab.routeParams}}
|
|
|
|
{{tab.label}}
|
|
|
|
{{/link-to}}
|
|
|
|
{{/link-to}}
|
2021-12-17 03:44:29 +00:00
|
|
|
{{! template-lint-configure no-curly-component-invocation "on" }}
|
2019-10-17 23:19:14 +00:00
|
|
|
{{/each}}
|
|
|
|
</ul>
|
|
|
|
</nav>
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
{{/with}}
|
2019-07-01 20:35:18 +00:00
|
|
|
<Toolbar>
|
|
|
|
<ToolbarActions>
|
2019-10-17 23:19:14 +00:00
|
|
|
<ToolbarLink
|
2021-12-17 03:44:29 +00:00
|
|
|
@data-test-entity-create-link={{this.itemType}}
|
2019-10-17 23:19:14 +00:00
|
|
|
@type="add"
|
2021-12-17 03:44:29 +00:00
|
|
|
@params={{array "vault.cluster.access.method.item.create" this.itemType}}
|
|
|
|
>
|
2019-07-01 20:35:18 +00:00
|
|
|
Create
|
2021-12-17 03:44:29 +00:00
|
|
|
{{singularize this.itemType}}
|
2019-07-01 20:35:18 +00:00
|
|
|
</ToolbarLink>
|
|
|
|
</ToolbarActions>
|
|
|
|
</Toolbar>
|
2021-12-17 03:44:29 +00:00
|
|
|
<ListView
|
|
|
|
@items={{this.model}}
|
|
|
|
@itemNoun={{this.itemType}}
|
|
|
|
@paginationRouteName="vault.cluster.access.method.item.list"
|
|
|
|
as |list|
|
|
|
|
>
|
2019-07-01 20:35:18 +00:00
|
|
|
{{#if list.empty}}
|
2021-12-17 03:44:29 +00:00
|
|
|
<list.empty
|
|
|
|
@title="No {{pluralize this.itemType}} yet"
|
|
|
|
@message="A list of {{pluralize
|
|
|
|
this.itemType
|
|
|
|
}} will be listed here. Create your first {{this.itemType}} to get started."
|
|
|
|
>
|
|
|
|
{{! template-lint-configure no-curly-component-invocation "warn" }}
|
|
|
|
{{! template-lint-configure no-link-to-positional-params "warn" }}
|
|
|
|
{{#link-to "vault.cluster.access.method.item.create" this.itemType class="link"}}
|
|
|
|
Create
|
|
|
|
{{singularize this.itemType}}
|
2019-07-01 20:35:18 +00:00
|
|
|
{{/link-to}}
|
2021-12-17 03:44:29 +00:00
|
|
|
{{! template-lint-configure no-curly-component-invocation "on" }}
|
|
|
|
{{! template-lint-configure no-link-to-positional-params "on" }}
|
2019-07-01 20:35:18 +00:00
|
|
|
</list.empty>
|
|
|
|
{{else if list.item}}
|
2021-12-17 03:44:29 +00:00
|
|
|
<ListItem @linkParams={{array "vault.cluster.access.method.item.show" this.itemType list.item.id}} as |Item|>
|
2019-07-01 20:35:18 +00:00
|
|
|
<Item.content>
|
2021-12-07 17:05:14 +00:00
|
|
|
<Icon @name="folder" class="has-text-grey-light" />{{list.item.id}}
|
2019-07-01 20:35:18 +00:00
|
|
|
</Item.content>
|
2019-10-17 23:19:14 +00:00
|
|
|
<Item.menu as |Menu|>
|
2019-07-01 20:35:18 +00:00
|
|
|
<li class="action">
|
2021-12-17 03:44:29 +00:00
|
|
|
{{! template-lint-configure no-curly-component-invocation "warn" }}
|
|
|
|
{{! template-lint-configure no-link-to-positional-params "warn" }}
|
2019-07-01 20:35:18 +00:00
|
|
|
{{#link-to "vault.cluster.access.method.item.show" list.item.id class="is-block"}}
|
2021-12-17 03:44:29 +00:00
|
|
|
View
|
|
|
|
{{singularize this.itemType}}
|
2019-07-01 20:35:18 +00:00
|
|
|
{{/link-to}}
|
|
|
|
</li>
|
|
|
|
<li class="action">
|
|
|
|
{{#link-to "vault.cluster.access.method.item.edit" list.item.id class="is-block"}}
|
2021-12-17 03:44:29 +00:00
|
|
|
Edit
|
|
|
|
{{singularize this.itemType}}
|
2019-07-01 20:35:18 +00:00
|
|
|
{{/link-to}}
|
2021-12-17 03:44:29 +00:00
|
|
|
{{! template-lint-configure no-curly-component-invocation "on" }}
|
|
|
|
{{! template-lint-configure no-link-to-positional-params "on" }}
|
2019-07-01 20:35:18 +00:00
|
|
|
</li>
|
|
|
|
<li>
|
2019-10-17 23:19:14 +00:00
|
|
|
<Menu.Message
|
|
|
|
@id={{list.item.id}}
|
|
|
|
@buttonClasses="link is-destroy"
|
|
|
|
@onConfirm={{action
|
|
|
|
(perform
|
|
|
|
Item.callMethod
|
|
|
|
"destroyRecord"
|
|
|
|
list.item
|
2021-12-17 03:44:29 +00:00
|
|
|
(concat "Successfully deleted " (singularize this.itemType) " " list.item.id ".")
|
|
|
|
(concat "There was an error deleting this " (singularize this.itemType))
|
2019-10-17 23:19:14 +00:00
|
|
|
(action "refreshItemList")
|
|
|
|
)
|
|
|
|
}}
|
2021-12-17 03:44:29 +00:00
|
|
|
@message={{concat "Are you sure you want to delete " (singularize this.itemType) " " list.item.id "?"}}
|
2019-10-17 23:19:14 +00:00
|
|
|
data-test-secret-delete="true"
|
2021-12-17 03:44:29 +00:00
|
|
|
@triggerText={{concat "Delete " (singularize this.itemType)}}
|
|
|
|
/>
|
2019-07-01 20:35:18 +00:00
|
|
|
</li>
|
|
|
|
</Item.menu>
|
|
|
|
</ListItem>
|
|
|
|
{{/if}}
|
2021-12-17 03:44:29 +00:00
|
|
|
</ListView>
|