All checks were successful
Plugins that require configuration (Twitter/Instagram expanders, Domain Blocker) can now have an app-wide default that each channel inherits and overrides only where needed. - model: add GlobalPluginConfig and MergeConfig (blank channel value inherits the global value) - migration: add global_plugin_config table (#5) - db: GetGlobalPluginConfig, GetAllGlobalPluginConfigs, SetGlobalPluginConfig - app: merge global + channel config per message - admin: /admin/plugins/config/<id> global config page, shared buildPluginConfigFromForm helper and _fields.html partial; channel form shows inherited global value as placeholder - docs: document global vs per-channel plugin configuration
53 lines
No EOL
2.2 KiB
HTML
53 lines
No EOL
2.2 KiB
HTML
{{define "content"}}
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<div class="card">
|
|
<div class="card-header">
|
|
<h3 class="card-title">Available Plugins</h3>
|
|
</div>
|
|
<div class="card-body">
|
|
<div class="table-responsive">
|
|
<table class="table table-vcenter card-table">
|
|
<thead>
|
|
<tr>
|
|
<th>ID</th>
|
|
<th>Name</th>
|
|
<th>Help</th>
|
|
<th>Requires Config</th>
|
|
<th>Global Config</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{{range $id, $plugin := .Plugins}}
|
|
<tr>
|
|
<td>{{$id}}</td>
|
|
<td>{{$plugin.GetName}}</td>
|
|
<td>{{$plugin.GetHelp}}</td>
|
|
<td>
|
|
{{if $plugin.RequiresConfig}}
|
|
<span class="badge bg-yellow">Yes</span>
|
|
{{else}}
|
|
<span class="badge bg-green">No</span>
|
|
{{end}}
|
|
</td>
|
|
<td>
|
|
{{if $plugin.RequiresConfig}}
|
|
<a href="/admin/plugins/config/{{$id}}" class="btn btn-sm btn-primary">Configure</a>
|
|
{{else}}
|
|
<span class="text-muted">—</span>
|
|
{{end}}
|
|
</td>
|
|
</tr>
|
|
{{else}}
|
|
<tr>
|
|
<td colspan="5" class="text-center">No plugins found</td>
|
|
</tr>
|
|
{{end}}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{{end}} |