summaryrefslogtreecommitdiffstats
path: root/web/react/components/new_channel.jsx
diff options
context:
space:
mode:
Diffstat (limited to 'web/react/components/new_channel.jsx')
-rw-r--r--web/react/components/new_channel.jsx8
1 files changed, 5 insertions, 3 deletions
diff --git a/web/react/components/new_channel.jsx b/web/react/components/new_channel.jsx
index 160241c1c..49e088458 100644
--- a/web/react/components/new_channel.jsx
+++ b/web/react/components/new_channel.jsx
@@ -6,6 +6,8 @@ var utils = require('../utils/utils.jsx');
var client = require('../utils/client.jsx');
var asyncClient = require('../utils/async_client.jsx');
var UserStore = require('../stores/user_store.jsx');
+var TeamStore = require('../stores/team_store.jsx');
+var Constants = require('../utils/constants.jsx');
module.exports = React.createClass({
handleSubmit: function(e) {
@@ -60,13 +62,13 @@ module.exports = React.createClass({
var self = this;
client.createChannel(channel,
- function(data) {
+ function() {
this.refs.display_name.getDOMNode().value = "";
this.refs.channel_name.getDOMNode().value = "";
this.refs.channel_desc.getDOMNode().value = "";
$(self.refs.modal.getDOMNode()).modal('hide');
- window.location.href = "/channels/" + channel.name;
+ window.location = TeamStore.getCurrentTeamUrl() + "/channels/" + channel.name;
asyncClient.getChannels(true);
}.bind(this),
function(err) {
@@ -122,7 +124,7 @@ module.exports = React.createClass({
</div>
<div className="form-group">
<label className='control-label'>Description</label>
- <textarea className="form-control" style={{resize: "none"}} ref="channel_desc" rows="3" placeholder="Description" maxLength="1024"></textarea>
+ <textarea className="form-control no-resize" ref="channel_desc" rows="3" placeholder="Description" maxLength="1024"></textarea>
</div>
{ server_error }
</form>