order printerで受注明細を印刷しています。
割引クーポン名またはクーポンコードを入れたいのですが、
{{ discount.code }} もしくは {{ discount.title }}
この2つを入力しても、表示されません。
どこが間違ってるのかご教授お願いいたします。
***************************************
.printer-preview-content h1 { font-size: 140%; margin: 20px 0 0 0; } .printer-preview-content h2 { font-size: 100%; } .printer-preview-content h3 { font-size: 90%; } .printer-preview-content li{ list-style:none; } p { margin: 0; } header { display: flex; justify-content: space-between; border: solid 1px #000; } .header_in { padding: 10px; } .order_item { border: solid 1px #000; } .transactions { border: solid 1px #000; } .shop { padding: 10px; background-color: #dddddd; text-align: right; } table .item { width: 100%; } .printer-preview-content th { width: -webkit-fill-available; background-color: #eaeaea; } table,th,td { border: 1px solid #bbb; padding: 0 20px; } .order_in { margin: 0 0 20px; border: solid 1px #000; } .billing ,.shipping { width: calc(100% / 2 - 10px); padding: 10px; border: solid 1px #000; } .pay { display: flex; margin: 0 0 10px; padding: 0 0 0 10px; border: solid 1px #000; } .address { display: flex; margin: 0 0 20px; justify-content: space-between; } .remarks { padding: 10px; border: solid 1px #000; }ご注文日{{ processed_at }}
ご注文番号{{ order_name }}
ショップ:{{ shop_name }}
〒{{ shop.zip | upcase }} {{ shop.province | replace: 'Aichi', '愛知県' | replace: 'Akita', '秋田 県' | replace: 'Aomori', '青森県' | replace: 'Chiba', '千葉県' | replace: 'Ehime', '愛 媛県' | replace: 'Fukui', '福井県' | replace: 'Fukuoka', '福岡県' | replace: 'Fukushima', '福島県' | replace: 'Gifu', '岐阜県' | replace: 'Gunma', '群馬県' | replace: 'Hiroshima', '広島県' | replace: 'Hokkaidō', '北海道' | replace: 'Hyōgo', '兵庫県' | replace: 'Ibaraki', '茨城県' | replace: 'Ishikawa', '石川県' | replace: 'Iwate', '岩手県' | replace: 'Kagawa', '香川県' | replace: 'Yamanashi', '山梨県' | replace: 'Yamaguchi', '山口県' | replace: 'Kōchi', '高知県' | replace: 'Kumamoto', '熊本県' | replace: 'Kyōto', '京都府' | replace: 'Mie', '三重県' | replace: 'Yamagata', '山形県' | replace: 'Miyazaki', '宮崎県' | replace: 'Nagano', '長野県' | replace: 'Nagasaki', '長崎県' | replace: 'Nara', '奈良県' | replace: 'Niigata', '新潟県' | replace: 'Ōita', '大分県' | replace: 'Okayama', '岡山県' | replace: 'Okinawa', '沖縄県' | replace: 'Ōsaka', '大阪府' | replace: 'Saga', '佐賀 県' | replace: 'Saitama', '埼玉県' | replace: 'Shiga', '滋賀県' | replace: 'Shimane', '島根県' | replace: 'Shizuoka', '静岡県' | replace: 'Tochigi', '栃木県' | replace: 'Tokushima', '徳島県' | replace: 'Tottori', '鳥取県' | replace: 'Toyama', '富山県' | replace: 'Tōkyō', '東京都' | replace: 'Miyagi', '宮城県' | replace: 'Wakayama', '和 歌山県' | replace: 'Kanagawa', '神奈川県' | replace: 'Kagoshima', '鹿児島県' }} {{ shop.city }} {{ shop.address }} {{ shop.address2 }}ご注文詳細
支払い方法
{% for transaction in transactions %} {% if transaction.status != "failure" and transaction.status != "error" %} {% if transaction.kind == "authorization" or transaction.kind == "sale" %} {% if transaction.payment_details.credit_card_number %}{{ transaction.gateway | payment_method }}:{{ transaction.payment_details.credit_card_company }}:{{ transaction.payment_details.credit_card_number }}{% break %}
{% else %}{{ transaction.gateway | payment_method }}:{{ transaction.gateway }}{% break %}
{% endif %} {% endif %} {% endif %} {% endfor %}
{% for line_item in line_items %}
{% endfor %}
| 商品名 | 数量 | 単価 (税込) |
|---|---|---|
| {% if line_item.sku != blank %}【{{ line_item.sku }}】{% endif %} {{ line_item.title }} | {{ line_item.quantity }} | {{ line_item.original_price | money }} |
お支払い内訳
| 割引コード{{ discount.title }} | {{ total_discounts | money }} |
|---|---|
| (内消費税) | {{ tax_price | money }} |
| 送料(税込) | {{ shipping_price | money }} |
| 総合計(税込) | {{ total_price | money }} {% if total_paid != total_price %} {% endif %} |
注文者
- {{ billing_address | format_address }}
- {{ billing_address.last_name }}{{ billing_address.first_name }}
- 電話番号:{{ billing_address.phone }}
お届け先
備考
{{ note }}
{{ shipping_method.title }}
{% for attribute in attributes %}
{% if attribute.first == "配送希望日" %}
{{ attribute | first }}
{{ attribute | last }}
{% endif %} {% endfor %} {% for attribute in attributes %} {% if attribute.first == "配送希望時間" %}{{ attribute | first }}
{{ attribute | last }}
{% endif %} {% endfor %}