61 lines
3.6 KiB
PHP
61 lines
3.6 KiB
PHP
<div class="form-group">
|
|
<label for="name">{{ __('Nom') }} *</label>
|
|
<input type="text" id="title" name="title" class="form-control" placeholder="{{ __('Nom') }} *" value="{{ old('title', $gamme->title ?? '') }}" required>
|
|
@include('back.modules.input-error', ['inputName'=>'title'])
|
|
</div>
|
|
<div class="form-group mb-3">
|
|
<label for="name">{{ __('Texte') }}</label>
|
|
<input type="text" id="text" name="text" class="form-control" placeholder="{{ __('Texte') }} *" value="{{ old('text', $gamme->text ?? '') }}" required>
|
|
@include('back.modules.input-error', ['inputName'=>'text'])
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="picture">{{ __('Vignette') }} <small class="text-muted">- JPEG/PNG, 1Mo max. Dimensions {{ Config::get('bo.gamme_image_maxwidth') }} px par {{ Config::get('bo.gamme_image_maxheight') }} px</small></label><br/>
|
|
<input type="file" id="picture" name="picture" accept="image/png, image/jpeg">
|
|
@if (!empty($gamme->picture))
|
|
<br/>
|
|
<br/>
|
|
<img src="{{$gamme->picture}}" alt="{{$gamme->alt_text_picture}}" style="max-height: 100px;">
|
|
@endif
|
|
@include('back.modules.input-error', ['inputName'=>'picture'])
|
|
</div>
|
|
<div class="form-group mb-3">
|
|
<label for="name">{{ __('Text alternatif de la vignette') }} *</label>
|
|
<input type="text" id="alt_text_picture" name="alt_text_picture" class="form-control" placeholder="{{ __('Texte alternatif de la vignette') }} *" value="{{ old('alt_text_picture', $gamme->alt_text_picture ?? '') }}" required>
|
|
@include('back.modules.input-error', ['inputName'=>'alt_text_picture'])
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="banner">{{ __('Bannière') }} <small class="text-muted">- JPEG/PNG, 2Mo max. Dimensions {{ Config::get('bo.gamme_banner_maxwidth') }} px par {{ Config::get('bo.gamme_banner_maxheight') }} px</small></label><br/>
|
|
<input type="file" id="banner" name="banner" accept="image/png, image/jpeg">
|
|
@if (!empty($gamme->banner))
|
|
<br/>
|
|
<br/>
|
|
<img src="{{$gamme->banner}}" alt="{{$gamme->alt_text_banner}}" style="max-height: 100px;">
|
|
@endif
|
|
@include('back.modules.input-error', ['inputName'=>'banner'])
|
|
</div>
|
|
<div class="form-group mb-3">
|
|
<label for="name">{{ __('Text alternatif de la bannière') }} *</label>
|
|
<input type="text" id="alt_text_banner" name="alt_text_banner" class="form-control" placeholder="{{ __('Texte alternatif de la bannière') }} *" value="{{ old('alt_text_banner', $gamme->alt_text_banner ?? '') }}" required>
|
|
@include('back.modules.input-error', ['inputName'=>'alt_text_banner'])
|
|
</div>
|
|
|
|
<div class="form-row mb-3">
|
|
<div class="form-group col">
|
|
<label for="parent_gamme_id">{{ __('Gamme parente') }}</label>
|
|
<select class="custom-select" id="parent_gamme_id" name="parent_gamme_id">
|
|
<option value="0">Pas de parent</option>
|
|
@foreach($parentGammes as $parentGamme)
|
|
<option value="{{$parentGamme->id}}" @if ($parentGamme->id === $gamme->parent_gamme_id) selected @endif>{{$parentGamme->title}}</option>
|
|
@endforeach
|
|
</select>
|
|
</div>
|
|
<div class="form-group col"></div>
|
|
<div class="form-group col"></div>
|
|
<div class="form-group col"></div>
|
|
@include('back.modules.input-error', ['inputName'=>'parent_gamme_id'])
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="color" class="form-label">Couleur de la gamme</label>
|
|
<input type="color" class="form-control form-control-color" name="color" id="color" value="{{ old('color', $gamme->color ?? '') }}" @if ($gamme->parent_gamme_id != null) disabled @endif title="Choisissez la couleur">
|
|
@include('back.modules.input-error', ['inputName'=>'color'])
|
|
</div>
|