ldc-supportweb/resources/views/crud/formfields/email.blade.php
Jérémy Munsch b60913525b - bump to Bootstrap 5
- added ACL policies
- added CRUD generic
- added User crud
- added search bar
2021-06-18 15:39:19 +02:00

33 lines
1.4 KiB
PHP

<td>
<label for="{{ $fieldName }}" class="form-label">{{ $prop['label'] }}</label>
</td>
<td>
@if(strlen($prop['placeholder']))
<div class="form-floating">
<input
id="{{ $fieldName }}"
name="{{ $fieldName }}"
type="email"
class="form-control"
value="{{ old($fieldName) ?? $model->{$fieldName} ?? '' }}"
@if(isset($prop['rules']['max']))maxlength="{{ $prop['rules']['max'] }}"@endif
@if(isset($prop['rules']['min']))minlength="{{ $prop['rules']['min'] }}"@endif
@if($prop['disabled'])disabled @endif
@if($readonly)readonly @endif
@if($prop['required'] or (!$prop['required'] and !$prop['nullable']))required @endif>
<label for="{{ $fieldName }}" class="form-label">{{ __('ex: :placeholder', ['placeholder' => $prop['placeholder']]) }}</label>
</div>
@else
<input
id="{{ $fieldName }}"
name="{{ $fieldName }}"
type="email"
class="form-control"
value="{{ old($fieldName) ?? $model->{$fieldName} ?? '' }}"
@if(isset($prop['rules']['max']))maxlength="{{ $prop['rules']['max'] }}"@endif
@if(isset($prop['rules']['min']))minlength="{{ $prop['rules']['min'] }}"@endif
@if($prop['disabled'])disabled @endif
@if($readonly)readonly @endif
@if($prop['required'] or (!$prop['required'] and !$prop['nullable']))required @endif>
@endif
</td>