Skip to content
Snippets Groups Projects
Commit 033aa1a8 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

refactor buttons pt1

parent 9fdbdc66
No related branches found
No related tags found
2 merge requests!2940Expanding repos and hooks paths in settings,!2770Capistrano deploy
Showing
with 22 additions and 32 deletions
Loading
Loading
@@ -2,7 +2,7 @@
 
.team_member_show
- if can? current_user, :admin_project, @project
= link_to 'Remove from team', project_team_member_path(@project, @member), confirm: 'Are you sure?', method: :delete, class: "right btn danger"
= link_to 'Remove from team', project_team_member_path(@project, @member), confirm: 'Are you sure?', method: :delete, class: "right btn btn-remove"
.profile_avatar_holder
= image_tag gravatar_icon(@member.email, 60), class: "borders"
%h3.page_title
Loading
Loading
Loading
Loading
@@ -17,6 +17,6 @@
= f.text_field :path, placeholder: "opensource", class: "xxlarge left"
.clearfix
.input.span3.center
= f.submit 'Save team changes', class: "btn primary"
= f.submit 'Save team changes', class: "btn btn-primary"
.input.span3.center
= link_to 'Delete team', team_path(@team), method: :delete, confirm: "You are shure?", class: "btn danger"
= link_to 'Delete team', team_path(@team), method: :delete, confirm: "You are shure?", class: "btn btn-remove"
Loading
Loading
@@ -16,5 +16,5 @@
 
%br
.actions
= submit_tag 'Save', class: "btn primary"
= submit_tag 'Save', class: "btn btn-save"
= link_to 'Cancel', :back, class: "btn"
Loading
Loading
@@ -17,8 +17,8 @@
= f.select :permission, options_for_select(UsersProject.access_roles, @team.default_projects_access(user)), {}, class: "medium project-access-select span2"
.left.span2
%span
Admin access
= check_box_tag :group_admin, true, @team.admin?(user)
Admin access
.right
- if current_user == user
%span.btn.disabled This is you!
Loading
Loading
@@ -27,5 +27,5 @@
- elsif user.blocked
%span.btn.disabled.blocked Blocked
- elsif allow_admin
= link_to team_member_path(@team, user), confirm: remove_from_user_team_message(@team, user), method: :delete, class: "very_small btn danger" do
= link_to team_member_path(@team, user), confirm: remove_from_user_team_message(@team, user), method: :delete, class: "very_small btn btn-remove" do
%i.icon-minus.icon-white
Loading
Loading
@@ -7,7 +7,7 @@
 
- if can? current_user, :manage_user_team, @team
%span.right
= link_to new_team_member_path(@team), class: "btn success small grouped", title: "New Team Member" do
= link_to new_team_member_path(@team), class: "btn btn-primary small grouped", title: "New Team Member" do
New Team Member
%hr
 
Loading
Loading
Loading
Loading
@@ -25,4 +25,4 @@
%td
%span= check_box_tag :group_admin
%span Admin?
%td= submit_tag 'Add', class: "btn primary", id: :add_members_to_team
%td= submit_tag 'Add User', class: "btn btn-create", id: :add_members_to_team
Loading
Loading
@@ -3,7 +3,7 @@
 
.team_member_show
- if can? current_user, :admin_project, @project
= link_to 'Remove from team', project_team_member_path(project_id: @project, id: @team_member.id), confirm: 'Are you sure?', method: :delete, class: "right btn danger"
= link_to 'Remove from team', project_team_member_path(project_id: @project, id: @team_member.id), confirm: 'Are you sure?', method: :delete, class: "right btn btn-remove"
.profile_avatar_holder
= image_tag gravatar_icon(user.email, 60), class: "borders"
%h3.page_title
Loading
Loading
Loading
Loading
@@ -10,7 +10,7 @@
.input
= f.text_field :name, placeholder: "Ex. Ruby Developers", class: "xxlarge left"
 
