remove SetViewingOptions, as its not needed any more, search gets values from pa_user table
This commit is contained in:
@@ -103,12 +103,7 @@
|
||||
</a>
|
||||
</div class="nav-item">
|
||||
|
||||
<form class="d-flex col ms-5" method="POST" onSubmit="SetViewingOptionsForSearchForm()" action="/search">
|
||||
<input type="hidden" id="search_noo" name="noo" value="">
|
||||
<input type="hidden" id="search_grouping" name="grouping" value="">
|
||||
<input type="hidden" id="search_how_many" name="how_many" value="">
|
||||
<input type="hidden" id="search_offset" name="offset" value="">
|
||||
<input type="hidden" id="search_size" name="size" value="">
|
||||
<form class="d-flex col ms-5" method="POST" action="/search">
|
||||
<input id="search_term" class="form-control" type="search" placeholder="by file, date (YYYMMDD) or tag" aria-label="Search" name="search_term">
|
||||
<button class="btn btn-outline-success" onClick="javascript:st=$('#search_term').val(); document.location.href='/search/'+st" type="button">Search</button>
|
||||
</form>
|
||||
@@ -160,45 +155,6 @@
|
||||
{% endblock main_content %}
|
||||
|
||||
{% if not InDBox %}
|
||||
<script>
|
||||
function SetViewingOptionsForSearchForm()
|
||||
{
|
||||
if( $('#noo').length )
|
||||
$('#search_noo').val( $('#noo').val() )
|
||||
else
|
||||
$('#search_noo').val("Oldest")
|
||||
|
||||
if( $('#grouping').length )
|
||||
$('#search_grouping').val( $('#grouping').val() )
|
||||
else
|
||||
$('#search_grouping').val("None")
|
||||
|
||||
if( $('#how_many').length )
|
||||
$('#search_how_many').val( $('#how_many').val() )
|
||||
else
|
||||
$('#search_how_many').val("10")
|
||||
|
||||
if( $('#offset').length )
|
||||
$('#search_offset').val( $('#offset').val() )
|
||||
else
|
||||
$('#search_offset').val(0)
|
||||
|
||||
if( $('#size').length )
|
||||
$('#search_size').val( $('#size').val() )
|
||||
else
|
||||
$('#search_size').val(128)
|
||||
|
||||
if( $('#folders').length )
|
||||
$('#search_folders').val( $('#folders').val() )
|
||||
else
|
||||
$('#search_folders').val('False')
|
||||
|
||||
if( $('#cwd').length )
|
||||
$('#search_cwd').val( $('#cwd').val() )
|
||||
else
|
||||
$('#search_cwd').val('')
|
||||
}
|
||||
</script>
|
||||
{%block script_content %}{% endblock script_content %}
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user