Updates to 03-2025

This commit is contained in:
Kevin Adametz 2025-04-01 10:40:14 +02:00
parent 881fc84207
commit 4eb83def39
142 changed files with 21396 additions and 11243 deletions

View file

@ -0,0 +1,226 @@
@extends('layouts.layout-2')
@section('content')
{!! Form::open(['url' => route('cms_news_detail', [$id]), 'class' => 'form-horizontal']) !!}
<h4 class="font-weight-bold py-3 mb-1">
News @if($id == "new") <span class="text-primary">anlegen</span> @else {{"(ID: ".$id.")"}} verwalten @endif
<div class="float-right">
<button type="submit" name="action" value="saveAll" class="btn btn-submit btn-sm">{{ __('save changes') }}</button>&nbsp;
<a href="{{route('cms_news')}}" class="btn btn-default btn-sm">{{ __('back') }}</a>
</div>
</h4>
<div class="clearfix"></div>
<input type="hidden" name="id" id="id" value="{{$id}}">
<!-- draft -->
<div class="card mb-2">
<div class="card-body">
<div class="form-row">
<div class="form-group col-sm-8">
<label class="form-label" for="news_title">{{ __('Title') }}*</label>
{{ Form::text('title', $news->title, array('placeholder'=>__('Title'), 'class'=>'form-control', 'id'=>'news_title', 'required'=>true)) }}
</div>
<div class="form-group col-sm-4">
<label class="custom-control custom-checkbox float-right">
{!! Form::checkbox('status', 1, $news->status, ['class'=>'custom-control-input']) !!}
<span class="custom-control-label">{{__('aktiv')}}</span>
</label>
{{-- @if($news->lvl != 0)
<label for="news_parent" class="form-label">{{__('Parent')}}*</label>
<select class="custom-select" data-style="btn-default" name="news_parent" required>
{!! HTMLHelper::getParentBy($news->parent, $news->getParentsArray()) !!}
</select>
@else
<label for="news_parent" class="form-label">{{__('Parent')}}</label>
<div>NON</div>
@endif
--}}
</div>
</div>
<div class="form-row">
<div class="form-group col-sm-8">
<label class="form-label" for="news_slug">{{ __('slug') }}*</label>
{{ Form::text('slug', $news->slug, array('placeholder'=>__('slug'), 'class'=>'form-control', 'id'=>'news_slug', 'required'=>true)) }}
</div>
<div class="form-group col-sm-4">
<label class="form-label" for="news_date">{{ __('Reisezeitraum') }}*</label>
{{ Form::text('date', $news->date, array('placeholder'=>__('Reisezeitraum'), 'class'=>'form-control datepicker-base', 'id'=>'news_date', 'required'=>true)) }}
</div>
</div>
<div class="form-row">
<div class="form-group col-sm-12">
<label class="form-label" for="news_content_new">{{ __('Text') }}*</label>
{{ Form::textarea('content_new', HTMLHelper::filterHTML($news->content_new, ['src' => ['addHost']]) , ['class' => 'form-control summernote', 'id'=>'news_content_new']) }}
</div>
</div>
<div class="form-row">
<div class="form-group col-md-12">
<label class="form-label" for="news_pagetitle">{{ __('META-Titel (optional)') }}</label>
{{ Form::text('pagetitle', $news->pagetitle, array('placeholder'=>__('pagetitle'), 'class'=>'form-control', 'id'=>'news_pagetitle')) }}
</div>
<div class="form-group col-md-12">
<label class="form-label" for="news_description">{{ __('META-Beschreibung (optional)') }}</label>
{{ Form::text('description', $news->description, array('placeholder'=>__('description'), 'class'=>'form-control', 'id'=>'news_description')) }}
</div>
<div class="form-group col-md-12">
<label class="form-label" for="news_keywords">{{ __('META-Keywords (optional)') }}</label>
{{ Form::text('keywords', $news->keywords, array('placeholder'=>__('keywords'), 'class'=>'form-control', 'id'=>'news_keywords')) }}
</div>
</div>
<h4 class="mb-0 bg-light p-1">Hauptbild</h4>
<hr class="mt-0">
<div class="media mx-auto pb-3" id="lfm-data-fill">
<img src="{{$news->getImage('thumb_url')}}" alt="" class="img_thumb_url d-block ui-w-100">
<div class="media-body mt-2 ml-2">
<div class="form-row">
<div class="form-group col-10 col-sm-11" >
{{ Form::hidden('image[slug]', $news->getImage('slug')) }}
{{ Form::hidden('image[thumb_url]', $news->getImage('thumb_url')) }}
{{ Form::hidden('image[url]', $news->getImage('url')) }}
{{ Form::text('image[title]', $news->getImage('title'), array('placeholder'=>'Bildtitel', 'class'=>'form-control mb-2')) }}
{{ Form::text('image[alt]', $news->getImage('alt'), array('placeholder'=>'Bild ALT Tag', 'class'=>'form-control')) }}
</div>
<div class="form-group col-2 col-sm-1">
<button type="button" class="btn btn-sm btn-secondary float-right btn-lfm-open-modal"
data-id="#lfm-data-fill"
data-obj="image"
data-set='["url", "slug", "thumb_url"]'
data-img='.img_thumb_url'
data-title="title"
data-alt="alt">
<i class="fa fa-image"></i>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="text-left mt-3">
<button type="submit" name="action" value="saveAll" class="btn btn-submit">{{ __('save changes') }}</button>&nbsp;
<a href="{{route('cms_news')}}" class="btn btn-default">{{ __('back') }}</a>
<a href="{{ make_v2_url("/acp/") }}" class="btn btn-default float-right">{{ __('zurück ins v2 Programm') }}</a>
</div>
{!! Form::close() !!}
{{--
<!-- Modal template -->
<div class="modal fade" id="modals-class">
<div class="modal-dialog">
<form class="modal-content" action="{{ route('travel_program_class_update') }}" method="post">
@csrf
<input type="hidden" class="form-control" name="id">
<input type="hidden" class="form-control" name="program_id" value="{{$news->id}}">
<div class="modal-header">
<h5 class="modal-title">Programm Katagorie/Klassen <span class="font-weight-light">anlegen/bearbeiten</span></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>
</div>
<div class="modal-body">
<div class="form-row">
<div class="form-group col">
<label class="custom-control custom-checkbox float-right">
<input type="checkbox" class="custom-control-input" name="standard" checked>
<span class="custom-control-label">{{__('Standard')}}</span>
</label>
<label for="name" class="form-label">Name*</label>
<input type="text" class="form-control" name="name" placeholder="{{__('Description')}}" required>
</div>
</div>
<div class="form-row">
<div class="form-group col">
<label for="description" class="form-label">Beschreibung</label>
<input type="text" class="form-control" name="description" placeholder="{{__('Description')}}">
</div>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">{{__('close')}}</button>
<button type="submit" class="btn btn-primary">{{__('save')}}</button>
</div>
</form>
</div>
</div>
<!-- Modal template -->
<div class="modal fade" id="modals-draft">
<div class="modal-dialog">
<form class="modal-content" action="{{ route('travel_program_draft_update') }}" method="post">
@csrf
<input type="hidden" class="form-control" name="id">
<input type="hidden" class="form-control" name="travel_program_id" value="{{$news->id}}">
<div class="modal-header">
<h5 class="modal-title">Vorlage Reiseprogramm <span class="font-weight-light">zuordnen</span></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>
</div>
<div class="modal-body">
<div class="form-row">
<div class="form-group col">
<label for="draft_id" class="form-label">{{__('Vorlage')}}</label>
<select class="selectpicker" data-style="btn-default" name="draft_id" data-live-search="true" required>
{!! HTMLHelper::getDraftOptions() !!}
</select>
</div>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">{{__('close')}}</button>
<button type="submit" class="btn btn-primary">{{__('save')}}</button>
</div>
</form>
</div>
</div>
<script>
$( document ).ready(function() {
$('#modals-class').on('show.bs.modal', function (event) {
var button = $(event.relatedTarget);
$(this).find(".modal-content input[name='id']").val(button.data('id'));
$(this).find(".modal-body input[name='name']").val(button.data('name'));
$(this).find(".modal-body input[name='description']").val(button.data('description'));
$(this).find(".modal-body input[name='standard']").prop( "checked", button.data('standard'));
});
$('#modals-draft').on('show.bs.modal', function (event) {
var button = $(event.relatedTarget);
$(this).find(".modal-content input[name='id']").val(button.data('id'));
$(this).find(".modal-body select[name='draft_id']").val(button.data('draft_id'));
$(this).find(".modal-body select[name='travel_class_id']").val(button.data('travel_class_id'));
$(this).find(".modal-body select[name='weekdays[]']").val(button.data('weekdays'));
$('.selectpicker').selectpicker('refresh');
});
});
</script>
--}}
@endsection
@section('scripts')
<script>
$(document).ready(function() {
IqLFileManager.init();
});
</script>
@endsection