Bug 14029: Provide 'clear' link to empty reports search filters
Patch adds a 'clear' link next to the 'Apply filters' button to empty out the form fields. To test: - go to the reports module - make sure you have some saved reports - search your saved reports using the author, keyword and date filters - verify searching works as expected - verify the new 'clear' link works as expected Tested couner patch, followed test plan, works as expected. QA tools ok. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
This commit is contained in:
parent
bba78196d3
commit
83da81e0ce
|
|
@ -1045,7 +1045,10 @@ Sub report:<select name="subreport">
|
|||
<li><label for="filter_keyword">Keyword:</label> <input type="text" id="filter_keyword" name="filter_keyword" value="[% filters.keyword %]" /></li>
|
||||
</ol>
|
||||
</fieldset>
|
||||
<fieldset class="action"><input type="submit" value="Apply filter" /></fieldset>
|
||||
<fieldset class="action">
|
||||
<input type="submit" value="Apply filter" />
|
||||
<a id="resetReportsFilter" href="?phase=Use saved&clear_filters=1">Clear</a>
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
[% END %]
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ if ( $input->param("filter_set") ) {
|
|||
$session->param('report_filter', $filter) if $session;
|
||||
$template->param( 'filter_set' => 1 );
|
||||
}
|
||||
elsif ($session) {
|
||||
elsif ($session and not $input->param('clear_filters')) {
|
||||
$filter = $session->param('report_filter');
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue