diff options
author | Corey Hulen <corey@hulen.com> | 2015-07-01 22:19:58 -0800 |
---|---|---|
committer | Corey Hulen <corey@hulen.com> | 2015-07-01 22:19:58 -0800 |
commit | d3efefba1f7d4c5f09f61227c49db9229cc65553 (patch) | |
tree | f122ed069ce178429b131eb4ede31209d83e86c5 /web/react/components/search_results.jsx | |
parent | 03d7fb1ff276393f79923f06570035389b7ed261 (diff) | |
parent | fd310e382a2cc1a9779ef28dee7fea9476bb425f (diff) | |
download | chat-d3efefba1f7d4c5f09f61227c49db9229cc65553.tar.gz chat-d3efefba1f7d4c5f09f61227c49db9229cc65553.tar.bz2 chat-d3efefba1f7d4c5f09f61227c49db9229cc65553.zip |
Merge pull request #92 from nickago/MM-1151
MM-1151 clickable search results
Diffstat (limited to 'web/react/components/search_results.jsx')
-rw-r--r-- | web/react/components/search_results.jsx | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/web/react/components/search_results.jsx b/web/react/components/search_results.jsx index 51aefd3b8..15c2b37a2 100644 --- a/web/react/components/search_results.jsx +++ b/web/react/components/search_results.jsx @@ -43,6 +43,7 @@ SearchItem = React.createClass({ e.preventDefault(); var self = this; + client.getPost( this.props.post.channel_id, this.props.post.id, @@ -64,6 +65,11 @@ SearchItem = React.createClass({ dispatchError(err, "getPost"); } ); + + var postChannel = ChannelStore.get(this.props.post.channel_id); + var teammate = postChannel.type === 'D' ? utils.getDirectTeammate(this.props.post.channel_id).username : ""; + + utils.switchChannel(postChannel,teammate); }, render: function() { |