ldc-startcoq/resources/views/partials/inputs/int-number.blade.php

36 lines
904 B
PHP

@if(!empty($label))
<label for="{{ $id }}" class="col-form-label">
<b>{{ $label }} {{ $required ? '*' : '' }}</b>
</label>
@endif
<input
id="{{ $id }}"
name="{{ $name }}"
type="number"
value="{{ old($name, $model->{$name} ?? $value ?? null) }}"
class="form-control"
aria-describedby="{{ $id }}Help"
@if(!empty($step))
step="{{ $step }}"
@else
step="1"
@endif
@if(!empty($max))
max="{{ $max }}"
@else
max="{{ !empty($unsigned) ? '4294967295' : '2147483647' }}"
@endif
@if(isset($min))
min="{{ $min }}"
@else
min="{{ !empty($unsigned) ? '0' : '-2147483648' }}"
@endif
@if(!empty($required))required @endif
@if(!empty($disabled))disabled @endif
@if(!empty($readonly))readonly @endif
>
@include('modules.input-error', [
'inputName' => $name,
'helperId' => '{{ $id }}Help',
'helper' => $helper
])