2018-04-15 09:41:53 +02:00
|
|
|
@push('componentScripts')
|
2018-06-15 20:50:40 +02:00
|
|
|
<script src="{{ $U('/viewjs/components/datetimepicker.js', true) }}?v={{ $version }}"></script>
|
2018-04-15 09:41:53 +02:00
|
|
|
@endpush
|
|
|
|
|
2018-09-22 22:01:32 +02:00
|
|
|
@php if(!isset($isRequired)) { $isRequired = true; } @endphp
|
2018-09-23 19:26:13 +02:00
|
|
|
@php if(!isset($initialValue)) { $initialValue = ''; } @endphp
|
2018-09-22 22:01:32 +02:00
|
|
|
|
2018-04-15 09:41:53 +02:00
|
|
|
<div class="form-group">
|
2018-07-14 08:38:03 +02:00
|
|
|
<label for="{{ $id }}">{{ $L($label) }} <span class="small text-muted"><time id="datetimepicker-timeago" class="timeago timeago-contextual"></time>@if(!empty($hint))<br>{{ $L($hint) }}@endif</span></label>
|
2018-09-08 08:36:45 +02:00
|
|
|
<div class="input-group">
|
|
|
|
<div class="input-group date datetimepicker @if(!empty($additionalCssClasses)){{ $additionalCssClasses }}@endif" id="{{ $id }}" data-target-input="nearest">
|
2018-09-22 22:01:32 +02:00
|
|
|
<input type="text" @if($isRequired) required @endif class="form-control datetimepicker-input"
|
2018-09-08 08:36:45 +02:00
|
|
|
data-target="#{{ $id }}" data-format="{{ $format }}"
|
|
|
|
data-init-with-now="{{ BoolToString($initWithNow) }}"
|
2018-09-23 19:26:13 +02:00
|
|
|
data-init-value="{{ $initialValue }}"
|
2018-09-08 08:36:45 +02:00
|
|
|
data-limit-end-to-now="{{ BoolToString($limitEndToNow) }}"
|
|
|
|
data-limit-start-to-now="{{ BoolToString($limitStartToNow) }}"
|
|
|
|
data-next-input-selector="{{ $nextInputSelector }}" />
|
|
|
|
<div class="input-group-append" data-target="#{{ $id }}" data-toggle="datetimepicker">
|
|
|
|
<div class="input-group-text"><i class="fas fa-calendar"></i></div>
|
|
|
|
</div>
|
2018-07-10 20:37:13 +02:00
|
|
|
</div>
|
2018-08-06 22:41:35 +02:00
|
|
|
@if(isset($shortcutValue) && isset($shortcutLabel))
|
|
|
|
<div class="form-check w-100">
|
|
|
|
<input class="form-check-input" type="checkbox" id="datetimepicker-shortcut" data-datetimepicker-shortcut-value="{{ $shortcutValue }}">
|
|
|
|
<label class="form-check-label" for="datetimepicker-shortcut">{{ $L($shortcutLabel) }}</label>
|
|
|
|
</div>
|
|
|
|
@endif
|
2018-07-12 19:12:31 +02:00
|
|
|
<div class="invalid-feedback">{{ $invalidFeedback }}</div>
|
2018-04-15 09:41:53 +02:00
|
|
|
</div>
|
|
|
|
</div>
|