mirror of
https://github.com/discourse/discourse.git
synced 2025-02-20 11:48:26 -06:00
DEV: Add outlet wrapper for user badges form (#29333)
* DEV: Add outlet wrapper for user badges form * Add outlet for badge granter table * add extra args to outlet
This commit is contained in:
parent
2f1d1cd062
commit
0ecad3a7c9
@ -16,6 +16,13 @@
|
||||
{{#if this.noAvailableBadges}}
|
||||
<p>{{i18n "admin.badges.no_badges"}}</p>
|
||||
{{else}}
|
||||
<PluginOutlet
|
||||
@name="badge-granter-form"
|
||||
@outletArgs={{hash
|
||||
availableBadges=this.availableBadges
|
||||
userBadges=this.userBadges
|
||||
}}
|
||||
>
|
||||
<form class="form-horizontal">
|
||||
<div class="control-group">
|
||||
<label>{{i18n "admin.badges.badge"}}</label>
|
||||
@ -28,9 +35,8 @@
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label>{{i18n "admin.badges.reason"}}</label>
|
||||
<Input @type="text" @value={{this.badgeReason}} /><br /><small>{{i18n
|
||||
"admin.badges.reason_help"
|
||||
}}</small>
|
||||
<Input @type="text" @value={{this.badgeReason}} /><br /><small
|
||||
>{{i18n "admin.badges.reason_help"}}</small>
|
||||
</div>
|
||||
<DButton
|
||||
@action={{this.performGrantBadge}}
|
||||
@ -39,8 +45,17 @@
|
||||
class="btn-primary"
|
||||
/>
|
||||
</form>
|
||||
</PluginOutlet>
|
||||
{{/if}}
|
||||
|
||||
<PluginOutlet
|
||||
@name="badge-granter-table"
|
||||
@outletArgs={{hash
|
||||
groupedBadges=this.groupedBadges
|
||||
revokeBadge=this.revokeBadge
|
||||
expandGroup=this.expandGroup
|
||||
}}
|
||||
>
|
||||
<table id="user-badges">
|
||||
<tbody>
|
||||
<tr>
|
||||
@ -95,5 +110,6 @@
|
||||
{{/each}}
|
||||
</tbody>
|
||||
</table>
|
||||
</PluginOutlet>
|
||||
</div>
|
||||
</ConditionalLoadingSpinner>
|
Loading…
Reference in New Issue
Block a user