From 253121dcd8f8d1ad81076d08bfa4d24074198d96 Mon Sep 17 00:00:00 2001 From: horus Date: Sat, 17 Oct 2020 13:26:54 +0200 Subject: Option to show real score. --- resources/views/anime.blade.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'resources/views') diff --git a/resources/views/anime.blade.php b/resources/views/anime.blade.php index 0d00cb4..804603c 100644 --- a/resources/views/anime.blade.php +++ b/resources/views/anime.blade.php @@ -59,14 +59,28 @@ new Chart(document.getElementById('score_chart'), { type: 'line', data: { labels: {!! json_encode($anime["chart_label_score"]) !!}, - datasets: [{ + datasets: [ + { label: 'Average Score on MAL', data: {!! printScoreData($anime["score"]) !!}, file: 'false', borderColor: 'rgb(75, 192, 192)', lineTension: 0.01, backgroundColor: 'rgb(255,255,255,0)', - }] + } + +@if ( \Request::input('showRealScore') ) + ,{ + label: 'Real calculated Score', + data: {!! printScoreData($anime["calculated_score"]) !!}, + file: 'false', + borderColor: 'grey', + lineTension: 0.01, + backgroundColor: 'rgb(255,255,255,0)', + } +@endif + + ] }, options: { maintainAspectRatio: true, -- cgit v1.2.3