@php $ligne=0; @endphp @foreach($liste_deficiences as $id=>$libelle) @php $ligne++; @endphp @for($col=1;$col<=4;$col++) @php $style="font-weight:bold;text-align:center;"; $value=isset($t_grille_handicap[$id][$col])?$t_grille_handicap[$id][$col]:""; if($value) { if($col==1) $back_color="#befcb4ff;"; if($col==2) $back_color="#fcd87cff"; if($col==3) $back_color="#fe8f3fff;"; if($col==4) $back_color="#fe583fff;"; } else $back_color="white;"; $style.="background-color:".$back_color.";"; @endphp @endfor @endforeach
Déficience \ Sévérité Forme légère (1-15%) Forme modérée (20-45%) Forme importante (50-75%) Forme sévère ou majeure (80-95%)
{{ $libelle }} @if($mode=='show') {!! html()->text('def_'.$col.'_'.$id,$value) ->attributes(['disabled','style'=>$style,'class' => 'form-control tx_calc']) !!} @else {!! html()->select('def_'.$col.'_'.$id,$t_taux[$col],$value) ->placeholder('') ->attributes([($mode=="show"?'disabled':''),'style'=>$style, 'class' => 'form-control tx_calc']) !!} @endif