Final Response

@if(!empty($data))
Aggregated Responses
@foreach($risks as $k=>$val) @php $ref = $risks_ref_no[$k]; //$actionplan_id = $risk_reference_no[$ref]; //dd($ref); @endphp @php $create = url('/actionplans/create'); $url = ''; if(isset($action_plans[$ref])){ $url = url('/actionplans/show/'.$action_plans[$ref]); } //$url = url('/actionplans/show/'.$action_plans[$ref]); $final_likelihood = $avg_risk_likelyhood[$k]; $final_impact = $avg_risk_impact[$k]; $final_design = $avg_risk_control_design[$k]; $final_performance = $avg_risk_cntrl_prfmnc[$k]; $intersect_calculated_risk = $avg_risk_residual[$k]; //$avg_risk_perceived = $avg_risk_perceived[$k]; /* $divisor = count($respondents); $likelihood = intval($row['inherent_risk_likelyhood']/$divisor); $impact = intval($row['inherent_risk_impact']/$divisor); $calculated = intval($row['calculated_residual_risk_impact']/$divisor); $perceived = intval($row['perceived_residual_risk_impact']/$divisor); $create = url('/actionplans/create'); $url = ''; if(isset($action_plans[$risks[$risk_id]])){ $url = url('/actionplans/show/'.$action_plans[$risks[$risk_id]]); } */ @endphp {{-- --}} @endforeach
Risk Reference No Risk Likelihood Risk Impact Risk Control/Performance Calculated Residual Risk Action Plan

{{@ucfirst($risks_ref_no[$k])}}

{{@ucwords($matrix['likelihood'][$final_likelihood])}}

{{@ucwords($matrix['impact'][$final_impact])}}

{{@ucwords($matrix['control_design'][$final_design])}}

{{@ucwords($matrix['control_performance'][$final_performance])}}

{{@ucwords($matrix['residual_risk'][$intersect_calculated_risk])}}

{{@ucwords($matrix['residual_risk'][$avg_risk_perceived])}}

@if(empty($url))Create@elseView@endif
@endif