open-vault/ui/app/templates/components/identity/item-details.hbs
Angel Garbarino 5ce35d1c52
Updating date-fns library from 1.x to 2.x (#10848)
* first round of fixes and setup

* test fixes

* fix dumb options on new method

* test fix

* clean up

* fixes

* clean up

* handle utc time

* add changelog
2021-02-08 13:13:00 -07:00

37 lines
1.4 KiB
Handlebars

<div class="box is-shadowless is-marginless is-fullwidth">
{{#if model.disabled}}
<AlertBanner
@type="warning"
@title="Attention"
@message="This {{model.identityType}} is disabled. All associated tokens cannot be used, but are not revoked."
data-test-disabled-warning>
{{#if model.canEdit}}
<button onclick={{action 'enable' model}} type="button" class="link" data-test-enable=true>
Enable
</button>
{{/if}}
</AlertBanner>
{{/if}}
<InfoTableRow @label="Name" @value={{model.name}} @data-test-identity-item-name={{true}} />
<InfoTableRow @label="Type" @value={{model.type}} />
<InfoTableRow @label="ID" @value={{model.id}} />
<InfoTableRow @label="Merged Ids" @value={{model.mergedEntityIds}}>
<div>
{{#each model.mergedEntityIds as |id|}}
<div>
<code class="has-text-black">{{id}}</code>
</div>
{{/each}}
</div>
</InfoTableRow>
<InfoTableRow @label="Created" @value={{model.creationTime}}>
<time datetime={{model.creationTime}} title={{model.creationTime}}>
{{date-format model.creationTime 'MMM dd, yyyy [at] h:mm a'}}
</time>
</InfoTableRow>
<InfoTableRow @label="Last Updated" @value={{model.lastUpdateTime}}>
<time datetime={{model.lastUpdateTime}} title={{model.lastUpdateTime}}>
{{date-format model.lastUpdateTime 'MMM dd, yyyy [at] h:mm a'}}
</time>
</InfoTableRow>
</div>