<?php

use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
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;

/* widget/widget-userteamprojects.html.twig */
class __TwigTemplate_cb4d959fa55b3327fd7c957a72becebdc995aef14bae5d06637896de09a7aa31 extends Template
{
    private $source;
    private $macros = [];

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

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

        $this->parent = false;

        $this->blocks = [
        ];
    }

    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 1
        $context["projectStats"] = ($context["data"] ?? null);
        // line 2
        $context["title"] = ((twig_get_attribute($this->env, $this->source, ($context["options"] ?? null), "title", [], "any", true, true, false, 2)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["options"] ?? null), "title", [], "any", false, false, false, 2), "label.my_team_projects")) : ("label.my_team_projects"));
        // line 3
        $context["widgetId"] = twig_get_attribute($this->env, $this->source, ($context["options"] ?? null), "id", [], "any", false, false, false, 3);
        // line 4
        echo "
";
        // line 5
        if (1 === twig_compare(twig_length_filter($this->env, ($context["projectStats"] ?? null)), 0)) {
            // line 6
            echo "<div class=\"row\">
    <div class=\"col-md-12\">
        ";
            // line 8
            $this->loadTemplate("widget/widget-userteamprojects.html.twig", "widget/widget-userteamprojects.html.twig", 8, "1147201688")->display($context);
            // line 49
            echo "    </div>
</div>
";
        }
    }

    public function getTemplateName()
    {
        return "widget/widget-userteamprojects.html.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  54 => 49,  52 => 8,  48 => 6,  46 => 5,  43 => 4,  41 => 3,  39 => 2,  37 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("", "widget/widget-userteamprojects.html.twig", "/var/www/html/kimai2/templates/widget/widget-userteamprojects.html.twig");
    }
}


/* widget/widget-userteamprojects.html.twig */
class __TwigTemplate_cb4d959fa55b3327fd7c957a72becebdc995aef14bae5d06637896de09a7aa31___1147201688 extends Template
{
    private $source;
    private $macros = [];

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

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

        $this->blocks = [
            'box_attributes' => [$this, 'block_box_attributes'],
            'box_body_class' => [$this, 'block_box_body_class'],
            'box_title' => [$this, 'block_box_title'],
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context)
    {
        // line 8
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 9
        $macros["widgets"] = $this->macros["widgets"] = $this->loadTemplate("macros/widgets.html.twig", "widget/widget-userteamprojects.html.twig", 9)->unwrap();
        // line 10
        $macros["progress"] = $this->macros["progress"] = $this->loadTemplate("macros/progressbar.html.twig", "widget/widget-userteamprojects.html.twig", 10)->unwrap();
        // line 8
        $this->parent = $this->loadTemplate("@AdminLTE/Widgets/box-widget.html.twig", "widget/widget-userteamprojects.html.twig", 8);
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }

    // line 11
    public function block_box_attributes($context, array $blocks = [])
    {
        $macros = $this->macros;
        echo "id=\"";
        echo twig_escape_filter($this->env, ($context["widgetId"] ?? null), "html", null, true);
        echo "\"";
    }

    // line 12
    public function block_box_body_class($context, array $blocks = [])
    {
        $macros = $this->macros;
        echo "no-padding";
    }

