mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 15:48:43 -05:00
FIX: private message button wasn't adding the recipient (cc @gdpelican)
This commit is contained in:
parent
f9f54e2626
commit
0f0a329e7c
3 changed files with 3 additions and 3 deletions
|
@ -15,7 +15,7 @@ var ApplicationRoute = Discourse.Route.extend({
|
|||
composePrivateMessage: function(user) {
|
||||
var self = this;
|
||||
this.transitionTo('userActivity', user).then(function () {
|
||||
self.controllerFor('user-activity').send('composePrivateMessage');
|
||||
self.controllerFor('user-activity').send('composePrivateMessage', user);
|
||||
});
|
||||
},
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ export default Discourse.Route.extend({
|
|||
},
|
||||
|
||||
composePrivateMessage: function(user) {
|
||||
var recipient = user ? user.username : '';
|
||||
var recipient = user ? user.get('username') : '';
|
||||
return this.controllerFor('composer').open({
|
||||
action: Discourse.Composer.PRIVATE_MESSAGE,
|
||||
usernames: recipient,
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
<ul>
|
||||
{{#if can_send_private_message_to_user}}
|
||||
<li>
|
||||
<a class='btn btn-primary right' {{action "composePrivateMessage"}}>
|
||||
<a class='btn btn-primary right' {{action "composePrivateMessage" model}}>
|
||||
{{fa-icon "envelope"}}
|
||||
{{i18n user.private_message}}
|
||||
</a>
|
||||
|
|
Loading…
Reference in a new issue