# 注文確認メールの「お支払い方法」の表記について

**URL:** <https://community.shopify.com/t/topic/381676>\
**Category:** 決済、配送、フルフィルメント\
**Created:** [December 18, 2024, 9:32am UTC](https://community.shopify.com/t/topic/381676 "2024-12-18T09:32:58Z")\
**Posts on this page:** 3\
**Page:** 1

## AI-generated summary

**問題の内容:**
注文確認メールで支払い方法を表示するためにコードを追加しているが、クレジットカード決済失敗時に店舗払いを再選択した場合、メール内で「shopify_payments」部分が非表示にできるか質問。

**現在の状況:**
- 支払い方法は「クレジットカード払い」と「店舗払い」の2つ
- `{% if gateway == 'shopify_payments' %}` で条件分岐を使用中
- 決済失敗後の店舗払い選択時に「shopify_payments」が表示される問題が発生

**提案された解決策:**
ROUTE06_babaから、`{{ gateway }}` の動的表示部分を固定文言「店舗払い」に変更する修正案が提示された。

**結果:**
質問者は提案された方法で確認することを了承し、スレッドは解決に向かっている。

<div class="post-metadata">

**Author:** ![ponuco](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@ponuco](https://community.shopify.com/u/ponuco)\
**Post date:** [December 18, 2024, 9:32am UTC](https://community.shopify.com/t/topic/381676/1 "2024-12-18T09:32:58Z")

</div>

設定画面にある通知の「注文の確認」メールについて質問があります。

支払い方法を表記したく、下記のようにコードを追加しております。

```auto
{% if gateway == 'shopify_payments' %}
       <table class="row">
           <tr>
             <td class="customer-info __item customer-info__ item--last">
                 <h4>お支払い方法</h4>
                 <p>クレジットカード支払い</p>                                      
             </td>
           </tr>
         </table>
 {% else %}
        <table class="row">
            <tr>
              <td class="customer-info __item customer-info__ item--last">
                  <h4>お支払い方法</h4>
                  <p>{{ gateway }}</p>
              </td>
       　 </tr>
          </table>            
  {% endif %}

```

支払い方法は「クレジットカード支払い」と「店舗支払い」の2つのみです。

クレジットカード決済が失敗した場合、支払い方法の再選択で店舗支払いを選んでいただいていると思うのですが、その際のメールの表示が下記添付画像のように表示されてしまいます。

 ![スクリーンショット 2024-12-17 181916.png](https://canada1.discourse-cdn.com/shopifyforum/original/3X/1/b/1b244a23b3513282497cdf9587e630472a2c268a.png)

決済確認時に「shopify\_payments, 店舗でのお支払い」の「shopify\_payments」部分の表記をなくしたいのですが、非表示にすることは可能でしょうか？

コードの修正等で改善できるようでしたらご教示いただきたいです。  
ご確認のほどどうぞよろしくお願いいたします。

---

<div class="post-metadata">

**Author:** ![ROUTE06\_baba](https://yyz1.discourse-cdn.com/shopifyforum/user_avatar/community.shopify.com/route06_baba/32/106703_2.png) [@ROUTE06\_baba](https://community.shopify.com/u/ROUTE06_baba)\
**Post date:** [December 18, 2024, 10:35am UTC](https://community.shopify.com/t/topic/381676/2 "2024-12-18T10:35:20Z")

</div>

こんにちは。以下のようにするのは、だめでしょうか？

```markup
{% if gateway == 'shopify_payments' %}
       

| <br> #### お支払い方法<br> <br><br>クレジットカード支払い<br><br> <br> |
| - |

 {% else %}
        
       　  

| <br> #### お支払い方法<br> <br><br>店舗払い<br><br><br> |
| - |

            
  {% endif %}

```

{{ gateway }}

 となっている部分を 

店舗払い

 として、固定の文言にしてしまう形です。

---

<div class="post-metadata">

**Author:** ![ponuco](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@ponuco](https://community.shopify.com/u/ponuco)\
**Post date:** [December 19, 2024, 12:41am UTC](https://community.shopify.com/t/topic/381676/3 "2024-12-19T00:41:02Z")

</div>

ご教示いただきありがとうございます！  
上記の方法で確認してみます。
