<?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;
/* Item/detail.twig */
class __TwigTemplate_5aec7e62a4d01aefa462aa4d12db6e59 extends \Eccube\Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'stylesheet' => [$this, 'block_stylesheet'],
'javascript' => [$this, 'block_javascript'],
'lm_after_contents_top' => [$this, 'block_lm_after_contents_top'],
'main' => [$this, 'block_main'],
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doGetParent(array $context)
{
// line 11
return "default_frame.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Item/detail.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Item/detail.twig"));
// line 13
$context["body_class"] = "item_page";
// line 11
$this->parent = $this->loadTemplate("default_frame.twig", "Item/detail.twig", 11);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 15
public function block_stylesheet($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheet"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "stylesheet"));
// line 16
echo " <style>
body {
color: #000;
}
hr {
border-color: #666;
}
.gno{
overflow:visible;
}
.top_sashikomi_wrapper img, .bottom_sashikomi_wrapper img
{
max-width:805px;
}
.top_sashikomi_wrapper div p, .bottom_sashikomi_wrapper div p
{
/*width:60%;*/
font-size:16px;
}
.recommend-images{
max-height:100px;
max-width:auto;
}
p.kodawari-no{
width:36px !important;
height:36px !important;
}
</style>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 46
public function block_javascript($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascript"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "javascript"));
// line 47
echo " <script type=\"text/javascript\" src=\"/javascripts/jquery.fbt.js?20200715_01\"></script>
<script type=\"text/javascript\">
\$(function() {
\$(window).on('scroll', function(e) {
var \$this = \$('.fbnr,.fbnr2');
var scrollTop = \$(window).scrollTop();
if (scrollTop >= 200) {
\$this.addClass('fixed');
} else {
\$this.removeClass('fixed');
}
});
});
var base = document.getElementsByTagName('base')[0];
\$(function() {
var \$contents_wrapper = \$('div#contents_wrapper').first();
var \$topBtn = \$('#pagetop').appendTo(\$contents_wrapper);
\$topBtn.hide();
//スクロールが100に達したらボタン表示
\$(window).scroll(function () {
if (\$(this).scrollTop() > 100) {
\$topBtn.fadeIn();
} else {
\$topBtn.fadeOut();
}
});
//スクロール後
\$topBtn.click(function () {
\$('body,html').animate({
scrollTop: 0
}, 500);
return false;
});
});
\$(function () {
var \$contents_wrapper = \$('div#contents_wrapper').first();
var \$cartinBtn = \$('#btm-cartin-btn').appendTo(\$contents_wrapper);
});
function zoom_dynamic(\$element) {
return \$element.each(function(i) {
var \$this = \$(this);
var width = parseInt(\$this.width());
var height = parseInt(\$this.height());
if (width > 805) {
if (navigator.userAgent.indexOf('Chrome') !== -1 || navigator.userAgent.indexOf('Safari') !== -1) {
// zoom 対応ブラウザ(Chrome、Safari)
\$this.css({ \"zoom\": \"calc( 805 / #width )\".replace(\"#width\", width), \"visibility\": \"visible\" });
} else {
// zoom 未対応ブラウザ(Firefox、IE、Opera、etc...)
var ratio = parseFloat( ( 805 / width ).toFixed(20) );
var margin_ratio = ratio - 1;
var margin_bottom = height * margin_ratio;
\$this.css({
\"transform-origin\": \"0 0\",
\"transform\": \"scale(#ratio)\".replace(/#ratio/g, ratio),
\"margin-bottom\": margin_bottom,
\"visibility\": \"visible\"
});
}
}
});
}
(function() {
\$('.kuru2').closest('.top_sashikomi_wrapper').width(990);
var \$sashikomi = \$('.top_sashikomi_wrapper').each(function(i) {
var \$sashikomi = \$(this);
\$('img', this).on('load', function(e) {
zoom_dynamic(\$sashikomi); // (2/3) 各、差込内の画像ロード完了直後
}).each(function(i) {
if(this.complete || /*for IE 10-*/ \$(this).height() > 0)
\$(this).load();
});
});
\$(function() {
zoom_dynamic(\$sashikomi).css({ \"visibility\": \"visible\" }); // (1/3) DOM読込み完了直後
\$(window).on('load', function(e) {
zoom_dynamic(\$sashikomi); // (3/3) 全script実行完了直後
});
});
}());
</script>
";
// line 130
if ((array_key_exists("useCache", $context) && ((isset($context["useCache"]) || array_key_exists("useCache", $context) ? $context["useCache"] : (function () { throw new RuntimeError('Variable "useCache" does not exist.', 130, $this->source); })()) == true))) {
// line 131
echo " <script type=\"text/javascript\">
/*
*日付の差分日数を返却します。
*/
function getDiff(date1Str, date2Str) {
var date1 = new Date(date1Str);
var date2 = new Date(date2Str);
// getTimeメソッドで経過ミリ秒を取得し、2つの日付の差を求める
var msDiff = date2.getTime() - date1.getTime();
// 求めた差分(ミリ秒)を日付へ変換します(経過ミリ秒÷(1000ミリ秒×60秒×60分×24時間)。端数切り捨て)
var daysDiff = Math.floor(msDiff / (1000 * 60 * 60 *24));
return daysDiff;
}
</script>
<script type=\"text/javascript\" async>
\$(function(){
\$.fbt('queryAll');
});
</script>
";
}
// line 155
echo "
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 158
public function block_lm_after_contents_top($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "lm_after_contents_top"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "lm_after_contents_top"));
// line 159
echo "
<div class=\"clearfix\">";
// line 160
$this->loadTemplate("Page/Parts/fixed-header.twig", "Item/detail.twig", 160)->display(twig_to_array(["category" => twig_get_attribute($this->env, $this->source, (isset($context["goods"]) || array_key_exists("goods", $context) ? $context["goods"] : (function () { throw new RuntimeError('Variable "goods" does not exist.', 160, $this->source); })()), "getMainCategory", [], "any", false, false, true, 160)]));
echo "</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 164
public function block_main($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "main"));
// line 165
echo " <div id=\"pagetop\">
<a href=\"#header\">
<img width=\"100px\" height=\"80px\" src=\"/images/top/top-jump-btn.jpg\" alt=\"ページTOPへ\">
</a>
</div>
<div id=\"btm-cartin-btn\">
<img width=\"220px\" height=\"50px\" src=\"/images/top/buy-jump-btn.jpg\" alt=\"購入ボタンへ\">
</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "Item/detail.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 284 => 165, 274 => 164, 261 => 160, 258 => 159, 248 => 158, 237 => 155, 211 => 131, 209 => 130, 124 => 47, 114 => 46, 76 => 16, 66 => 15, 55 => 11, 53 => 13, 40 => 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 = 'item_page' %}
{% block stylesheet %}
<style>
body {
color: #000;
}
hr {
border-color: #666;
}
.gno{
overflow:visible;
}
.top_sashikomi_wrapper img, .bottom_sashikomi_wrapper img
{
max-width:805px;
}
.top_sashikomi_wrapper div p, .bottom_sashikomi_wrapper div p
{
/*width:60%;*/
font-size:16px;
}
.recommend-images{
max-height:100px;
max-width:auto;
}
p.kodawari-no{
width:36px !important;
height:36px !important;
}
</style>
{% endblock %}
{% block javascript %}
<script type=\"text/javascript\" src=\"/javascripts/jquery.fbt.js?20200715_01\"></script>
<script type=\"text/javascript\">
\$(function() {
\$(window).on('scroll', function(e) {
var \$this = \$('.fbnr,.fbnr2');
var scrollTop = \$(window).scrollTop();
if (scrollTop >= 200) {
\$this.addClass('fixed');
} else {
\$this.removeClass('fixed');
}
});
});
var base = document.getElementsByTagName('base')[0];
\$(function() {
var \$contents_wrapper = \$('div#contents_wrapper').first();
var \$topBtn = \$('#pagetop').appendTo(\$contents_wrapper);
\$topBtn.hide();
//スクロールが100に達したらボタン表示
\$(window).scroll(function () {
if (\$(this).scrollTop() > 100) {
\$topBtn.fadeIn();
} else {
\$topBtn.fadeOut();
}
});
//スクロール後
\$topBtn.click(function () {
\$('body,html').animate({
scrollTop: 0
}, 500);
return false;
});
});
\$(function () {
var \$contents_wrapper = \$('div#contents_wrapper').first();
var \$cartinBtn = \$('#btm-cartin-btn').appendTo(\$contents_wrapper);
});
function zoom_dynamic(\$element) {
return \$element.each(function(i) {
var \$this = \$(this);
var width = parseInt(\$this.width());
var height = parseInt(\$this.height());
if (width > 805) {
if (navigator.userAgent.indexOf('Chrome') !== -1 || navigator.userAgent.indexOf('Safari') !== -1) {
// zoom 対応ブラウザ(Chrome、Safari)
\$this.css({ \"zoom\": \"calc( 805 / #width )\".replace(\"#width\", width), \"visibility\": \"visible\" });
} else {
// zoom 未対応ブラウザ(Firefox、IE、Opera、etc...)
var ratio = parseFloat( ( 805 / width ).toFixed(20) );
var margin_ratio = ratio - 1;
var margin_bottom = height * margin_ratio;
\$this.css({
\"transform-origin\": \"0 0\",
\"transform\": \"scale(#ratio)\".replace(/#ratio/g, ratio),
\"margin-bottom\": margin_bottom,
\"visibility\": \"visible\"
});
}
}
});
}
(function() {
\$('.kuru2').closest('.top_sashikomi_wrapper').width(990);
var \$sashikomi = \$('.top_sashikomi_wrapper').each(function(i) {
var \$sashikomi = \$(this);
\$('img', this).on('load', function(e) {
zoom_dynamic(\$sashikomi); // (2/3) 各、差込内の画像ロード完了直後
}).each(function(i) {
if(this.complete || /*for IE 10-*/ \$(this).height() > 0)
\$(this).load();
});
});
\$(function() {
zoom_dynamic(\$sashikomi).css({ \"visibility\": \"visible\" }); // (1/3) DOM読込み完了直後
\$(window).on('load', function(e) {
zoom_dynamic(\$sashikomi); // (3/3) 全script実行完了直後
});
});
}());
</script>
{% if useCache is defined and useCache == true %}
<script type=\"text/javascript\">
/*
*日付の差分日数を返却します。
*/
function getDiff(date1Str, date2Str) {
var date1 = new Date(date1Str);
var date2 = new Date(date2Str);
// getTimeメソッドで経過ミリ秒を取得し、2つの日付の差を求める
var msDiff = date2.getTime() - date1.getTime();
// 求めた差分(ミリ秒)を日付へ変換します(経過ミリ秒÷(1000ミリ秒×60秒×60分×24時間)。端数切り捨て)
var daysDiff = Math.floor(msDiff / (1000 * 60 * 60 *24));
return daysDiff;
}
</script>
<script type=\"text/javascript\" async>
\$(function(){
\$.fbt('queryAll');
});
</script>
{% endif %}
{% endblock %}
{% block lm_after_contents_top %}
<div class=\"clearfix\">{% include 'Page/Parts/fixed-header.twig' with { category: goods.getMainCategory } only %}</div>
{% endblock %}
{% block main %}
<div id=\"pagetop\">
<a href=\"#header\">
<img width=\"100px\" height=\"80px\" src=\"/images/top/top-jump-btn.jpg\" alt=\"ページTOPへ\">
</a>
</div>
<div id=\"btm-cartin-btn\">
<img width=\"220px\" height=\"50px\" src=\"/images/top/buy-jump-btn.jpg\" alt=\"購入ボタンへ\">
</div>
{% endblock %}
", "Item/detail.twig", "/var/www/html/app/template/default/Item/detail.twig");
}
public function checkSecurity()
{
static $tags = array("set" => 13, "if" => 130, "include" => 160);
static $filters = array();
static $functions = array();
try {
$this->sandbox->checkSecurity(
['set', 'if', 'include'],
[],
[]
);
} catch (SecurityError $e) {
$e->setSourceContext($this->source);
if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
$e->setTemplateLine($tags[$e->getTagName()]);
} elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
$e->setTemplateLine($filters[$e->getFilterName()]);
} elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
$e->setTemplateLine($functions[$e->getFunctionName()]);
}
throw $e;
}
}
}