Commit 4ab43ff52cfdec5e9c449fad9d90cbc29e71faea
Committed by
Álvaro Fernando Matos de Souza
1 parent
056acac9
Exists in
master
and in
5 other branches
Fix search catalog divs(to help in design)
Showing
1 changed file
with
35 additions
and
36 deletions
Show diff stats
views/search/_software_search_form.html.erb
| 1 | -<div class='search-form'> | |
| 2 | - <h3> <%= _("Search Public Software Catalog") %> </h3> | |
| 1 | +<div> | |
| 2 | + <div class='search-form'> | |
| 3 | + <h3> <%= _("Search Public Software Catalog") %> </h3> | |
| 3 | 4 | |
| 4 | - <%= form_tag( { :controller => 'search', :action => @asset ? @asset : 'index', :asset => nil, :category_path => ( @category ? @category.path : nil ) }, | |
| 5 | - :method => 'get', :class => 'search_form' ) do %> | |
| 5 | + <%= form_tag( { :controller => 'search', :action => @asset ? @asset : 'index', :asset => nil, :category_path => ( @category ? @category.path : nil ) }, | |
| 6 | + :method => 'get', :class => 'search_form' ) do %> | |
| 6 | 7 | |
| 7 | 8 | <div style="margin:0;padding:0;display:inline"> |
| 8 | - <input name="utf8" type="hidden" value="✓" /></div> | |
| 9 | + <input name="utf8" type="hidden" value="✓" /> | |
| 10 | + </div> | |
| 9 | 11 | <%= hidden_field_tag :display, params[:display] %> |
| 10 | 12 | <%= hidden_field_tag :filter, params[:filter] %> |
| 11 | 13 | |
| ... | ... | @@ -18,43 +20,40 @@ |
| 18 | 20 | </div> |
| 19 | 21 | <%= render :partial => 'search_form_extra_fields' %> |
| 20 | 22 | <%= render :partial => 'catalog_filter' %> |
| 23 | + <% end %> | |
| 24 | + </div> | |
| 21 | 25 | |
| 22 | - <br /> | |
| 26 | + <div id="catalog-display-options"> | |
| 27 | + <div id="catalog-display-options-count"> | |
| 28 | + <strong id="software-count"><%= "#{@software_count} Software(s)" %></strong> | |
| 29 | + </div> | |
| 23 | 30 | |
| 24 | - <div id="catalog-display-options"> | |
| 25 | - <div id="catalog-display-options-count"> | |
| 26 | - <strong id="software-count"><%= "#{@software_count} Software(s)" %></strong> | |
| 31 | + <div id="catalog-display-options-show-and-sort"> | |
| 32 | + <div id="catalog-display-options-show"> | |
| 33 | + Show: | |
| 34 | + <%= select_tag("software_display", | |
| 35 | + options_for_select(['15', '30', '90', 'All'], :selected=>params[:display]) | |
| 36 | + ) %> | |
| 27 | 37 | </div> |
| 28 | 38 | |
| 29 | - <div id="catalog-display-options-show-and-sort"> | |
| 30 | - <div id="catalog-display-options-show"> | |
| 31 | - Show: | |
| 32 | - <%= select_tag("software_display", | |
| 33 | - options_for_select(['15', '30', '90', 'All'], :selected=>params[:display]) | |
| 34 | - ) %> | |
| 35 | - </div> | |
| 36 | - | |
| 37 | - <div id="catalog-display-options-sort"> | |
| 38 | - Sort by: | |
| 39 | - <%= select_tag("sort", | |
| 40 | - options_for_select( | |
| 41 | - [ | |
| 42 | - [_("Name A-Z"), 'asc'], | |
| 43 | - [_("Name Z-A"), 'desc'], | |
| 44 | - [_("Relevance"), 'relevance'] | |
| 39 | + <div id="catalog-display-options-sort"> | |
| 40 | + Sort by: | |
| 41 | + <%= select_tag("sort", | |
| 42 | + options_for_select( | |
| 43 | + [ | |
| 44 | + [_("Name A-Z"), 'asc'], | |
| 45 | + [_("Name Z-A"), 'desc'], | |
| 46 | + [_("Relevance"), 'relevance'] | |
| 45 | 47 | ], :selected=>params[:sort]) |
| 46 | - ) %> | |
| 47 | - </div> | |
| 48 | + ) %> | |
| 48 | 49 | </div> |
| 49 | 50 | </div> |
| 50 | - <% end %> | |
| 51 | + </div> | |
| 52 | +</div> | |
| 51 | 53 | |
| 52 | - <% if @empty_query %> | |
| 53 | - <% hint = environment.search_hints[@asset] %> | |
| 54 | - <% if hint and !hint.blank? %> | |
| 55 | - <div class="search-hint"><%= hint %></div> | |
| 56 | - <% end %> | |
| 54 | +<% if @empty_query %> | |
| 55 | + <% hint = environment.search_hints[@asset] %> | |
| 56 | + <% if hint and !hint.blank? %> | |
| 57 | + <div class="search-hint"><%= hint %></div> | |
| 57 | 58 | <% end %> |
| 58 | - | |
| 59 | - <div style="clear: both"></div> | |
| 60 | -</div> | |
| 59 | +<% end %> | ... | ... |