mirror of
https://github.com/discourse/discourse.git
synced 2025-05-23 21:41:26 +08:00
Add some plugin outlets to the user card
This commit is contained in:
@ -270,6 +270,10 @@ export default Ember.Component.extend(CleansUp, CanCheckEmails, {
|
|||||||
},
|
},
|
||||||
|
|
||||||
actions: {
|
actions: {
|
||||||
|
close() {
|
||||||
|
this._close();
|
||||||
|
},
|
||||||
|
|
||||||
cancelFilter() {
|
cancelFilter() {
|
||||||
const postStream = this.get('postStream');
|
const postStream = this.get('postStream');
|
||||||
postStream.cancelFilter();
|
postStream.cancelFilter();
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
<h1 class="{{staff}} {{new_user}} {{if nameFirst "full-name" "username"}}">
|
<h1 class="{{staff}} {{new_user}} {{if nameFirst "full-name" "username"}}">
|
||||||
<a href={{user.path}} {{action "showUser"}}>{{if nameFirst user.name (format-username username)}} {{user-status user currentUser=currentUser}}</a>
|
<a href={{user.path}} {{action "showUser"}}>{{if nameFirst user.name (format-username username)}} {{user-status user currentUser=currentUser}}</a>
|
||||||
</h1>
|
</h1>
|
||||||
|
{{plugin-outlet name="user-card-after-username" args=(hash user=user) tagName=''}}
|
||||||
|
|
||||||
{{#unless nameFirst}}
|
{{#unless nameFirst}}
|
||||||
{{#if user.name}}
|
{{#if user.name}}
|
||||||
@ -78,11 +79,15 @@
|
|||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</ul>
|
</ul>
|
||||||
|
{{plugin-outlet
|
||||||
|
name="user-card-additional-controls"
|
||||||
|
args=(hash user=user close=(action "close"))
|
||||||
|
tagName=""}}
|
||||||
|
|
||||||
{{#if isSuspended}}
|
{{#if isSuspended}}
|
||||||
<div class='suspended'>
|
<div class='suspended'>
|
||||||
{{d-icon "ban"}}
|
{{d-icon "ban"}}
|
||||||
<b>{{i18n 'user.suspended_notice' date=user.suspendedTillDate}}</b><br/>
|
<b>{{i18n 'user.suspended_notice' date=user.suspendedTillDate}}</b><br>
|
||||||
<b>{{i18n 'user.suspended_reason'}}</b> {{user.suspend_reason}}
|
<b>{{i18n 'user.suspended_reason'}}</b> {{user.suspend_reason}}
|
||||||
</div>
|
</div>
|
||||||
{{else}}
|
{{else}}
|
||||||
|
Reference in New Issue
Block a user