discourse/app/assets/javascripts/admin/templates/plugins-index.hbs

Failed to ignore revisions in .git-blame-ignore-revs.

66 lines
2.1 KiB
Handlebars
Raw Normal View History

{{#if model.length}}
<h3>{{i18n "admin.plugins.installed"}}</h3>
2018-07-03 11:14:53 +08:00
<table class="admin-plugins grid">
2015-05-14 00:13:25 +08:00
<thead>
<tr>
<th></th>
2015-05-14 00:13:25 +08:00
<th>{{i18n "admin.plugins.name"}}</th>
<th>{{i18n "admin.plugins.version"}}</th>
<th>{{i18n "admin.plugins.enabled"}}</th>
<th></th>
2015-05-14 00:13:25 +08:00
</tr>
</thead>
<tbody>
{{#each model as |plugin|}}
<tr>
<td>
{{#if plugin.is_official}}
{{d-icon "check-circle"
title="admin.plugins.official"
class="admin-plugins-official-badge"}}
{{/if}}
</td>
2018-07-03 11:14:53 +08:00
<td class="plugin-name">
{{#if plugin.url}}
<a href={{plugin.url}} rel="noopener noreferrer" target="_blank">{{plugin.name}}</a>
{{else}}
{{plugin.name}}
{{/if}}
</td>
<td class="version">
<div class="label">{{i18n "admin.plugins.version"}}</div>
{{plugin.version}}
</td>
<td class="col-enabled">
2018-07-03 11:14:53 +08:00
<div class="label">{{i18n "admin.plugins.enabled"}}</div>
{{#if plugin.enabled_setting}}
{{#if plugin.enabled}}
{{i18n "admin.plugins.is_enabled"}}
{{else}}
{{i18n "admin.plugins.not_enabled"}}
{{/if}}
{{else}}
{{i18n "admin.plugins.is_enabled"}}
{{/if}}
</td>
2018-07-03 11:14:53 +08:00
<td class="settings">
{{#if currentUser.admin}}
{{#if plugin.enabled_setting}}
2019-01-22 19:02:02 +08:00
{{d-button class="btn-default" action=(route-action "showSettings") actionParam=plugin icon="cog" label="admin.plugins.change_settings_short"}}
{{/if}}
{{/if}}
</td>
</tr>
{{/each}}
</tbody>
</table>
{{else}}
<p>{{i18n "admin.plugins.none_installed"}}</p>
{{/if}}
<p class="admin-plugins-howto"><a href="https://meta.discourse.org/t/install-a-plugin/19157">{{i18n "admin.plugins.howto"}}</a></p>
{{plugin-outlet name="admin-below-plugins-index" args=(hash model=model)}}