v1.5.15a - Changes by Anders
This commit is contained in:
@@ -40,7 +40,7 @@
|
||||
<tr id="guide_row_{{ $guide->id }}" data-id="guide_category_row{{ \App\GuidesCategory::query()->where('id', '=', $guide->guide_category_id)->first()->id }}">
|
||||
<td>{{$guide->name}}</td>
|
||||
<td>{{ \App\GuidesCategory::query()->where('id', '=', $guide->guide_category_id)->first()->guidesCategoryName }}</td>
|
||||
<td><a id="preview" onclick="modalNewsContent({{$guide->id}})" style="cursor: pointer" ><img class="w-100" src="{{ asset('/images/icons/preview-dark.svg') }}" alt="preview"></a></td>
|
||||
<td><a id="preview" onclick="modalGuidesContent({{$guide->id}})" style="cursor: pointer" ><img class="w-100" src="{{ asset('/images/icons/preview-dark.svg') }}" alt="preview"></a></td>
|
||||
@if(auth()->user()->can('guides.edit'))
|
||||
<td><a href="{{ route("guides.edit", [ "guide" => $guide ]) }}"><img class="w-100" src="{{ asset('/images/icons/pencil-dark.svg') }}" alt="Update"></a></td>
|
||||
@endif
|
||||
@@ -89,7 +89,7 @@
|
||||
</div>
|
||||
|
||||
|
||||
<div id="newsModal" class="modal zindex-100">
|
||||
<div id="guidesModal" class="modal zindex-100">
|
||||
<div id="modal-content" class="modal-content text-black d-block w-50">
|
||||
<span class="close" onclick="closeModal()">×</span>
|
||||
<center>
|
||||
@@ -104,9 +104,9 @@
|
||||
@endsection
|
||||
@section('scripts')
|
||||
<script>
|
||||
var modalNews = document.getElementById("newsModal");
|
||||
var modalGuides = document.getElementById("guidesModal");
|
||||
|
||||
function modalNewsContent(id) {
|
||||
function modalGuidesContent(id) {
|
||||
$.ajax({
|
||||
type: 'get',
|
||||
url: '{{route('guides.preview')}}',
|
||||
@@ -128,15 +128,15 @@
|
||||
}
|
||||
|
||||
function closeModal() {
|
||||
modalNews.style.display = "none";
|
||||
modalGuides.style.display = "none";
|
||||
$("#name").html('');
|
||||
$("#guide_articles").html('');
|
||||
$("#eventimg").attr('src', '');
|
||||
}
|
||||
|
||||
window.onmousedown = function(event) {
|
||||
if (event.target == modalNews) {
|
||||
modalNews.style.display = "none";
|
||||
if (event.target == modalGuides) {
|
||||
modalGuides.style.display = "none";
|
||||
$("#name").html('');
|
||||
$("#guide_articles").html('');
|
||||
$("#eventimg").attr('src', '');
|
||||
|
||||
Reference in New Issue
Block a user