File: D:/web/matomo.circ/tmp/templates_c/24/2433d34cbdaae0621a2c1749926af35c.php
<?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;
/* @Insights/insightVisualization.twig */
class __TwigTemplate_ec5fc69309a57791d488c421b8ad013f 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
if ((array_key_exists("cannotDisplayReport", $context) && (isset($context["cannotDisplayReport"]) || array_key_exists("cannotDisplayReport", $context) ? $context["cannotDisplayReport"] : (function () { throw new RuntimeError('Variable "cannotDisplayReport" does not exist.', 1, $this->source); })()))) {
// line 2
yield " ";
yield from $this->loadTemplate("@Insights/cannotDisplayReport.twig", "@Insights/insightVisualization.twig", 2)->unwrap()->yield($context);
} else {
// line 4
yield " ";
$context["metadata"] = CoreExtension::getAttribute($this->env, $this->source, (isset($context["dataTable"]) || array_key_exists("dataTable", $context) ? $context["dataTable"] : (function () { throw new RuntimeError('Variable "dataTable" does not exist.', 4, $this->source); })()), "getAllTableMetadata", [], "any", false, false, false, 4);
// line 5
yield " ";
$context["consideredGrowth"] = $this->env->getFilter('translate')->getCallable()("Insights_TitleConsideredInsightsGrowth", CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 5, $this->source); })()), "minGrowthPercentPositive", [], "any", false, false, false, 5), $this->env->getFilter('prettyDate')->getCallable()(CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 5, $this->source); })()), "lastDate", [], "any", false, false, false, 5), CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 5, $this->source); })()), "period", [], "any", false, false, false, 5)));
// line 6
yield " ";
$context["consideredChanges"] = "";
// line 7
yield "
";
// line 8
if ((CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 8, $this->source); })()), "minChangeMovers", [], "any", false, false, false, 8) && (CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 8, $this->source); })()), "minChangeMovers", [], "any", false, false, false, 8) > 1))) {
// line 9
yield " ";
$context["consideredChanges"] = $this->env->getFilter('translate')->getCallable()("Insights_IgnoredChanges", CoreExtension::getAttribute($this->env, $this->source, (isset($context["metadata"]) || array_key_exists("metadata", $context) ? $context["metadata"] : (function () { throw new RuntimeError('Variable "metadata" does not exist.', 9, $this->source); })()), "minChangeMovers", [], "any", false, false, false, 9));
// line 10
yield " ";
}
// line 11
yield "
<div class=\"insightsDataTable\" title=\"";
// line 12
yield \Piwik\piwik_escape_filter($this->env, (isset($context["consideredGrowth"]) || array_key_exists("consideredGrowth", $context) ? $context["consideredGrowth"] : (function () { throw new RuntimeError('Variable "consideredGrowth" does not exist.', 12, $this->source); })()), "html_attr");
yield " ";
yield \Piwik\piwik_escape_filter($this->env, (isset($context["consideredChanges"]) || array_key_exists("consideredChanges", $context) ? $context["consideredChanges"] : (function () { throw new RuntimeError('Variable "consideredChanges" does not exist.', 12, $this->source); })()), "html_attr");
yield "\">
";
// line 13
if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["dataTable"]) || array_key_exists("dataTable", $context) ? $context["dataTable"] : (function () { throw new RuntimeError('Variable "dataTable" does not exist.', 13, $this->source); })()), "getRowsCount", [], "any", false, false, false, 13)) {
// line 14
yield " <div class=\"dataTableScroller\">
<table class=\"dataTable\">
<thead>
";
// line 18
yield from $this->loadTemplate("@Insights/table_header.twig", "@Insights/insightVisualization.twig", 18)->unwrap()->yield($context);
// line 19
yield " </thead>
<tbody>
";
// line 22
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env, $this->source, (isset($context["dataTable"]) || array_key_exists("dataTable", $context) ? $context["dataTable"] : (function () { throw new RuntimeError('Variable "dataTable" does not exist.', 22, $this->source); })()), "getRows", [], "any", false, false, false, 22));
$context['loop'] = [
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
];
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["_key"] => $context["row"]) {
// line 23
yield " ";
yield from $this->loadTemplate("@Insights/table_row.twig", "@Insights/insightVisualization.twig", 23)->unwrap()->yield($context);
// line 24
yield " ";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['row'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 25
yield " </tbody>
</table>
</div>
";
} else {
// line 29
yield " <div class=\"pk-emptyDataTable\">
";
// line 30
yield \Piwik\piwik_escape_filter($this->env, $this->env->getFilter('translate')->getCallable()("Insights_NoResultMatchesCriteria"), "html", null, true);
yield "
</div>
";
}
// line 33
yield "
";
// line 34
yield from $this->loadTemplate("@Insights/insightControls.twig", "@Insights/insightVisualization.twig", 34)->unwrap()->yield($context);
// line 35
yield " </div>
";
}
return; yield '';
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName()
{
return "@Insights/insightVisualization.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable()
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo()
{
return array ( 142 => 35, 140 => 34, 137 => 33, 131 => 30, 128 => 29, 122 => 25, 108 => 24, 105 => 23, 88 => 22, 83 => 19, 81 => 18, 75 => 14, 73 => 13, 67 => 12, 64 => 11, 61 => 10, 58 => 9, 56 => 8, 53 => 7, 50 => 6, 47 => 5, 44 => 4, 40 => 2, 38 => 1,);
}
public function getSourceContext()
{
return new Source("{% if cannotDisplayReport is defined and cannotDisplayReport %}
{% include \"@Insights/cannotDisplayReport.twig\" %}
{% else %}
{% set metadata = dataTable.getAllTableMetadata%}
{% set consideredGrowth = 'Insights_TitleConsideredInsightsGrowth'|translate(metadata.minGrowthPercentPositive, metadata.lastDate|prettyDate(metadata.period)) %}
{% set consideredChanges = '' %}
{% if metadata.minChangeMovers and metadata.minChangeMovers > 1 %}
{% set consideredChanges = 'Insights_IgnoredChanges'|translate(metadata.minChangeMovers) %}
{% endif %}
<div class=\"insightsDataTable\" title=\"{{ consideredGrowth|e('html_attr') }} {{ consideredChanges|e('html_attr') }}\">
{% if dataTable.getRowsCount %}
<div class=\"dataTableScroller\">
<table class=\"dataTable\">
<thead>
{% include \"@Insights/table_header.twig\" %}
</thead>
<tbody>
{% for row in dataTable.getRows %}
{% include \"@Insights/table_row.twig\" %}
{% endfor %}
</tbody>
</table>
</div>
{% else %}
<div class=\"pk-emptyDataTable\">
{{ 'Insights_NoResultMatchesCriteria'|translate }}
</div>
{% endif %}
{% include \"@Insights/insightControls.twig\" %}
</div>
{% endif %}", "@Insights/insightVisualization.twig", "D:\\web\\matomo.circ\\plugins\\Insights\\templates\\insightVisualization.twig");
}
}