From d39a269a7f567bd80234e9a030604a710dcd3351 Mon Sep 17 00:00:00 2001 From: Alexander Machehin Date: Fri, 22 Feb 2013 16:54:08 +0600 Subject: [PATCH] #921 change order ownership buttons --- app/views/projects/build_lists/_filter.html.haml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/views/projects/build_lists/_filter.html.haml b/app/views/projects/build_lists/_filter.html.haml index b669101e3..fff377fb4 100644 --- a/app/views/projects/build_lists/_filter.html.haml +++ b/app/views/projects/build_lists/_filter.html.haml @@ -15,9 +15,7 @@ %h3.medium= t("layout.build_lists.ownership.header") =f.hidden_field :ownership .btn-group - - ownerships = %w[owned everything] - - ownerships << 'related' unless @project - - ownerships.each do |ownership| + - ['owned', (@project ? nil : 'related'), 'everything'].compact.each do |ownership| -options = {:class => @filter.ownership == ownership ? 'active' : '', :value => ownership, :style => (@project ? 'width:50%;' : '')} %button.btn.ownership{options}= t "layout.build_lists.ownership.#{ownership}" %h3.medium= t 'number_rows'