From e9d8d074a12007ba23b198a2587e31456c3d6a18 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Mon, 18 Feb 2013 20:31:43 +0200 Subject: [PATCH] no projects message in group area --- app/views/groups/_filter.html.haml | 2 ++ app/views/groups/_people_filter.html.haml | 2 ++ app/views/groups/edit.html.haml | 2 ++ app/views/teams/edit.html.haml | 43 ++++++++++++++--------- 4 files changed, 32 insertions(+), 17 deletions(-) diff --git a/app/views/groups/_filter.html.haml b/app/views/groups/_filter.html.haml index c14fc8e5..5c66f977 100644 --- a/app/views/groups/_filter.html.haml +++ b/app/views/groups/_filter.html.haml @@ -26,6 +26,8 @@ = link_to group_filter_path(entity, project_id: project.id) do = project.name_with_namespace %small.pull-right= entities_per_project(project, entity) + - if @projects.blank? + %p.nothing_here_message This group has no projects yet %fieldset %hr diff --git a/app/views/groups/_people_filter.html.haml b/app/views/groups/_people_filter.html.haml index 901a037a..ee63743e 100644 --- a/app/views/groups/_people_filter.html.haml +++ b/app/views/groups/_people_filter.html.haml @@ -7,6 +7,8 @@ = link_to people_group_path(@group, project_id: project.id) do = project.name_with_namespace %small.pull-right= project.users.count + - if @projects.blank? + %p.nothing_here_message This group has no projects yet %fieldset %hr diff --git a/app/views/groups/edit.html.haml b/app/views/groups/edit.html.haml index 7202ef26..41ebf606 100644 --- a/app/views/groups/edit.html.haml +++ b/app/views/groups/edit.html.haml @@ -30,6 +30,8 @@ = link_to 'Team', project_team_index_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" = link_to 'Edit', edit_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small" = link_to 'Remove', project, confirm: "REMOVE #{project.name}? Are you sure?", method: :delete, class: "btn btn-small btn-remove" + - if @group.projects.blank? + %p.nothing_here_message This group has no projects yet .span5 .ui-box diff --git a/app/views/teams/edit.html.haml b/app/views/teams/edit.html.haml index 34355836..751fe94c 100644 --- a/app/views/teams/edit.html.haml +++ b/app/views/teams/edit.html.haml @@ -1,20 +1,29 @@ %h3.page_title= "Edit Team #{@team.name}" %hr -= form_for @team, url: team_path(@team) do |f| - - if @team.errors.any? - .alert.alert-error - %span= @team.errors.full_messages.first - .clearfix - = f.label :name do - Team name is - .input - = f.text_field :name, placeholder: "Ex. OpenSource", class: "xxlarge left" +.row + .span7 + = form_for @team, url: team_path(@team) do |f| + - if @team.errors.any? + .alert.alert-error + %span= @team.errors.full_messages.first + .clearfix + = f.label :name do + Team name is + .input + = f.text_field :name, placeholder: "Ex. OpenSource", class: "xlarge left" + + .clearfix + = f.label :path do + Team path is + .input + = f.text_field :path, placeholder: "opensource", class: "xlarge left" + .form-actions + = f.submit 'Save team changes', class: "btn btn-save" + .span5 + .ui-box + %h5.title Remove team + .padded.bgred + %p + Removed team can not be restored! + = link_to 'Remove team', team_path(@team), method: :delete, confirm: "You are sure?", class: "btn btn-remove btn-small" - .clearfix - = f.label :path do - Team path is - .input - = f.text_field :path, placeholder: "opensource", class: "xxlarge left" - .form-actions - = f.submit 'Save team changes', class: "btn btn-primary" - = link_to 'Delete team', team_path(@team), method: :delete, confirm: "You are shure?", class: "btn btn-remove pull-right"