mirror of
https://github.com/discourse/discourse.git
synced 2024-11-29 01:43:45 +08:00
371bbadb92
* Run no-implicit-this codemod for app templates * Run tagless-ember-components-codemod for plugins * Turn on no-implicit-this lint
37 lines
1.3 KiB
Handlebars
37 lines
1.3 KiB
Handlebars
<DModalBody @title="admin.user.suspend_modal_title">
|
|
<ConditionalLoadingSpinner @condition={{this.loadingUser}}>
|
|
|
|
{{#if this.errorMessage}}
|
|
<div class="alert alert-error">{{this.errorMessage}}</div>
|
|
{{/if}}
|
|
|
|
{{#if this.user.canSuspend}}
|
|
<AdminPenaltyHistory @user={{this.user}} />
|
|
|
|
<div class="until-controls">
|
|
<label>
|
|
<FutureDateInput @class="suspend-until" @label="admin.user.suspend_duration" @clearable={{false}} @input={{this.suspendUntil}} @onChangeInput={{action (mut this.suspendUntil)}} />
|
|
</label>
|
|
</div>
|
|
<SuspensionDetails @reason={{this.reason}} @message={{this.message}} />
|
|
|
|
{{#if this.postId}}
|
|
<PenaltyPostAction @postId={{this.postId}} @postAction={{this.postAction}} @postEdit={{this.postEdit}} />
|
|
{{/if}}
|
|
|
|
{{else}}
|
|
<div class="cant-suspend">
|
|
{{i18n "admin.user.cant_suspend"}}
|
|
</div>
|
|
{{/if}}
|
|
|
|
</ConditionalLoadingSpinner>
|
|
|
|
</DModalBody>
|
|
|
|
<div class="modal-footer">
|
|
<DButton @class="btn-danger perform-suspend" @action={{action "suspend"}} @disabled={{this.submitDisabled}} @icon="ban" @label="admin.user.suspend" />
|
|
<DModalCancel @close={{route-action "closeModal"}} />
|
|
<ConditionalLoadingSpinner @condition={{this.loading}} @size="small" />
|
|
</div>
|