Dashboard

Rating

{{--
--}}
@if(!$selectedtypes) @else Reset @endif
@if(!$selectedtypes) @else

Score Overview

@foreach($scores as $level) @foreach($selectedtypes as $types) @if($types == 'housing')

Housing Price

@switch($level->score->housing_level) @case('very low')

Very Low

@break @case('low')

Low

@break @case('medium')

Medium

@break @case('high')

High

@break @case('very high')

Very High

@break @default @endswitch
@elseif($types == 'lifestyle')

Life Style

@switch($level->score->life_style_risk_level) @case('very low')

Very Low

@break @case('low')

Low

@break @case('medium')

Medium

@break @case('high')

High

@break @case('very high')

Very High

@break @default @endswitch
@elseif($types == 'persona')

Persona

@switch($level->score->persona_level) @case('very low')

Very Low

@break @case('low')

Low

@break @case('medium')

Medium

@break @case('high')

High

@break @case('very high')

Very High

@break @default @endswitch
@elseif($types == 'financial')

Financial Risk

@switch($level->score->financial_risk_level) @case('very low')

Very Low

@break @case('low')

Low

@break @case('medium')

Medium

@break @case('high')

High

@break @case('very high')

Very High

@break @default @endswitch
@endif @endforeach @endforeach
@foreach($scores as $level) @foreach($selectedtypes as $types) @if($types == 'overall')
@switch($level->score->final_risk_level) @case('very low')

Overall Score

Very Low

@break @case('low')

Overall Score

Low

@break @case('medium')

Overall Score

Medium

@break @case('high')

Overall Score

High

@break @case('very high')

Overall Score

Very High

@break @default @endswitch
@endif @endforeach @endforeach
@php $promdata = array(); @endphp @php $prombg = array(); @endphp @foreach($scores as $level) @foreach($selectedtypes as $types) @if($types == 'housing') @switch($level->score->housing_level) @case('very low') @php $promdata[] = 2000; @endphp @php $prombg[] = '#7ed957'; @endphp @break @case('low') @php $promdata[] = 4000; @endphp @php $prombg[] = '#70c5d8'; @endphp @break @case('medium') @php $promdata[] = 6000; @endphp @php $prombg[] = '#fecd56'; @endphp @break @case('high') @php $promdata[] = 8000; @endphp @php $prombg[] = '#ff7c1f'; @endphp @break @case('very high') @php $promdata[] = 10000; @endphp @php $prombg[] = '#ff1616'; @endphp @break @default @php $promdata[] = 0; @endphp @php $prombg[] = '#7ed957'; @endphp @endswitch @elseif($types == 'lifestyle') @switch($level->score->life_style_risk_level) @case('very low') @php $promdata[] = 2000; @endphp @php $prombg[] = '#7ed957'; @endphp @break @case('low') @php $promdata[] = 4000; @endphp @php $prombg[] = '#70c5d8'; @endphp @break @case('medium') @php $promdata[] = 6000; @endphp @php $prombg[] = '#fecd56'; @endphp @break @case('high') @php $promdata[] = 8000; @endphp @php $prombg[] = '#ff7c1f'; @endphp @break @case('very high') @php $promdata[] = 10000; @endphp @php $prombg[] = '#ff1616'; @endphp @break @default @php $promdata[] = 0; @endphp @php $prombg[] = '#7ed957'; @endphp @endswitch @elseif($types == 'persona') @switch($level->score->persona_level) @case('very low') @php $promdata[] = 2000; @endphp @php $prombg[] = '#7ed957'; @endphp @break @case('low') @php $promdata[] = 4000; @endphp @php $prombg[] = '#70c5d8'; @endphp @break @case('medium') @php $promdata[] = 6000; @endphp @php $prombg[] = '#fecd56'; @endphp @break @case('high') @php $promdata[] = 8000; @endphp @php $prombg[] = '#ff7c1f'; @endphp @break @case('very high') @php $promdata[] = 10000; @endphp @php $prombg[] = '#ff1616'; @endphp @break @default @php $promdata[] = 0; @endphp @php $prombg[] = '#7ed957'; @endphp @endswitch @elseif($types == 'financial') @switch($level->score->financial_risk_level) @case('very low') @php $promdata[] = 2000; @endphp @php $prombg[] = '#7ed957'; @endphp @break @case('low') @php $promdata[] = 4000; @endphp @php $prombg[] = '#70c5d8'; @endphp @break @case('medium') @php $promdata[] = 6000; @endphp @php $prombg[] = '#fecd56'; @endphp @break @case('high') @php $promdata[] = 8000; @endphp @php $prombg[] = '#ff7c1f'; @endphp @break @case('very high') @php $promdata[] = 10000; @endphp @php $prombg[] = '#ff1616'; @endphp @break @default @php $promdata[] = 0; @endphp @php $prombg[] = '#7ed957'; @endphp @endswitch @elseif($types == 'overall') @switch($level->score->final_risk_level) @case('very low') @php $promdata[] = 2000; @endphp @php $prombg[] = '#7ed957'; @endphp @break @case('low') @php $promdata[] = 4000; @endphp @php $prombg[] = '#70c5d8'; @endphp @break @case('medium') @php $promdata[] = 6000; @endphp @php $prombg[] = '#fecd56'; @endphp @break @case('high') @php $promdata[] = 8000; @endphp @php $prombg[] = '#ff7c1f'; @endphp @break @case('very high') @php $promdata[] = 10000; @endphp @php $prombg[] = '#ff1616'; @endphp @break @default @php $promdata[] = 0; @endphp @php $prombg[] = '#7ed957'; @endphp @endswitch @endif @endforeach @endforeach
{{--

Score Distribution

@foreach($selectedtypes as $types) @if($types == 'housing')
Housing Price
@elseif($types == 'lifestyle')
Life Style
@elseif($types == 'persona')
Persona
@elseif($types == 'financial')
Finance Risk
@elseif($types == 'overall')
Overall Score
@endif @endforeach
@foreach($selectedtypes as $types) @if($types == 'housing')

Housing Price

@elseif($types == 'lifestyle')

Life Style

@elseif($types == 'persona')

Persona

@elseif($types == 'financial')

Finance Risk

@elseif($types == 'overall')

Overall Score

@endif @endforeach
--}}

