<?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;
/* Product/detail.twig */
class __TwigTemplate_9bbd4ced6074fd22ad653bd6f735c57ba907af5127e578a9314aa4e3b841256d extends \Eccube\Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'tracking_script' => [$this, 'block_tracking_script'],
'stylesheet' => [$this, 'block_stylesheet'],
'javascript' => [$this, 'block_javascript'],
'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", "Product/detail.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Product/detail.twig"));
// line 13
$context["body_class"] = "product_page";
// line 11
$this->parent = $this->loadTemplate("default_frame.twig", "Product/detail.twig", 11);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 15
public function block_tracking_script($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", "tracking_script"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "tracking_script"));
// line 16
echo "<script>
gtag('event', 'view_item', {
currency: 'JPY',
value: ";
// line 19
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 19, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 19), "html", null, true);
echo ",
items: [{
item_id: '";
// line 21
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 21, $this->source); })()), "id", [], "any", false, false, false, 21), "html", null, true);
echo "',
item_name: '";
// line 22
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 22, $this->source); })()), "name", [], "any", false, false, false, 22), "html", null, true);
echo "',
price: ";
// line 23
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 23, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 23), "html", null, true);
echo ",
currency: 'JPY'
}]
});
</script>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 30
public function block_stylesheet($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", "stylesheet"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheet"));
// line 31
echo " <style>
.slick-slider {
margin-bottom: 30px;
}
.slick-dots {
position: absolute;
bottom: -45px;
display: block;
width: 100%;
padding: 0;
list-style: none;
text-align: center;
}
.slick-dots li {
position: relative;
display: inline-block;
width: 20px;
height: 20px;
margin: 0 5px;
padding: 0;
cursor: pointer;
}
.slick-dots li button {
font-size: 0;
line-height: 0;
display: block;
width: 20px;
height: 20px;
padding: 5px;
cursor: pointer;
color: transparent;
border: 0;
outline: none;
background: transparent;
}
.slick-dots li button:hover,
.slick-dots li button:focus {
outline: none;
}
.slick-dots li button:hover:before,
.slick-dots li button:focus:before {
opacity: 1;
}
.slick-dots li button:before {
content: \" \";
line-height: 20px;
position: absolute;
top: 0;
left: 0;
width: 12px;
height: 12px;
text-align: center;
opacity: .25;
background-color: black;
border-radius: 50%;
}
.slick-dots li.slick-active button:before {
opacity: .75;
background-color: black;
}
.slick-dots li button.thumbnail img {
width: 0;
height: 0;
}
.freearea-modal-wrap {
position: fixed;
top: 0;
left: 0;
z-index: 99999;
width: 100%;
height: 100%;
}
.freearea-modal-overlay {
display: flex;
justify-content: center;
align-items: center;
width: 100%;
height: 100%;
}
.freearea-modal-layer-mask {
position: absolute;
z-index: 0;
background-color: rgba(0, 0, 0, 0.3);
width: 100%;
height: 100vh;
}
.freearea-modal-cont {
position: relative;
border-radius: 6px;
border: 1px solid #333;
background: #eee;
width: 100%;
max-width: 620px;
margin: 0 10px;
padding: 25px 15px 10px;
text-align: center;
}
.freearea-modal-inner-wrap {
margin: 20px 0 35px;
}
.freearea-modal-close-wrap {
text-align: right;
}
.freearea-modal-close {
background: #DE5D50;
border: none;
border-radius: 3px;
}
</style>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 154
public function block_javascript($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", "javascript"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascript"));
// line 155
echo " <script>
eccube.classCategories = ";
// line 156
echo $this->extensions['Eccube\Twig\Extension\EccubeExtension']->getClassCategoriesAsJson((isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 156, $this->source); })()));
echo ";
// 規格2に選択肢を割り当てる。
function fnSetClassCategories(form, classcat_id2_selected) {
var \$form = \$(form);
var product_id = \$form.find('input[name=product_id]').val();
var \$sele1 = \$form.find('select[name=classcategory_id1]');
var \$sele2 = \$form.find('select[name=classcategory_id2]');
eccube.setClassCategories(\$form, product_id, \$sele1, \$sele2, classcat_id2_selected);
}
";
// line 167
if (twig_get_attribute($this->env, $this->source, ($context["form"] ?? null), "classcategory_id2", [], "any", true, true, false, 167)) {
// line 168
echo " fnSetClassCategories(
\$('#form1'), ";
// line 169
echo json_encode(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 169, $this->source); })()), "classcategory_id2", [], "any", false, false, false, 169), "vars", [], "any", false, false, false, 169), "value", [], "any", false, false, false, 169));
echo "
);
";
} elseif (twig_get_attribute($this->env, $this->source, // line 171
($context["form"] ?? null), "classcategory_id1", [], "any", true, true, false, 171)) {
// line 172
echo " eccube.checkStock(\$('#form1'), ";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 172, $this->source); })()), "id", [], "any", false, false, false, 172), "html", null, true);
echo ", ";
echo json_encode(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 172, $this->source); })()), "classcategory_id1", [], "any", false, false, false, 172), "vars", [], "any", false, false, false, 172), "value", [], "any", false, false, false, 172));
echo ", null);
";
}
// line 174
echo " </script>
<script>
\$(function() {
// bfcache無効化
\$(window).bind('pageshow', function(event) {
if (event.originalEvent.persisted) {
location.reload(true);
}
});
\$('.item_visual').slick({
dots: false,
arrows: false,
responsive: [{
breakpoint: 768,
settings: {
dots: true
}
}]
});
\$('.slideThumb').on('click', function() {
var index = \$(this).attr('data-index');
\$('.item_visual').slick('slickGoTo', index, false);
})
});
</script>
<script>
\$(function() {
\$('.add-cart').on('click', function(event) {
";
// line 204
if (twig_get_attribute($this->env, $this->source, ($context["form"] ?? null), "classcategory_id1", [], "any", true, true, false, 204)) {
// line 205
echo " // 規格1フォームの必須チェック
if (\$('#classcategory_id1').val() == '__unselected' || \$('#classcategory_id1').val() == '') {
\$('#classcategory_id1')[0].setCustomValidity('";
// line 207
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("項目が選択されていません"), "html", null, true);
echo "');
return true;
} else {
\$('#classcategory_id1')[0].setCustomValidity('');
}
";
}
// line 213
echo "
";
// line 214
if (twig_get_attribute($this->env, $this->source, ($context["form"] ?? null), "classcategory_id2", [], "any", true, true, false, 214)) {
// line 215
echo " // 規格2フォームの必須チェック
if (\$('#classcategory_id2').val() == '__unselected' || \$('#classcategory_id2').val() == '') {
\$('#classcategory_id2')[0].setCustomValidity('";
// line 217
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("項目が選択されていません"), "html", null, true);
echo "');
return true;
} else {
\$('#classcategory_id2')[0].setCustomValidity('');
}
";
}
// line 223
echo "
// 個数フォームのチェック
if (\$('#quantity').val() < 1) {
\$('#quantity')[0].setCustomValidity('";
// line 226
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("1以上で入力してください。"), "html", null, true);
echo "');
return true;
} else {
\$('#quantity')[0].setCustomValidity('');
}
event.preventDefault();
\$form = \$('#form1');
\$.ajax({
url: \$form.attr('action'),
type: \$form.attr('method'),
data: \$form.serialize(),
dataType: 'json',
beforeSend: function(xhr, settings) {
// Buttonを無効にする
\$('.add-cart').prop('disabled', true);
}
}).done(function(data) {
// レスポンス内のメッセージをalertで表示
\$.each(data.messages, function() {
\$('#ec-modal-header').html(this);
});
\$('.ec-modal').show()
// カートブロックを更新する
\$.ajax({
url: \"";
// line 253
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("block_cart");
echo "\",
type: 'GET',
dataType: 'html'
}).done(function(html) {
\$('.ec-headerRole__cart').html(html);
});
}).fail(function(data) {
alert('";
// line 260
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへの追加に失敗しました。"), "html", null, true);
echo "');
}).always(function(data) {
// Buttonを有効にする
\$('.add-cart').prop('disabled', false);
});
});
});
\$('.ec-modal-wrap').on('click', function(e) {
// モーダル内の処理は外側にバブリングさせない
e.stopPropagation();
});
\$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
\$('.ec-modal').hide()
});
window.addEventListener('DOMContentLoaded', () =>
{
const modalWrap = document.querySelector('.freearea-modal-wrap')
if(modalWrap) {
const closeModalButton = document.querySelector('.freearea-modal-close')
closeModalButton.addEventListener('click', () => modalWrap.remove())
}
})
</script>
<script type=\"application/ld+json\">
{
\"@context\": \"https://schema.org/\",
\"@type\": \"Product\",
\"name\": \"";
// line 290
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 290, $this->source); })()), "name", [], "any", false, false, false, 290), "html", null, true);
echo "\",
\"image\": [
";
// line 292
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 292, $this->source); })()), "ProductImage", [], "any", false, false, false, 292));
$context['_iterated'] = false;
$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["img"]) {
// line 293
echo " \"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 293, $this->source); })()), "request", [], "any", false, false, false, 293), "schemeAndHttpHost", [], "any", false, false, false, 293), "html", null, true);
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($context["img"], "save_image"), "html", null, true);
echo "\"";
if ( !twig_get_attribute($this->env, $this->source, $context["loop"], "last", [], "any", false, false, false, 293)) {
echo ",";
}
// line 294
echo "
";
$context['_iterated'] = true;
++$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'];
}
}
if (!$context['_iterated']) {
// line 296
echo " \"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 296, $this->source); })()), "request", [], "any", false, false, false, 296), "schemeAndHttpHost", [], "any", false, false, false, 296), "html", null, true);
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($this->extensions['Eccube\Twig\Extension\EccubeExtension']->getNoImageProduct(""), "save_image"), "html", null, true);
echo "\"
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['img'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 298
echo " ],
\"description\": \"";
// line 299
echo twig_escape_filter($this->env, twig_slice($this->env, twig_replace_filter(((twig_get_attribute($this->env, $this->source, ($context["Product"] ?? null), "description_list", [], "any", true, true, false, 299)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["Product"] ?? null), "description_list", [], "any", false, false, false, 299), twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 299, $this->source); })()), "description_detail", [], "any", false, false, false, 299))) : (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 299, $this->source); })()), "description_detail", [], "any", false, false, false, 299))), ["
" => "", "
" => ""]), 0, 300), "html", null, true);
echo "\",
";
// line 300
if (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 300, $this->source); })()), "code_min", [], "any", false, false, false, 300)) {
// line 301
echo " \"sku\": \"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 301, $this->source); })()), "code_min", [], "any", false, false, false, 301), "html", null, true);
echo "\",
";
}
// line 303
echo " \"offers\": {
\"@type\": \"Offer\",
\"url\": \"";
// line 305
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_detail", ["id" => twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 305, $this->source); })()), "id", [], "any", false, false, false, 305)]), "html", null, true);
echo "\",
\"priceCurrency\": \"";
// line 306
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["eccube_config"]) || array_key_exists("eccube_config", $context) ? $context["eccube_config"] : (function () { throw new RuntimeError('Variable "eccube_config" does not exist.', 306, $this->source); })()), "currency", [], "any", false, false, false, 306), "html", null, true);
echo "\",
\"price\": ";
// line 307
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 307, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 307), "html", null, true);
echo ",
\"availability\": \"";
// line 308
echo ((twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 308, $this->source); })()), "stock_find", [], "any", false, false, false, 308)) ? ("InStock") : ("OutOfStock"));
echo "\"
}
}
</script>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 314
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 315
echo " <div class=\"ec-productRole\">
<div class=\"ec-grid2\">
<div class=\"ec-grid2__cell\">
<div class=\"ec-sliderItemRole\">
<div class=\"item_visual\">
";
// line 321
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 321, $this->source); })()), "ProductImage", [], "any", false, false, false, 321));
$context['_iterated'] = false;
$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["ProductImage"]) {
// line 322
echo " <div class=\"slide-item\"><img src=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($context["ProductImage"], "save_image"), "html", null, true);
echo "\" alt=\"";
((twig_get_attribute($this->env, $this->source, $context["loop"], "first", [], "any", false, false, false, 322)) ? (print (twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 322, $this->source); })()), "name", [], "any", false, false, false, 322), "html", null, true))) : (print ("")));
echo "\"></div>
";
$context['_iterated'] = true;
++$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'];
}
}
if (!$context['_iterated']) {
// line 324
echo " <div class=\"slide-item\"><img src=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($this->extensions['Eccube\Twig\Extension\EccubeExtension']->getNoImageProduct(""), "save_image"), "html", null, true);
echo "\" alt=\"";
((twig_get_attribute($this->env, $this->source, $context["loop"], "first", [], "any", false, false, false, 324)) ? (print (twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 324, $this->source); })()), "name", [], "any", false, false, false, 324), "html", null, true))) : (print ("")));
echo "\" /></div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['ProductImage'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 326
echo " </div>
<div class=\"item_nav\">
";
// line 328
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 328, $this->source); })()), "ProductImage", [], "any", false, false, false, 328));
$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["ProductImage"]) {
// line 329
echo " <div class=\"slideThumb\" data-index=\"";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["loop"], "index0", [], "any", false, false, false, 329), "html", null, true);
echo "\"><img src=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl($context["ProductImage"], "save_image"), "html", null, true);
echo "\" alt=\"\"></div>
";
++$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['ProductImage'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 331
echo " </div>
</div>
</div>
<div class=\"ec-grid2__cell\">
<div class=\"ec-productRole__profile\">
";
// line 337
echo " <div class=\"ec-productRole__title\">
<h2 class=\"ec-headingTitle\">";
// line 338
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 338, $this->source); })()), "name", [], "any", false, false, false, 338), "html", null, true);
echo "</h2>
</div>
";
// line 341
echo " <ul class=\"ec-productRole__tags\">
";
// line 342
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 342, $this->source); })()), "Tags", [], "any", false, false, false, 342));
foreach ($context['_seq'] as $context["_key"] => $context["Tag"]) {
// line 343
echo " <li class=\"ec-productRole__tag tag_";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["Tag"], "id", [], "any", false, false, false, 343), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, $context["Tag"], "html", null, true);
echo "</li>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['Tag'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 345
echo " </ul>
";
// line 347
echo " ";
if (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 347, $this->source); })()), "hasProductClass", [], "any", false, false, false, 347)) {
// line 348
echo "<div class=\"ec-productRole__priceRegular\">
";
// line 349
if (( !(null === twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 349, $this->source); })()), "getPrice01Min", [], "any", false, false, false, 349)) && (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 349, $this->source); })()), "getPrice01IncTaxMin", [], "any", false, false, false, 349) == twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 349, $this->source); })()), "getPrice01IncTaxMax", [], "any", false, false, false, 349)))) {
// line 350
echo " <span class=\"f-small\">寄付金額</span>
<span class=\"ec-productRole__priceRegularPrice\">";
// line 351
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("通常価格"), "html", null, true);
echo ":<span class=\"price01-default\">";
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 351, $this->source); })()), "getPrice01IncTaxMin", [], "any", false, false, false, 351)), "html", null, true);
echo "</span></span>
";
// line 353
echo " ";
} elseif (( !(null === twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 353, $this->source); })()), "getPrice01Min", [], "any", false, false, false, 353)) && !(null === twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 353, $this->source); })()), "getPrice01Max", [], "any", false, false, false, 353)))) {
// line 354
echo " <span class=\"f-small\">寄付金額</span>
<span class=\"ec-productRole__priceRegularPrice\">";
// line 355
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("通常価格"), "html", null, true);
echo ":<span class=\"price01-default\">";
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 355, $this->source); })()), "getPrice01IncTaxMin", [], "any", false, false, false, 355)), "html", null, true);
echo "~ ";
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 355, $this->source); })()), "getPrice01IncTaxMax", [], "any", false, false, false, 355)), "html", null, true);
echo "</span></span>
";
// line 357
echo " ";
}
// line 358
echo " </div>
";
} else {
// line 360
echo " ";
// line 364
echo " ";
}
// line 365
echo " ";
// line 366
echo " <div class=\"ec-productRole__price\">
";
// line 367
if (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 367, $this->source); })()), "hasProductClass", [], "any", false, false, false, 367)) {
// line 368
if ((twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 368, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 368) == twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 368, $this->source); })()), "getPrice02IncTaxMax", [], "any", false, false, false, 368))) {
// line 369
echo " <div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price price02-default\">";
// line 371
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 371, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 371)), "html", null, true);
echo "円</span>
";
// line 373
echo " </div>
";
} else {
// line 375
echo " <div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price price02-default\">";
// line 377
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 377, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 377)), "html", null, true);
echo " ~ ";
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 377, $this->source); })()), "getPrice02IncTaxMax", [], "any", false, false, false, 377)), "html", null, true);
echo "円</span>
";
// line 379
echo " </div>
";
}
// line 381
echo " ";
} else {
// line 382
echo " <div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price\">";
// line 384
echo twig_escape_filter($this->env, twig_number_format_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 384, $this->source); })()), "getPrice02IncTaxMin", [], "any", false, false, false, 384)), "html", null, true);
echo "円</span>
";
// line 386
echo " </div>
";
}
// line 388
echo " </div>
";
// line 390
echo " ";
if ( !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 390, $this->source); })()), "code_min", [], "any", false, false, false, 390))) {
// line 391
echo " <div class=\"ec-productRole__code\">
";
// line 392
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("商品コード"), "html", null, true);
echo ": <span class=\"product-code-default\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 392, $this->source); })()), "code_min", [], "any", false, false, false, 392), "html", null, true);
if ((twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 392, $this->source); })()), "code_min", [], "any", false, false, false, 392) != twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 392, $this->source); })()), "code_max", [], "any", false, false, false, 392))) {
echo " ~ ";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 392, $this->source); })()), "code_max", [], "any", false, false, false, 392), "html", null, true);
}
echo "</span>
</div>
";
}
// line 395
echo " ";
// line 396
echo " ";
if ( !twig_test_empty(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 396, $this->source); })()), "ProductCategories", [], "any", false, false, false, 396))) {
// line 397
echo " <div class=\"ec-productRole__category\">
<div>";
// line 398
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("関連カテゴリ"), "html", null, true);
echo "</div>
";
// line 399
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 399, $this->source); })()), "ProductCategories", [], "any", false, false, false, 399));
foreach ($context['_seq'] as $context["_key"] => $context["ProductCategory"]) {
// line 400
echo " <ul>
<li>
";
// line 402
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["ProductCategory"], "Category", [], "any", false, false, false, 402), "path", [], "any", false, false, false, 402));
$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["Category"]) {
// line 403
echo " <a href=\"";
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_list");
echo "?category_id=";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["Category"], "id", [], "any", false, false, false, 403), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["Category"], "name", [], "any", false, false, false, 403), "html", null, true);
echo "</a>";
if ((twig_get_attribute($this->env, $this->source, $context["loop"], "last", [], "any", false, false, false, 403) == false)) {
// line 404
echo " <span>></span>";
}
++$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['Category'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 406
echo " </li>
</ul>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['ProductCategory'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 409
echo " </div>
";
}
// line 411
echo " <form action=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_add_cart", ["id" => twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 411, $this->source); })()), "id", [], "any", false, false, false, 411)]), "html", null, true);
echo "\" method=\"post\" id=\"form1\" name=\"form1\">
";
// line 412
if (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 412, $this->source); })()), "stock_find", [], "any", false, false, false, 412)) {
// line 413
echo " <div class=\"ec-productRole__actions\">
";
// line 414
if (twig_get_attribute($this->env, $this->source, ($context["form"] ?? null), "classcategory_id1", [], "any", true, true, false, 414)) {
// line 415
echo " <div class=\"ec-select\">
";
// line 416
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 416, $this->source); })()), "classcategory_id1", [], "any", false, false, false, 416), 'widget');
echo "
";
// line 417
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 417, $this->source); })()), "classcategory_id1", [], "any", false, false, false, 417), 'errors');
echo "
</div>
";
// line 419
if (twig_get_attribute($this->env, $this->source, ($context["form"] ?? null), "classcategory_id2", [], "any", true, true, false, 419)) {
// line 420
echo " <div class=\"ec-select\">
";
// line 421
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 421, $this->source); })()), "classcategory_id2", [], "any", false, false, false, 421), 'widget');
echo "
";
// line 422
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 422, $this->source); })()), "classcategory_id2", [], "any", false, false, false, 422), 'errors');
echo "
</div>
";
}
// line 425
echo " ";
}
// line 426
echo " <div class=\"ec-numberInput\"><span>";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("数量"), "html", null, true);
echo "</span>
";
// line 427
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 427, $this->source); })()), "quantity", [], "any", false, false, false, 427), 'widget');
echo "
";
// line 428
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env, $this->source, (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 428, $this->source); })()), "quantity", [], "any", false, false, false, 428), 'errors');
echo "
</div>
</div>
";
// line 432
$context["now_date"] = twig_date_format_filter($this->env, "now", "Y/m/d");
// line 433
echo " ";
$context["set_period"] = twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 433, $this->source); })()), "period_range", [], "any", false, false, false, 433);
// line 434
echo "
";
// line 435
if ( !(null === (isset($context["set_period"]) || array_key_exists("set_period", $context) ? $context["set_period"] : (function () { throw new RuntimeError('Variable "set_period" does not exist.', 435, $this->source); })()))) {
// line 436
echo " ";
$context["expiration_date"] = twig_date_modify_filter($this->env, (isset($context["now_date"]) || array_key_exists("now_date", $context) ? $context["now_date"] : (function () { throw new RuntimeError('Variable "now_date" does not exist.', 436, $this->source); })()), (("+" . (isset($context["set_period"]) || array_key_exists("set_period", $context) ? $context["set_period"] : (function () { throw new RuntimeError('Variable "set_period" does not exist.', 436, $this->source); })())) . " months -1 day"));
// line 437
echo " ";
$context["year"] = twig_round(((isset($context["set_period"]) || array_key_exists("set_period", $context) ? $context["set_period"] : (function () { throw new RuntimeError('Variable "set_period" does not exist.', 437, $this->source); })()) / 12), 0, "floor");
// line 438
echo " ";
$context["month"] = ((isset($context["set_period"]) || array_key_exists("set_period", $context) ? $context["set_period"] : (function () { throw new RuntimeError('Variable "set_period" does not exist.', 438, $this->source); })()) % 12);
// line 439
echo " <div>有効期限:寄付完了日から<span style=\"color: #DE5D50;\">";
if (((isset($context["year"]) || array_key_exists("year", $context) ? $context["year"] : (function () { throw new RuntimeError('Variable "year" does not exist.', 439, $this->source); })()) > 0)) {
echo twig_escape_filter($this->env, (isset($context["year"]) || array_key_exists("year", $context) ? $context["year"] : (function () { throw new RuntimeError('Variable "year" does not exist.', 439, $this->source); })()), "html", null, true);
echo "年";
}
if (((isset($context["month"]) || array_key_exists("month", $context) ? $context["month"] : (function () { throw new RuntimeError('Variable "month" does not exist.', 439, $this->source); })()) > 0)) {
echo twig_escape_filter($this->env, (isset($context["month"]) || array_key_exists("month", $context) ? $context["month"] : (function () { throw new RuntimeError('Variable "month" does not exist.', 439, $this->source); })()), "html", null, true);
echo "ヶ月";
}
echo "</span></div>
<div>本日付で寄付された場合の有効期限は<span style=\"color: #DE5D50;\">";
// line 440
echo twig_escape_filter($this->env, twig_date_format_filter($this->env, (isset($context["expiration_date"]) || array_key_exists("expiration_date", $context) ? $context["expiration_date"] : (function () { throw new RuntimeError('Variable "expiration_date" does not exist.', 440, $this->source); })()), "Y/m/d"), "html", null, true);
echo "</span>までとなります。</div>
";
}
// line 442
echo "
<div class=\"ec-productRole__btn\">
<button type=\"submit\" class=\"ec-blockBtn--action add-cart\">
";
// line 445
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートに入れる"), "html", null, true);
echo "
</button>
</div>
";
} else {
// line 449
echo " <div class=\"ec-productRole__btn\">
<button type=\"button\" class=\"ec-blockBtn--action\" disabled=\"disabled\">
";
// line 451
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("ただいま品切れ中です。"), "html", null, true);
echo "
</button>
</div>
";
}
// line 455
echo "
";
// line 456
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 456, $this->source); })()), 'rest');
echo "
</form>
<div class=\"ec-modal\">
<div class=\"ec-modal-overlay\">
<div class=\"ec-modal-wrap\">
<span class=\"ec-modal-close\"><span class=\"ec-icon\"><img src=\"";
// line 461
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("assets/icon/cross-dark.svg"), "html", null, true);
echo "\" alt=\"\"/></span></span>
<div id=\"ec-modal-header\" class=\"text-center\">";
// line 462
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートに追加しました。"), "html", null, true);
echo "</div>
<div class=\"ec-modal-box\">
<div class=\"ec-role\">
<span class=\"ec-inlineBtn--cancel\">";
// line 465
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お買い物を続ける"), "html", null, true);
echo "</span>
<a href=\"";
// line 466
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("cart");
echo "\" class=\"ec-inlineBtn--action\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("カートへ進む"), "html", null, true);
echo "</a>
</div>
</div>
</div>
</div>
</div>
";
// line 472
if (twig_get_attribute($this->env, $this->source, (isset($context["BaseInfo"]) || array_key_exists("BaseInfo", $context) ? $context["BaseInfo"] : (function () { throw new RuntimeError('Variable "BaseInfo" does not exist.', 472, $this->source); })()), "option_favorite_product", [], "any", false, false, false, 472)) {
// line 473
echo " <form action=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getUrl("product_add_favorite", ["id" => twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 473, $this->source); })()), "id", [], "any", false, false, false, 473)]), "html", null, true);
echo "\" method=\"post\">
<div class=\"ec-productRole__btn\">
";
// line 475
if (((isset($context["is_favorite"]) || array_key_exists("is_favorite", $context) ? $context["is_favorite"] : (function () { throw new RuntimeError('Variable "is_favorite" does not exist.', 475, $this->source); })()) == false)) {
// line 476
echo " <button type=\"submit\" id=\"favorite\" class=\"ec-blockBtn--cancel\">
";
// line 477
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お気に入りに追加"), "html", null, true);
echo "
</button>
";
} else {
// line 480
echo " <button type=\"submit\" id=\"favorite\" class=\"ec-blockBtn--cancel\"
disabled=\"disabled\">";
// line 481
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("お気に入りに追加済です。"), "html", null, true);
echo "
</button>
";
}
// line 484
echo " </div>
</form>
";
}
// line 487
echo " <div class=\"ec-productRole__description\">
";
// line 488
echo twig_nl2br(twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 488, $this->source); })()), "description_detail", [], "any", false, false, false, 488));
echo "
</div>
</div>
</div>
</div>
";
// line 493
if (twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 493, $this->source); })()), "freearea", [], "any", false, false, false, 493)) {
// line 494
echo " <div class=\"freearea-modal-wrap\">
<div class=\"freearea-modal-overlay\">
<div class=\"freearea-modal-layer-mask\"></div>
<div class=\"freearea-modal-cont\">
<div class=\"freearea-modal-inner-wrap\">
";
// line 499
echo twig_include($this->env, $context, twig_template_from_string($this->env, twig_get_attribute($this->env, $this->source, (isset($context["Product"]) || array_key_exists("Product", $context) ? $context["Product"] : (function () { throw new RuntimeError('Variable "Product" does not exist.', 499, $this->source); })()), "freearea", [], "any", false, false, false, 499)));
echo "
</div>
<div class=\"freearea-modal-close-wrap\">
<button class=\"freearea-modal-close ec-inlineBtn--action\">確認</button>
</div>
</div>
</div>
</div>
";
}
// line 508
echo " </div>
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "Product/detail.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 1087 => 508, 1075 => 499, 1068 => 494, 1066 => 493, 1058 => 488, 1055 => 487, 1050 => 484, 1044 => 481, 1041 => 480, 1035 => 477, 1032 => 476, 1030 => 475, 1024 => 473, 1022 => 472, 1011 => 466, 1007 => 465, 1001 => 462, 997 => 461, 989 => 456, 986 => 455, 979 => 451, 975 => 449, 968 => 445, 963 => 442, 958 => 440, 946 => 439, 943 => 438, 940 => 437, 937 => 436, 935 => 435, 932 => 434, 929 => 433, 927 => 432, 920 => 428, 916 => 427, 911 => 426, 908 => 425, 902 => 422, 898 => 421, 895 => 420, 893 => 419, 888 => 417, 884 => 416, 881 => 415, 879 => 414, 876 => 413, 874 => 412, 869 => 411, 865 => 409, 857 => 406, 842 => 404, 833 => 403, 816 => 402, 812 => 400, 808 => 399, 804 => 398, 801 => 397, 798 => 396, 796 => 395, 784 => 392, 781 => 391, 778 => 390, 775 => 388, 771 => 386, 767 => 384, 763 => 382, 760 => 381, 756 => 379, 750 => 377, 746 => 375, 742 => 373, 738 => 371, 734 => 369, 732 => 368, 730 => 367, 727 => 366, 725 => 365, 722 => 364, 720 => 360, 716 => 358, 713 => 357, 705 => 355, 702 => 354, 699 => 353, 693 => 351, 690 => 350, 688 => 349, 685 => 348, 682 => 347, 679 => 345, 668 => 343, 664 => 342, 661 => 341, 656 => 338, 653 => 337, 646 => 331, 627 => 329, 610 => 328, 606 => 326, 595 => 324, 577 => 322, 559 => 321, 551 => 315, 541 => 314, 526 => 308, 522 => 307, 518 => 306, 514 => 305, 510 => 303, 504 => 301, 502 => 300, 497 => 299, 494 => 298, 484 => 296, 470 => 294, 462 => 293, 444 => 292, 439 => 290, 406 => 260, 396 => 253, 366 => 226, 361 => 223, 352 => 217, 348 => 215, 346 => 214, 343 => 213, 334 => 207, 330 => 205, 328 => 204, 296 => 174, 288 => 172, 286 => 171, 281 => 169, 278 => 168, 276 => 167, 262 => 156, 259 => 155, 249 => 154, 118 => 31, 108 => 30, 92 => 23, 88 => 22, 84 => 21, 79 => 19, 74 => 16, 64 => 15, 53 => 11, 51 => 13, 38 => 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 tracking_script %}
<script>
gtag('event', 'view_item', {
currency: 'JPY',
value: {{ Product.getPrice02IncTaxMin }},
items: [{
item_id: '{{ Product.id }}',
item_name: '{{ Product.name }}',
price: {{ Product.getPrice02IncTaxMin }},
currency: 'JPY'
}]
});
</script>
{% endblock %}
{% block stylesheet %}
<style>
.slick-slider {
margin-bottom: 30px;
}
.slick-dots {
position: absolute;
bottom: -45px;
display: block;
width: 100%;
padding: 0;
list-style: none;
text-align: center;
}
.slick-dots li {
position: relative;
display: inline-block;
width: 20px;
height: 20px;
margin: 0 5px;
padding: 0;
cursor: pointer;
}
.slick-dots li button {
font-size: 0;
line-height: 0;
display: block;
width: 20px;
height: 20px;
padding: 5px;
cursor: pointer;
color: transparent;
border: 0;
outline: none;
background: transparent;
}
.slick-dots li button:hover,
.slick-dots li button:focus {
outline: none;
}
.slick-dots li button:hover:before,
.slick-dots li button:focus:before {
opacity: 1;
}
.slick-dots li button:before {
content: \" \";
line-height: 20px;
position: absolute;
top: 0;
left: 0;
width: 12px;
height: 12px;
text-align: center;
opacity: .25;
background-color: black;
border-radius: 50%;
}
.slick-dots li.slick-active button:before {
opacity: .75;
background-color: black;
}
.slick-dots li button.thumbnail img {
width: 0;
height: 0;
}
.freearea-modal-wrap {
position: fixed;
top: 0;
left: 0;
z-index: 99999;
width: 100%;
height: 100%;
}
.freearea-modal-overlay {
display: flex;
justify-content: center;
align-items: center;
width: 100%;
height: 100%;
}
.freearea-modal-layer-mask {
position: absolute;
z-index: 0;
background-color: rgba(0, 0, 0, 0.3);
width: 100%;
height: 100vh;
}
.freearea-modal-cont {
position: relative;
border-radius: 6px;
border: 1px solid #333;
background: #eee;
width: 100%;
max-width: 620px;
margin: 0 10px;
padding: 25px 15px 10px;
text-align: center;
}
.freearea-modal-inner-wrap {
margin: 20px 0 35px;
}
.freearea-modal-close-wrap {
text-align: right;
}
.freearea-modal-close {
background: #DE5D50;
border: none;
border-radius: 3px;
}
</style>
{% endblock %}
{% block javascript %}
<script>
eccube.classCategories = {{ class_categories_as_json(Product)|raw }};
// 規格2に選択肢を割り当てる。
function fnSetClassCategories(form, classcat_id2_selected) {
var \$form = \$(form);
var product_id = \$form.find('input[name=product_id]').val();
var \$sele1 = \$form.find('select[name=classcategory_id1]');
var \$sele2 = \$form.find('select[name=classcategory_id2]');
eccube.setClassCategories(\$form, product_id, \$sele1, \$sele2, classcat_id2_selected);
}
{% if form.classcategory_id2 is defined %}
fnSetClassCategories(
\$('#form1'), {{ form.classcategory_id2.vars.value|json_encode|raw }}
);
{% elseif form.classcategory_id1 is defined %}
eccube.checkStock(\$('#form1'), {{ Product.id }}, {{ form.classcategory_id1.vars.value|json_encode|raw }}, null);
{% endif %}
</script>
<script>
\$(function() {
// bfcache無効化
\$(window).bind('pageshow', function(event) {
if (event.originalEvent.persisted) {
location.reload(true);
}
});
\$('.item_visual').slick({
dots: false,
arrows: false,
responsive: [{
breakpoint: 768,
settings: {
dots: true
}
}]
});
\$('.slideThumb').on('click', function() {
var index = \$(this).attr('data-index');
\$('.item_visual').slick('slickGoTo', index, false);
})
});
</script>
<script>
\$(function() {
\$('.add-cart').on('click', function(event) {
{% if form.classcategory_id1 is defined %}
// 規格1フォームの必須チェック
if (\$('#classcategory_id1').val() == '__unselected' || \$('#classcategory_id1').val() == '') {
\$('#classcategory_id1')[0].setCustomValidity('{{ '項目が選択されていません'|trans }}');
return true;
} else {
\$('#classcategory_id1')[0].setCustomValidity('');
}
{% endif %}
{% if form.classcategory_id2 is defined %}
// 規格2フォームの必須チェック
if (\$('#classcategory_id2').val() == '__unselected' || \$('#classcategory_id2').val() == '') {
\$('#classcategory_id2')[0].setCustomValidity('{{ '項目が選択されていません'|trans }}');
return true;
} else {
\$('#classcategory_id2')[0].setCustomValidity('');
}
{% endif %}
// 個数フォームのチェック
if (\$('#quantity').val() < 1) {
\$('#quantity')[0].setCustomValidity('{{ '1以上で入力してください。'|trans }}');
return true;
} else {
\$('#quantity')[0].setCustomValidity('');
}
event.preventDefault();
\$form = \$('#form1');
\$.ajax({
url: \$form.attr('action'),
type: \$form.attr('method'),
data: \$form.serialize(),
dataType: 'json',
beforeSend: function(xhr, settings) {
// Buttonを無効にする
\$('.add-cart').prop('disabled', true);
}
}).done(function(data) {
// レスポンス内のメッセージをalertで表示
\$.each(data.messages, function() {
\$('#ec-modal-header').html(this);
});
\$('.ec-modal').show()
// カートブロックを更新する
\$.ajax({
url: \"{{ url('block_cart') }}\",
type: 'GET',
dataType: 'html'
}).done(function(html) {
\$('.ec-headerRole__cart').html(html);
});
}).fail(function(data) {
alert('{{ 'カートへの追加に失敗しました。'|trans }}');
}).always(function(data) {
// Buttonを有効にする
\$('.add-cart').prop('disabled', false);
});
});
});
\$('.ec-modal-wrap').on('click', function(e) {
// モーダル内の処理は外側にバブリングさせない
e.stopPropagation();
});
\$('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function() {
\$('.ec-modal').hide()
});
window.addEventListener('DOMContentLoaded', () =>
{
const modalWrap = document.querySelector('.freearea-modal-wrap')
if(modalWrap) {
const closeModalButton = document.querySelector('.freearea-modal-close')
closeModalButton.addEventListener('click', () => modalWrap.remove())
}
})
</script>
<script type=\"application/ld+json\">
{
\"@context\": \"https://schema.org/\",
\"@type\": \"Product\",
\"name\": \"{{ Product.name }}\",
\"image\": [
{% for img in Product.ProductImage %}
\"{{ app.request.schemeAndHttpHost }}{{ asset(img, 'save_image') }}\"{% if not loop.last %},{% endif %}
{% else %}
\"{{ app.request.schemeAndHttpHost }}{{ asset(''|no_image_product, 'save_image') }}\"
{% endfor %}
],
\"description\": \"{{ Product.description_list | default(Product.description_detail) | replace({'\\n': '', '\\r': ''}) | slice(0,300) }}\",
{% if Product.code_min %}
\"sku\": \"{{ Product.code_min }}\",
{% endif %}
\"offers\": {
\"@type\": \"Offer\",
\"url\": \"{{ url('product_detail', {'id': Product.id}) }}\",
\"priceCurrency\": \"{{ eccube_config.currency }}\",
\"price\": {{ Product.getPrice02IncTaxMin }},
\"availability\": \"{{ Product.stock_find ? \"InStock\" : \"OutOfStock\" }}\"
}
}
</script>
{% endblock %}
{% block main %}
<div class=\"ec-productRole\">
<div class=\"ec-grid2\">
<div class=\"ec-grid2__cell\">
<div class=\"ec-sliderItemRole\">
<div class=\"item_visual\">
{% for ProductImage in Product.ProductImage %}
<div class=\"slide-item\"><img src=\"{{ asset(ProductImage, 'save_image') }}\" alt=\"{{ loop.first ? Product.name : '' }}\"></div>
{% else %}
<div class=\"slide-item\"><img src=\"{{ asset(''|no_image_product, 'save_image') }}\" alt=\"{{ loop.first ? Product.name : '' }}\" /></div>
{% endfor %}
</div>
<div class=\"item_nav\">
{% for ProductImage in Product.ProductImage %}
<div class=\"slideThumb\" data-index=\"{{ loop.index0 }}\"><img src=\"{{ asset(ProductImage, 'save_image') }}\" alt=\"\"></div>
{% endfor %}
</div>
</div>
</div>
<div class=\"ec-grid2__cell\">
<div class=\"ec-productRole__profile\">
{# 商品名 #}
<div class=\"ec-productRole__title\">
<h2 class=\"ec-headingTitle\">{{ Product.name }}</h2>
</div>
{# タグ #}
<ul class=\"ec-productRole__tags\">
{% for Tag in Product.Tags %}
<li class=\"ec-productRole__tag tag_{{ Tag.id }}\">{{ Tag }}</li>
{% endfor %}
</ul>
{# 通常価格 #}
{% if Product.hasProductClass -%}
<div class=\"ec-productRole__priceRegular\">
{% if Product.getPrice01Min is not null and Product.getPrice01IncTaxMin == Product.getPrice01IncTaxMax %}
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-productRole__priceRegularPrice\">{{ '通常価格'|trans }}:<span class=\"price01-default\">{{ Product.getPrice01IncTaxMin|number_format }}</span></span>
{# <span class=\"ec-productRole__priceRegularTax\">{{ '税込'|trans }}</span> #}
{% elseif Product.getPrice01Min is not null and Product.getPrice01Max is not null %}
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-productRole__priceRegularPrice\">{{ '通常価格'|trans }}:<span class=\"price01-default\">{{ Product.getPrice01IncTaxMin|number_format }}~ {{ Product.getPrice01IncTaxMax|number_format }}</span></span>
{# <span class=\"ec-productRole__priceRegularTax\">{{ '税込'|trans }}</span> #}
{% endif %}
</div>
{% else %}
{# {% if Product.getPrice01Max is not null %}
<span class=\"ec-productRole__priceRegularPrice\">{{ '通常価格'|trans }}:{{ Product.getPrice01IncTaxMin|number_format }}</span>
<span class=\"ec-productRole__priceRegularTax\">{{ '税込'|trans }}</span>
{% endif %} #}
{% endif %}
{# 販売価格 #}
<div class=\"ec-productRole__price\">
{% if Product.hasProductClass -%}
{% if Product.getPrice02IncTaxMin == Product.getPrice02IncTaxMax %}
<div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price price02-default\">{{ Product.getPrice02IncTaxMin|number_format }}円</span>
{# <span class=\"ec-price__tax\">{{ '税込'|trans }}</span> #}
</div>
{% else %}
<div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price price02-default\">{{ Product.getPrice02IncTaxMin|number_format }} ~ {{ Product.getPrice02IncTaxMax|number_format }}円</span>
{# <span class=\"ec-price__tax\">{{ '税込'|trans }}</span> #}
</div>
{% endif %}
{% else %}
<div class=\"ec-price\">
<span class=\"f-small\">寄付金額</span>
<span class=\"ec-price__price\">{{ Product.getPrice02IncTaxMin|number_format }}円</span>
{# <span class=\"ec-price__tax\">{{ '税込'|trans }}</span> #}
</div>
{% endif %}
</div>
{# 商品コード #}
{% if Product.code_min is not empty %}
<div class=\"ec-productRole__code\">
{{ '商品コード'|trans }}: <span class=\"product-code-default\">{{ Product.code_min }}{% if Product.code_min != Product.code_max %} ~ {{ Product.code_max }}{% endif %}</span>
</div>
{% endif %}
{# 関連カテゴリ #}
{% if Product.ProductCategories is not empty %}
<div class=\"ec-productRole__category\">
<div>{{ '関連カテゴリ'|trans }}</div>
{% for ProductCategory in Product.ProductCategories %}
<ul>
<li>
{% for Category in ProductCategory.Category.path %}
<a href=\"{{ url('product_list') }}?category_id={{ Category.id }}\">{{ Category.name }}</a> {%- if loop.last == false %}
<span>></span>{% endif -%}
{% endfor %}
</li>
</ul>
{% endfor %}
</div>
{% endif %}
<form action=\"{{ url('product_add_cart', {id:Product.id}) }}\" method=\"post\" id=\"form1\" name=\"form1\">
{% if Product.stock_find %}
<div class=\"ec-productRole__actions\">
{% if form.classcategory_id1 is defined %}
<div class=\"ec-select\">
{{ form_widget(form.classcategory_id1) }}
{{ form_errors(form.classcategory_id1) }}
</div>
{% if form.classcategory_id2 is defined %}
<div class=\"ec-select\">
{{ form_widget(form.classcategory_id2) }}
{{ form_errors(form.classcategory_id2) }}
</div>
{% endif %}
{% endif %}
<div class=\"ec-numberInput\"><span>{{ '数量'|trans }}</span>
{{ form_widget(form.quantity) }}
{{ form_errors(form.quantity) }}
</div>
</div>
{% set now_date = 'now'|date('Y/m/d') %}
{% set set_period = Product.period_range %}
{% if set_period is not null %}
{% set expiration_date = now_date|date_modify('+' ~ set_period ~ ' months -1 day') %}
{% set year = (set_period / 12)|round(0, 'floor') %}
{% set month = set_period % 12 %}
<div>有効期限:寄付完了日から<span style=\"color: #DE5D50;\">{% if year > 0 %}{{ year }}年{% endif %}{% if month > 0 %}{{ month }}ヶ月{% endif %}</span></div>
<div>本日付で寄付された場合の有効期限は<span style=\"color: #DE5D50;\">{{ expiration_date|date('Y/m/d') }}</span>までとなります。</div>
{% endif %}
<div class=\"ec-productRole__btn\">
<button type=\"submit\" class=\"ec-blockBtn--action add-cart\">
{{ 'カートに入れる'|trans }}
</button>
</div>
{% else %}
<div class=\"ec-productRole__btn\">
<button type=\"button\" class=\"ec-blockBtn--action\" disabled=\"disabled\">
{{ 'ただいま品切れ中です。'|trans }}
</button>
</div>
{% endif %}
{{ form_rest(form) }}
</form>
<div class=\"ec-modal\">
<div class=\"ec-modal-overlay\">
<div class=\"ec-modal-wrap\">
<span class=\"ec-modal-close\"><span class=\"ec-icon\"><img src=\"{{ asset('assets/icon/cross-dark.svg') }}\" alt=\"\"/></span></span>
<div id=\"ec-modal-header\" class=\"text-center\">{{ 'カートに追加しました。'|trans }}</div>
<div class=\"ec-modal-box\">
<div class=\"ec-role\">
<span class=\"ec-inlineBtn--cancel\">{{ 'お買い物を続ける'|trans }}</span>
<a href=\"{{ url('cart') }}\" class=\"ec-inlineBtn--action\">{{ 'カートへ進む'|trans }}</a>
</div>
</div>
</div>
</div>
</div>
{% if BaseInfo.option_favorite_product %}
<form action=\"{{ url('product_add_favorite', {id:Product.id}) }}\" method=\"post\">
<div class=\"ec-productRole__btn\">
{% if is_favorite == false %}
<button type=\"submit\" id=\"favorite\" class=\"ec-blockBtn--cancel\">
{{ 'お気に入りに追加'|trans }}
</button>
{% else %}
<button type=\"submit\" id=\"favorite\" class=\"ec-blockBtn--cancel\"
disabled=\"disabled\">{{ 'お気に入りに追加済です。'|trans }}
</button>
{% endif %}
</div>
</form>
{% endif %}
<div class=\"ec-productRole__description\">
{{ Product.description_detail|raw|nl2br }}
</div>
</div>
</div>
</div>
{% if Product.freearea %}
<div class=\"freearea-modal-wrap\">
<div class=\"freearea-modal-overlay\">
<div class=\"freearea-modal-layer-mask\"></div>
<div class=\"freearea-modal-cont\">
<div class=\"freearea-modal-inner-wrap\">
{{ include(template_from_string(Product.freearea)) }}
</div>
<div class=\"freearea-modal-close-wrap\">
<button class=\"freearea-modal-close ec-inlineBtn--action\">確認</button>
</div>
</div>
</div>
</div>
{% endif %}
</div>
{% endblock %}", "Product/detail.twig", "/home/cajiya/fjdksla.com/public_html/cocofuru.fjdksla.com/src/Eccube/Resource/template/default/Product/detail.twig");
}
}