FIX: Don't show the Quote popup if posting is disabled
This commit is contained in:
parent
10723ba1c2
commit
e37c4a4525
|
@ -70,6 +70,15 @@ export default Ember.Controller.extend(BufferedContent, {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@computed("model.details.can_create_post")
|
||||||
|
embedQuoteButton(canCreatePost) {
|
||||||
|
return (
|
||||||
|
canCreatePost &&
|
||||||
|
this.currentUser &&
|
||||||
|
this.currentUser.get("enable_quoting")
|
||||||
|
);
|
||||||
|
},
|
||||||
|
|
||||||
@computed("model.postStream.loaded", "model.category_id")
|
@computed("model.postStream.loaded", "model.category_id")
|
||||||
showSharedDraftControls(loaded, categoryId) {
|
showSharedDraftControls(loaded, categoryId) {
|
||||||
let draftCat = this.site.shared_drafts_category_id;
|
let draftCat = this.site.shared_drafts_category_id;
|
||||||
|
|
|
@ -322,7 +322,7 @@
|
||||||
|
|
||||||
{{share-popup topic=model replyAsNewTopic="replyAsNewTopic"}}
|
{{share-popup topic=model replyAsNewTopic="replyAsNewTopic"}}
|
||||||
|
|
||||||
{{#if currentUser.enable_quoting}}
|
{{#if embedQuoteButton}}
|
||||||
{{quote-button quoteState=quoteState selectText=(action "selectText")}}
|
{{quote-button quoteState=quoteState selectText=(action "selectText")}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{/discourse-topic}}
|
{{/discourse-topic}}
|
||||||
|
|
Loading…
Reference in New Issue