From f6247600a3f5d500952b0ba32e6915a2d045e392 Mon Sep 17 00:00:00 2001 From: "Luke \"Jared\" Bennett" Date: Tue, 28 Feb 2017 16:32:30 +0000 Subject: Review changes --- app/assets/javascripts/dispatcher.js.es6 | 6 ++++-- app/services/groups/base_service.rb | 2 +- app/views/groups/_create_chat_team.html.haml | 2 +- app/views/groups/edit.html.haml | 2 -- 4 files changed, 6 insertions(+), 6 deletions(-) (limited to 'app') diff --git a/app/assets/javascripts/dispatcher.js.es6 b/app/assets/javascripts/dispatcher.js.es6 index 93d2cdbf440..202a571f6c2 100644 --- a/app/assets/javascripts/dispatcher.js.es6 +++ b/app/assets/javascripts/dispatcher.js.es6 @@ -215,11 +215,13 @@ const ShortcutsBlob = require('./shortcuts_blob'); new UsersSelect(); break; case 'groups:new': + case 'admin:groups:new': + gl.BindInOut.initAll(); + case 'groups:new': + case 'admin:groups:new': case 'groups:edit': case 'admin:groups:edit': - case 'admin:groups:new': new GroupAvatar(); - gl.BindInOut.initAll(); break; case 'projects:tree:show': shortcut_handler = new ShortcutsNavigation(); diff --git a/app/services/groups/base_service.rb b/app/services/groups/base_service.rb index eb2abcd3723..47476aaa05e 100644 --- a/app/services/groups/base_service.rb +++ b/app/services/groups/base_service.rb @@ -9,7 +9,7 @@ module Groups private def create_chat_team? - @chat_team == "true" && Gitlab.config.mattermost.enabled + @chat_team == true && Gitlab.config.mattermost.enabled end end end diff --git a/app/views/groups/_create_chat_team.html.haml b/app/views/groups/_create_chat_team.html.haml index b9bf9fe39c2..f0ace28c422 100644 --- a/app/views/groups/_create_chat_team.html.haml +++ b/app/views/groups/_create_chat_team.html.haml @@ -6,7 +6,7 @@ .col-sm-10 .checkbox.js-toggle-container = f.label :create_chat_team do - .js-toggle-button= f.check_box(:create_chat_team, { checked: true }, 'true', 'false') + .js-toggle-button= f.check_box(:create_chat_team, { checked: true }, true, false) Create a Mattermost team for this group %br %small.light.js-toggle-content diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml index c904b25fe94..2706e8692d1 100644 --- a/app/views/groups/edit.html.haml +++ b/app/views/groups/edit.html.haml @@ -22,8 +22,6 @@ = render 'shared/visibility_level', f: f, visibility_level: @group.visibility_level, can_change_visibility_level: can_change_group_visibility_level?(@group), form_model: @group - = render 'create_chat_team', f: f if Gitlab.config.mattermost.enabled - .form-group .col-sm-offset-2.col-sm-10 = render 'shared/allow_request_access', form: f -- cgit v1.2.1