app/template/uarts/Product/detail.twig line 1

Open in your IDE?
  1. {% extends 'default_frame.twig' %}
  2. {% set body_id = 'product_page' %}
  3. {% block stylesheet %}
  4. <link rel="stylesheet" href="//unpkg.com/scroll-hint@1.1.10/css/scroll-hint.css">
  5. <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick-theme.min.css">
  6. <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.min.css">
  7. <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luminous-lightbox@2.4.0/dist/luminous-basic.min.css" />
  8. <style>
  9.     .item_detail_icon {
  10.         display: inline-block;
  11.         margin-bottom: 10px;
  12.         margin-right: 10px;
  13.     }f
  14.     .item_detail .item_detail_img .subimg .thumbnail {
  15.         cursor: pointer;
  16.     }
  17.     .item_detail .item_detail_img .mainimg,
  18.     .item_detail .item_detail_img .subimg {
  19.         display: none;
  20.     }
  21.     .item_detail .item_detail_img .mainimg.slick-initialized,
  22.     .item_detail .item_detail_img .subimg.slick-initialized {
  23.         display: block;
  24.     }
  25.     .item_detail2 .table_dl dl{
  26.         margin-right: -1px;
  27.     }
  28. </style>
  29. {% endblock %}
  30. {% block javascript %}
  31. <script src="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.min.js"></script>
  32. <script src="//cdn.jsdelivr.net/npm/luminous-lightbox@2.4.0/dist/luminous.min.js"></script>
  33. <script src="//unpkg.com/scroll-hint@1.1.10/js/scroll-hint.js"></script>
  34. <script>
  35.     eccube.classCategories = {{ class_categories_as_json(Product) | raw }};
  36.     // 規格2に選択肢を割り当てる。
  37.     function fnSetClassCategories(form, classcat_id2_selected) {
  38.         var $form = $(form);
  39.         var product_id = $form.find('input[name=product_id]').val();
  40.         var $sele1 = $form.find('select[name=classcategory_id1]');
  41.         var $sele2 = $form.find('select[name=classcategory_id2]');
  42.         eccube.setClassCategories($form, product_id, $sele1, $sele2, classcat_id2_selected);
  43.     }
  44.     {% if form.classcategory_id2 is defined %}
  45.     fnSetClassCategories(
  46.         $('#form1'), {{ form.classcategory_id2.vars.value | json_encode | raw }}
  47.     );
  48.     {% elseif form.classcategory_id1 is defined %}
  49.     eccube.checkStock($('#form1'), {{ Product.id }}, {{ form.classcategory_id1.vars.value | json_encode | raw }}, null);
  50.     {% endif %}
  51. </script>
  52. <script>
  53.     $(function () {
  54.         $('.add-cart').on('click', function (event) {
  55.             {% if form.classcategory_id1 is defined %}
  56.             // 規格1フォームの必須チェック
  57.             if ($('#classcategory_id1').val() == '__unselected' || $('#classcategory_id1').val() == '') {
  58.                 $('#classcategory_id1')[0].setCustomValidity('{{ '項目が選択されていません'|trans }}');
  59.                 return true;
  60.             } else {
  61.                 $('#classcategory_id1')[0].setCustomValidity('');
  62.             }
  63.             {% endif %}
  64.             {% if form.classcategory_id2 is defined %}
  65.             // 規格2フォームの必須チェック
  66.             if ($('#classcategory_id2').val() == '__unselected' || $('#classcategory_id2').val() == '') {
  67.                 $('#classcategory_id2')[0].setCustomValidity('{{ '項目が選択されていません'|trans }}');
  68.                 return true;
  69.             } else {
  70.                 $('#classcategory_id2')[0].setCustomValidity('');
  71.             }
  72.             {% endif %}
  73.             // 個数フォームのチェック
  74.             if ($('#quantity').val() < 1) {
  75.                 $('#quantity')[0].setCustomValidity('{{ '1以上で入力してください。'|trans }}');
  76.                 return true;
  77.             } else {
  78.                 $('#quantity')[0].setCustomValidity('');
  79.             }
  80.             event.preventDefault();
  81.             $form = $('#form1');
  82.             $.ajax({
  83.                 url: $form.attr('action'),
  84.                 type: $form.attr('method'),
  85.                 data: $form.serialize(),
  86.                 dataType: 'json',
  87.                 beforeSend: function (xhr, settings) {
  88.                     // Buttonを無効にする
  89.                     $('.add-cart').prop('disabled', true);
  90.                 }
  91.             }).done(function (data) {
  92.                 // レスポンス内のメッセージをalertで表示
  93.     
  94.                 $.each(data.messages, function () {
  95.                     $('#ec-modal-header').html(this.replace(/[\n\r]/g, "<br />"));
  96.                 });
  97.                 if(data.done){
  98.                     $(".ec-modal .ec-inlineBtn--action").show();
  99.                 }else{
  100.                     // 成功していなかったら非表示
  101.                     $(".ec-modal .ec-inlineBtn--action").hide();
  102.                 }
  103.                 
  104.                 $('.ec-modal').show()
  105.                 // カートブロックを更新する
  106.                 $.ajax({
  107.                     url: "{{ url('block_cart') }}",
  108.                     type: 'GET',
  109.                     dataType: 'html'
  110.                 }).done(function (html) {
  111.                     $('.ec-headerRole__cart').html(html);
  112.                 });
  113.             }).fail(function (data) {
  114.                 alert('{{ 'カートへの追加に失敗しました。'|trans }}');
  115.             }).always(function (data) {
  116.                 // Buttonを有効にする
  117.                 $('.add-cart').prop('disabled', false);
  118.             });
  119.         });
  120.     });
  121.     $('.ec-modal-wrap').on('click', function (e) {
  122.         // モーダル内の処理は外側にバブリングさせない
  123.         e.stopPropagation();
  124.     });
  125.     $('.ec-modal-overlay, .ec-modal, .ec-modal-close, .ec-inlineBtn--cancel').on('click', function () {
  126.         $('.ec-modal').hide()
  127.     });
  128.     $('.item_detail .item_detail_info .goods_memo').each(function () {
  129.         if ($.trim($(this).text()) == '') {
  130.             $(this).css('display', 'none');
  131.         }
  132.     });
  133. </script>
  134. <script type="application/ld+json">
  135.     {
  136.         "@context": "https://schema.org/",
  137.         "@type": "Product",
  138.         "name": "{{ Product.name }}",
  139.         "image": [
  140.             {% for img in Product.ProductImage %}
  141.                 "{{ app.request.schemeAndHttpHost }}{{ asset(img, 'save_image') }}"{% if not loop.last %},{% endif %}
  142.             {% else %}
  143.                 "{{ app.request.schemeAndHttpHost }}{{ asset(''|no_image_product, 'save_image') }}"
  144.             {% endfor %}
  145.         ],
  146.         "description": "{{ Product.description_list | default(Product.description_detail) | replace({'\n': '', '\r': ''}) | slice(0,300) }}",
  147.         {% if Product.code_min %}
  148.         "sku": "{{ Product.code_min }}",
  149.         {% endif %}
  150.         "offers": {
  151.             "@type": "Offer",
  152.             "url": "{{ url('product_detail', {'id': Product.id}) }}",
  153.             "priceCurrency": "{{ eccube_config.currency }}",
  154.             "price": {{ Product.getPrice02IncTaxMin ? Product.getPrice02IncTaxMin : 0}},
  155.             "availability": "{{ Product.stock_find ? "InStock" : "OutOfStock" }}"
  156.         }
  157.     }
  158.     </script>
  159. {% endblock %}
  160. {% block sub_area %}
  161.     {% if Product.ProductCategories is not empty %}
  162.     {% set displayed_category_ids = [] %}
  163.     <ul class="pankuzu">
  164.         <li><a href="{{ url('homepage') }}">トップ</a></li>
  165.         {% set exclude_ids = [32, 31, 30] %} 
  166.     {% for ProductCategory in Product.ProductCategories %}
  167.    
  168.     {# {% if loop.last %}
  169.     <ul class="pankuzu">
  170.         <li><a href="{{ url('homepage') }}">トップ</a></li>
  171.         {% for Category in ProductCategory.Category.path %}
  172.         <li>
  173.             <a href="{{ url('product_list') }}?category_id={{ Category.id }}">{{ Category.name}}</a>
  174.         </li>
  175.         {% endfor %}
  176.         <li>
  177.             <a href="{{ url('product_detail', {'id': Product.id}) }}">{{ Product.name }}</a>
  178.         </li>
  179.     </ul>
  180.     {% endif %} #}
  181.     
  182.         {% for Category in ProductCategory.Category.path %}
  183.         {% if Category.id not in exclude_ids %}
  184.         {% if Category.id not in displayed_category_ids %}
  185.         <li>
  186.             <a href="{{ url('product_list') }}?category_id={{ Category.id }}">{{ Category.name}}</a>
  187.         </li>
  188.         {% set displayed_category_ids = displayed_category_ids|merge([Category.id]) %}
  189.         {% endif %}
  190.         {% endif %}
  191.         {% endfor %}
  192.     {% endfor %}
  193. </ul>
  194.     {% else %}
  195.     <ul class="pankuzu">
  196.         <li><a href="{{ url('homepage') }}">トップ</a></li>
  197.         <li><a href="{{ url('product_list') }}">商品一覧</a></li>
  198.         <li><a href="{{ url('product_detail', {'id': Product.id}) }}">{{ Product.name }}</a></li>
  199.     </ul>
  200. {% endif %}
  201. {% endblock %}
  202. {% block main %}
  203. {% set country = getProduct_field(Product.id,"country") %}
  204. {# {% set frame_width = getProduct_field(Product.id,"frame_width") %}
  205. {% set frame_thickness = getProduct_field(Product.id,"frame_thickness") %} #}
  206. {% set delivery = getProduct_field(Product.id,"delivery") %}
  207. {% set add_txt1 = getProduct_field(Product.id,"add_txt1") %}
  208. {% set add_txt2 = getProduct_field(Product.id,"add_txt2") %}
  209. {% set add_txt3 = getProduct_field(Product.id,"add_txt3") %}
  210. <div class="item_detail">
  211.     <div class="item_detail_img">
  212.         <div class="mainimg">
  213.             {% for ProductImage in Product.ProductImage %}
  214.             <div class="slide_img">
  215.                 <a href="{{ asset(ProductImage, 'save_image') }}" class="luminous">
  216.                     <img src="{{ asset(ProductImage, 'save_image') }}" alt="">
  217.                 </a>
  218.             </div>
  219.             {% else %}
  220.             <div class="slide_img">
  221.                 <a href="{{ asset(''|no_image_product, 'save_image') }}" class="luminous">
  222.                     <img src="{{ asset(''|no_image_product, 'save_image') }}" alt="">
  223.                 </a>
  224.             </div>
  225.             {% endfor %}
  226.         </div>
  227.         <div class="flex between">
  228.             <span href="#" class="click_txt">クリックで拡大</span>
  229.             <span class="txt_red">※製造時期の違いから、色合い等に若干差異が生じる場合がございます。</span>
  230.         </div>
  231.         <div class="subimg">
  232.             {% for ProductImage in Product.ProductImage %}
  233.             <div class="thumbnail"><img src="{{ asset(ProductImage, 'save_image') }}" alt=""></div>
  234.             {% else %}
  235.             <div class="thumbnail"><img src="{{ asset(''|no_image_product, 'save_image') }}" alt=""></div>
  236.             {% endfor %}
  237.         </div>
  238.         <p class="frame_block_ttl">
  239.             フレームサイズのイメージ
  240.         </p>
  241.         <div class="frame_block_wrap">
  242.             <div id="frame_block"></div>
  243.         </div>
  244.     </div>
  245.     <div class="item_detail_info">
  246.         <ul class="item_detail_icon_list">
  247.             {% for Tag in Product.Tags %}
  248.             <li class="item_detail_icon tag_{{ Tag.id }}">{{ Tag }}</li>
  249.             {% endfor %}
  250.         </ul>
  251.         <p class="goods_info product">品番:<span>{{ Product.name }}</span></p>
  252.         {# 通常価格 #}
  253.         {% if Product.hasProductClass -%}
  254.         {% if Product.getPrice01Min is not null and Product.getPrice01IncTaxMin ==
  255.         Product.getPrice01IncTaxMax %}
  256.         <div class="goods_info price">
  257.             通常価格:<span class="txt_pink">{{ Product.getPrice01IncTaxMin|number_format() }}<span
  258.                     class="unit">円</span></span>
  259.         </div>
  260.         {% elseif Product.getPrice01Min is not null and Product.getPrice01Max is not null %}
  261.         <div class="goods_info price">
  262.             通常価格:<span class="txt_pink">{{ Product.getPrice01IncTaxMin|number_format() }}~{{
  263.                 Product.getPrice01IncTaxMin|number_format() }}<span class="unit">円</span></span>
  264.         </div>
  265.         {% endif %}
  266.         {% else %}
  267.         {% if Product.getPrice01Max is not null %}
  268.         <div class="goods_info price">
  269.             通常価格:<span class="txt_pink">{{ Product.getPrice01IncTaxMin|number_format() }}<span
  270.                     class="unit">円</span></span>
  271.         </div>
  272.         {% endif %}
  273.         {% endif %}
  274.         {% set minPrice = CustomProductFindWhere(Product,"min_price") %}
  275.         {% set maxPrice = CustomProductFindWhere(Product,"max_price") %}
  276.         {% set maxTotal = CustomProductFindWhere(Product,"max_total") %}
  277.         {% set minTotal = CustomProductFindWhere(Product,"min_total") %}
  278.         {% if minPrice != maxPrice and maxPrice is not null %}
  279.         <div class="goods_info price">
  280.             価格帯:<span class="txt_pink">{{ minPrice|number_format() }}~{{ maxPrice|number_format()
  281.                 }}<span class="unit">円</span></span>
  282.         </div>
  283.         {% elseif minPrice is not null %}
  284.         <div class="goods_info price">
  285.             価格帯:<span class="txt_pink">{{ minPrice|number_format() }}<span class="unit">円</span></span>
  286.         </div>
  287.         {% elseif maxPrice is not null %}
  288.         <div class="goods_info price">
  289.             価格帯:<span class="txt_pink">{{ maxPrice|number_format() }}<span class="unit">円</span></span>
  290.         </div>
  291.         {% else %}
  292.         {# 通常 #}
  293.         <div class="ec-productRole__price">
  294.             {% if Product.hasProductClass -%}
  295.             {% if Product.getPrice02IncTaxMin == Product.getPrice02IncTaxMax %}
  296.             <div class="goods_info price">
  297.                 価格帯:<span class="txt_pink">{{ Product.getPrice02IncTaxMin|number_format() }}<span
  298.                         class="unit">円</span></span>
  299.             </div>
  300.             {% else %}
  301.             <div class="goods_info price">
  302.                 価格帯:<span class="txt_pink">{{ Product.getPrice02IncTaxMin|number_format() }} ~ {{
  303.                     Product.getPrice02IncTaxMax|number_format() }}<span class="unit">円</span></span>
  304.             </div>
  305.             {% endif %}
  306.             {% else %}
  307.             <div class="goods_info price">
  308.                 価格帯:<span class="txt_pink">{{ Product.getPrice02IncTaxMin|number_format() }}<span
  309.                         class="unit">円</span></span>
  310.             </div>
  311.             {% endif %}
  312.         </div>
  313.         {% endif %}
  314.         <div class="ec-productRole__description">{{ Product.description_detail|raw|nl2br }}
  315.         </div>
  316.         {# {% if Product.ProductClasses.first().DeliveryDuration is not null %}
  317.         <p class="goods_info delivery">お届けまでの日数:<span>{{ Product.ProductClasses.first().DeliveryDuration }}営業日</span>
  318.         </p>
  319.         {% endif %} #}
  320.         {% if delivery %}
  321.         <p class="goods_info delivery">お届けまでの日数:<span>{{ delivery }}</span>
  322.         </p>
  323.         {% endif %}
  324.         <div class="goods_memo">
  325.             <div>
  326.                 {% if Product.getCalcMinLength is not null and Product.getCalcMaxLength is not null %}
  327.                 一辺の長さ:{{ Product.getCalcMinLength|number_format() }} ~ {{
  328.                 Product.getCalcMaxLength|number_format() }}mm
  329.                 {% elseif Product.getCalcMinLength is not null %}
  330.                 一辺の長さ:{{ Product.getCalcMinLength|number_format() }}mm
  331.                 {% elseif Product.getCalcMaxLength is not null %}
  332.                 一辺の長さ:{{ Product.getCalcMaxLength|number_format() }}mm
  333.                 {% endif %}
  334.             </div>
  335.             <div class="txt_red">※自動計算で表示される一般的なサイズのため、実際に購入できるサイズは「ヨコ・タテ合計」サイズを参照ください。</div>
  336.             <div>フレーム幅:{{ Product.minlength|number_format() }}mm</div>
  337.             
  338.             <div>
  339.                 {% if minTotal is not null and maxTotal is not null %}
  340.                 {% if minTotal == maxTotal %}
  341.                 ヨコ・タテ合計:{{ maxTotal|number_format() }}mmまで製作可能
  342.                 {% else %}
  343.                 ヨコ・タテ合計:{# {{ minTotal|number_format() }}~ #}{{ maxTotal|number_format() }}mmまで製作可能
  344.                 {% endif %}
  345.                 {% elseif minTotal is not null %}
  346.                 <!-- ヨコ・タテ合計:{{ minTotal|number_format() }}mmまで製作可能 -->
  347.                 {% elseif maxTotal is not null %}
  348.                 ヨコ・タテ合計:{{ maxTotal|number_format() }}mmまで製作可能
  349.                 {% endif %}
  350.             </div>
  351.             
  352.         </div>
  353.         <form action="{{ url('product_add_cart', {id:Product.id}) }}" method="post" id="form1" name="form1">
  354.             {% if Product.stock_find %}
  355.             <div class="ec-productRole__actions">
  356.                 {% if form.classcategory_id1 is defined %}
  357.                 <div class="ec-select">
  358.                     {{ form_row(form.classcategory_id1) }}
  359.                     {{ form_errors(form.classcategory_id1) }}
  360.                 </div>
  361.                 {% if form.classcategory_id2 is defined %}
  362.                 <div class="ec-select">
  363.                     {{ form_row(form.classcategory_id2) }}
  364.                     {{ form_errors(form.classcategory_id2) }}
  365.                 </div>
  366.                 {% endif %}
  367.                 {% endif %}
  368.             </div>
  369.             {% if Product.CustomProductPrice is not empty %}
  370.             <ul class="goods_size mb20">
  371.                 <li><label class="labeltxt">ヨコ幅</label>{{ form_widget(form.custom_width, {'attr': {'class': 'inputBox'
  372.                     }}) }}mm
  373.                 </li>
  374.                 <li><label class="labeltxt">タテ長</label>{{ form_widget(form.custom_height, {'attr': {'class': 'inputBox'
  375.                     }}) }}mm
  376.                 </li>
  377.             </ul>
  378.             <div class="goods_option_block">
  379.                 <p class="goods_option">オプション</p>
  380.                 <p class="txt_right mb10">オプションについて詳しくは<a href="{{ url('user_data', {'route': 'setting'}) }}">こちら</a></p>
  381.     
  382.                 <label class="labeltxt">面取り加工</label>
  383.                 {{ form_widget(form.custom_chamfer, {'attr': {'class': 'selectBox mb10' }}) }}
  384.     
  385.     
  386.                 <label class="labeltxt">取付金具</label>
  387.                 {{ form_widget(form.custom_mounting, {'attr': {'class': 'selectBox mb10' }}) }}
  388.     
  389.                 {# <label class="labeltxt">吊り金具・ヒモ(無料)</label>
  390.                 {{ form_widget(form.custom_hanging, {'attr': {'class': 'selectBox mb10' }}) }}
  391.     
  392.                 <label class="labeltxt" for="">ゴム足(無料)</label>
  393.                 {{ form_widget(form.custom_rubber, {'attr': {'class': 'selectBox mb20' }}) }} #}
  394.     
  395.                 <p class="">吊り金具・ヒモとゴム足は無料で同梱されています。</p>
  396.             </div>
  397.             
  398.             {% endif %}
  399.             <div class="goods_number">
  400.                 <div class="flex mb10">数量
  401.                     {{ form_widget(form.quantity, {'attr': {'class': 'inputBox short_box' }}) }}
  402.                 </div>
  403.                 <div class="goods_info purchase" id="add_price">
  404.                 </div>
  405.             </div>
  406.             {{ form_errors(form.quantity) }}
  407.             {% else %}
  408.             <div class="goods_btn">
  409.                 <button class="action_btn btn no_arrow icon_cart" type="button"
  410.                     style="opacity: 0.6; pointer-events:none;"><span>{{ 'front.product.out_of_stock'|trans
  411.                         }}</span></button>
  412.             </div>
  413.             {% endif %}
  414.             <div class="goods_btn">
  415.                 {# <button type="submit" class="action_btn btn no_arrow icon_cart">
  416.                     <span>カートに入れる</span>
  417.                 </button> #}
  418.                 <button type="submit" class="action_btn btn no_arrow icon_cart add-cart">
  419.                     <span>カートに入れる</span>
  420.                 </button>
  421.                 
  422.                 <a class="white_btn btn no_arrow"
  423.                     href="{{ url('free_sample_add_sample', {'id': Product.id}) }}">無料サンプルのご請求</a>
  424.             </div>
  425.             {{ form_rest(form) }}
  426.         </form>
  427.         {# モーダルここから #}
  428.         <div class="ec-modal">
  429.             <div class="ec-modal-overlay">
  430.                 <div class="ec-modal-wrap">
  431.                     <span class="ec-modal-close"><span class="ec-icon"><img
  432.                                 src="{{ asset('assets/icon/cross-dark.svg') }}" alt="" /></span></span>
  433.                     <div id="ec-modal-header" class="text-center">{{ 'front.product.add_cart_complete'|trans }}
  434.                     </div>
  435.                     <div class="ec-modal-box">
  436.                         <div class="ec-role">
  437.                             <span class="ec-inlineBtn--cancel">{{ 'front.product.continue'|trans }}</span>
  438.                             <a href="{{ url('cart') }}" class="ec-inlineBtn--action">{{
  439.                                 'common.go_to_cart'|trans }}</a>
  440.                         </div>
  441.                     </div>
  442.                 </div>
  443.             </div>
  444.         </div>
  445.         {# モーダルここまで #}
  446.     </div>
  447. </div>
  448. {% if Product.freearea %}
  449. <div class="ec-productRole__description">
  450.     {{ include(template_from_string(Product.freearea), sandboxed = true) }}
  451. </div>
  452. {% endif %}
  453. <div class="item_detail2">
  454.     <ul class="tab-list">
  455.         <li class="tab-list-item active">商品について</li>
  456.         <li class="tab-list-item">価格について</li>
  457.         <li class="tab-list-item">価格表</li>
  458.     </ul>
  459.     <div class="tab-contents">
  460.         <div class="tab-contents-item active">
  461.             <table class="table_style">
  462.                 {% if country %}
  463.                 <tr>
  464.                     <th>原産国</th>
  465.                     <td>{{country}}</td>
  466.                 </tr>
  467.                 {% endif %}
  468.                 {% if Product.getMinLength %}
  469.                 <tr>
  470.                     <th>フレーム幅</th>
  471.                     <td>{{ Product.getMinLength|number_format()}}mm</td>
  472.                 </tr>
  473.                 {% endif %}
  474.                 {% if Product.getMaxLength %}
  475.                 <tr>
  476.                     <th>フレーム厚み</th>
  477.                     <td>{{Product.getMaxLength|number_format()}}mm</td>
  478.                 </tr>
  479.                 {% endif %}
  480.                 {% if maxTotal is not null %}
  481.                 <tr>
  482.                     <th>ヨコ・タテ合計</th>
  483.                     <td>{{maxTotal|number_format()}}mmまで</td>
  484.                 </tr>
  485.                 {% endif %}
  486.                 {% if delivery %}
  487.                 <tr>
  488.                     <th>お届けまでの日数</th>
  489.                     <td>{{delivery}}</td>
  490.                 </tr>
  491.                 {% endif %}
  492.             </table>
  493.             {% if add_txt1 %}
  494.             {{add_txt1|raw}}
  495.             {% endif %}
  496.             <h3 class="border_ttl mt60 txt_left">フレームの幅と厚み</h3>
  497.             <ul class="flame_block">
  498.                 <li>
  499.                   <figure><img src="{{ asset('assets/img/item/itempage_flameimg01.jpg') }}" alt="フレーム幅"></figure>
  500.                   <h4 class="rhombus_ttl">フレーム幅</h4>
  501.                   <p>画像の矢印部分をフレーム幅といいます。鏡を壁面に掛けた際、正面から見える縁の部分です。</p>
  502.                 </li>
  503.                 <li>
  504.                   <figure><img src="{{ asset('assets/img/item/itempage_flameimg02.jpg') }}" alt="フレー厚み"></figure>
  505.                   <h4 class="rhombus_ttl">フレーム厚み</h4>
  506.                   <p>画像の矢印部分をフレーム厚みといいます。側面から見えるフレームの厚みです。</p>
  507.                 </li>
  508.              </ul>
  509.             <h3 class="border_ttl mt60 txt_left">付属品(無料)</h3>
  510.             <h4 class="rhombus_ttl">吊り金具・ヒモ</h4>
  511.             <dl class="imgtxt mb20">
  512.                 <dt><img src="{{ asset('assets/img/item/itempage_img01_1.jpg') }}" alt=""></dt>
  513.                 <dd>
  514.                     <ul class="asterisk txt_red f16">
  515.                         <li>付属する吊り金具は鏡の大きさとフレーム幅によって形状が異なります。</li>
  516.                         <li>ヨコ・タテ合計が1800mm以上の場合は壁に立て掛け時の転倒防止用にご使用ください。</li>
  517.                         <!--<li>ハングマンを選択された場合は、不要なので同梱・取り付けされません。</li>-->
  518.                     </ul>
  519.                 </dd>
  520.             </dl>
  521.             <h4 class="rhombus_ttl">ゴム足</h4>
  522.             <dl class="imgtxt mb20">
  523.                 <dt><img src="{{ asset('assets/img/item/itempage_img01_2.jpg') }}" alt=""></dt>
  524.                 <dd>
  525.                     <ul class="asterisk txt_red f16">
  526.                         <li>ゴム足は鏡を壁に立てかける場合にご使用できます。</li>
  527.                         <li>フレームの形状によっては取り付けできない場合があります。</li>
  528.                         <!--<li>剛力フック・ハングマンを選択された場合は、不要なので同梱・取り付けされません。</li>-->
  529.                     </ul>
  530.                 </dd>
  531.             </dl>
  532.             <h3 class="border_ttl mt60 txt_left">鏡の取り付け方と取付金具の種類</h3>
  533.             <div class="table_dl">
  534.                 <dl>
  535.                     <dt>剛力フック</dt>
  536.                     <dd>
  537.                         <img src="{{ asset('assets/img/item/itempage_img02_1.jpg') }}" alt="">
  538.                         <p>鏡の裏にヒモをつけて剛力フックで壁に掛ける方法</p>
  539.                         <ul class="asterisk f16">
  540.                             <li>剛力フックの詳細は<a href="/user_data/setting#howto01">こちら</a></li>
  541.                         </ul>
  542.                     </dd>
  543.                 </dl>
  544.                 <dl>
  545.                     <dt>ハングマン</dt>
  546.                     <dd>
  547.                         <img src="{{ asset('assets/img/item/itempage_img02_2.jpg') }}" alt="">
  548.                         <p>ハングマンで壁にしっかり掛ける方法</p>
  549.                         <ul class="asterisk f16">
  550.                             <li>ハングマンの詳細は<a href="/user_data/setting#howto02">こちら</a></li>
  551.                         </ul>
  552.                     </dd>
  553.                 </dl>
  554.                 <!--<dl>
  555.                     <dt>ゴム足 / 吊り金具・ヒモ</dt>
  556.                     <dd>
  557.                         <img src="{{ asset('assets/img/item/itempage_img02_3.jpg') }}" alt="">
  558.                         <p>ゴム足をフレーム下側に取り付けて壁に立てかける方法。ゴム足・鏡の裏に取り付ける吊り金具・強化ヒモ
  559.                             はご希望であれば、無料で同送いたします。</p>
  560.                     </dd>
  561.                 </dl>-->
  562.             </div>
  563.             <a href="{{ url('user_data', {'route': 'setting'}) }}"
  564.                 class="btn item_detail2_btn no_arrow">鏡の取り付け方についてはこちら</a>
  565.         </div>
  566.         <div class="tab-contents-item">
  567.             <dl class="imgtxt mb20 w320">
  568.                 <dt><img src="{{ asset('assets/img/item/itempage_img03.png') }}" alt=""></dt>
  569.                 <dd>
  570.                     <p>タテとヨコの長さ(mm)を足した合計で価格が決定します。
  571.                     </p>
  572.                     <ul class="circle">
  573.                         <li>例えば、タテが450mm、ヨコが230mmのサイズでは、タテとヨコの合計が680mmなので700mmの価格帯になります。
  574.                             価格帯700mmは、タテとヨコの合計が601mm~700mmまでの鏡に適用されます。<br>
  575.                             タテとヨコの合計が701mmになると、次の価格帯800mmが適用されます。
  576.                         </li>
  577.                         <li>価格帯はタテとヨコの合計サイズが2000mmまでは100mmごとに、2000mm以降は200mmごとに変わります。
  578.                         </li>
  579.                         <li>価格帯のついての詳細は価格表をご参照ください。</li>
  580.                     </ul>
  581.                     <h3 class="border_ttl mt50 txt_left">面取り加工について</h3>
  582.                     <p>価格表には、「面取り加工あり」と「面取り加工なし」の2種類を表記しています。<br>
  583.                         面取り加工の説明は<a href="#">こちら</a>をご覧ください。</p>
  584.                     <h3 class="border_ttl mt50 txt_left">サイズの入力条件</h3>
  585.                     <p>一辺の長さ:152~1882mm<br>
  586.                         合計サイズ:304~2600mm</p>
  587.                 </dd>
  588.             </dl>
  589.             <h3 class="border_ttl mt60 txt_left">製作限界サイズについて</h3>
  590.             <p class="mb10">商品を製作する際、そのフレーム幅や厚みに対して鏡のサイズが大き過ぎると鏡の重さにフレームが持ちこたえられず、フレームが破損する可能性がございます。
  591.                 従いまして、製作可能サイズ内であっても、フレームの種類によっては、下記の理由により製作できない場合があります。</p>
  592.             <ul class="circle mb10">
  593.                 <li>フレームの幅と厚みが製作サイズに対して充分でない</li>
  594.                 <li>フレームの使用木材が柔らかい木の種類である</li>
  595.                 <li>ヨコとタテの比率の差が極端にある</li>
  596.             </ul>
  597.             <p>また、各商品の価格表で「製作不可または別途お見積もり」と表記しているのは、特に割高になるなどの理由からではなく、前述のようなフレームの強度不足になる可能性があるということから、あえて価格を記載していません。<br>
  598.                 その都度、サイズをお聞きして製作可能か弊社で判断し、お客様にお伝えしております。</p>
  599.             {% if add_txt2 %}
  600.             {{add_txt2|raw}}
  601.             {% endif %}
  602.         </div>
  603.       
  604.         <div class="tab-contents-item">
  605.             {% if  Product.CustomProductPrice is not null and  Product.CustomProductPrice.CustomPriceConfig.CustomPrices is not null %}
  606.             <div class="js-scrollable">
  607.                 <table class="table_style_item" id="table_prices">
  608.                     <thead>
  609.                         <tr>
  610.                             <th>価格帯</th>
  611.                             <th class="pink">面取り加工なし</th>
  612.                             <th class="pink">面取り加工あり</th>
  613.                             <th>価格帯</th>
  614.                             <th class="pink">面取り加工なし</th>
  615.                             <th class="pink">面取り加工あり</th>
  616.                         </tr>
  617.                     </thead>
  618.                     <tbody>
  619.                         {% for CustomProductPrice in Product.CustomProductPrice.CustomPriceConfig.CustomPrices %}
  620.                         {% if CustomProductPrice.id in Product.CustomProductPrice.Prices %}
  621.                         {% set total = ChamferTotal(CustomProductPrice.total,2) %}
  622.                     
  623.                         {% set total_tax = CustomPriceTax(CustomProductPrice.price,Product) %}
  624.                      
  625.                         <tr>
  626.                             <th>{{ CustomProductPrice.total|number_format() }}mm</th>
  627.                             <td>{{ total_tax|number_format() }}円</td>
  628.                             {% if total %}
  629.                             {% set option_total_tax = CustomPriceTax(CustomProductPrice.price + total.price,Product) %}
  630.                             <td>{{ (option_total_tax)|number_format()}}円
  631.                             </td>
  632.                             {% else %}
  633.                             <td>-</td>
  634.                             {% endif %}
  635.                         </tr>
  636.                         {% endif %}
  637.                         {% endfor %}
  638.                         <tr class="last">
  639.                             <th>以上</th>
  640.                             <td colspan="2">製作不可または別途お見積もり</td>
  641.                         </tr>
  642.                     </tbody>
  643.                 </table>
  644.             </div>
  645.             
  646.             {% endif %}
  647.             {% if add_txt3 %}
  648.             {{add_txt3|raw}}
  649.             {% endif %}
  650.         </div>
  651.     </div>
  652. </div>
  653. <script>
  654.     $(function(){
  655.         var $rows = $('#table_prices tbody tr');
  656.         // 2つの行ごとにループ処理
  657.         for (var i = 0; i < $rows.length; i += 2) {
  658.             // 現在の行と次の行の内容を取得
  659.             var $current = $($rows[i]);
  660.             var $next = $($rows[i + 1]);
  661.     
  662.             // 次の行が存在する場合、内容を結合
  663.             if ($next.length) {
  664.                 // 新しい行を作成
  665.                 var $newRow = $('<tr></tr>');
  666.     
  667.             
  668.                 // 現在の行と次の行の<th>と<td>を新しい行に追加
  669.                 $newRow.append($current.html());
  670.                 $newRow.append($next.html());
  671.                 $current.replaceWith($newRow);
  672.                 // 新しい行を現在の行の位置に挿入し、元の2行を削除
  673.                 $next.remove();
  674.             }
  675.         }
  676.         if(!$('#table_prices').prev("td").length){
  677.             $('#table_prices .last td').attr("colspan",5);
  678.         }
  679.     });
  680. </script>
  681. {% endblock %}