mirror of
https://gitlab.com/signalytic/client-external/streamline/streamline-emr.git
synced 2026-09-11 18:51:31 +00:00
116 lines
5.0 KiB
PHP
Executable File
116 lines
5.0 KiB
PHP
Executable File
@extends('layouts.main')
|
|
|
|
@push('styles')
|
|
<link href="{{ asset('elite/bower_components/typeahead.js-master/dist/typehead-min.css') }}" rel="stylesheet">
|
|
<link href="{{ asset('/elite/bower_components/datatables/jquery.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
|
<link href="{{ asset('elite/tables/css/buttons.dataTables.min.css') }}" rel="stylesheet" type="text/css" />
|
|
@endpush
|
|
|
|
@section('content')
|
|
<div class="row bg-title">
|
|
<div class="col-lg-3 col-md-4 col-sm-4 col-xs-12">
|
|
<h4 class="page-title">{{ __('frequently_asked_questions.faq') }}</h4>
|
|
</div>
|
|
<div class="col-lg-9 col-sm-8 col-md-8 col-xs-12">
|
|
<ol class="breadcrumb">
|
|
<li><a href="{{ route('home') }}">{{ __('frequently_asked_questions.dashboard') }}</a></li>
|
|
<li><a class="btn btn-outline-success btn-sm btn-rounded" href="{{ route('frequently_asked_questions.create') }}">{{ __('frequently_asked_questions.add_faqs') }}</a></li>
|
|
<li class="active">{{ __('frequently_asked_questions.add_faq') }}</li>
|
|
</ol>
|
|
</div>
|
|
</div>
|
|
|
|
@include('frequently_asked_questions.menu')
|
|
|
|
@include('flash::message')
|
|
|
|
<div class="panel">
|
|
<div class="panel-body">
|
|
<div class="row">
|
|
<div class="col-md-3 b-r">
|
|
{{ __('frequently_asked_questions.search_more') }}
|
|
{{ Form::open(['route'=>'frequently_asked_questions.result', 'data-toggle' => 'validator']) }}
|
|
<div class="input-group" id="questions">
|
|
{{ Form::text('question', '', ['class' => 'form-control typeahead', 'required', 'placeholder' => __('frequently_asked_questions.search_for'), 'autocomplete' => 'off', 'spellcheck' => false]) }}
|
|
<span class="input-group-btn">
|
|
{{ Form::submit(__('frequently_asked_questions.search'), ['class'=>'btn btn-info']) }}
|
|
</span>
|
|
</div>
|
|
{{ Form::close() }}
|
|
</div>
|
|
<div class="col-md-6">
|
|
<img src="{{ asset('uploads/streamline/color/280X50-06.png') }}" style="height: 25px; width: 130px;" alt="home" /><br/><br/>
|
|
@foreach($questions as $question)
|
|
<label class="label label-success">{{ __('frequently_asked_questions.question') }}</label>
|
|
<h3>{{ $question->question }}</h3><br>
|
|
|
|
<label class="label label-success">{{ __('frequently_asked_questions.answer') }}</label>
|
|
<article>
|
|
{{ $question->answer }}
|
|
</article>
|
|
@endforeach
|
|
</div>
|
|
<div class="col-md-3">
|
|
{{ __('frequently_asked_questions.related_questions') }}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
@endsection
|
|
|
|
@push('scripts')
|
|
|
|
<script src="{{ asset('elite/bower_components/typeahead.js-master/dist/typeahead.bundle.min.js') }}"></script>
|
|
<script src="{{ asset('elite/bower_components/datatables/jquery.dataTables.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/dataTables.buttons.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/buttons.flash.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/jszip.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/pdfmake.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/vfs_fonts.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/buttons.html5.min.js') }}"></script>
|
|
<script src="{{ asset('elite/tables/js/buttons.print.min.js') }}"></script>
|
|
|
|
<script>
|
|
$('.table').DataTable({
|
|
dom: 'Bfrtip',
|
|
buttons: [
|
|
'copy', 'csv', 'excel', 'pdf', 'print'
|
|
]
|
|
});
|
|
|
|
let substringMatcher = function(strs) {
|
|
return function findMatches(q, cb) {
|
|
let matches, substrRegex;
|
|
|
|
// an array that will be populated with substring matches
|
|
matches = [];
|
|
|
|
// regex used to determine if a string contains the substring `q`
|
|
substrRegex = new RegExp(q, 'i');
|
|
|
|
// iterate through the pool of strings and for any string that
|
|
// contains the substring `q`, add it to the `matches` array
|
|
$.each(strs, function(i, str) {
|
|
if (substrRegex.test(str)) {
|
|
matches.push(str);
|
|
}
|
|
});
|
|
|
|
cb(matches);
|
|
};
|
|
};
|
|
|
|
$('#questions .typeahead').typeahead(
|
|
{
|
|
hint: true,
|
|
highlight: true,
|
|
minLength: 1
|
|
},
|
|
{
|
|
name: 'patient_numbers',
|
|
source: substringMatcher(<?php echo json_encode($faqs); ?>)
|
|
}
|
|
);
|
|
</script>
|
|
@endpush
|