diff --git a/app/models/build_list/filter.rb b/app/models/build_list/filter.rb index bc76ee73e..5e39ec5b1 100644 --- a/app/models/build_list/filter.rb +++ b/app/models/build_list/filter.rb @@ -56,7 +56,7 @@ class BuildList::Filter :project_name => nil })) - @options[:ownership] = @options[:ownership].presence || 'owned' + @options[:ownership] = @options[:ownership].presence || (@project ? 'index' : 'owned') @options[:status] = @options[:status].present? ? @options[:status].to_i : nil @options[:created_at_start] = build_date_from_params(:created_at_start, @options) @options[:created_at_end] = build_date_from_params(:created_at_end, @options) diff --git a/app/views/build_lists/_filter.html.haml b/app/views/build_lists/_filter.html.haml index 2a6ee9f6e..8d967dcc5 100644 --- a/app/views/build_lists/_filter.html.haml +++ b/app/views/build_lists/_filter.html.haml @@ -24,10 +24,11 @@ .lefter= f.radio_button :ownership, 'owned', :class => 'niceRadio', :id => 'myradio1' .lefter= t("layout.build_lists.ownership.owned") .both - .table - .lefter= f.radio_button :ownership, 'related', :class => 'niceRadio', :id => 'myradio2' - .lefter= t("layout.build_lists.ownership.related") - .both + - unless @project + .table + .lefter= f.radio_button :ownership, 'related', :class => 'niceRadio', :id => 'myradio2' + .lefter= t("layout.build_lists.ownership.related") + .both .table .lefter= f.radio_button :ownership, 'index', :class => 'niceRadio', :id => 'myradio3' .lefter= t("layout.build_lists.ownership.index") diff --git a/config/initializers/core.rb b/config/initializers/core.rb deleted file mode 100644 index 683f5b02f..000000000 --- a/config/initializers/core.rb +++ /dev/null @@ -1,2 +0,0 @@ -# -*- encoding : utf-8 -*- -require './lib/ext/core/string'