var/cache/dev/twig/ae/ae7fd4eec6d93a889babddd4353373cc.php line 41

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\CoreExtension;
  6. use Twig\Extension\SandboxExtension;
  7. use Twig\Markup;
  8. use Twig\Sandbox\SecurityError;
  9. use Twig\Sandbox\SecurityNotAllowedTagError;
  10. use Twig\Sandbox\SecurityNotAllowedFilterError;
  11. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  12. use Twig\Source;
  13. use Twig\Template;
  14. /* admin/invoice/invoices.html.twig */
  15. class __TwigTemplate_80558bf31c35f0dd00e075cfdf1d2974 extends Template
  16. {
  17.     private $source;
  18.     private $macros = [];
  19.     public function __construct(Environment $env)
  20.     {
  21.         parent::__construct($env);
  22.         $this->source $this->getSourceContext();
  23.         $this->blocks = [
  24.             'title' => [$this'block_title'],
  25.             'content' => [$this'block_content'],
  26.             'addJs' => [$this'block_addJs'],
  27.         ];
  28.     }
  29.     protected function doGetParent(array $context)
  30.     {
  31.         // line 1
  32.         return "admin/base.html.twig";
  33.     }
  34.     protected function doDisplay(array $context, array $blocks = [])
  35.     {
  36.         $macros $this->macros;
  37.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  38.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""admin/invoice/invoices.html.twig"));
  39.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  40.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""admin/invoice/invoices.html.twig"));
  41.         $this->parent $this->loadTemplate("admin/base.html.twig""admin/invoice/invoices.html.twig"1);
  42.         yield from $this->parent->unwrap()->yield($contextarray_merge($this->blocks$blocks));
  43.         
  44.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  45.         
  46.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  47.     }
  48.     // line 3
  49.     public function block_title($context, array $blocks = [])
  50.     {
  51.         $macros $this->macros;
  52.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  53.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  54.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  55.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  56.         yield "Счета на оплату";
  57.         
  58.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  59.         
  60.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  61.         return; yield '';
  62.     }
  63.     // line 5
  64.     public function block_content($context, array $blocks = [])
  65.     {
  66.         $macros $this->macros;
  67.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  68.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  69.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  70.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  71.         // line 6
  72.         yield "    <h1 class=\"h3 mb-2 text-gray-800\">Счета на оплату</h1>
  73.     <div class=\"card shadow mb-4 mt-4\">
  74.         <div class=\"card-header py-3\">
  75.             <h6 class=\"m-0 font-weight-bold text-primary\">Список счетов на оплату</h6>
  76.         </div>
  77.         <div class=\"card-body\">
  78.             <div id=\"invoices-table-filters\" class=\"mb-4 d-flex align-items-center\" style=\"gap: 20px; flex-wrap: wrap;\">
  79.                 ";
  80.         // line 15
  81.         yield from         $this->loadTemplate("components/calendar_events_component.html.twig""admin/invoice/invoices.html.twig"15)->unwrap()->yield($context);
  82.         // line 16
  83.         yield "
  84.                 ";
  85.         // line 17
  86.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/invoice/invoices.html.twig"17)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Мероприятие""dropdownIdPrefix" => "calendarEvent""allItemsButtonText" => "Все мероприятия"]]));
  87.         // line 22
  88.         yield "
  89.                 ";
  90.         // line 23
  91.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/invoice/invoices.html.twig"23)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Уровень учащегося""dropdownIdPrefix" => "level""allItemsButtonText" => "Все уровни"]]));
  92.         // line 28
  93.         yield "
  94.                 ";
  95.         // line 29
  96.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/invoice/invoices.html.twig"29)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Статус учащегося""dropdownIdPrefix" => "status""allItemsButtonText" => "Все статусы"]]));
  97.         // line 34
  98.         yield "
  99.                 ";
  100.         // line 35
  101.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/invoice/invoices.html.twig"35)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Статус счёта""dropdownIdPrefix" => "invoiceStatus""allItemsButtonText" => "Все статусы счёта"]]));
  102.         // line 40
  103.         yield "
  104.                 ";
  105.         // line 41
  106.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/invoice/invoices.html.twig"41)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Статья финансов""dropdownIdPrefix" => "financeCategory""allItemsButtonText" => "Все статьи финансов"]]));
  107.         // line 46
  108.         yield "            </div>
  109.             <div class=\"table-responsive\">
  110.                 <table class=\"table table-bordered\" id=\"invoices-data-table\">
  111.                     <thead>
  112.                         <tr>
  113.                             <th data-table-type=\"num\">Номер п/п</th>
  114.                             <th data-table-type=\"date-d-m-Y\">Дата создания</th>
  115.                             <th>Имя</th>
  116.                             <th data-table-dropdown-id=\"levelDropdown\"
  117.                                 data-table-badge-id=\"levelBadge\"
  118.                                 data-table-dropdown-text-for-all=\"Все уровни\">Уровень учащегося</th>
  119.                             <th data-export-exclude-col>Статус учащегося</th>
  120.                             <th data-table-hide-col
  121.                                 data-table-dropdown-id=\"statusDropdown\"
  122.                                 data-table-badge-id=\"statusBadge\"
  123.                                 data-table-dropdown-text-for-all=\"Все статусы\">Статус учащегося (текст)</th>
  124.                             <th data-table-dropdown-id=\"calendarEventDropdown\"
  125.                                 data-table-badge-id=\"calendarEventBadge\"
  126.                                 data-table-dropdown-text-for-all=\"Все мероприятия\">Мероприятие</th>
  127.                             <th>Сумма</th>
  128.                             <th data-export-exclude-col
  129.                                 data-table-dropdown-id=\"invoiceStatusDropdown\"
  130.                                 data-table-badge-id=\"invoiceStatusBadge\"
  131.                                 data-table-dropdown-text-for-all=\"Все статусы счёта\">Статус счёта</th>
  132.                             <th data-table-hide-col
  133.                                 data-table-dropdown-id=\"invoiceStatusDropdown\"
  134.                                 data-table-badge-id=\"invoiceStatusBadge\"
  135.                                 data-table-dropdown-text-for-all=\"Все статусы счёта\">Статус счёта (текст)</th>
  136.                             <th data-table-dropdown-id=\"financeCategoryDropdown\"
  137.                                 data-table-badge-id=\"financeCategoryBadge\"
  138.                                 data-table-dropdown-text-for-all=\"Все статьи\">Статья финансов</th>
  139.                         </tr>
  140.                     </thead>
  141.                     <tbody>
  142.                         ";
  143.         // line 81
  144.         $context["i"] = 0;
  145.         // line 82
  146.         yield "                        ";
  147.         $context['_parent'] = $context;
  148.         $context['_seq'] = CoreExtension::ensureTraversable((isset($context["items"]) || array_key_exists("items"$context) ? $context["items"] : (function () { throw new RuntimeError('Variable "items" does not exist.'82$this->source); })()));
  149.         $context['loop'] = [
  150.           'parent' => $context['_parent'],
  151.           'index0' => 0,
  152.           'index'  => 1,
  153.           'first'  => true,
  154.         ];
  155.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  156.             $length count($context['_seq']);
  157.             $context['loop']['revindex0'] = $length 1;
  158.             $context['loop']['revindex'] = $length;
  159.             $context['loop']['length'] = $length;
  160.             $context['loop']['last'] = === $length;
  161.         }
  162.         foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  163.             // line 83
  164.             yield "                            ";
  165.             $context["i"] = ((isset($context["i"]) || array_key_exists("i"$context) ? $context["i"] : (function () { throw new RuntimeError('Variable "i" does not exist.'83$this->source); })()) + 1);
  166.             // line 84
  167.             yield "                            ";
  168.             $context["person"] = CoreExtension::getAttribute($this->env$this->source$context["item"], "person", [], "any"falsefalsefalse84);
  169.             // line 85
  170.             yield "                            ";
  171.             $context["student"] = (((isset($context["person"]) || array_key_exists("person"$context) ? $context["person"] : (function () { throw new RuntimeError('Variable "person" does not exist.'85$this->source); })())) ? (CoreExtension::getAttribute($this->env$this->source, (isset($context["person"]) || array_key_exists("person"$context) ? $context["person"] : (function () { throw new RuntimeError('Variable "person" does not exist.'85$this->source); })()), "student", [], "any"falsefalsefalse85)) : (null));
  172.             // line 86
  173.             yield "                            ";
  174.             $context["calendarEvent"] = ((CoreExtension::getAttribute($this->env$this->source$context["item"], "candidate", [], "any"falsefalsefalse86)) ? (CoreExtension::getAttribute($this->env$this->sourceCoreExtension::getAttribute($this->env$this->source$context["item"], "candidate", [], "any"falsefalsefalse86), "calendarEvent", [], "any"falsefalsefalse86)) : (null));
  175.             // line 87
  176.             yield "                            <tr>
  177.                                 <td>";
  178.             // line 88
  179.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["i"]) || array_key_exists("i"$context) ? $context["i"] : (function () { throw new RuntimeError('Variable "i" does not exist.'88$this->source); })()), "html"nulltrue);
  180.             yield "</td>
  181.                                 <td>";
  182.             // line 89
  183.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env$this->source$context["item"], "createdAt", [], "any"falsefalsefalse89), "d.m.Y"), "html"nulltrue);
  184.             yield "</td>
  185.                                 <td>";
  186.             // line 90
  187.             (((isset($context["person"]) || array_key_exists("person"$context) ? $context["person"] : (function () { throw new RuntimeError('Variable "person" does not exist.'90$this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["person"]) || array_key_exists("person"$context) ? $context["person"] : (function () { throw new RuntimeError('Variable "person" does not exist.'90$this->source); })()), "name", [], "any"falsefalsefalse90), "html"nulltrue)) : (yield "–"));
  188.             yield "</td>
  189.                                 <td>";
  190.             // line 91
  191.             (((isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'91$this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'91$this->source); })()), "level", [], "any"falsefalsefalse91), "html"nulltrue)) : (yield "–"));
  192.             yield "</td>
  193.                                 <td>
  194.                                     ";
  195.             // line 93
  196.             if ((isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'93$this->source); })())) {
  197.                 // line 94
  198.                 yield "                                        <span class=\"btn btn-";
  199.                 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'94$this->source); })()), "statusCssClass", [], "any"falsefalsefalse94), "html"nulltrue);
  200.                 yield " btn-icon-split w-max cursor-default\">
  201.                                             <span class=\"icon text-white-50\"><i class=\"fas fa-tag\"></i></span>
  202.                                             <span class=\"text\">";
  203.                 // line 96
  204.                 yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'96$this->source); })()), "statusText", [], "any"falsefalsefalse96), "html"nulltrue);
  205.                 yield "</span>
  206.                                         </span>
  207.                                     ";
  208.             } else {
  209.                 // line 99
  210.                 yield "                                        –
  211.                                     ";
  212.             }
  213.             // line 101
  214.             yield "                                </td>
  215.                                 <td>";
  216.             // line 102
  217.             (((isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'102$this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["student"]) || array_key_exists("student"$context) ? $context["student"] : (function () { throw new RuntimeError('Variable "student" does not exist.'102$this->source); })()), "statusText", [], "any"falsefalsefalse102), "html"nulltrue)) : (yield "–"));
  218.             yield "</td>
  219.                                 <td>";
  220.             // line 103
  221.             (((isset($context["calendarEvent"]) || array_key_exists("calendarEvent"$context) ? $context["calendarEvent"] : (function () { throw new RuntimeError('Variable "calendarEvent" does not exist.'103$this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source, (isset($context["calendarEvent"]) || array_key_exists("calendarEvent"$context) ? $context["calendarEvent"] : (function () { throw new RuntimeError('Variable "calendarEvent" does not exist.'103$this->source); })()), "getText", [], "method"falsefalsefalse103), "html"nulltrue)) : (yield "–"));
  222.             yield "</td>
  223.                                 <td>";
  224.             // line 104
  225.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["item"], "amount", [], "any"falsefalsefalse104), "html"nulltrue);
  226.             yield "</td>
  227.                                 <td>
  228.                                     ";
  229.             // line 106
  230.             yield from             $this->loadTemplate("components/status_button.html.twig""admin/invoice/invoices.html.twig"106)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["buttonClass" => CoreExtension::getAttribute($this->env$this->source,             // line 107
  231. $context["item"], "statusCssClass", [], "any"falsefalsefalse107), "text" => CoreExtension::getAttribute($this->env$this->source,             // line 108
  232. $context["item"], "statusText", [], "any"falsefalsefalse108)]]));
  233.             // line 110
  234.             yield "                                </td>
  235.                                 <td>";
  236.             // line 111
  237.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["item"], "statusText", [], "any"falsefalsefalse111), "html"nulltrue);
  238.             yield "</td>
  239.                                 <td>";
  240.             // line 112
  241.             ((CoreExtension::getAttribute($this->env$this->source$context["item"], "financeCategory", [], "any"falsefalsefalse112)) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->sourceCoreExtension::getAttribute($this->env$this->source$context["item"], "financeCategory", [], "any"falsefalsefalse112), "name", [], "any"falsefalsefalse112), "html"nulltrue)) : (yield "–"));
  242.             yield "</td>
  243.                         ";
  244.             ++$context['loop']['index0'];
  245.             ++$context['loop']['index'];
  246.             $context['loop']['first'] = false;
  247.             if (isset($context['loop']['length'])) {
  248.                 --$context['loop']['revindex0'];
  249.                 --$context['loop']['revindex'];
  250.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  251.             }
  252.         }
  253.         $_parent $context['_parent'];
  254.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  255.         $context array_intersect_key($context$_parent) + $_parent;
  256.         // line 114
  257.         yield "                    </tbody>
  258.                 </table>
  259.             </div>
  260.             <div class=\"mt-4 d-flex\">
  261.                 <button id=\"download-csv-btn\" class=\"btn btn-primary\">Скачать таблицу</button>
  262.             </div>
  263.         </div>
  264.     </div>
  265. ";
  266.         
  267.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  268.         
  269.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  270.         return; yield '';
  271.     }
  272.     // line 125
  273.     public function block_addJs($context, array $blocks = [])
  274.     {
  275.         $macros $this->macros;
  276.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  277.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""addJs"));
  278.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  279.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""addJs"));
  280.         // line 126
  281.         yield "    <script>
  282.         let table = new CustomDataTable('#invoices-data-table', {
  283.             drawRowNumbersForColIndex: 0,
  284.         });
  285.         table.initDataTable();
  286.         \$('#download-csv-btn').click(function() {
  287.             table.downloadCsv();
  288.         });
  289.     </script>
  290. ";
  291.         
  292.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  293.         
  294.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  295.         return; yield '';
  296.     }
  297.     /**
  298.      * @codeCoverageIgnore
  299.      */
  300.     public function getTemplateName()
  301.     {
  302.         return "admin/invoice/invoices.html.twig";
  303.     }
  304.     /**
  305.      * @codeCoverageIgnore
  306.      */
  307.     public function isTraitable()
  308.     {
  309.         return false;
  310.     }
  311.     /**
  312.      * @codeCoverageIgnore
  313.      */
  314.     public function getDebugInfo()
  315.     {
  316.         return array (  309 => 126,  299 => 125,  279 => 114,  263 => 112,  259 => 111,  256 => 110,  254 => 108,  253 => 107,  252 => 106,  247 => 104,  243 => 103,  239 => 102,  236 => 101,  232 => 99,  226 => 96,  220 => 94,  218 => 93,  213 => 91,  209 => 90,  205 => 89,  201 => 88,  198 => 87,  195 => 86,  192 => 85,  189 => 84,  186 => 83,  168 => 82,  166 => 81,  129 => 46,  127 => 41,  124 => 40,  122 => 35,  119 => 34,  117 => 29,  114 => 28,  112 => 23,  109 => 22,  107 => 17,  104 => 16,  102 => 15,  91 => 6,  81 => 5,  61 => 3,  38 => 1,);
  317.     }
  318.     public function getSourceContext()
  319.     {
  320.         return new Source("{% extends 'admin/base.html.twig' %}
  321. {% block title %}Счета на оплату{% endblock %}
  322. {% block content %}
  323.     <h1 class=\"h3 mb-2 text-gray-800\">Счета на оплату</h1>
  324.     <div class=\"card shadow mb-4 mt-4\">
  325.         <div class=\"card-header py-3\">
  326.             <h6 class=\"m-0 font-weight-bold text-primary\">Список счетов на оплату</h6>
  327.         </div>
  328.         <div class=\"card-body\">
  329.             <div id=\"invoices-table-filters\" class=\"mb-4 d-flex align-items-center\" style=\"gap: 20px; flex-wrap: wrap;\">
  330.                 {% include 'components/calendar_events_component.html.twig' %}
  331.                 {% include 'components/table_filter.html.twig' with { options: {
  332.                     labelText: 'Мероприятие',
  333.                     dropdownIdPrefix: 'calendarEvent',
  334.                     allItemsButtonText: 'Все мероприятия',
  335.                 }} %}
  336.                 {% include 'components/table_filter.html.twig' with { options: {
  337.                     labelText: 'Уровень учащегося',
  338.                     dropdownIdPrefix: 'level',
  339.                     allItemsButtonText: 'Все уровни',
  340.                 }} %}
  341.                 {% include 'components/table_filter.html.twig' with { options: {
  342.                     labelText: 'Статус учащегося',
  343.                     dropdownIdPrefix: 'status',
  344.                     allItemsButtonText: 'Все статусы',
  345.                 }} %}
  346.                 {% include 'components/table_filter.html.twig' with { options: {
  347.                     labelText: 'Статус счёта',
  348.                     dropdownIdPrefix: 'invoiceStatus',
  349.                     allItemsButtonText: 'Все статусы счёта',
  350.                 }} %}
  351.                 {% include 'components/table_filter.html.twig' with { options: {
  352.                     labelText: 'Статья финансов',
  353.                     dropdownIdPrefix: 'financeCategory',
  354.                     allItemsButtonText: 'Все статьи финансов',
  355.                 }} %}
  356.             </div>
  357.             <div class=\"table-responsive\">
  358.                 <table class=\"table table-bordered\" id=\"invoices-data-table\">
  359.                     <thead>
  360.                         <tr>
  361.                             <th data-table-type=\"num\">Номер п/п</th>
  362.                             <th data-table-type=\"date-d-m-Y\">Дата создания</th>
  363.                             <th>Имя</th>
  364.                             <th data-table-dropdown-id=\"levelDropdown\"
  365.                                 data-table-badge-id=\"levelBadge\"
  366.                                 data-table-dropdown-text-for-all=\"Все уровни\">Уровень учащегося</th>
  367.                             <th data-export-exclude-col>Статус учащегося</th>
  368.                             <th data-table-hide-col
  369.                                 data-table-dropdown-id=\"statusDropdown\"
  370.                                 data-table-badge-id=\"statusBadge\"
  371.                                 data-table-dropdown-text-for-all=\"Все статусы\">Статус учащегося (текст)</th>
  372.                             <th data-table-dropdown-id=\"calendarEventDropdown\"
  373.                                 data-table-badge-id=\"calendarEventBadge\"
  374.                                 data-table-dropdown-text-for-all=\"Все мероприятия\">Мероприятие</th>
  375.                             <th>Сумма</th>
  376.                             <th data-export-exclude-col
  377.                                 data-table-dropdown-id=\"invoiceStatusDropdown\"
  378.                                 data-table-badge-id=\"invoiceStatusBadge\"
  379.                                 data-table-dropdown-text-for-all=\"Все статусы счёта\">Статус счёта</th>
  380.                             <th data-table-hide-col
  381.                                 data-table-dropdown-id=\"invoiceStatusDropdown\"
  382.                                 data-table-badge-id=\"invoiceStatusBadge\"
  383.                                 data-table-dropdown-text-for-all=\"Все статусы счёта\">Статус счёта (текст)</th>
  384.                             <th data-table-dropdown-id=\"financeCategoryDropdown\"
  385.                                 data-table-badge-id=\"financeCategoryBadge\"
  386.                                 data-table-dropdown-text-for-all=\"Все статьи\">Статья финансов</th>
  387.                         </tr>
  388.                     </thead>
  389.                     <tbody>
  390.                         {% set i = 0 %}
  391.                         {% for item in items %}
  392.                             {% set i = i + 1 %}
  393.                             {% set person = item.person %}
  394.                             {% set student = person ? person.student : null %}
  395.                             {% set calendarEvent = item.candidate ? item.candidate.calendarEvent : null %}
  396.                             <tr>
  397.                                 <td>{{ i }}</td>
  398.                                 <td>{{ item.createdAt|date('d.m.Y') }}</td>
  399.                                 <td>{{ person ? person.name : '–' }}</td>
  400.                                 <td>{{ student ? student.level : '–' }}</td>
  401.                                 <td>
  402.                                     {% if student %}
  403.                                         <span class=\"btn btn-{{ student.statusCssClass }} btn-icon-split w-max cursor-default\">
  404.                                             <span class=\"icon text-white-50\"><i class=\"fas fa-tag\"></i></span>
  405.                                             <span class=\"text\">{{ student.statusText }}</span>
  406.                                         </span>
  407.                                     {% else %}
  408.                                         –
  409.                                     {% endif %}
  410.                                 </td>
  411.                                 <td>{{ student ? student.statusText : '–' }}</td>
  412.                                 <td>{{ calendarEvent ? calendarEvent.getText() : '–' }}</td>
  413.                                 <td>{{ item.amount }}</td>
  414.                                 <td>
  415.                                     {% include 'components/status_button.html.twig' with { options: {
  416.                                         buttonClass: item.statusCssClass,
  417.                                         text: item.statusText,
  418.                                     }} %}
  419.                                 </td>
  420.                                 <td>{{ item.statusText }}</td>
  421.                                 <td>{{ item.financeCategory ? item.financeCategory.name : '–' }}</td>
  422.                         {% endfor %}
  423.                     </tbody>
  424.                 </table>
  425.             </div>
  426.             <div class=\"mt-4 d-flex\">
  427.                 <button id=\"download-csv-btn\" class=\"btn btn-primary\">Скачать таблицу</button>
  428.             </div>
  429.         </div>
  430.     </div>
  431. {% endblock %}
  432. {% block addJs %}
  433.     <script>
  434.         let table = new CustomDataTable('#invoices-data-table', {
  435.             drawRowNumbersForColIndex: 0,
  436.         });
  437.         table.initDataTable();
  438.         \$('#download-csv-btn').click(function() {
  439.             table.downloadCsv();
  440.         });
  441.     </script>
  442. {% endblock %}
  443. ""admin/invoice/invoices.html.twig""/home/sariato/www/dev.centr.sariato.ru/templates/admin/invoice/invoices.html.twig");
  444.     }
  445. }