@php //print_r($FieldsList); @endphp
@foreach($FieldsList as $Field) @php $checked=""; $selected=""; @endphp @if($Field->DependentField==1) @php $DependentFieldId=$Field->DependentFieldId; $DependentFieldId=explode(',',$DependentFieldId); $optionsLength=sizeof($options); $count=0; foreach($options as $option) { if(in_array($option,$DependentFieldId)) { $count++; } } if($count==$optionsLength) { $checked="checked"; } else { $checked=""; } @endphp @endif
@endforeach