FEATURE: suppress admin glyph for admins
If you want to a shield you must grant moderation to the admin.
This commit is contained in:
parent
70eb7b8fdf
commit
5cb7c8ee11
|
@ -83,10 +83,7 @@ var PosterNameComponent = Em.Component.extend({
|
|||
posterGlyph: function(post) {
|
||||
var desc;
|
||||
|
||||
if(post.get('admin')) {
|
||||
desc = I18n.t('user.admin_tooltip');
|
||||
return '<i class="fa fa-shield" title="' + desc + '" alt="' + desc + '"></i>';
|
||||
} else if(post.get('moderator')) {
|
||||
if(post.get('moderator')) {
|
||||
desc = I18n.t('user.moderator_tooltip');
|
||||
return '<i class="fa fa-shield" title="' + desc + '" alt="' + desc + '"></i>';
|
||||
}
|
||||
|
|
|
@ -79,9 +79,11 @@ Discourse.User = Discourse.Model.extend({
|
|||
var name = Handlebars.Utils.escapeExpression(this.get('name')),
|
||||
desc;
|
||||
|
||||
if(this.get('admin')) {
|
||||
desc = I18n.t('user.admin', {user: name});
|
||||
return '<i class="fa fa-shield" title="' + desc + '" alt="' + desc + '"></i>';
|
||||
if(Discourse.User.currentProp("admin") || Discourse.User.currentProp("moderator")) {
|
||||
if(this.get('admin')) {
|
||||
desc = I18n.t('user.admin', {user: name});
|
||||
return '<i class="fa fa-shield" title="' + desc + '" alt="' + desc + '"></i>';
|
||||
}
|
||||
}
|
||||
if(this.get('moderator')){
|
||||
desc = I18n.t('user.moderator', {user: name});
|
||||
|
|
Loading…
Reference in New Issue