    // line 13
    public function block_box_title($context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 14
        echo "                ";
        if ( !twig_test_empty(($context["title"] ?? null))) {
            echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans(($context["title"] ?? null)), "html", null, true);
        }
        // line 15
        echo "            ";
    }

    // line 16
    public function block_box_body($context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 17
        echo "                <table class=\"table table-hover dataTable\" role=\"grid\">
                    <tbody>
                    ";
        // line 19
        $context['_parent'] = $context;
        $context['_seq'] = twig_ensure_traversable(($context["projectStats"] ?? null));
        foreach ($context['_seq'] as $context["_key"] => $context["stats"]) {
            // line 20
            echo "                        ";
            $context["project"] = twig_get_attribute($this->env, $this->source, $context["stats"], "project", [], "any", false, false, false, 20);
            // line 21
            echo "                        <tr>
                            <td>
                                ";
            // line 23
            echo twig_call_macro($macros["widgets"], "macro_label_project", [twig_get_attribute($this->env, $this->source, $context["stats"], "project", [], "any", false, false, false, 23)], 23, $context, $this->getSourceContext());
            echo "
                                <br>
                                <small>";
            // line 25
            echo twig_call_macro($macros["widgets"], "macro_label_customer", [twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["stats"], "project", [], "any", false, false, false, 25), "customer", [], "any", false, false, false, 25)], 25, $context, $this->getSourceContext());
            echo "</small>
                            </td>
                            <td class=\"hidden-xs hidden-sm hidden-md\">
                                ";
            // line 28
            $context['_parent'] = $context;
            $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "teams", [], "any", false, false, false, 28));
            foreach ($context['_seq'] as $context["_key"] => $context["team"]) {
                // line 29
                echo "                                    ";
                if (twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["app"] ?? null), "user", [], "any", false, false, false, 29), "isInTeam", [0 => $context["team"]], "method", false, false, false, 29)) {
                    // line 30
                    echo "                                        ";
                    echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["team"], "name", [], "any", false, false, false, 30), "html", null, true);
                    echo "
                                    ";
                }
                // line 32
                echo "                                ";
            }
            $_parent = $context['_parent'];
            unset($context['_seq'], $context['_iterated'], $context['_key'], $context['team'], $context['_parent'], $context['loop']);
            $context = array_intersect_key($context, $_parent) + $_parent;
            // line 33
            echo "                            </td>
                            <td style=\"width:50%\">
                                ";
            // line 35
            if (( !twig_test_empty(twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "timeBudget", [], "any", false, false, false, 35)) && 1 === twig_compare(twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "timeBudget", [], "any", false, false, false, 35), 0))) {
                // line 36
                echo "                                    ";
                $context["budgetLeft"] = (twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "timeBudget", [], "any", false, false, false, 36) - twig_get_attribute($this->env, $this->source, $context["stats"], "recordDuration", [], "any", false, false, false, 36));
                // line 37
                echo "                                    ";
                echo twig_call_macro($macros["progress"], "macro_progressbar_small", [twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "timeBudget", [], "any", false, false, false, 37), twig_get_attribute($this->env, $this->source, $context["stats"], "recordDuration", [], "any", false, false, false, 37), ($context["budgetLeft"] ?? null), $this->extensions['App\Twig\LocaleExtensions']->duration(($context["budgetLeft"] ?? null))], 37, $context, $this->getSourceContext());
                echo "
                                ";
            } elseif (( !twig_test_empty(twig_get_attribute($this->env, $this->source,             // line 38
($context["project"] ?? null), "budget", [], "any", false, false, false, 38)) && 1 === twig_compare(twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "budget", [], "any", false, false, false, 38), 0))) {
                // line 39
                echo "                                    ";
                $context["budgetLeft"] = (twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "budget", [], "any", false, false, false, 39) - twig_get_attribute($this->env, $this->source, $context["stats"], "recordRate", [], "any", false, false, false, 39));
                // line 40
                echo "                                    ";
                echo twig_call_macro($macros["progress"], "macro_progressbar_small", [twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "budget", [], "any", false, false, false, 40), twig_get_attribute($this->env, $this->source, $context["stats"], "recordRate", [], "any", false, false, false, 40), ($context["budgetLeft"] ?? null), $this->extensions['App\Twig\LocaleExtensions']->money(($context["budgetLeft"] ?? null), twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["project"] ?? null), "customer", [], "any", false, false, false, 40), "currency", [], "any", false, false, false, 40))], 40, $context, $this->getSourceContext());
                echo "
                                ";
            }
            // line 42
            echo "                            </td>
                        </tr>
                    ";
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_iterated'], $context['_key'], $context['stats'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 45
        echo "                    </tbody>
                </table>                
            ";
    }

    public function getTemplateName()
    {
        return "widget/widget-userteamprojects.html.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  232 => 45,  224 => 42,  218 => 40,  215 => 39,  213 => 38,  208 => 37,  205 => 36,  203 => 35,  199 => 33,  193 => 32,  187 => 30,  184 => 29,  180 => 28,  174 => 25,  169 => 23,  165 => 21,  162 => 20,  158 => 19,  154 => 17,  150 => 16,  146 => 15,  141 => 14,  137 => 13,  130 => 12,  121 => 11,  116 => 8,  114 => 10,  112 => 9,  105 => 8,  54 => 49,  52 => 8,  48 => 6,  46 => 5,  43 => 4,  41 => 3,  39 => 2,  37 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("", "widget/widget-userteamprojects.html.twig", "/var/www/html/kimai2/templates/widget/widget-userteamprojects.html.twig");
    }
}
