Remove unncessary CP
This commit is contained in:
parent
abc41c7d5b
commit
7b8e313dac
|
@ -2,7 +2,6 @@ import computed from 'ember-addons/ember-computed-decorators';
|
||||||
import Topic from 'discourse/models/topic';
|
import Topic from 'discourse/models/topic';
|
||||||
|
|
||||||
export default Ember.Controller.extend({
|
export default Ember.Controller.extend({
|
||||||
|
|
||||||
needs: ["application", "user-topics-list", "user"],
|
needs: ["application", "user-topics-list", "user"],
|
||||||
pmView: false,
|
pmView: false,
|
||||||
viewingSelf: Em.computed.alias('controllers.user.viewingSelf'),
|
viewingSelf: Em.computed.alias('controllers.user.viewingSelf'),
|
||||||
|
@ -11,10 +10,6 @@ export default Ember.Controller.extend({
|
||||||
selected: Em.computed.alias('controllers.user-topics-list.selected'),
|
selected: Em.computed.alias('controllers.user-topics-list.selected'),
|
||||||
bulkSelectEnabled: Em.computed.alias('controllers.user-topics-list.bulkSelectEnabled'),
|
bulkSelectEnabled: Em.computed.alias('controllers.user-topics-list.bulkSelectEnabled'),
|
||||||
|
|
||||||
mobileView: function() {
|
|
||||||
return this.site.mobileView;
|
|
||||||
}.property(),
|
|
||||||
|
|
||||||
showNewPM: function(){
|
showNewPM: function(){
|
||||||
return this.get('controllers.user.viewingSelf') &&
|
return this.get('controllers.user.viewingSelf') &&
|
||||||
Discourse.User.currentProp('can_send_private_messages');
|
Discourse.User.currentProp('can_send_private_messages');
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
<section class='user-navigation'>
|
<section class='user-navigation'>
|
||||||
{{#unless mobileView}}
|
{{#unless site.mobileView}}
|
||||||
{{#if showNewPM}}
|
{{#if showNewPM}}
|
||||||
{{d-button class="btn-primary new-private-message" action="composePrivateMessage" icon="envelope" label="user.new_private_message"}}
|
{{d-button class="btn-primary new-private-message" action="composePrivateMessage" icon="envelope" label="user.new_private_message"}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{/unless}}
|
{{/unless}}
|
||||||
|
|
||||||
{{#mobile-nav class='messages-nav' desktopClass='nav-stacked action-list' currentPath=currentPath}}
|
{{#mobile-nav class='messages-nav' desktopClass='nav-stacked action-list' currentPath=currentPath}}
|
||||||
|
@ -47,10 +47,10 @@
|
||||||
<i class="fa fa-list"></i>
|
<i class="fa fa-list"></i>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
{{#if mobileView}}
|
{{#if site.mobileView}}
|
||||||
{{#if showNewPM}}
|
{{#if showNewPM}}
|
||||||
{{d-button class="btn-primary new-private-message" action="composePrivateMessage" icon="envelope" label="user.new_private_message"}}
|
{{d-button class="btn-primary new-private-message" action="composePrivateMessage" icon="envelope" label="user.new_private_message"}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
{{#if canArchive}}
|
{{#if canArchive}}
|
||||||
|
|
Loading…
Reference in New Issue