<?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;

/* oc01/template/extension/module/category.twig */
class __TwigTemplate_90d34385233e58e29ee98c69c21f4f713ac57558c893eb544c82b9d1560b20b7 extends \Twig\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
        echo "<div class=\"sidebar section sidebar_category\">
<div class=\"section-heading\"><div class=\"border\"></div>";
        // line 2
        echo ($context["heading_title"] ?? null);
        echo "</div>   
  <div class=\"section-block category_block\">    
      <ul class=\"left-category treeview-list treeview\">
               ";
        // line 5
        $context['_parent'] = $context;
        $context['_seq'] = twig_ensure_traversable(($context["categories"] ?? null));
        foreach ($context['_seq'] as $context["_key"] => $context["category"]) {
            // line 6
            echo "    ";
            if ((twig_get_attribute($this->env, $this->source, $context["category"], "category_id", [], "any", false, false, false, 6) == ($context["category_id"] ?? null))) {
                // line 7
                echo "    <li class=\"cat-active expandable\">
        <a href=\"";
                // line 8
                echo twig_get_attribute($this->env, $this->source, $context["category"], "href", [], "any", false, false, false, 8);
                echo "\" class=\"active\">";
                echo twig_get_attribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 8);
                echo "</a>
    ";
            } else {
                // line 10
                echo "    <li class=\"expandable\">
        <a href=\"";
                // line 11
                echo twig_get_attribute($this->env, $this->source, $context["category"], "href", [], "any", false, false, false, 11);
                echo "\">";
                echo twig_get_attribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 11);
                echo "</a>
        ";
            }
            // line 13
            echo "        ";
            if (twig_get_attribute($this->env, $this->source, $context["category"], "children", [], "any", false, false, false, 13)) {
                // line 14
                echo "       
         ";
                // line 15
                if ((twig_get_attribute($this->env, $this->source, $context["category"], "category_id", [], "any", false, false, false, 15) == ($context["category_id"] ?? null))) {
                    // line 16
                    echo "              <ul class=\"menu-dropdown in collapsable\">
                 ";
                } else {
                    // line 18
                    echo "         <ul class=\"menu-dropdown\">
        ";
                }
                // line 20
                echo "            ";
                $context['_parent'] = $context;
                $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, $context["category"], "children", [], "any", false, false, false, 20));
                foreach ($context['_seq'] as $context["_key"] => $context["child"]) {
                    // line 21
                    echo "            
            <li>
                ";
                    // line 23
                    if ((twig_get_attribute($this->env, $this->source, $context["child"], "category_id", [], "any", false, false, false, 23) == ($context["child_id"] ?? null))) {
                        // line 24
                        echo "                <a href=\"";
                        echo twig_get_attribute($this->env, $this->source, $context["child"], "href", [], "any", false, false, false, 24);
                        echo "\" class=\"active\">";
                        echo twig_get_attribute($this->env, $this->source, $context["child"], "name", [], "any", false, false, false, 24);
                        echo "</a>
               ";
                    } else {
                        // line 26
                        echo "                <a href=\"";
                        echo twig_get_attribute($this->env, $this->source, $context["child"], "href", [], "any", false, false, false, 26);
                        echo "\">";
                        echo twig_get_attribute($this->env, $this->source, $context["child"], "name", [], "any", false, false, false, 26);
                        echo "</a>
              ";
                    }
                    // line 28
                    echo "         ";
                    if (twig_get_attribute($this->env, $this->source, $context["child"], "children", [], "any", false, false, false, 28)) {
                        echo "         
         ";
                        // line 29
                        if ((twig_get_attribute($this->env, $this->source, $context["category"], "category_id", [], "any", false, false, false, 29) == ($context["category_id"] ?? null))) {
                            // line 30
                            echo "              <ul class=\"menu-dropdown in collapsable\">
                 ";
                        } else {
                            // line 32
                            echo "         <ul class=\"menu-dropdown\">
        ";
                        }
                        // line 34
                        echo "           ";
                        $context['_parent'] = $context;
                        $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, $context["child"], "children", [], "any", false, false, false, 34));
                        foreach ($context['_seq'] as $context["_key"] => $context["child_2"]) {
                            // line 35
                            echo "          <li>
           ";
                            // line 36
                            if ((twig_get_attribute($this->env, $this->source, $context["child_2"], "category_id", [], "any", false, false, false, 36) == ($context["child2_id"] ?? null))) {
                                // line 37
                                echo "            <a href=\"";
                                echo twig_get_attribute($this->env, $this->source, $context["child_2"], "href", [], "any", false, false, false, 37);
                                echo "\" class=\"active\">";
                                echo twig_get_attribute($this->env, $this->source, $context["child_2"], "name", [], "any", false, false, false, 37);
                                echo "</a>
            ";
                            } else {
                                // line 39
                                echo "            <a href=\"";
                                echo twig_get_attribute($this->env, $this->source, $context["child_2"], "href", [], "any", false, false, false, 39);
                                echo "\">";
                                echo twig_get_attribute($this->env, $this->source, $context["child_2"], "name", [], "any", false, false, false, 39);
                                echo "</a>
             ";
                            }
                            // line 41
                            echo "          </li>
         ";
                        }
                        $_parent = $context['_parent'];
                        unset($context['_seq'], $context['_iterated'], $context['_key'], $context['child_2'], $context['_parent'], $context['loop']);
                        $context = array_intersect_key($context, $_parent) + $_parent;
                        // line 43
                        echo "        </ul>
        ";
                    }
                    // line 45
                    echo "            </li>
             ";
                }
                $_parent = $context['_parent'];
                unset($context['_seq'], $context['_iterated'], $context['_key'], $context['child'], $context['_parent'], $context['loop']);
                $context = array_intersect_key($context, $_parent) + $_parent;
                // line 47
                echo "        </ul>
        ";
            }
            // line 49
            echo "    </li>
    ";
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_iterated'], $context['_key'], $context['category'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 51
        echo "    </ul>
  </div>
</div>
";
    }

    public function getTemplateName()
    {
        return "oc01/template/extension/module/category.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  186 => 51,  179 => 49,  175 => 47,  168 => 45,  164 => 43,  157 => 41,  149 => 39,  141 => 37,  139 => 36,  136 => 35,  131 => 34,  127 => 32,  123 => 30,  121 => 29,  116 => 28,  108 => 26,  100 => 24,  98 => 23,  94 => 21,  89 => 20,  85 => 18,  81 => 16,  79 => 15,  76 => 14,  73 => 13,  66 => 11,  63 => 10,  56 => 8,  53 => 7,  50 => 6,  46 => 5,  40 => 2,  37 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("", "oc01/template/extension/module/category.twig", "");
    }
}
