mirror of
https://github.com/discourse/discourse.git
synced 2025-02-27 16:06:10 +00:00
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() {
|
hide: function() {
|
||||||
this.set('menuVisible', false);
|
this.set('menuVisible', false);
|
||||||
}
|
},
|
||||||
|
|
||||||
|
showRecover: Em.computed.and('deleted', 'details.can_recover'),
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
{{#if details.can_recover}}
|
{{#if showRecover}}
|
||||||
<li>
|
<li>
|
||||||
<button {{action recoverTopic}} class='btn btn-admin'><i class='icon-undo'></i> {{i18n topic.actions.recover}}</button>
|
<button {{action recoverTopic}} class='btn btn-admin'><i class='icon-undo'></i> {{i18n topic.actions.recover}}</button>
|
||||||
</li>
|
</li>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user