Merge pull request #563 from warpc/561-build_lists_page_change
[issue #561] Some cosmetic changes for BuildList: * Reordered columns in BuildLists table; * Reordered rows in BuildLists filter; * Removed created_at filter (Commented. See TODOs).
This commit is contained in:
commit
3509edc81e
|
@ -21,9 +21,11 @@ class BuildList::Filter
|
|||
build_lists = build_lists.scoped_to_project_name(@options[:project_name]) if @options[:project_name]
|
||||
build_lists = build_lists.by_mass_build(@options[:mass_build_id]) if @options[:mass_build_id]
|
||||
|
||||
if @options[:created_at_start] || @options[:created_at_end]
|
||||
build_lists = build_lists.for_creation_date_period(@options[:created_at_start], @options[:created_at_end])
|
||||
end
|
||||
# TODO [BuildList#created_at filters] Uncomment here and in build_lists/_filter.html.haml to return filters
|
||||
#
|
||||
# if @options[:created_at_start] || @options[:created_at_end]
|
||||
# build_lists = build_lists.for_creation_date_period(@options[:created_at_start], @options[:created_at_end])
|
||||
# end
|
||||
if @options[:updated_at_start] || @options[:updated_at_end]
|
||||
build_lists = build_lists.for_notified_date_period(@options[:updated_at_start], @options[:updated_at_end])
|
||||
end
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
%td= build_list.human_status
|
||||
%td= link_to build_list.project.name_with_owner, build_list.project
|
||||
%td= build_list_version_link(build_list)
|
||||
%td= build_list.arch.name
|
||||
%td= link_to build_list.save_to_platform.name, build_list.save_to_platform
|
||||
%td= build_list.arch.name
|
||||
%td= link_to build_list.user.try(:fullname), build_list.user
|
||||
|
|
|
@ -37,20 +37,19 @@
|
|||
%br
|
||||
= f.submit t("layout.search.header")
|
||||
.block
|
||||
%h3.small= t("activerecord.attributes.build_list.mass_build")
|
||||
.lineForm.aside= f.select :mass_build_id, options_from_collection_for_select( MassBuild.all, :id, :name, @filter.mass_build_id ), {:include_blank => true}
|
||||
%h3.small= t("activerecord.attributes.build_list.status")
|
||||
.lineForm.aside= f.select :status, BuildList::STATUSES.collect{|status| [BuildList.human_status(status), status]}, {:include_blank => true, :selected => @filter.status}, {:class => 'sel80 aside', :id => 'status', :tabindex => 2}
|
||||
%h3.small= t("activerecord.attributes.build_list.is_circle")
|
||||
.lineForm.aside= f.select :is_circle, [[t("layout.yes_"), 1], [t("layout.no_"), 0]], {:include_blank => true, :selected => @filter.is_circle.present? ? (@filter.is_circle ? "1" : "0") : nil}, {:class => 'sel80 aside', :id => 'recurrent', :tabindex => 2}
|
||||
%h3.small= t("activerecord.attributes.build_list.arch")
|
||||
.lineForm.aside= f.select :arch_id, Arch.recent.collect{|arch| [arch.name, arch.id]}, {:include_blank => true, :selected => @filter.arch_id}, {:class => 'sel80 aside', :id => 'architecture', :tabindex => 2}
|
||||
%h3.small= t("activerecord.models.platform")
|
||||
.lineForm.aside= f.select :platform_id, Platform.main.collect{|pl| [pl.name, pl.id]}, {:include_blank => true, :selected => @filter.platform_id}, {:class => 'sel80 aside', :id => 'platform', :tabindex => 2}
|
||||
%h3.small= t("layout.build_lists.created_at_start")
|
||||
.date_select= f.date_select(:created_at_start, :include_blank => true, :selected => @filter.created_at_start)
|
||||
%h3.small= t("layout.build_lists.created_at_end")
|
||||
.date_select= f.date_select(:created_at_end, :include_blank => true, :selected => @filter.created_at_end)
|
||||
%h3.small= t("activerecord.attributes.build_list.mass_build")
|
||||
.lineForm.aside= f.select :mass_build_id, options_from_collection_for_select( MassBuild.all, :id, :name, @filter.mass_build_id ), {:include_blank => true}
|
||||
%h3.small= t("activerecord.attributes.build_list.arch")
|
||||
.lineForm.aside= f.select :arch_id, Arch.recent.collect{|arch| [arch.name, arch.id]}, {:include_blank => true, :selected => @filter.arch_id}, {:class => 'sel80 aside', :id => 'architecture', :tabindex => 2}
|
||||
-# TODO [BuildList#created_at filters] Uncomment here and in BuildList::Filter to return filters
|
||||
%h3.small= t("layout.build_lists.created_at_start")
|
||||
.date_select= f.date_select(:created_at_start, :include_blank => true, :selected => @filter.created_at_start)
|
||||
%h3.small= t("layout.build_lists.created_at_end")
|
||||
.date_select= f.date_select(:created_at_end, :include_blank => true, :selected => @filter.created_at_end)
|
||||
%h3.small= t("layout.build_lists.updated_at_start")
|
||||
.date_select= f.date_select(:updated_at_start, :include_blank => true, :selected => @filter.updated_at_start)
|
||||
%h3.small= t("layout.build_lists.updated_at_end")
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
%th.lpadding16= t("activerecord.attributes.build_list.status")
|
||||
%th.lpadding16= t("activerecord.attributes.build_list.project")
|
||||
%th.lpadding16= t("activerecord.attributes.build_list.project_version")
|
||||
%th.lpadding16= t("activerecord.attributes.build_list.arch")
|
||||
%th.lpadding16= t("activerecord.models.platform")
|
||||
%th.lpadding16= t("activerecord.attributes.build_list.arch")
|
||||
%th.lpadding16= t("activerecord.attributes.build_list.user")
|
||||
%tbody= render :partial => 'projects/build_lists/build_list', :collection => @build_lists
|
||||
.both
|
||||
|
|
|
@ -14,6 +14,10 @@
|
|||
- container_url = "http://#{request.host_with_port}/downloads#{@build_list.container_path}"
|
||||
= link_to container_url, container_url
|
||||
.both
|
||||
|
||||
.leftlist= t("activerecord.attributes.build_list.bs_id")
|
||||
.rightlist= @build_list.bs_id.present? ? @build_list.bs_id : t("layout.build_lists.bs_id_not_set")
|
||||
.both
|
||||
.leftlist= t("activerecord.attributes.build_list.user")
|
||||
.rightlist
|
||||
= link_to @build_list.user.try(:fullname), @build_list.user
|
||||
|
|
Loading…
Reference in New Issue