Skip to content

Commit

Permalink
Fix a bug in the search. When the user search for a folder in a popup…
Browse files Browse the repository at this point in the history
… the filer was loosing the 'select_folder'. This problem has be resolved by passing the appropriate option to the view.
  • Loading branch information
yml committed Nov 30, 2010
1 parent ae9cc58 commit fb77624
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions filer/templates/admin/filer/tools/search_form.html
Expand Up @@ -2,11 +2,14 @@
{% load i18n %}
<div id="toolbar">
<div style="float: left;">
<form id="changelist-search" action="" method="get">
<form id="changelist-search" action="." method="get">
{% csrf_token %}
<div>
<label for="searchbar"><img src="{% admin_media_prefix %}img/admin/icon_searchbox.png" alt="{% trans "Search" %}" /></label>
{% if is_popup %}<input type="hidden" name="_popup" value="1" />{% endif %}
{% if is_popup %}
<input type="hidden" name="_popup" value="1" />
{% if select_folder %}<input type="hidden" name="select_folder" value="1" />{% endif %}
{% endif %}
<input type="text" size="40" name="q" value="{{ search_string }}" id="searchbar" title="{% trans "Enter your search phrase here" %}" />
<input type="submit" value="{% trans 'Search' %}" title="{% trans "Click here to" %} {% trans "run search for entered phrase" %}" />
<input type="checkbox" id="limit_search_to_folder" name="limit_search_to_folder" {% if limit_search_to_folder %}checked="checked"{% endif %} title="{% trans "Check it to" %} {% trans "limit the search to current folder" %}"/>
Expand Down

0 comments on commit fb77624

Please sign in to comment.