app/template/default/Mypage/history.twig line 1

Open in your IDE?
  1. {#
  2. This file is part of EC-CUBE
  3. Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
  4. http://www.ec-cube.co.jp/
  5. For the full copyright and license information, please view the LICENSE
  6. file that was distributed with this source code.
  7. #}
  8. {% extends 'default_frame.twig' %}
  9. {% set mypageno = 'index' %}
  10. {% set body_class = 'mypage' %}
  11. {% block main %}
  12.     <div class="ec-layoutRole__main">
  13.         <div class="ec-mypageRole">
  14.             <div class="ec-pageHeader">
  15.                 <h1>{{ 'マイページ'|trans }}/{{ 'ご注文履歴詳細'|trans }}</h1>
  16.             </div>
  17.             {% include 'Mypage/navi.twig' %}
  18.         </div>
  19.         {% set remessage = false %}
  20.         {% set IsFirstShipment = false %}
  21.         <div class="ec-orderRole">
  22.             <div class="ec-orderRole__detail">
  23.                 <div class="ec-orderOrder">
  24.                     <div class="ec-definitions">
  25.                         <dt>{{ 'ご注文日時'|trans }}</dt>
  26.                         <dd>{{ Order.order_date|date_sec }}</dd>
  27.                     </div>
  28.                     <div class="ec-definitions">
  29.                         <dt>{{ 'ご注文番号'|trans }}</dt>
  30.                         <dd>{{ Order.order_no }}</dd>
  31.                     </div>
  32.                     {% if BaseInfo.option_mypage_order_status_display %}
  33.                         <div class="ec-definitions">
  34.                             <dt>{{ 'ご注文状況'|trans }}</dt>
  35.                             <dd>{{ Order.CustomerOrderStatus }}</dd>
  36.                         </div>
  37.                     {% endif %}
  38.                     {% if BaseInfo.isOptionPoint %}
  39.                         <div class="ec-definitions">
  40.                             <dt>{{ 'ご利用ポイント'|trans }}</dt>
  41.                             <dd>{{ Order.usePoint|number_format }} pt</dd>
  42.                         </div>
  43.                         <div class="ec-definitions">
  44.                             <dt>{{ '加算ポイント'|trans }}</dt>
  45.                             <dd>{{ Order.addPoint|number_format }} pt</dd>
  46.                         </div>
  47.                     {% endif %}
  48.                 </div>
  49.                 <div class="ec-orderDelivery">
  50.                     <div class="ec-rectHeading">
  51.                         <h2>{{ '配送情報'|trans }}</h2>
  52.                     </div>
  53.                     {% for Shipping in Order.Shippings %}
  54.                         {% set isShowReducedTaxMess = false %}
  55.                         <div class="ec-orderDelivery__title">{{ 'お届け先'|trans }}{% if Order.multiple %}({{ loop.index }}){% endif %}</div>
  56.                         {% for orderItem in Shipping.productOrderItems %}
  57.                             {% if checkProductIsFirstShipment(orderItem.Product.id) %}
  58.                                 {% set IsFirstShipment = true %}
  59.                             {% endif %}
  60.                             <div class="ec-orderDelivery__item">
  61.                                 <div class="ec-imageGrid">
  62.                                     <div class="ec-imageGrid__img">
  63.                                         {% if orderItem.product is null %}
  64.                                             <img src="{{ asset(''|no_image_product, 'save_image') }}"/>
  65.                                         {% else %}
  66.                                             <img src="{{ asset(orderItem.Product.MainListImage|no_image_product, 'save_image') }}"
  67.                                                  alt="{{ orderItem.productName }}"/>
  68.                                         {% endif %}
  69.                                     </div>
  70.                                     <div class="ec-imageGrid__content">
  71.                                         <p>
  72.                                             {% if orderItem.Product is not null and orderItem.Product.Status.id == constant('Eccube\\Entity\\Master\\ProductStatus::DISPLAY_SHOW') %}
  73.                                                 <a href="{{ url('product_detail', {'id': orderItem.Product.id}) }}">{{ orderItem.productName }}</a>
  74.                                             {% else %}
  75.                                                 {{ orderItem.productName }}
  76.                                             {% endif %} ×{{ orderItem.quantity }} {% if is_reduced_tax_rate(orderItem) %}{{ '※'|trans }}{% set isShowReducedTaxMess = true %}{% endif %}
  77.                                         </p>
  78.                                         {% if orderItem.ProductClass is not null %}
  79.                                             {% if orderItem.ProductClass.ClassCategory1 is not null %}
  80.                                                 {{ orderItem.productClass.classCategory1.className.name }}:{{ orderItem.productClass.classCategory1 }}
  81.                                             {% endif %}
  82.                                             {% if orderItem.ProductClass.ClassCategory2 %}
  83.                                                 <br>{{ orderItem.productClass.classCategory2.className.name }}:{{ orderItem.productClass.classCategory2 }}
  84.                                             {% endif %}
  85.                                         {% endif %}
  86.                                         <p>{{ orderItem.price_inc_tax|price }}
  87.                                             × {{ orderItem.quantity|number_format }}</p>
  88.                                         {% if orderItem.product and orderItem.price_inc_tax != orderItem.productClass.price02IncTax %}
  89.                                             <p class="ec-color-accent">
  90.                                                 {{ '【現在価格】'|trans }}{{ orderItem.productClass.price02IncTax|price }}</p>
  91.                                             {% set remessage = true %}
  92.                                         {% endif %}
  93.                                     </div>
  94.                                 </div>
  95.                             </div>
  96.                         {% endfor %}
  97.                         <p>{{ isShowReducedTaxMess ? '※ は軽減税率対象商品です。'|trans }}</p>
  98.                         <div class="ec-orderDelivery__address">
  99.                             <p>{{ Shipping.name01 }}&nbsp;{{ Shipping.name02 }}&nbsp;
  100.                                 ({{ Shipping.kana01 }}&nbsp;{{ Shipping.kana02 }})</p>
  101.                             <p>{{ '〒'|trans }}{{ Shipping.postal_code }} {{ Shipping.Pref }}{{ Shipping.addr01 }}{{ Shipping.addr02 }}</p>
  102.                             <p>{{ Shipping.phone_number }}</p>
  103.                         </div>
  104.                         <div class="ec-definitions--soft">
  105.                             <dt>{{ '配送方法'|trans }} :</dt>
  106.                             <dd>{{ Shipping.shipping_delivery_name }}</dd>
  107.                         </div>
  108.                         <div class="ec-definitions--soft">
  109.                             <dt>{{ 'お届け日'|trans }} :</dt>
  110.                             <dd>{{ Shipping.shipping_delivery_date|date_day_with_weekday|default('指定なし'|trans) }}</dd>
  111.                         </div>
  112.                         <div class="ec-definitions--soft">
  113.                             <dt>{{ 'お届け時間'|trans }} :</dt>
  114.                             <dd>{{ Shipping.shipping_delivery_time|default('指定なし'|trans) }}</dd>
  115.                         </div>
  116.                     {% endfor %}
  117.                 </div>
  118.                 <div class="ec-orderPayment">
  119.                     <div class="ec-rectHeading">
  120.                         <h2>{{ 'お支払い情報'|trans }}</h2>
  121.                     </div>
  122.                     <p>{{ 'お支払い方法'|trans }} : {{ Order.PaymentMethod }}</p>
  123.                 </div>
  124.                 <div class="ec-orderConfirm">
  125.                     <div class="ec-rectHeading">
  126.                         <h2>{{ 'お問い合わせ'|trans }}</h2>
  127.                     </div>
  128.                     <p>{{ Order.message|default('記載なし'|trans)|nl2br }}</p>
  129.                 </div>
  130.                 <div class="ec-orderMails">
  131.                     <div class="ec-rectHeading">
  132.                         <h2>{{ 'メール配信履歴一覧'|trans }}</h2>
  133.                     </div>
  134.                     {% for MailHistory in Order.MailHistories %}
  135.                         <div class="ec-orderMail">
  136.                             <div class="ec-orderMail__time">{{ MailHistory.send_date|date_sec }}</div>
  137.                             <div class="ec-orderMail__link"><a>{{ MailHistory.mail_subject }}</a></div>
  138.                             <div class="ec-orderMail__body">{{ MailHistory.mail_body|nl2br }}<p class="ec-orderMail__close"><a>{{ '閉じる'|trans }}</a></p></div>
  139.                         </div>
  140.                     {% else %}
  141.                         <p class="ec-reportDescription">{{ 'メール履歴はありません。'|trans }}</p>
  142.                     {% endfor %}
  143.                 </div>
  144.             </div>
  145.             <div class="ec-orderRole__summary">
  146.                 <div class="ec-totalBox">
  147.                     <dl class="ec-totalBox__spec">
  148.                         <dt>{{ '小計'|trans }}</dt>
  149.                         <dd>{{ Order.subtotal|price }}</dd>
  150.                     </dl>
  151.                     <dl class="ec-totalBox__spec">
  152.                         <dt>{{ '手数料'|trans }}</dt>
  153.                         <dd>{{ Order.charge|price }}</dd>
  154.                     </dl>
  155.                     <dl class="ec-totalBox__spec">
  156.                         <dt>{{ '送料'|trans }}</dt>
  157.                         <dd>{{ Order.delivery_fee_total|price }}</dd>
  158.                     </dl>
  159.                     {% if Order.taxable_discount < 0 %}
  160.                     <dl class="ec-totalBox__spec">
  161.                         <dt>{{ '値引き'|trans }}</dt>
  162.                         <dd>{{ Order.taxable_discount|price }}</dd>
  163.                     </dl>
  164.                     {% endif %}
  165.                     <div class="ec-totalBox__total">{{ '合計'|trans }}<span
  166.                                 class="ec-totalBox__price">{{ Order.taxable_total|price }}</span><span
  167.                                 class="ec-totalBox__taxLabel">{{ '税込'|trans }}</span></div>
  168.                     {% for item in Order.tax_free_discount_items %}
  169.                         <dl class="ec-totalBox__spec">
  170.                             <dt>{{ item.product_name }}</dt>
  171.                             <dd>{{ item.total_price|price }}</dd>
  172.                         </dl>
  173.                     {% endfor %}
  174.                     <div class="ec-totalBox__paymentTotal">{{ '合計'|trans }}<span
  175.                                 class="ec-totalBox__price">{{ Order.payment_total|price }}</span><span
  176.                                 class="ec-totalBox__taxLabel">{{ '税込'|trans }}</span></div>
  177.                     {% for rate, total in Order.total_by_tax_rate %}
  178.                         <dl class="ec-totalBox__taxRate">
  179.                             <dt>{{ '税率 %rate% %対象'|trans({ '%rate%': rate }) }}</dt>
  180.                             <dd>{{ total|price }} ({{ '内消費税'|trans }} {{ Order.tax_by_tax_rate[rate]|price }})</dd>
  181.                         </dl>
  182.                     {% endfor %}
  183.                     {% if stockOrder and not IsFirstShipment %}
  184.                         <a href="{{ url('mypage_order', {'order_no': Order.order_no }) }}"
  185.                        class="ec-blockBtn--action load-overlay" {{ csrf_token_for_anchor() }} data-method="put"
  186.                        data-confirm="false">{{ '再注文する'|trans }}</a>
  187.                     {% endif %}
  188.                 </div>
  189.                 {% if remessage %}
  190.                     <p class="ec-color-accent">
  191.                         <strong>{{ '※金額が変更されている商品があるため、再注文時はご注意ください。'|trans }}</strong>
  192.                     </p>
  193.                 {% endif %}
  194.             </div>
  195.         </div>
  196.         <div class="ec-role ec-orderRole">
  197.             <div class="ec-orderRole__detail">
  198.                 <a href="{{ url('mypage') }}" class="ec-inlineBtn ec-font-bold">{{ '戻る'|trans }}</a>
  199.             </div>
  200.         </div>
  201.     </div>
  202. {% endblock %}