var/cache/dev/twig/4a/4a10f90f6d94e94993e6818c56305cc3.php line 81

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/entity_log/entity_log.html.twig */
  15. class __TwigTemplate_3e2ad665ed474299b31d6d569884396b 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/entity_log/entity_log.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/entity_log/entity_log.html.twig"));
  41.         $this->parent $this->loadTemplate("admin/base.html.twig""admin/entity_log/entity_log.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=\"entity-log-table-filters\" class=\"mb-4 d-flex align-items-center\" style=\"gap: 20px; flex-wrap: wrap;\">
  79.                 ";
  80.         // line 14
  81.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/entity_log/entity_log.html.twig"14)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Автор""dropdownIdPrefix" => "author""allItemsButtonText" => "Все авторы"]]));
  82.         // line 19
  83.         yield "
  84.                 ";
  85.         // line 20
  86.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/entity_log/entity_log.html.twig"20)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Тип данных""dropdownIdPrefix" => "entityType""allItemsButtonText" => "Все типы"]]));
  87.         // line 25
  88.         yield "
  89.                 ";
  90.         // line 26
  91.         yield from         $this->loadTemplate("components/table_filter.html.twig""admin/entity_log/entity_log.html.twig"26)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["labelText" => "Действие""dropdownIdPrefix" => "actionType""allItemsButtonText" => "Все действия"]]));
  92.         // line 31
  93.         yield "            </div>
  94.             <div class=\"table-responsive\">
  95.                 <table class=\"table table-bordered\" id=\"entity-log-data-table\">
  96.                     <thead>
  97.                         <tr>
  98.                             <th data-table-type=\"num\">Номер п/п</th>
  99.                             <th data-table-type=\"date-d-m-Y-asc\">Дата</th>
  100.                             <th data-table-dropdown-id=\"authorDropdown\"
  101.                                 data-table-badge-id=\"authorBadge\"
  102.                                 data-table-dropdown-text-for-all=\"Все авторы\">Автор</th>
  103.                             <th>Данные</th>
  104.                             <th data-table-hide-col
  105.                                 data-table-dropdown-id=\"entityTypeDropdown\"
  106.                                 data-table-badge-id=\"entityTypeBadge\"
  107.                                 data-table-dropdown-text-for-all=\"Все типы\">Тип данных</th>
  108. ";
  109.         // line 48
  110.         yield "                            <th data-table-dropdown-id=\"actionTypeDropdown\"
  111.                                 data-table-badge-id=\"actionTypeBadge\"
  112.                                 data-table-dropdown-text-for-all=\"Все действия\">Действие</th>
  113.                             <th>Старое значение</th>
  114.                             <th>Новое значение</th>
  115.                         </tr>
  116.                     </thead>
  117.                     <tbody>
  118.                         ";
  119.         // line 56
  120.         $context["i"] = 0;
  121.         // line 57
  122.         yield "                        ";
  123.         $context['_parent'] = $context;
  124.         $context['_seq'] = CoreExtension::ensureTraversable((isset($context["items"]) || array_key_exists("items"$context) ? $context["items"] : (function () { throw new RuntimeError('Variable "items" does not exist.'57$this->source); })()));
  125.         $context['loop'] = [
  126.           'parent' => $context['_parent'],
  127.           'index0' => 0,
  128.           'index'  => 1,
  129.           'first'  => true,
  130.         ];
  131.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  132.             $length count($context['_seq']);
  133.             $context['loop']['revindex0'] = $length 1;
  134.             $context['loop']['revindex'] = $length;
  135.             $context['loop']['length'] = $length;
  136.             $context['loop']['last'] = === $length;
  137.         }
  138.         foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  139.             // line 58
  140.             yield "                            ";
  141.             $context["i"] = ((isset($context["i"]) || array_key_exists("i"$context) ? $context["i"] : (function () { throw new RuntimeError('Variable "i" does not exist.'58$this->source); })()) + 1);
  142.             // line 59
  143.             yield "                            <tr>
  144.                                 <td>";
  145.             // line 60
  146.             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.'60$this->source); })()), "html"nulltrue);
  147.             yield "</td>
  148.                                 <td>";
  149.             // line 61
  150.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env$this->source$context["item"], "createdAt", [], "any"falsefalsefalse61), "d.m.Y H:i"), "html"nulltrue);
  151.             yield "</td>
  152.                                 <td>";
  153.             // line 62
  154.             ((CoreExtension::getAttribute($this->env$this->source$context["item"], "editedBy", [], "any"falsefalsefalse62)) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->sourceCoreExtension::getAttribute($this->env$this->source$context["item"], "editedBy", [], "any"falsefalsefalse62), "name", [], "any"falsefalsefalse62), "html"nulltrue)) : (yield "–"));
  155.             yield "</td>
  156.                                 <td>
  157.                                     ";
  158.             // line 64
  159.             $context["fieldLabel"] = CoreExtension::getAttribute($this->env$this->source$context["item"], "getEntityFieldText", [], "method"falsefalsefalse64);
  160.             // line 65
  161.             yield "                                    ";
  162.             if (((isset($context["fieldLabel"]) || array_key_exists("fieldLabel"$context) ? $context["fieldLabel"] : (function () { throw new RuntimeError('Variable "fieldLabel" does not exist.'65$this->source); })()) == CoreExtension::getAttribute($this->env$this->source$context["item"], "fieldName", [], "any"falsefalsefalse65))) {
  163.                 // line 66
  164.                 yield "                                        ";
  165.                 $context["fieldLabel"] = CoreExtension::getAttribute($this->env$this->source, (isset($context["entityLogService"]) || array_key_exists("entityLogService"$context) ? $context["entityLogService"] : (function () { throw new RuntimeError('Variable "entityLogService" does not exist.'66$this->source); })()), "getEntityFormFieldLabel", [("App\\Entity\\" CoreExtension::getAttribute($this->env$this->source,                 // line 67
  166. $context["item"], "entityClass", [], "any"falsefalsefalse67)), CoreExtension::getAttribute($this->env$this->source$context["item"], "fieldName", [], "any"falsefalsefalse67)], "method"falsefalsefalse66);
  167.                 // line 68
  168.                 yield "                                    ";
  169.             }
  170.             // line 69
  171.             yield "                                    ";
  172.             yield from             $this->loadTemplate("components/status_button.html.twig""admin/entity_log/entity_log.html.twig"69)->unwrap()->yield(CoreExtension::merge($context, ["options" => ["buttonClass" => CoreExtension::getAttribute($this->env$this->source,             // line 70
  173. $context["item"], "getEntityClassCss", [], "method"falsefalsefalse70), "text" => CoreExtension::getAttribute($this->env$this->source,             // line 71
  174. $context["item"], "getEntityText", [], "method"falsefalsefalse71)]]));
  175.             // line 73
  176.             yield "                                    <small class=\"text-muted\">";
  177.             (((isset($context["fieldLabel"]) || array_key_exists("fieldLabel"$context) ? $context["fieldLabel"] : (function () { throw new RuntimeError('Variable "fieldLabel" does not exist.'73$this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["fieldLabel"]) || array_key_exists("fieldLabel"$context) ? $context["fieldLabel"] : (function () { throw new RuntimeError('Variable "fieldLabel" does not exist.'73$this->source); })()), "html"nulltrue)) : (yield "–"));
  178.             yield "</small>
  179.                                 </td>
  180.                                 <td>";
  181.             // line 75
  182.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["item"], "getEntityText", [], "method"falsefalsefalse75), "html"nulltrue);
  183.             yield "</td>
  184. ";
  185.             // line 77
  186.             yield "                                <td>";
  187.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["item"], "typeText", [], "any"falsefalsefalse77), "html"nulltrue);
  188.             yield "</td>
  189.                                 <td>
  190.                                     ";
  191.             // line 79
  192.             if (CoreExtension::getAttribute($this->env$this->source$context["item"], "getOldFieldValueText", [], "any"falsefalsefalse79)) {
  193.                 // line 80
  194.                 yield "                                        ";
  195.                 yield CoreExtension::getAttribute($this->env$this->source$context["item"], "getOldFieldValueText", [], "any"falsefalsefalse80);
  196.                 yield "
  197.                                     ";
  198.             } elseif (CoreExtension::getAttribute($this->env$this->source,             // line 81
  199. $context["item"], "oldData", [], "any"falsefalsefalse81)) {
  200.                 // line 82
  201.                 yield "                                        ";
  202.                 $context['_parent'] = $context;
  203.                 $context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env$this->source$context["item"], "oldData", [], "any"falsefalsefalse82));
  204.                 $context['loop'] = [
  205.                   'parent' => $context['_parent'],
  206.                   'index0' => 0,
  207.                   'index'  => 1,
  208.                   'first'  => true,
  209.                 ];
  210.                 if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  211.                     $length count($context['_seq']);
  212.                     $context['loop']['revindex0'] = $length 1;
  213.                     $context['loop']['revindex'] = $length;
  214.                     $context['loop']['length'] = $length;
  215.                     $context['loop']['last'] = === $length;
  216.                 }
  217.                 foreach ($context['_seq'] as $context["key"] => $context["value"]) {
  218.                     // line 83
  219.                     yield "                                            <strong>";
  220.                     yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["value"], "label", [], "any"falsefalsefalse83), "html"nulltrue);
  221.                     yield ":</strong> ";
  222.                     yield (($this->extensions['App\Twig\AppExtension']->isArray(CoreExtension::getAttribute($this->env$this->source$context["value"], "value", [], "any"falsefalsefalse83))) ? ("[]") : (CoreExtension::getAttribute($this->env$this->source$context["value"], "value", [], "any"falsefalsefalse83)));
  223.                     if ( !CoreExtension::getAttribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsefalse83)) {
  224.                         yield "<br>";
  225.                     }
  226.                     // line 84
  227.                     yield "                                        ";
  228.                     ++$context['loop']['index0'];
  229.                     ++$context['loop']['index'];
  230.                     $context['loop']['first'] = false;
  231.                     if (isset($context['loop']['length'])) {
  232.                         --$context['loop']['revindex0'];
  233.                         --$context['loop']['revindex'];
  234.                         $context['loop']['last'] = === $context['loop']['revindex0'];
  235.                     }
  236.                 }
  237.                 $_parent $context['_parent'];
  238.                 unset($context['_seq'], $context['_iterated'], $context['key'], $context['value'], $context['_parent'], $context['loop']);
  239.                 $context array_intersect_key($context$_parent) + $_parent;
  240.                 // line 85
  241.                 yield "                                    ";
  242.             } else {
  243.                 // line 86
  244.                 yield "                                        –
  245.                                     ";
  246.             }
  247.             // line 88
  248.             yield "                                </td>
  249.                                 <td>
  250.                                 ";
  251.             // line 90
  252.             if (CoreExtension::getAttribute($this->env$this->source$context["item"], "getOldFieldValueText", [], "any"falsefalsefalse90)) {
  253.                 // line 91
  254.                 yield "                                    ";
  255.                 yield CoreExtension::getAttribute($this->env$this->source$context["item"], "getOldFieldValueText", [], "any"falsefalsefalse91);
  256.                 yield "
  257.                                 ";
  258.             } elseif (CoreExtension::getAttribute($this->env$this->source,             // line 92
  259. $context["item"], "data", [], "any"falsefalsefalse92)) {
  260.                 // line 93
  261.                 yield "                                    ";
  262.                 $context['_parent'] = $context;
  263.                 $context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env$this->source$context["item"], "data", [], "any"falsefalsefalse93));
  264.                 $context['loop'] = [
  265.                   'parent' => $context['_parent'],
  266.                   'index0' => 0,
  267.                   'index'  => 1,
  268.                   'first'  => true,
  269.                 ];
  270.                 if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  271.                     $length count($context['_seq']);
  272.                     $context['loop']['revindex0'] = $length 1;
  273.                     $context['loop']['revindex'] = $length;
  274.                     $context['loop']['length'] = $length;
  275.                     $context['loop']['last'] = === $length;
  276.                 }
  277.                 foreach ($context['_seq'] as $context["key"] => $context["value"]) {
  278.                     // line 94
  279.                     yield "                                        <strong>";
  280.                     yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->source$context["value"], "label", [], "any"falsefalsefalse94), "html"nulltrue);
  281.                     yield ":</strong> ";
  282.                     yield (($this->extensions['App\Twig\AppExtension']->isArray(CoreExtension::getAttribute($this->env$this->source$context["value"], "value", [], "any"falsefalsefalse94))) ? ("[]") : (CoreExtension::getAttribute($this->env$this->source$context["value"], "value", [], "any"falsefalsefalse94)));
  283.                     if ( !CoreExtension::getAttribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsefalse94)) {
  284.                         yield "<br>";
  285.                     }
  286.                     // line 95
  287.                     yield "                                    ";
  288.                     ++$context['loop']['index0'];
  289.                     ++$context['loop']['index'];
  290.                     $context['loop']['first'] = false;
  291.                     if (isset($context['loop']['length'])) {
  292.                         --$context['loop']['revindex0'];
  293.                         --$context['loop']['revindex'];
  294.                         $context['loop']['last'] = === $context['loop']['revindex0'];
  295.                     }
  296.                 }
  297.                 $_parent $context['_parent'];
  298.                 unset($context['_seq'], $context['_iterated'], $context['key'], $context['value'], $context['_parent'], $context['loop']);
  299.                 $context array_intersect_key($context$_parent) + $_parent;
  300.                 // line 96
  301.                 yield "                                ";
  302.             } else {
  303.                 // line 97
  304.                 yield "                                    –
  305.                                 ";
  306.             }
  307.             // line 99
  308.             yield "                                </td>
  309.                             </tr>
  310.                         ";
  311.             ++$context['loop']['index0'];
  312.             ++$context['loop']['index'];
  313.             $context['loop']['first'] = false;
  314.             if (isset($context['loop']['length'])) {
  315.                 --$context['loop']['revindex0'];
  316.                 --$context['loop']['revindex'];
  317.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  318.             }
  319.         }
  320.         $_parent $context['_parent'];
  321.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  322.         $context array_intersect_key($context$_parent) + $_parent;
  323.         // line 102
  324.         yield "                    </tbody>
  325.                 </table>
  326.             </div>
  327.         </div>
  328.     </div>
  329. ";
  330.         
  331.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  332.         
  333.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  334.         return; yield '';
  335.     }
  336.     // line 109
  337.     public function block_addJs($context, array $blocks = [])
  338.     {
  339.         $macros $this->macros;
  340.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  341.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""addJs"));
  342.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  343.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""addJs"));
  344.         // line 110
  345.         yield "    <script>
  346.         let table = new CustomDataTable('#entity-log-data-table', {
  347.             \"lengthMenu\": [[20, 50, 100, 200, -1], [20, 50, 100, 200, \"Все\"]],
  348.             drawRowNumbersForColIndex: 0,
  349.         });
  350.         table.initDataTable();
  351.     </script>
  352. ";
  353.         
  354.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  355.         
  356.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  357.         return; yield '';
  358.     }
  359.     /**
  360.      * @codeCoverageIgnore
  361.      */
  362.     public function getTemplateName()
  363.     {
  364.         return "admin/entity_log/entity_log.html.twig";
  365.     }
  366.     /**
  367.      * @codeCoverageIgnore
  368.      */
  369.     public function isTraitable()
  370.     {
  371.         return false;
  372.     }
  373.     /**
  374.      * @codeCoverageIgnore
  375.      */
  376.     public function getDebugInfo()
  377.     {
  378.         return array (  371 => 110,  361 => 109,  345 => 102,  329 => 99,  325 => 97,  322 => 96,  308 => 95,  300 => 94,  282 => 93,  280 => 92,  275 => 91,  273 => 90,  269 => 88,  265 => 86,  262 => 85,  248 => 84,  240 => 83,  222 => 82,  220 => 81,  215 => 80,  213 => 79,  207 => 77,  203 => 75,  197 => 73,  195 => 71,  194 => 70,  192 => 69,  189 => 68,  187 => 67,  185 => 66,  182 => 65,  180 => 64,  175 => 62,  171 => 61,  167 => 60,  164 => 59,  161 => 58,  143 => 57,  141 => 56,  131 => 48,  113 => 31,  111 => 26,  108 => 25,  106 => 20,  103 => 19,  101 => 14,  91 => 6,  81 => 5,  61 => 3,  38 => 1,);
  379.     }
  380.     public function getSourceContext()
  381.     {
  382.         return new Source("{% extends 'admin/base.html.twig' %}
  383. {% block title %}История изменения данных{% endblock %}
  384. {% block content %}
  385.     <h1 class=\"h3 mb-2 text-gray-800\">История изменения данных</h1>
  386.     <div class=\"card shadow mb-4 mt-4\">
  387.         <div class=\"card-header py-3\">
  388.             <h6 class=\"m-0 font-weight-bold text-primary\">Список изменений</h6>
  389.         </div>
  390.         <div class=\"card-body\">
  391.             <div id=\"entity-log-table-filters\" class=\"mb-4 d-flex align-items-center\" style=\"gap: 20px; flex-wrap: wrap;\">
  392.                 {% include 'components/table_filter.html.twig' with { options: {
  393.                     labelText: 'Автор',
  394.                     dropdownIdPrefix: 'author',
  395.                     allItemsButtonText: 'Все авторы',
  396.                 }} %}
  397.                 {% include 'components/table_filter.html.twig' with { options: {
  398.                     labelText: 'Тип данных',
  399.                     dropdownIdPrefix: 'entityType',
  400.                     allItemsButtonText: 'Все типы',
  401.                 }} %}
  402.                 {% include 'components/table_filter.html.twig' with { options: {
  403.                     labelText: 'Действие',
  404.                     dropdownIdPrefix: 'actionType',
  405.                     allItemsButtonText: 'Все действия',
  406.                 }} %}
  407.             </div>
  408.             <div class=\"table-responsive\">
  409.                 <table class=\"table table-bordered\" id=\"entity-log-data-table\">
  410.                     <thead>
  411.                         <tr>
  412.                             <th data-table-type=\"num\">Номер п/п</th>
  413.                             <th data-table-type=\"date-d-m-Y-asc\">Дата</th>
  414.                             <th data-table-dropdown-id=\"authorDropdown\"
  415.                                 data-table-badge-id=\"authorBadge\"
  416.                                 data-table-dropdown-text-for-all=\"Все авторы\">Автор</th>
  417.                             <th>Данные</th>
  418.                             <th data-table-hide-col
  419.                                 data-table-dropdown-id=\"entityTypeDropdown\"
  420.                                 data-table-badge-id=\"entityTypeBadge\"
  421.                                 data-table-dropdown-text-for-all=\"Все типы\">Тип данных</th>
  422. {#                            <th>Поле</th>#}
  423.                             <th data-table-dropdown-id=\"actionTypeDropdown\"
  424.                                 data-table-badge-id=\"actionTypeBadge\"
  425.                                 data-table-dropdown-text-for-all=\"Все действия\">Действие</th>
  426.                             <th>Старое значение</th>
  427.                             <th>Новое значение</th>
  428.                         </tr>
  429.                     </thead>
  430.                     <tbody>
  431.                         {% set i = 0 %}
  432.                         {% for item in items %}
  433.                             {% set i = i + 1 %}
  434.                             <tr>
  435.                                 <td>{{ i }}</td>
  436.                                 <td>{{ item.createdAt|date('d.m.Y H:i') }}</td>
  437.                                 <td>{{ item.editedBy ? item.editedBy.name : '–' }}</td>
  438.                                 <td>
  439.                                     {% set fieldLabel = item.getEntityFieldText() %}
  440.                                     {% if fieldLabel == item.fieldName %}
  441.                                         {% set fieldLabel = entityLogService.getEntityFormFieldLabel(
  442.                                             \"App\\\\Entity\\\\\" ~ item.entityClass, item.fieldName) %}
  443.                                     {% endif %}
  444.                                     {% include 'components/status_button.html.twig' with { options: {
  445.                                         buttonClass: item.getEntityClassCss(),
  446.                                         text: item.getEntityText(),
  447.                                     } } %}
  448.                                     <small class=\"text-muted\">{{ fieldLabel ?: '–' }}</small>
  449.                                 </td>
  450.                                 <td>{{ item.getEntityText() }}</td>
  451. {#                                <td>{{ item.getEntityFieldText() ?: '–' }}</td>#}
  452.                                 <td>{{ item.typeText }}</td>
  453.                                 <td>
  454.                                     {% if item.getOldFieldValueText %}
  455.                                         {{ item.getOldFieldValueText|raw }}
  456.                                     {% elseif item.oldData %}
  457.                                         {% for key, value in item.oldData %}
  458.                                             <strong>{{ value.label }}:</strong> {{ isArray(value.value) ? \"[]\" : value.value|raw }}{% if not loop.last %}<br>{% endif %}
  459.                                         {% endfor %}
  460.                                     {% else %}
  461.                                         –
  462.                                     {% endif %}
  463.                                 </td>
  464.                                 <td>
  465.                                 {% if item.getOldFieldValueText %}
  466.                                     {{ item.getOldFieldValueText|raw }}
  467.                                 {% elseif item.data %}
  468.                                     {% for key, value in item.data %}
  469.                                         <strong>{{ value.label }}:</strong> {{ isArray(value.value) ? \"[]\" : value.value|raw }}{% if not loop.last %}<br>{% endif %}
  470.                                     {% endfor %}
  471.                                 {% else %}
  472.                                     –
  473.                                 {% endif %}
  474.                                 </td>
  475.                             </tr>
  476.                         {% endfor %}
  477.                     </tbody>
  478.                 </table>
  479.             </div>
  480.         </div>
  481.     </div>
  482. {% endblock %}
  483. {% block addJs %}
  484.     <script>
  485.         let table = new CustomDataTable('#entity-log-data-table', {
  486.             \"lengthMenu\": [[20, 50, 100, 200, -1], [20, 50, 100, 200, \"Все\"]],
  487.             drawRowNumbersForColIndex: 0,
  488.         });
  489.         table.initDataTable();
  490.     </script>
  491. {% endblock %}
  492. ""admin/entity_log/entity_log.html.twig""/home/sariato/www/dev.centr.sariato.ru/templates/admin/entity_log/entity_log.html.twig");
  493.     }
  494. }