checkbox.blade.php 907 B

1234567891011121314151617181920212223242526
  1. <div class="{{$viewClass['form-group']}} {!! !$errors->has($column) ?: 'has-error' !!}" {!! $inline ? 'style="margin-bottom:23px"' : '' !!}>
  2. <label for="{{$id}}" class="{{$viewClass['label']}} control-label">{!! $label !!}</label>
  3. <div class="{{$viewClass['field']}}" id="{{$id}}">
  4. @include('admin::form.error')
  5. @php
  6. $checkbox = new \Dcat\Admin\Widgets\Checkbox($name.'[]', $options, $checkboxStyle);
  7. if($inline) $checkbox->inline();
  8. if ($disabled) $checkbox->disabled();
  9. // {{ ($option == old($column, $value)) || ($value === null && in_array($label, $checked)) ?'checked':'' }}
  10. $checkbox->checked(old($column, $value));
  11. $checkbox->circle($circle);
  12. @endphp
  13. {!! $checkbox !!}
  14. <input type="hidden" name="{{$name}}[]">
  15. @include('admin::form.help-block')
  16. </div>
  17. </div>