<?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;
/* @user_data/News/index.twig */
class __TwigTemplate_de0afb5423a2cbbd1e6187ae1f668d86757f84771572633d8f36821d9d974a9f extends \Eccube\Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'main' => [$this, 'block_main'],
];
}
protected function doGetParent(array $context)
{
// line 11
return "default_frame.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@user_data/News/index.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@user_data/News/index.twig"));
$this->parent = $this->loadTemplate("default_frame.twig", "@user_data/News/index.twig", 11);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 22
public function block_main($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
// line 23
echo " <div class=\"ec-registerPage\">
<div class=\"ec-registerPage__header ec-newsTitle\">
<h1 class=\"ec-registerPage__title\">
";
// line 26
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("News"), "html", null, true);
echo "
<br/>
<p>";
// line 28
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("ニュース"), "html", null, true);
echo "</p>
</h1>
</div>
</div>
<div class=\"ec-blockspliter\"></div>
<div class=\"ec-role\">
<div class=\"ec-newsRole\">
<div class=\"ec-newsRole__news\">
";
// line 36
if ((twig_length_filter($this->env, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 36, $this->source); })())) > 0)) {
// line 37
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 37, $this->source); })()));
foreach ($context['_seq'] as $context["key"] => $context["News"]) {
// line 38
echo " <div class=\"ec-newsRole__newsItem\">
<a class=\"ec-newsItem\" href=\"";
// line 39
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("news_detail", ["id" => twig_get_attribute($this->env, $this->source, $context["News"], "id", [], "any", false, false, false, 39)]), "html", null, true);
echo "\">
<div class=\"ec-newsRole__newsHeading\">
<div class=\"ec-newsRole__newsDate\">
";
// line 42
echo twig_escape_filter($this->env, $this->extensions['Eccube\Twig\Extension\IntlExtension']->date_day($this->env, twig_get_attribute($this->env, $this->source, $context["News"], "publish_date", [], "any", false, false, false, 42)), "html", null, true);
echo "
</div>
<div class=\"ec-newsRole__newsTitle\">
";
// line 45
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["News"], "title", [], "any", false, false, false, 45), "html", null, true);
echo "
</div>
";
// line 47
if ((($context["key"] % 2) == 1)) {
// line 48
echo " <span class=\"ec-newsRole__newsBtn even\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お知らせ"), "html", null, true);
echo "</span>
";
} else {
// line 50
echo " <span class=\"ec-newsRole__newsBtn odd\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お知らせ"), "html", null, true);
echo "</span>
";
}
// line 52
echo " </div>
</a>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['key'], $context['News'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 56
echo " ";
} else {
// line 57
echo " <p class=\"ec-para-normal ec-dataEmpty\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("資料はありません。"), "html", null, true);
echo "</p>
";
}
// line 59
echo " </div>
</div>
";
// line 61
if ((twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 61, $this->source); })()), "pageCount", [], "any", false, false, false, 61) > 1)) {
// line 62
echo " <div class=\"ec-blockspliter\"></div>
";
}
// line 64
echo " </div>
";
// line 65
if ((twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 65, $this->source); })()), "pageCount", [], "any", false, false, false, 65) > 1)) {
// line 66
echo " <div class=\"ec-role\">
<div class=\"ec-pagerRole ec-newsPagination\">
";
// line 68
$this->loadTemplate("pager.twig", "@user_data/News/index.twig", 68)->display(twig_array_merge($context, ["pages" => twig_get_attribute($this->env, $this->source, (isset($context["pagination"]) || array_key_exists("pagination", $context) ? $context["pagination"] : (function () { throw new RuntimeError('Variable "pagination" does not exist.', 68, $this->source); })()), "paginationData", [], "any", false, false, false, 68)]));
// line 69
echo " </div>
</div>
";
}
// line 72
echo " <div class=\"ec-blockspliter\"></div>
<div class=\"ec-blockempty\"></div>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "@user_data/News/index.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 174 => 72, 169 => 69, 167 => 68, 163 => 66, 161 => 65, 158 => 64, 154 => 62, 152 => 61, 148 => 59, 142 => 57, 139 => 56, 130 => 52, 124 => 50, 118 => 48, 116 => 47, 111 => 45, 105 => 42, 99 => 39, 96 => 38, 91 => 37, 89 => 36, 78 => 28, 73 => 26, 68 => 23, 58 => 22, 35 => 11,);
}
public function getSourceContext()
{
return new Source("{#
This file is part of EC-CUBE
Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
http://www.ec-cube.co.jp/
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends 'default_frame.twig' %}
{# {% set body_class = 'product_page' %} #}
{# {% block javascript %} #}
{# <script> #}
{# \$(document).ready(function() { #}
{# console.log(\"pagination: \", pagination) #}
{# }); #}
{# </script> #}
{# {% endblock %} #}
{% block main %}
<div class=\"ec-registerPage\">
<div class=\"ec-registerPage__header ec-newsTitle\">
<h1 class=\"ec-registerPage__title\">
{{ 'News'|trans }}
<br/>
<p>{{ 'ニュース'|trans }}</p>
</h1>
</div>
</div>
<div class=\"ec-blockspliter\"></div>
<div class=\"ec-role\">
<div class=\"ec-newsRole\">
<div class=\"ec-newsRole__news\">
{% if pagination|length > 0 %}
{% for key, News in pagination %}
<div class=\"ec-newsRole__newsItem\">
<a class=\"ec-newsItem\" href=\"{{ url('news_detail', {'id': News.id}) }}\">
<div class=\"ec-newsRole__newsHeading\">
<div class=\"ec-newsRole__newsDate\">
{{ News.publish_date|date_day }}
</div>
<div class=\"ec-newsRole__newsTitle\">
{{ News.title }}
</div>
{% if key % 2 == 1 %}
<span class=\"ec-newsRole__newsBtn even\">{{ 'お知らせ'|trans }}</span>
{% else %}
<span class=\"ec-newsRole__newsBtn odd\">{{ 'お知らせ'|trans }}</span>
{% endif %}
</div>
</a>
</div>
{% endfor %}
{% else %}
<p class=\"ec-para-normal ec-dataEmpty\">{{ '資料はありません。'|trans }}</p>
{% endif %}
</div>
</div>
{% if pagination.pageCount > 1 %}
<div class=\"ec-blockspliter\"></div>
{% endif %}
</div>
{% if pagination.pageCount > 1 %}
<div class=\"ec-role\">
<div class=\"ec-pagerRole ec-newsPagination\">
{% include \"pager.twig\" with {'pages': pagination.paginationData} %}
</div>
</div>
{% endif %}
<div class=\"ec-blockspliter\"></div>
<div class=\"ec-blockempty\"></div>
{% endblock %}", "@user_data/News/index.twig", "/home/snowtiger27/www/three-m.online/app/template/user_data/News/index.twig");
}
}