diff --git a/app/controllers/groups_controller.rb b/app/controllers/groups_controller.rb index 8976262f4f72c1769c80cc9c2a210a0fed0853e2..38bc3665b51c2951b6ebf8ffe055aaa8e87c2c5a 100644 --- a/app/controllers/groups_controller.rb +++ b/app/controllers/groups_controller.rb @@ -12,6 +12,9 @@ class GroupsController < ApplicationController # Load group projects before_filter :projects, except: [:new, :create] + layout 'navless', only: [:new, :create] + before_filter :set_title, only: [:new, :create] + def new @group = Group.new end @@ -134,4 +137,8 @@ class GroupsController < ApplicationController return render_404 end end + + def set_title + @title = 'New Group' + end end diff --git a/app/controllers/teams_controller.rb b/app/controllers/teams_controller.rb index 26c1d84f86bd71d142549815e989a4c5fe5b6521..c7d4040725db1962f38b9f55a75aadd192aaf87a 100644 --- a/app/controllers/teams_controller.rb +++ b/app/controllers/teams_controller.rb @@ -7,6 +7,8 @@ class TeamsController < ApplicationController before_filter :user_team, except: [:new, :create] layout 'user_team', except: [:new, :create] + layout 'navless', only: [:new, :create] + before_filter :set_title, only: [:new, :create] def show projects @@ -76,4 +78,8 @@ class TeamsController < ApplicationController def user_team @team ||= current_user.authorized_teams.find_by_path(params[:id]) end + + def set_title + @title = 'New Team' + end end diff --git a/app/views/groups/new.html.haml b/app/views/groups/new.html.haml index b395a8bc6a3b161c1186f871f7597f3acfe555fa..4aa58dedc4a79a5b2215b10df3039ad7047c1e33 100644 --- a/app/views/groups/new.html.haml +++ b/app/views/groups/new.html.haml @@ -1,5 +1,3 @@ -%h3.page_title New Group -%hr = form_for @group do |f| - if @group.errors.any? .alert.alert-error @@ -15,14 +13,16 @@ .input = f.text_area :description, maxlength: 250, class: "xxlarge js-gfm-input", rows: 4 + .clearfix + .input + %ul + %li Group is kind of directory for several projects + %li All created groups are private + %li People within a group see only projects they have access to + %li All projects of group will be stored in a group directory + %li You will be able to move existing projects into group + .form-actions = f.submit 'Create group', class: "btn btn-create" - .padded - %ul - %li Group is kind of directory for several projects - %li All created groups are private - %li People within a group see only projects they have access to - %li All projects of group will be stored in a group directory - %li You will be able to move existing projects into group diff --git a/app/views/teams/new.html.haml b/app/views/teams/new.html.haml index 99d308217e007cc9bc1de630e197e8629c3cc4db..fe1f9cf10ec063b5e0713f133a11846798b60fe7 100644 --- a/app/views/teams/new.html.haml +++ b/app/views/teams/new.html.haml @@ -1,5 +1,3 @@ -%h3.page_title New Team -%hr = form_for @team, url: teams_path do |f| - if @team.errors.any? .alert.alert-error @@ -15,16 +13,16 @@ .input = f.text_area :description, maxlength: 250, class: "xxlarge js-gfm-input", rows: 4 + + .clearfix + .input + %ul + %li All created teams are public (users can view who enter into team and which project are assigned for this team) + %li People within a team see only projects they have access to + %li You will be able to assign existing projects for team .form-actions = f.submit 'Create team', class: "btn btn-create" - .padded - %ul - %li All created teams are public (users can view who enter into team and which project are assigned for this team) - %li People within a team see only projects they have access to - %li You will be able to assign existing projects for team - %hr - - if current_user.can_create_group? .clearfix .input.light