move search logic to frontend
This commit is contained in:
parent
783ac823ba
commit
98f50a2b6f
18 changed files with 330 additions and 76 deletions
63
resources/views/frontend/partials/simpleSearchForm.blade.php
Normal file
63
resources/views/frontend/partials/simpleSearchForm.blade.php
Normal file
|
@ -0,0 +1,63 @@
|
|||
<div class="sidebar-simplesearch">
|
||||
{!! Form::open(array('route' => 'frontend.queries','method' => 'POST', 'class'=>'pure-form')) !!}
|
||||
|
||||
|
||||
|
||||
{!! Form::text('query', null, array('class'=>'pure-input-1', 'placeholder'=>'Search for a dataset...')) !!}
|
||||
|
||||
<!--<div id="edit-submit-search-wrapper" class="form-item">
|
||||
<span class="form-submit-wrapper">
|
||||
<input type="submit" id="edit-submit-search" class="form-submit" value="Search" />
|
||||
</span>
|
||||
</div>-->
|
||||
<button type="submit">
|
||||
<i class="fa fa-search"></i>
|
||||
</button>
|
||||
|
||||
<p class="footer-link">
|
||||
<?php
|
||||
$searchAllDocsText = Illuminate\Support\Facades\Lang::get('resources.solrsearch_title_alldocs');
|
||||
if (isset($totalNumOfDocs))
|
||||
{
|
||||
$searchAllDocsText = $searchAllDocsText . ' (<span id="solrsearch-totalnumofdocs">' . $totalNumOfDocs . '</span>)';
|
||||
}
|
||||
?>
|
||||
|
||||
<a id="link-solrsearch-all-documents" class="link" href="{{ URL::route('frontend.queries1',['searchtype' => 'all']) }}"><?= $searchAllDocsText; ?>
|
||||
</a>
|
||||
<!--<a class="link" href="">'resources.solrsearch_title_latest'</a>-->
|
||||
|
||||
<a href="" class="rss" type="application/rss+xml">
|
||||
<img src="{{ URL::asset('/img/feed_small.png' )}}" width="12" height="12" alt="{{ Lang::get('resources.rss_icon')}}" title="@lang('resources.rss_title')" />
|
||||
</a>
|
||||
</p>
|
||||
|
||||
<input type="hidden" name="searchtype" id="searchtype" value="simple" />
|
||||
<input type="hidden" name="start" id="start" value="0" />
|
||||
<input type="hidden" name="sortfield" id="sortfield" value="score" />
|
||||
<input type="hidden" name="sordorder" id="sortorder" value="desc" />
|
||||
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.sidebar-simplesearch {
|
||||
position: relative;
|
||||
margin-bottom: 2.5em;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.sidebar-simplesearch input[type=text] {
|
||||
padding: 0.25em 0.3em;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.sidebar-simplesearch button {
|
||||
padding: 0.25em 0.3em;
|
||||
border: none;
|
||||
background: none;
|
||||
position: absolute;
|
||||
right: 0.25em;
|
||||
color: #666;
|
||||
}
|
||||
</style>
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue