FIX: Only show undelete button when the topic is deleted
This commit is contained in:
parent
50238d71c8
commit
86c884aa29
|
@ -16,6 +16,8 @@ Discourse.TopicAdminMenuController = Discourse.ObjectController.extend({
|
|||
|
||||
hide: function() {
|
||||
this.set('menuVisible', false);
|
||||
}
|
||||
},
|
||||
|
||||
showRecover: Em.computed.and('deleted', 'details.can_recover'),
|
||||
|
||||
});
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if details.can_recover}}
|
||||
{{#if showRecover}}
|
||||
<li>
|
||||
<button {{action recoverTopic}} class='btn btn-admin'><i class='icon-undo'></i> {{i18n topic.actions.recover}}</button>
|
||||
</li>
|
||||
|
|
Loading…
Reference in New Issue