User Score

@foreach($scores as $level) @foreach($selectedtypes as $types) @if($types == 'housing') @switch($level->score->housing_level) @case('very low') @php $bgcolor = 'user-very-low'; @endphp @break @case('low') @php $bgcolor = 'user-low'; @endphp @break @case('medium') @php $bgcolor = 'user-medium'; @endphp @break @case('high') @php $bgcolor = 'user-high'; @endphp @break @case('very high') @php $bgcolor = 'user-very-high'; @endphp @break @default @php $bgcolor = 'user-very-low'; @endphp @endswitch @elseif($types == 'lifestyle') @switch($level->score->life_style_risk_level) @case('very low') @php $bgcolor = 'user-very-low'; @endphp @break @case('low') @php $bgcolor = 'user-low'; @endphp @break @case('medium') @php $bgcolor = 'user-medium'; @endphp @break @case('high') @php $bgcolor = 'user-high'; @endphp @break @case('very high') @php $bgcolor = 'user-very-high'; @endphp @break @default @php $bgcolor = 'user-very-low'; @endphp @endswitch @elseif($types == 'persona') @switch($level->score->persona_level) @case('very low') @php $bgcolor = 'user-very-low'; @endphp @break @case('low') @php $bgcolor = 'user-low'; @endphp @break @case('medium') @php $bgcolor = 'user-medium'; @endphp @break @case('high') @php $bgcolor = 'user-high'; @endphp @break @case('very high') @php $bgcolor = 'user-very-high'; @endphp @break @default @php $bgcolor = 'user-very-low'; @endphp @endswitch @elseif($types == 'financial') @switch($level->score->financial_risk_level) @case('very low') @php $bgcolor = 'user-very-low'; @endphp @break @case('low') @php $bgcolor = 'user-low'; @endphp @break @case('medium') @php $bgcolor = 'user-medium'; @endphp @break @case('high') @php $bgcolor = 'user-high'; @endphp @break @case('very high') @php $bgcolor = 'user-very-high'; @endphp @break @default @php $bgcolor = 'user-very-low'; @endphp @endswitch @elseif($types == 'overall') @switch($level->score->final_risk_level) @case('very low') @php $bgcolor = 'user-very-low'; @endphp @break @case('low') @php $bgcolor = 'user-low'; @endphp @break @case('medium') @php $bgcolor = 'user-medium'; @endphp @break @case('high') @php $bgcolor = 'user-high'; @endphp @break @case('very high') @php $bgcolor = 'user-very-high'; @endphp @break @default @php $bgcolor = 'user-very-low'; @endphp @endswitch @endif @endforeach
Phone {{ $level->phone_number }}
Housing Price{{ ucwords($level->score->housing_level) }}
Life Style{{ ucwords($level->score->life_style_risk_level) }}
Persona{{ ucwords($level->score->persona_level) }}
Financial Risk{{ ucwords($level->score->financial_risk_level) }}
Overall Score{{ ucwords($level->score->final_risk_level) }}
@endforeach
@foreach($selectedtypes as $types) @if($types == 'housing')
@elseif($types == 'lifestyle')
@elseif($types == 'persona')
@elseif($types == 'financial')
@elseif($types == 'overall')
@endif @endforeach
{{--

Score Radar

@foreach($selectedtypes as $types) @if($types == 'housing')
@elseif($types == 'lifestyle')
@elseif($types == 'persona')
@elseif($types == 'financial')
@elseif($types == 'overall')
@endif @endforeach
--}}
@php $labels = array(); @endphp @php $labelstwo = array(); @endphp @php $radardata = array(); @endphp @php $radarcolor = array(); @endphp @php $verylow = array(); @endphp @php $low = array(); @endphp @php $medium = array(); @endphp @php $high = array(); @endphp @php $veryhigh = array(); @endphp @php $doughnutdata = array(); @endphp @foreach($selectedtypes as $types) @if($types == 'housing') @php $labels[] = 'Housing Price'; @endphp @php $labelstwo[] = 'Housing Price'; @endphp @php $radardata[] = number_format($scores[0]->score->housing_score, 6); @endphp @php $radarcolor[] = '#FF6384'; @endphp @php $verylow[] = 62; @endphp @php $low[] = 15; @endphp @php $medium[] = 19; @endphp @php $high[] = 1; @endphp @php $veryhigh[] = 3; @endphp @php $doughnutdata[] = array('data' => [62, 15, 19, 1, 3], 'backgroundColor' => ["#3faa59", "#b3df72", "#fffebe", "#fdbb6c", "#e54e35"], 'label' => 'Housing Price'); @endphp @elseif($types == 'lifestyle') @php $labels[] = 'Life Style'; @endphp @php $labelstwo[] = 'Life Style'; @endphp @php $radardata[] = number_format($scores[0]->score->life_style_class_score, 6); @endphp @php $radarcolor[] = '#4BC0C0'; @endphp @php $verylow[] = 44; @endphp @php $low[] = 43; @endphp @php $medium[] = 9; @endphp @php $high[] = 4; @endphp @php $veryhigh[] = 0; @endphp @php $doughnutdata[] = array('data' => [44, 43, 9, 4, 0], 'backgroundColor' => ["#3faa59", "#b3df72", "#fffebe", "#fdbb6c", "#e54e35"], 'label' => 'Life Style'); @endphp @elseif($types == 'persona') @php $labels[] = 'Persona'; @endphp @php $labelstwo[] = 'Persona'; @endphp @php $radardata[] = number_format($scores[0]->score->persona_score, 6); @endphp @php $radarcolor[] = '#FFCE56'; @endphp @php $verylow[] = 53; @endphp @php $low[] = 19; @endphp @php $medium[] = 25; @endphp @php $high[] = 3; @endphp @php $veryhigh[] = 0; @endphp @php $doughnutdata[] = array('data' => [53, 19, 25, 3, 0], 'backgroundColor' => ["#3faa59", "#b3df72", "#fffebe", "#fdbb6c", "#e54e35"], 'label' => 'Persona'); @endphp @elseif($types == 'financial') @php $labels[] = 'Financial Risk'; @endphp @php $labelstwo[] = 'Financial'; @endphp @php $radardata[] = number_format($scores[0]->score->financial_class_score, 6); @endphp @php $radarcolor[] = '#36A2EB'; @endphp @php $verylow[] = 6; @endphp @php $low[] = 49; @endphp @php $medium[] = 37; @endphp @php $high[] = 4; @endphp @php $veryhigh[] = 4; @endphp @php $doughnutdata[] = array('data' => [6, 49, 37, 4, 4], 'backgroundColor' => ["#3faa59", "#b3df72", "#fffebe", "#fdbb6c", "#e54e35"], 'label' => 'Financial Risk'); @endphp @elseif($types == 'overall') @php $labels[] = 'Overall Score'; @endphp @php $verylow[] = 13; @endphp @php $low[] = 54; @endphp @php $medium[] = 26; @endphp @php $high[] = 5; @endphp @php $veryhigh[] = 2; @endphp @php $doughnutdata[] = array('data' => [13, 54, 26, 5, 2], 'backgroundColor' => ["#3faa59", "#b3df72", "#fffebe", "#fdbb6c", "#e54e35"], 'label' => 'Overall Score'); @endphp @endif @endforeach @endif