Ghost/ghost/admin/app/components/settings/audit-log/table.hbs

48 lines
2.1 KiB
Handlebars
Raw Normal View History

<table class="gh-list">
<thead>
<tr>
<th>User</th>
<th>Action</th>
<th>When</th>
</tr>
</thead>
<tbody>
{{#each @events as |event|}}
{{#let (parse-audit-log-event event) as |ev|}}
<tr>
<div class="gh-list-data gh-list-cellwidth-30">
<div class="flex items-center">
<span class="user-list-item-figure" style={{background-image-style (or ev.actor.profileImageUrl ev.actor.iconImage)}}>
<span class="hidden">Photo of {{ev.actor.name}}</span>
</span>
<h3 class="ma0 pa0 gh-members-list-name">{{ev.actor.name}}</h3>
</div>
</div>
<div class="gh-list-data gh-list-cellwidth-50">
<div class="gh-members-activity-container">
<div class="gh-members-activity-icon">{{svg-jar ev.actionIcon}}</div>
<div class="gh-members-activity-event">
<span class="gh-members-activity-description">
{{capitalize-first-letter ev.action}}
{{#if (or ev.resource.title ev.resource.name)}}
{{#if ev.linkable}}
<LinkTo @route="editor.edit" @models={{array ev.resource.displayName ev.resource.id}} class="permalink">
<strong>{{or ev.resource.title ev.resource.name}}</strong>
</LinkTo>
{{else}}
<strong>{{or ev.resource.title ev.resource.name}}</strong>
{{/if}}
{{else}}
<small>(unknown)</small>
{{/if}}
</span>
</div>
</div>
</div>
<div class="gh-list-data">{{moment-format ev.original.created_at "DD MMM YYYY HH:mm:ss"}}</div>
</tr>
{{/let}}
{{/each}}
</tbody>
</table>