move search logic to frontend
This commit is contained in:
parent
783ac823ba
commit
98f50a2b6f
18 changed files with 330 additions and 76 deletions
22
resources/assets/js/app.js
Normal file
22
resources/assets/js/app.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
|
||||
/**
|
||||
* First we will load all of this project's JavaScript dependencies which
|
||||
* includes Vue and other libraries. It is a great starting point when
|
||||
* building robust, powerful web applications using Vue and Laravel.
|
||||
*/
|
||||
|
||||
require('./bootstrap');
|
||||
|
||||
window.Vue = require('vue');
|
||||
|
||||
/**
|
||||
* Next, we will create a fresh Vue application instance and attach it to
|
||||
* the page. Then, you may begin adding components to this application
|
||||
* or customize the JavaScript scaffolding to fit your unique needs.
|
||||
*/
|
||||
|
||||
Vue.component('my-vuetable', require('./components/MyVuetable.vue'));
|
||||
|
||||
const app = new Vue({
|
||||
el: '#app'
|
||||
});
|
18
resources/assets/js/components/MyVuetable.vue
Normal file
18
resources/assets/js/components/MyVuetable.vue
Normal file
|
@ -0,0 +1,18 @@
|
|||
// MyVuetable.vue
|
||||
|
||||
<template>
|
||||
<vuetable ref="vuetable"
|
||||
api-url="https://vuetable.ratiw.net/api/users"
|
||||
:fields="['name', 'email', 'birthdate']"
|
||||
></vuetable>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Vuetable from "vuetable-2/src/components/Vuetable";
|
||||
|
||||
export default {
|
||||
components: {
|
||||
Vuetable
|
||||
}
|
||||
};
|
||||
</script>
|
|
@ -1,5 +1,5 @@
|
|||
<div class="sidebar-simplesearch">
|
||||
{!! Form::open(array('route' => 'queries','method' => 'POST', 'class'=>'pure-form')) !!}
|
||||
{!! Form::open(array('route' => 'frontend.queries','method' => 'POST', 'class'=>'pure-form')) !!}
|
||||
|
||||
|
||||
|
||||
|
@ -23,7 +23,7 @@
|
|||
}
|
||||
?>
|
||||
|
||||
<a id="link-solrsearch-all-documents" class="link" href="{{ URL::route('queries1',['searchtype' => 'all']) }}"><?= $searchAllDocsText; ?>
|
||||
<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>-->
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
<div class="pure-u-1 pure-u-md-2-3">
|
||||
<div class="content">
|
||||
<h1>Suche</h1>
|
||||
@include('rdr.solrsearch.simpleSearchForm')
|
||||
@include('frontend.partials.simpleSearchForm')
|
||||
|
||||
<div id="searchbar">
|
||||
@if (isset($results))
|
||||
|
@ -25,7 +25,7 @@
|
|||
@endif
|
||||
|
||||
@if (!is_null($result->getAsset('title_output')))
|
||||
<a href="{{ route('document.show', $result->getId()) }}">
|
||||
<a href="{{ route('frontend.dataset.show', $result->getId()) }}">
|
||||
{{ $result->getAsset('title_output') }}
|
||||
</a>
|
||||
@else
|
||||
|
@ -38,9 +38,9 @@
|
|||
</dt>
|
||||
|
||||
|
||||
@if (!is_null($result->getAsset( 'author' )))
|
||||
@if (!is_null($result->getAsset('author')))
|
||||
<dt class="results_author">
|
||||
@foreach($result->getAsset( 'author' ) as $authorIndex => $author)
|
||||
@foreach($result->getAsset('author') as $authorIndex => $author)
|
||||
<a>{{ htmlspecialchars($author)}}</a>
|
||||
@endforeach
|
||||
</dt>
|
||||
|
@ -55,7 +55,7 @@
|
|||
</div>
|
||||
@endif
|
||||
|
||||
@include('rdr.solrsearch.pagination')
|
||||
@include('frontend.solrsearch.pagination')
|
||||
</div>
|
||||
|
||||
</div>
|
|
@ -18,5 +18,4 @@
|
|||
</strong>
|
||||
</p>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
|
@ -99,11 +99,11 @@
|
|||
</p>-->
|
||||
</div>
|
||||
<div class="pure-u-1 pure-u-md-1-4 footer-funded">
|
||||
@role('administrator')
|
||||
{{-- @role('administrator')
|
||||
I'm an administrator!
|
||||
@else
|
||||
I'm not an administrator...
|
||||
@endrole
|
||||
@endrole --}}
|
||||
</div>
|
||||
<div class="pure-u-1 pure-u-md-1-4 footer-funded">
|
||||
</div>
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<div id="topmenu-inner">
|
||||
<nav class="pure-menu pure-menu-open pure-menu-horizontal">
|
||||
<ul class="pure-menu-list">
|
||||
<li class="pure-menu-item {{ Route::currentRouteName() == 'home.index' ? 'active' : '' }}">
|
||||
<li class="pure-menu-item {{ Route::currentRouteName() == 'frontend.home.index' ? 'active' : '' }}">
|
||||
<a class="pure-menu-link" href="{{ url('/') }}">HOME</a>
|
||||
</li>
|
||||
|
||||
|
@ -51,8 +51,8 @@
|
|||
|
||||
@else
|
||||
|
||||
<li class="pure-menu-item {{ Route::currentRouteName() == 'search.index' ? 'active' : '' }}">
|
||||
<a class="pure-menu-link" href="{{ route('search.index') }}">
|
||||
<li class="pure-menu-item {{ Route::currentRouteName() == 'frontend.search.index' ? 'active' : '' }}">
|
||||
<a class="pure-menu-link" href="{{ route('frontend.search.index') }}">
|
||||
<i class="fa fa-search" aria-hidden="true"></i>
|
||||
SEARCH
|
||||
</a>
|
||||
|
|
|
@ -35,8 +35,11 @@
|
|||
{{-- <input name="rights" value="0" type="hidden"> --}}
|
||||
<label>
|
||||
<input class="form-checkbox" name="rights" id="rights" type="checkbox" v-model="dataset.rights" true-value="1" false-value="0">
|
||||
<p>
|
||||
I accept {!! link_to_route('frontend.pages.show', trans('validation.attributes.backend.create-dataset.terms_and_conditions').'*', ['page_slug'=>'terms-and-conditions']) !!}
|
||||
<p>
|
||||
I accept
|
||||
<a target="_blank" href="{{ route("frontend.pages.show", ['page_slug'=>'terms-and-conditions']) }}">
|
||||
{!! trans('validation.attributes.backend.create-dataset.terms_and_conditions').'*' !!}
|
||||
</a>
|
||||
</p>
|
||||
</label>
|
||||
</div>
|
||||
|
|
28
resources/views/welcome.blade.php
Normal file
28
resources/views/welcome.blade.php
Normal file
|
@ -0,0 +1,28 @@
|
|||
<!doctype html>
|
||||
<html lang="{{ app()->getLocale() }}">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<!-- CSRF Token -->
|
||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||
|
||||
<title>{{ config('app.name', 'Laravel') }}</title>
|
||||
|
||||
<!-- Fonts -->
|
||||
<link href="https://fonts.googleapis.com/css?family=Raleway:100,600" rel="stylesheet" type="text/css">
|
||||
|
||||
<!-- Styles -->
|
||||
<link href="{{ asset('css/app.css') }}" rel="stylesheet">
|
||||
</head>
|
||||
<body>
|
||||
<div id="app">
|
||||
<div class="container">
|
||||
<my-vuetable></my-vuetable>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="{{ asset('js/app.js') }}"></script>
|
||||
</body>
|
||||
</html>
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue