Update
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
@extends('admin::layout.default')
|
||||
|
||||
@section('content')
|
||||
@include('plugin.services::heading')
|
||||
@include('plugin.services::form', ['pageURL' => route('admin.plugin.services.insert')])
|
||||
@endsection
|
||||
6
oldSite/Plugins/Services/Resources/views/edit.blade.php
Normal file
6
oldSite/Plugins/Services/Resources/views/edit.blade.php
Normal file
@@ -0,0 +1,6 @@
|
||||
@extends('admin::layout.default')
|
||||
|
||||
@section('content')
|
||||
@include('plugin.services::heading')
|
||||
@include('plugin.services::form', ['pageURL' => route('admin.plugin.services.update', [$table->service_id])])
|
||||
@endsection
|
||||
130
oldSite/Plugins/Services/Resources/views/form.blade.php
Normal file
130
oldSite/Plugins/Services/Resources/views/form.blade.php
Normal file
@@ -0,0 +1,130 @@
|
||||
<section class="content" id="serviceApp">
|
||||
<form action="{{ $pageURL }}" method="post" enctype="multipart/form-data">
|
||||
@csrf
|
||||
|
||||
@component('admin::blocks.card_language', ['languages' => $languages])
|
||||
|
||||
<div class="tab-content" id="block-tabContent">
|
||||
@foreach($languages as $lang)
|
||||
<div class="tab-pane fade show @if($loop->first) active @endif"
|
||||
id="{{ $lang->iso }}"
|
||||
role="tabpanel"
|
||||
aria-labelledby="tab-{{ $lang->iso }}">
|
||||
|
||||
<div class="row">
|
||||
<div class="col col-md-6">
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label">{{ trans('admin.HEADLINE') }}</label>
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text">
|
||||
<img src="{{ config('cp.admin_path') }}/images/flags/languages/16/{{ $lang->iso }}.png" alt="">
|
||||
</span>
|
||||
</div>
|
||||
<input class="form-control" type="text" name="prevod[{{ $lang->iso }}][headline]" value="{{ $translation[$lang->iso]['headline'] ?? null}}">
|
||||
</div> <!-- end .input-group -->
|
||||
</div> <!-- end .form-group -->
|
||||
|
||||
|
||||
<label class="label-control">{{trans('admin.CONTENT')}} 1</label>
|
||||
<textarea name="prevod[{{ $lang->iso }}][content1]"
|
||||
class="tinymce2"
|
||||
style="width:100%;height:150px;">{{ $translation[$lang->iso]['content1'] ?? null }}
|
||||
</textarea>
|
||||
|
||||
<label class="label-control">{{trans('admin.CONTENT')}} 2</label>
|
||||
<textarea name="prevod[{{ $lang->iso }}][content2]"
|
||||
class="tinymce2"
|
||||
style="width:100%;height:150px;">{{ $translation[$lang->iso]['content2'] ?? null }}
|
||||
</textarea>
|
||||
|
||||
|
||||
</div> <!-- end .col -->
|
||||
|
||||
<div class="col col-md-6">
|
||||
<label class="label-control">{{trans('admin.CONTENT')}} 3</label>
|
||||
<textarea name="prevod[{{ $lang->iso }}][content3]"
|
||||
class="tinymce2"
|
||||
style="width:100%;height:100px;">{{ $translation[$lang->iso]['content3'] ?? null }}
|
||||
</textarea>
|
||||
|
||||
|
||||
<label class="label-control">{{trans('admin.CONTENT')}} 4</label>
|
||||
<textarea name="prevod[{{ $lang->iso }}][content4]"
|
||||
class="tinymce2"
|
||||
style="width:100%;height:100px;">{{ $translation[$lang->iso]['content4'] ?? null }}
|
||||
</textarea>
|
||||
|
||||
|
||||
<label class="label-control">{{trans('admin.CONTENT')}} 5</label>
|
||||
<textarea name="prevod[{{ $lang->iso }}][content5]"
|
||||
class="tinymce2"
|
||||
style="width:100%;height:100px;">{{
|
||||
$translation[$lang->iso]['content5'] ?? null }}
|
||||
</textarea>
|
||||
|
||||
</div> <!-- end .col -->
|
||||
</div> <!-- end .row -->
|
||||
|
||||
<hr>
|
||||
|
||||
</div> <!-- end .tab-pane -->
|
||||
@endforeach
|
||||
|
||||
<label>
|
||||
<input type="hidden" name="active" value="N">
|
||||
<input type="checkbox" class="minimal" name="active" value="Y"
|
||||
@if (isset($table->active))
|
||||
@if($table->active == 'Y')
|
||||
checked
|
||||
@endif
|
||||
@endif
|
||||
> {{ trans('admin.ACTIVE') }}<br>
|
||||
</label>
|
||||
|
||||
@include('plugin.services::form.layout')
|
||||
|
||||
<div class="text-center">
|
||||
<button type="submit" class="btn btn-success"><i class="fa fa-save fa-fw"></i> {{ trans('admin.SAVE') }}</button>
|
||||
</div>
|
||||
|
||||
</div> <!-- end .tab-content -->
|
||||
@endcomponent
|
||||
</form>
|
||||
</section>
|
||||
|
||||
@section('header-addon')
|
||||
@append
|
||||
@section('footer-addon')
|
||||
<script>
|
||||
$(document).on("change", ".thumbPreview", function(evt) {
|
||||
var lang = $(this).data('lang');
|
||||
var files = evt.target.files;
|
||||
var f = files[0];
|
||||
var reader = new FileReader();
|
||||
|
||||
reader.onload = (function(theFile) {
|
||||
return function(e) {
|
||||
$('.quickPreview-' + lang).html('<img src="' + e.target.result + '" title="' + theFile.name + '" class="img-responsive">');
|
||||
};
|
||||
})(f);
|
||||
|
||||
reader.readAsDataURL(f);
|
||||
});
|
||||
|
||||
var app = new Vue({
|
||||
el: '#serviceApp',
|
||||
data: {
|
||||
content1: null,
|
||||
content2: null,
|
||||
content3: null,
|
||||
content4: null,
|
||||
content5: null,
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
});
|
||||
</script>
|
||||
@append
|
||||
377
oldSite/Plugins/Services/Resources/views/form/layout.blade.php
Normal file
377
oldSite/Plugins/Services/Resources/views/form/layout.blade.php
Normal file
@@ -0,0 +1,377 @@
|
||||
<br>
|
||||
<hr>
|
||||
<h1>{{ trans('admin.LAYOUT') }}</h1>
|
||||
<br>
|
||||
<div class="services-grid">
|
||||
|
||||
|
||||
<div class="holder">
|
||||
<article class="article article01">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="text-holder">
|
||||
<div class="text" data-text="01">
|
||||
<p>CONTENT 1</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">309x461</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_1"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture1">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture1">
|
||||
@if (!empty($table->picture_1))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_1 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/309X461" class="img-fluid upload-box">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">1132x792</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_2"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture2">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture2">
|
||||
@if (!empty($table->picture_2))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_2 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/1132X792" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
</div> <!-- end .img-box -->
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
<hr>
|
||||
|
||||
<article class="article article02">
|
||||
<div class="row align-items-start">
|
||||
<div class="col-md-3 offset-md-3">
|
||||
<div class="text-holder">
|
||||
<div class="text" data-text="02">
|
||||
<p>CONTENT 2</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">746x746</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_3"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture3">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture3">
|
||||
@if (!empty($table->picture_3))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_3 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/746x746" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
|
||||
</div> <!-- end .img-box -->
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
|
||||
<hr>
|
||||
|
||||
<article class="article article03">
|
||||
<div class="row">
|
||||
<div class="col-md-3 order-md-2">
|
||||
<div class="text-holder">
|
||||
<div class="text" data-text="03">
|
||||
<p>CONTENT 3</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6 img-col">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">746x909</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_4"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture4">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture4">
|
||||
@if (!empty($table->picture_4))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_4 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/746x909" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
</div> <!-- end .img-box -->
|
||||
</div>
|
||||
<div class="col-md-3 order-md-3">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">358x358</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_5"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture5">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
<div id="quickPreviewPicture5">
|
||||
@if (!empty($table->picture_5))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_5 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/358x358" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
|
||||
<hr>
|
||||
|
||||
<article class="article article04">
|
||||
<div class="row">
|
||||
<div class="col-md-3 order-md-4">
|
||||
<div class="text-holder">
|
||||
<div class="text" data-text="04">
|
||||
<p>CONTENT 4</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3 img-col">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">358x358</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_6"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture6">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture6">
|
||||
@if (!empty($table->picture_6))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_6 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/358x358" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
|
||||
</div>
|
||||
<br>
|
||||
<div class="img-box">
|
||||
<div class="upload-box">
|
||||
<div class="resolution">358x358</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_7"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture7">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture7">
|
||||
@if (!empty($table->picture_7))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_7 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/358x358" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="img-box">
|
||||
|
||||
<div class="upload-box">
|
||||
<div class="resolution">748x765</div>
|
||||
<div class="upload">
|
||||
<div class="upload-btn-wrapper">
|
||||
<i class="fa fa-upload"></i>
|
||||
<input type="file"
|
||||
name="picture_8"
|
||||
class="pictureUploadPreview"
|
||||
data-preview="quickPreviewPicture8">
|
||||
</div> <!-- end .btn -->
|
||||
</div> <!-- end .upload -->
|
||||
</div> <!-- end .upload-box -->
|
||||
|
||||
<div id="quickPreviewPicture8">
|
||||
@if (!empty($table->picture_8))
|
||||
<img src="/{{ $uploadPath }}{{ $table->picture_8 ?? null }}"
|
||||
class="img-fluid">
|
||||
@else
|
||||
<img src="https://via.placeholder.com/748x765" class="img-fluid" alt="image description">
|
||||
@endif
|
||||
</div> <!-- end #quickPreview -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-12 col-md-6 col-lg-4 col-xl-3 offset-md-6 offset-lg-8 offset-xl-9">
|
||||
<div class="text-info-box" data-speed="130">
|
||||
<div class="info">
|
||||
CONTENT 5
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
|
||||
|
||||
@section('header-addon')
|
||||
<style>
|
||||
.text-info-box {
|
||||
background: black;
|
||||
color:white;
|
||||
font-size:15px;
|
||||
min-height:150px;
|
||||
display:grid;
|
||||
align-items: center;
|
||||
text-align:center;
|
||||
}
|
||||
.upload-box {
|
||||
display:grid;
|
||||
grid-template-columns: auto 20px;
|
||||
grid-template-rows: 20px;
|
||||
grid-gap:0;
|
||||
color:#999;
|
||||
font-size:10px;
|
||||
margin-bottom:1px;
|
||||
}
|
||||
|
||||
.upload-box > div.resolution {
|
||||
color:#ccc;
|
||||
align-self: end;
|
||||
}
|
||||
|
||||
.upload-box > div.upload {
|
||||
color:#bbb;
|
||||
max-height:16px;
|
||||
font-size:12px;
|
||||
text-align:right;
|
||||
align-self: end;
|
||||
}
|
||||
|
||||
.upload-box > div.upload:hover {
|
||||
cursor:pointer;
|
||||
color:#909;
|
||||
}
|
||||
|
||||
.img-box, .text {
|
||||
border:dotted 1px #ccc;
|
||||
padding:3px;
|
||||
margin-bottom:3px;
|
||||
}
|
||||
|
||||
.image-preview > img {
|
||||
object-fit: contain;
|
||||
width:100%;
|
||||
height:200px;
|
||||
}
|
||||
|
||||
.upload-btn-wrapper {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
display: inline-block;
|
||||
padding:0;
|
||||
margin:0;
|
||||
}
|
||||
|
||||
.upload-btn-wrapper input[type=file] {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.upload-box {
|
||||
cursor: pointer;
|
||||
}
|
||||
</style>
|
||||
@append
|
||||
|
||||
@section('footer-addon')
|
||||
<script>
|
||||
$(document).on("change", ".pictureUploadPreview", function(evt) {
|
||||
|
||||
var files = evt.target.files;
|
||||
var f = files[0];
|
||||
var reader = new FileReader();
|
||||
let obj = $(this).data('preview');
|
||||
|
||||
reader.onload = (function(theFile) {
|
||||
return function(e) {
|
||||
|
||||
document.getElementById(obj).innerHTML = ['<img src="', e.target.result,'" title="', theFile.name, '" class="img-fluid" />'].join('');
|
||||
};
|
||||
})(f);
|
||||
|
||||
reader.readAsDataURL(f);
|
||||
});
|
||||
|
||||
</script>
|
||||
@append
|
||||
13
oldSite/Plugins/Services/Resources/views/heading.blade.php
Normal file
13
oldSite/Plugins/Services/Resources/views/heading.blade.php
Normal file
@@ -0,0 +1,13 @@
|
||||
@component('admin::blocks.heading')
|
||||
@slot('mainRoute')
|
||||
{{ route('admin.plugin.services') }}
|
||||
@endslot
|
||||
|
||||
@slot('addRoute')
|
||||
{{ route('admin.plugin.services.create') }}
|
||||
@endslot
|
||||
|
||||
@slot('title')
|
||||
{{ trans('admin.SERVICES') }}
|
||||
@endslot
|
||||
@endcomponent
|
||||
63
oldSite/Plugins/Services/Resources/views/main.blade.php
Normal file
63
oldSite/Plugins/Services/Resources/views/main.blade.php
Normal file
@@ -0,0 +1,63 @@
|
||||
@extends('admin::layout.default')
|
||||
|
||||
@section('content')
|
||||
@include('plugin.services::heading')
|
||||
|
||||
<section class="content">
|
||||
@component('admin::blocks.card')
|
||||
@slot('title')
|
||||
{{ trans('admin.LIST') }}
|
||||
@endslot
|
||||
@slot('actions')
|
||||
@endslot
|
||||
@include('admin::blocks.notification_error')
|
||||
|
||||
<table class="table table-bordered table-striped table-hover table-advance">
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ trans('admin.OPTIONS') }}</th>
|
||||
<th>{{ trans('admin.TITLE') }}</th>
|
||||
<th>{{ trans('admin.VISIBLE') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
@foreach($table as $row)
|
||||
<tr id="{{$row->service_id}}">
|
||||
<td width="36">
|
||||
|
||||
<x-table-options
|
||||
editURL="{{ route('admin.plugin.services.edit', $row->service_id) }}"
|
||||
deleteURL="{{ route('admin.plugin.services.delete', $row->service_id) }}"
|
||||
/>
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ route('admin.plugin.services.edit', $row->service_id) }}">
|
||||
{{ $row->headline ?? null }}
|
||||
</a>
|
||||
</td>
|
||||
<td class="text-center">
|
||||
@if ($row->active == 'Y')
|
||||
<i style="color:#0a0" class="fa fa-check-circle"></i>
|
||||
@else
|
||||
<i style="color:#a00" class="fa fa-ban"></i>
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
@endcomponent
|
||||
</section>
|
||||
@endsection
|
||||
|
||||
@section('footer-addon')
|
||||
<script>
|
||||
var slider = document.getElementById("myRange");
|
||||
slider.oninput = function() {
|
||||
$('.slider-image').width(this.value + '%');
|
||||
}
|
||||
</script>
|
||||
@append
|
||||
Reference in New Issue
Block a user