Permalink
Browse files

Clean up so search and actions and both be displayed in the subnav

  • Loading branch information...
1 parent 1125743 commit a1850327f81bd82d852495d654df4ef1efbd82c1 @tswicegood committed May 18, 2012
Showing with 23 additions and 11 deletions.
  1. +8 −4 pops/static/pops/less/style.less
  2. +13 −5 pops/templates/admin/change_list.html
  3. +2 −2 pops/templates/admin/search_form.html
@@ -191,11 +191,15 @@ td.action-checkbox {
}
}
-#changelist-search {
- input.search-query,
- div.search-results { float: left; }
- div.search-results { padding: @gridGutterWidth / 4;}
+@subNavPadding: @gridGutterWidth / 4;
+
+.object-tools-left {
+ .admin-model-search-container { padding-left: @subNavPadding; padding-right: @subNavPadding; }
+}
+
+#changelist-search {
+ div.search-results { padding: @subNavPadding; }
}
#menu_search {
@@ -78,11 +78,19 @@
</div>
{% endif %}
- {% if action_form and cl.full_result_count %}{% admin_actions %}{% endif %}
-
- {% if cl %}
- {% search_form cl %}
- {% endif %}
+ <div class="pull-left object-tools object-tools-left">
+ {% block object-tools-items-left %}
+ <div class="pull-left admin-actions-container">
+ {% if action_form and cl.full_result_count %}{% admin_actions %}{% endif %}
+ </div>
+
+ <div class="pull-left admin-model-search-container">
+ {% if cl %}
+ {% search_form cl %}
+ {% endif %}
+ </div>
+ {% endblock %}
+ </div>
</div>
{% endif %}
{% endblock %}
@@ -3,12 +3,12 @@
{% if cl.search_fields %}
<form id="changelist-search" action="" method="get">
- <input type="search" size="40" class="search-query"
+ <input type="search" size="40" class="pull-left search-query"
name="{{ search_var }}" id="searchbar"
value="{{ cl.query }}" placeholder="{% trans "Search" %} {{ cl.opts.verbose_name_plural|capfirst }}...">
{% if show_result_count %}
- <div class="small quiet search-results">
+ <div class="pull-left small quiet search-results">
{% blocktrans count cl.result_count as counter %}{{ counter }} result{% plural %}{{ counter }} results{% endblocktrans %}
(<a href="?{% if cl.is_popup %}pop=1{% endif %}">
{% blocktrans with cl.full_result_count as full_result_count %}{{ full_result_count }} total{% endblocktrans %}

0 comments on commit a185032

Please sign in to comment.