PageRenderTime 24ms CodeModel.GetById 21ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/django/contrib/admin/templates/mako/admin/search_form.html

https://code.google.com/p/mango-py/
HTML | 39 lines | 26 code | 13 blank | 0 comment | 0 complexity | cd9f8e36e62e7cbc88529b394f26d41a MD5 | raw file
 1<%namespace name="admin" module="django.contrib.admin.templatetags.adminmedia" />
 2
 3<% 
 4    from django.contrib.admin.views.main import SEARCH_VAR
 5%>
 6
 7% if cl.search_fields:
 8
 9<div id="toolbar"><form id="changelist-search" action="" method="get">
10<div><!-- DIV needed for valid HTML -->
11<label for="searchbar"><img src="${admin_media_prefix()}img/admin/icon_searchbox.png" alt="Search" /></label>
12<input type="text" size="40" name="${SEARCH_VAR}" value="${cl.query}" id="searchbar" />
13<input type="submit" value="${trans('Go')}" />
14
15% if show_result_count:
16
17    <span class="small quiet"><%def name="blocktrans()"><% counter = cl.result_count %>${counter} result${counter|pluralize} results</%def>${blocktrans()} (<a href="?
18% if cl.is_popup:
19pop=1
20% endif
21"><%def name="blocktrans()"><% full_result_count = cl.full_result_count %>${full_result_count} total</%def>${blocktrans()}</a>)</span>
22
23% endif
24
25
26% for pair in cl.params.items():
27
28    % if pair[0] != SEARCH_VAR:
29        <input type="hidden" name="${pair[0]}" value="${pair[1]}"/>
30    % endif
31
32% endfor
33
34</div>
35</form></div>
36<script type="text/javascript">document.getElementById("searchbar").focus();</script>
37
38% endif
39