= f.submit 'Create team', class: "btn primary"
= f.submit 'Create team', class: "btn btn-primary"
%hr
.padded
%ul
Loading
Loading
Loading
Loading
@@ -12,5 +12,5 @@
 
%br
.actions
= submit_tag 'Save', class: "btn primary"
= link_to 'Cancel', :back, class: "btn"
= submit_tag 'Save', class: "btn btn-save"
= link_to 'Cancel', :back, class: "btn btn-cancel"
%h3
Edit max access in #{@project.name} for #{@team.name} team
%h3.page_title
Edit max access in #{link_to @project.name_with_namespace, @project} for #{link_to(@team.name, team_path(@team))} team
 
%hr
%table.zebra-striped
%tr
%td Project:
%td= @project.name
%tr
%td Team:
%td= @team.name
%tr
%td Since:
%td= assigned_since(@team, @project).stamp("Nov 11, 2010")
 
= render 'form'
Loading
Loading
@@ -6,7 +6,7 @@
 
- if current_user.can?(:manage_user_team, @team) && @avaliable_projects.any?
%span.right
= link_to new_team_project_path(@team), class: "btn success small grouped", title: "New Team Member" do
= link_to new_team_project_path(@team), class: "btn btn-primary small grouped", title: "New Team Member" do
Assign project to Team
 
%hr
Loading
Loading
@@ -30,7 +30,7 @@
- if current_user.can?(:admin_user_team, @team)
%td.bgred
= link_to 'Edit max access', edit_team_project_path(@team, project), class: "btn small"
= link_to 'Relegate', team_project_path(@team, project), confirm: 'Remove project from team and move to global namespace. Are you sure?', method: :delete, class: "btn danger small"
= link_to 'Relegate', team_project_path(@team, project), confirm: 'Remove project from team and move to global namespace. Are you sure?', method: :delete, class: "btn btn-remove small"
 
- else
%p.nothing_here_message This team has no projects yet
Loading
Loading
@@ -20,4 +20,4 @@
%tr
%td= select_tag :project_ids, options_from_collection_for_select(@avaliable_projects , :id, :name_with_namespace), multiple: true, data: {placeholder: 'Select projects'}, class: 'chosen span5'
%td= select_tag :greatest_project_access, options_for_select(UserTeam.access_roles), {class: "project-access-select chosen span3" }
%td= submit_tag 'Add', class: "btn primary", id: :assign_projects_to_team
%td= submit_tag 'Add Project', class: "btn btn-create", id: :assign_projects_to_team
Loading
Loading
@@ -10,7 +10,7 @@
%strong= @ref
%span.options
.btn-group.tree-btn-group
= link_to "Cancel", project_tree_path(@project, @id), class: "btn very_small cancel-btn", confirm: "Are you sure?"
= link_to "Cancel", project_tree_path(@project, @id), class: "btn very_small btn-cancel", confirm: "Are you sure?"
.file_content.code
%pre#editor= @tree.data
 
Loading
Loading
@@ -27,7 +27,7 @@
.message
to branch
%strong= @ref
= link_to "Cancel", project_tree_path(@project, @id), class: "btn cancel-btn", confirm: "Are you sure?"
= link_to "Cancel", project_tree_path(@project, @id), class: "btn btn-cancel", confirm: "Are you sure?"
 
:javascript
var ace_mode = "#{@tree.language.try(:ace_mode)}";
Loading
Loading
Loading
Loading
@@ -23,5 +23,5 @@
= f.label :content
.input= f.text_area :content, class: 'span8 js-gfm-input'
.actions
= f.submit 'Save', class: "save-btn btn"
= link_to "Cancel", project_wiki_path(@project, :index), class: "btn cancel-btn"
= f.submit 'Save', class: "btn-save btn"
= link_to "Cancel", project_wiki_path(@project, :index), class: "btn btn-cancel"
Loading
Loading
@@ -4,5 +4,5 @@
 
.right
- if can? current_user, :admin_wiki, @project
= link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete, class: "btn small danger" do
= link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete, class: "btn small btn-remove" do
Delete this page
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment