<?php

use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;

/* communes/graph.html.twig */
class __TwigTemplate_1897d5d1ca06642c2244f82be83791c9 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'page_title' => [$this, 'block_page_title'],
            'page_content' => [$this, 'block_page_content'],
            'javascripts' => [$this, 'block_javascripts'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 1
        return "@AdminLTE/layout/communeodd-layout.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/layout/communeodd-layout.html.twig", 1);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 3
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_page_title(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Graphiques", [], "messages");
        yield from [];
    }

    // line 6
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_page_content(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 7
        yield "

";
        // line 9
        yield from $this->load("communes/graph.html.twig", 9, 459416186)->unwrap()->yield($context);
        // line 20
        yield "

";
        // line 22
        yield from $this->load("communes/graph.html.twig", 22, 51432273)->unwrap()->yield($context);
        // line 29
        yield "

";
        // line 31
        if ((($tmp = ($context["indicator"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            // line 32
            yield "
";
            // line 33
            yield from $this->load("communes/graph.html.twig", 33, 2072025025)->unwrap()->yield($context);
            // line 44
            yield "


";
            // line 47
            yield from $this->load("communes/graph.html.twig", 47, 2043494616)->unwrap()->yield($context);
            // line 58
            yield "
";
        }
        // line 60
        yield "    
";
        yield from [];
    }

    // line 65
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_javascripts(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 66
        yield "    <script>
        \$(function () {
            var barChartData = {
                labels  : ";
        // line 69
        if ((($tmp = ($context["data1"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v0 = ($context["data1"] ?? null)) && is_array($_v0) || $_v0 instanceof ArrayAccess ? ($_v0["labels"] ?? null) : null));
        }
        yield ",
                datasets: [
                    {
                        label               : 'Valeur des indicateurs renseignables',
                        backgroundColor     : 'blue',
                        borderColor         : 'blue',
                        borderWidth         : 1,
                        maxBarThickness     : 75,
                        pointRadius         : false,
                        pointColor          : '#3b8bba',
                        pointStrokeColor    : 'rgba(60,141,188,1)',
                        pointHighlightFill  : '#fff',
                        pointHighlightStroke: 'rgba(60,141,188,1)',
                        data                : ";
        // line 82
        if ((($tmp = ($context["data1"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v1 = ($context["data1"] ?? null)) && is_array($_v1) || $_v1 instanceof ArrayAccess ? ($_v1["values"] ?? null) : null));
        }
        // line 83
        yield "                    },
                ]
            }

            var barChartCanvas = document.getElementById('barChart').getContext('2d');
      
            var barChartOptions = {
                responsive              : true,
                maintainAspectRatio     : false,
                datasetFill             : false,
                scales: {
                    yAxes: [{
                        ticks: {
                            beginAtZero: true
                        }
                    }]
                },
                plugins: {
                    // Change options for ALL labels of THIS CHART
                    datalabels: {
                        color: 'white',
                        font: {
                            weight: 'bold',
                            size: 12,
                        },
                        align: 'start',
\t\t\t\t\t\tanchor: 'end'
                    }
                }
            }
        
            var barChart = new Chart(barChartCanvas, {
                type: 'bar', 
                data: barChartData,
                options: barChartOptions
            })
      
        })
    </script>



    <script>
        \$(function () {
            var barChartData = {
                labels  : ";
        // line 128
        if ((($tmp = ($context["data3"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v2 = ($context["data3"] ?? null)) && is_array($_v2) || $_v2 instanceof ArrayAccess ? ($_v2["labels"] ?? null) : null));
        }
        yield ",
                datasets: [
                    {
                        label               : 'Situation de l\\'indicateur dans le département',
                        backgroundColor     : 'green',
                        borderColor         : 'green',
                        borderWidth         : 1,
                        maxBarThickness     : 75,
                        pointRadius         : false,
                        pointColor          : '#3b8bba',
                        pointStrokeColor    : 'rgba(60,141,188,1)',
                        pointHighlightFill  : '#fff',
                        pointHighlightStroke: 'rgba(60,141,188,1)',
                        data                : ";
        // line 141
        if ((($tmp = ($context["data3"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v3 = ($context["data3"] ?? null)) && is_array($_v3) || $_v3 instanceof ArrayAccess ? ($_v3["values"] ?? null) : null));
        }
        // line 142
        yield "                    },
                ]
            }

            var barChartCanvas = document.getElementById('barChart3').getContext('2d');
      
            var barChartOptions = {
                responsive              : true,
                maintainAspectRatio     : false,
                datasetFill             : false,
                scales: {
                    yAxes: [{
                        ticks: {
                            beginAtZero: true
                        }
                    }]
                },
                plugins: {
                    // Change options for ALL labels of THIS CHART
                    datalabels: {
                        color: 'white',
                        font: {
                            weight: 'bold',
                            size: 12,
                        },
                        align: 'start',
\t\t\t\t\t\tanchor: 'end'
                    }
                }
            }
        
            var barChart = new Chart(barChartCanvas, {
                type: 'bar', 
                data: barChartData,
                options: barChartOptions
            })
      
        })
    </script>



    <script>
        \$(function () {
            var barChartData = {
                labels  : ";
        // line 187
        if ((($tmp = ($context["data2"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v4 = ($context["data2"] ?? null)) && is_array($_v4) || $_v4 instanceof ArrayAccess ? ($_v4["labels"] ?? null) : null));
        }
        yield ",
                datasets: [
                    {
                        label               : 'Evolution de l\\'indicateur pour la commune',
                        backgroundColor     : 'red',
                        borderColor         : 'red',
                        borderWidth         : 1,
                        maxBarThickness     : 75,
                        pointRadius         : false,
                        pointColor          : '#3b8bba',
                        pointStrokeColor    : 'rgba(60,141,188,1)',
                        pointHighlightFill  : '#fff',
                        pointHighlightStroke: 'rgba(60,141,188,1)',
                        data                : ";
        // line 200
        if ((($tmp = ($context["data2"] ?? null)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            yield json_encode((($_v5 = ($context["data2"] ?? null)) && is_array($_v5) || $_v5 instanceof ArrayAccess ? ($_v5["values"] ?? null) : null));
        }
        // line 201
        yield "                    },
                ]
            }

            var barChartCanvas = document.getElementById('barChart2').getContext('2d');
      
            var barChartOptions = {
                responsive              : true,
                maintainAspectRatio     : false,
                datasetFill             : false,
                scales: {
                    yAxes: [{
                        ticks: {
                            beginAtZero: true
                        }
                    }]
                },
                plugins: {
                    // Change options for ALL labels of THIS CHART
                    datalabels: {
                        color: 'white',
                        font: {
                            weight: 'bold',
                            size: 12,
                        },
                        align: 'start',
\t\t\t\t\t\tanchor: 'end'
                    }
                }
            }
        
            var barChart = new Chart(barChartCanvas, {
                type: 'bar', 
                data: barChartData,
                options: barChartOptions
            })
      
        })
    </script>

    <script src=\"";
        // line 241
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/chart.js/Chart.min.js"), "html", null, true);
        yield "\"></script>
    <script src=\"";
        // line 242
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/chartjs-plugin-datalabels/chartjs-plugin-datalabels.min.js"), "html", null, true);
        yield "\"></script>    
";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "communes/graph.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  329 => 242,  325 => 241,  283 => 201,  279 => 200,  261 => 187,  214 => 142,  210 => 141,  192 => 128,  145 => 83,  141 => 82,  123 => 69,  118 => 66,  111 => 65,  105 => 60,  101 => 58,  99 => 47,  94 => 44,  92 => 33,  89 => 32,  87 => 31,  83 => 29,  81 => 22,  77 => 20,  75 => 9,  71 => 7,  64 => 6,  53 => 3,  42 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "communes/graph.html.twig", "/var/www/html/templates/communes/graph.html.twig");
    }
}


/* communes/graph.html.twig */
class __TwigTemplate_1897d5d1ca06642c2244f82be83791c9___459416186 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 9
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/Widgets/box-widget.html.twig", 9);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 10
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_box_body(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 11
        yield "            <div class=\"row\">
                <div class=\"chart\" style=\"position: relative; height:60vh; width:100%\">
                    <canvas id=\"barChart\"></canvas>
                    <!--canvas id=\"myChart\" width=\"400\" height=\"400\"></canvas-->
                    <div id=\"bar-chart\" style=\"height: 100%;\"></div>
                </div>
            </div>
        ";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "communes/graph.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  407 => 11,  400 => 10,  389 => 9,  329 => 242,  325 => 241,  283 => 201,  279 => 200,  261 => 187,  214 => 142,  210 => 141,  192 => 128,  145 => 83,  141 => 82,  123 => 69,  118 => 66,  111 => 65,  105 => 60,  101 => 58,  99 => 47,  94 => 44,  92 => 33,  89 => 32,  87 => 31,  83 => 29,  81 => 22,  77 => 20,  75 => 9,  71 => 7,  64 => 6,  53 => 3,  42 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "communes/graph.html.twig", "/var/www/html/templates/communes/graph.html.twig");
    }
}


/* communes/graph.html.twig */
class __TwigTemplate_1897d5d1ca06642c2244f82be83791c9___51432273 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 22
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/Widgets/box-widget.html.twig", 22);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 23
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_box_body(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 24
        yield "            ";
        yield         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock(($context["form"] ?? null), 'form_start');
        yield "
                ";
        // line 25
        yield $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(($context["form"] ?? null), 'widget');
        yield "
            ";
        // line 26
        yield         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock(($context["form"] ?? null), 'form_end');
        yield "    
        ";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "communes/graph.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  499 => 26,  495 => 25,  490 => 24,  483 => 23,  472 => 22,  407 => 11,  400 => 10,  389 => 9,  329 => 242,  325 => 241,  283 => 201,  279 => 200,  261 => 187,  214 => 142,  210 => 141,  192 => 128,  145 => 83,  141 => 82,  123 => 69,  118 => 66,  111 => 65,  105 => 60,  101 => 58,  99 => 47,  94 => 44,  92 => 33,  89 => 32,  87 => 31,  83 => 29,  81 => 22,  77 => 20,  75 => 9,  71 => 7,  64 => 6,  53 => 3,  42 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "communes/graph.html.twig", "/var/www/html/templates/communes/graph.html.twig");
    }
}


/* communes/graph.html.twig */
class __TwigTemplate_1897d5d1ca06642c2244f82be83791c9___2072025025 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 33
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/Widgets/box-widget.html.twig", 33);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 34
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_box_body(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 35
        yield "            <div class=\"row\">
                <div class=\"chart\" style=\"position: relative; height:60vh; width:100%\">
                    <canvas id=\"barChart3\"></canvas>
                    <!--canvas id=\"myChart\" width=\"400\" height=\"400\"></canvas-->
                    <div id=\"bar-chart3\" style=\"height: 100%;\"></div>
                </div>
            </div>
        ";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "communes/graph.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  577 => 35,  570 => 34,  559 => 33,  499 => 26,  495 => 25,  490 => 24,  483 => 23,  472 => 22,  407 => 11,  400 => 10,  389 => 9,  329 => 242,  325 => 241,  283 => 201,  279 => 200,  261 => 187,  214 => 142,  210 => 141,  192 => 128,  145 => 83,  141 => 82,  123 => 69,  118 => 66,  111 => 65,  105 => 60,  101 => 58,  99 => 47,  94 => 44,  92 => 33,  89 => 32,  87 => 31,  83 => 29,  81 => 22,  77 => 20,  75 => 9,  71 => 7,  64 => 6,  53 => 3,  42 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "communes/graph.html.twig", "/var/www/html/templates/communes/graph.html.twig");
    }
}


/* communes/graph.html.twig */
class __TwigTemplate_1897d5d1ca06642c2244f82be83791c9___2043494616 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 47
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/Widgets/box-widget.html.twig", 47);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 48
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_box_body(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 49
        yield "            <div class=\"row\">
                <div class=\"chart\" style=\"position: relative; height:60vh; width:100%\">
                    <canvas id=\"barChart2\"></canvas>
                    <!--canvas id=\"myChart\" width=\"400\" height=\"400\"></canvas-->
                    <div id=\"bar-chart2\" style=\"height: 100%;\"></div>
                </div>
            </div>
        ";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "communes/graph.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  660 => 49,  653 => 48,  642 => 47,  577 => 35,  570 => 34,  559 => 33,  499 => 26,  495 => 25,  490 => 24,  483 => 23,  472 => 22,  407 => 11,  400 => 10,  389 => 9,  329 => 242,  325 => 241,  283 => 201,  279 => 200,  261 => 187,  214 => 142,  210 => 141,  192 => 128,  145 => 83,  141 => 82,  123 => 69,  118 => 66,  111 => 65,  105 => 60,  101 => 58,  99 => 47,  94 => 44,  92 => 33,  89 => 32,  87 => 31,  83 => 29,  81 => 22,  77 => 20,  75 => 9,  71 => 7,  64 => 6,  53 => 3,  42 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "communes/graph.html.twig", "/var/www/html/templates/communes/graph.html.twig");
    }
}
