テーマ仕様書 更新履歴
2025年
2025/04/15更新

2025/04/15更新

+ 更新した行
- 削除した行

受取場所管理機能の実装(置き配サービス対応)

受取場所管理は、以下の機能を提供します。

  • 配送業者ごとの受取場所データの作成・管理
  • 配送業者と受取場所を関連付け
  • 顧客は注文時やマイページから希望の受取場所を選択可能

詳しい設定方法は受取場所管理機能 (opens in a new tab)をご覧ください。

mypage > 定期注文詳細画面 基本情報の編集

ec_force/shop/customer/subs_orders/edit.html.liquid
ec_force/shop/customer/subs_orders/edit.html+smartphone.liquid

   <!-- 次回配送のスキップの変更 -->
   {% if base_info.skip_next_delivery_on_mypage? %}
     <div id="skip-next-delivery-view">
       <form class="form-horizontal" action="/shop/customer/subs_orders/{{ subs_order.number }}" accept-charset="UTF-8" method="post">
         <input type="hidden" name="_method" value="put">
         <input value="true" type="hidden" name="subs_order[skip_next_scheduled_delivery]" id="subs_order_skip_next_scheduled_delivery">
         {{ subs_order.scheduled_to_be_delivered_at | date: "%Y-%m-%d" }}
         {% if subs_order.skip_next_scheduled_delivery? == false %}
           {{ subs_order.next_scheduled_to_be_delivered_at | date: "%Y-%m-%d" }}
         {% endif %}
         <input type="submit" name="commit" value="配送をスキップ" class="btn btn-primary btn-sm" {% if subs_order.skip_next_scheduled_delivery? %} disabled {% endif %} />
         <a class="btn btn-sm btn-default" href="/shop/customer/subs_orders/{{ subs_order.number }}">戻る</a>
       </form>
     </div>
   {% endif %}
+
+  <!-- 受取場所の変更 -->
+  {% if base_info.subs_order_changeable_pickup_locations? %}
+    <div id="change-pickup-locations-view">
+
+      <form action="/shop/customer/subs_orders/{{ subs_order.number }}" accept-charset="UTF-8" method="post">
+        <input type="hidden" name="_method" value="put">
+
+        <!-- 受取場所の選択 -->
+        {% assign pickup_location_count = shipping_carrier.pickup_location_count %}
+        {% for index in (1..pickup_location_max_count) %}
+          {% assign array_index = index | minus: 1 %}
+          {% assign subs_order_pickup_location = subs_order_pickup_locations[array_index] %}
+          <div id="pickup_location_{{ index }}">
+            <label>受取場所 第{{ index }}希望</label>
+            <select id="pickup_location_select_{{ index }}" name="subs_order[subs_order_pickup_locations_attributes][][pickup_location_id]" {% if index > pickup_location_count %}disabled{% endif %}>
+              <option value="">置き配を利用しない</option>
+              {% for location in pickup_locations %}
+                <option value="{{ location.id }}" {% if location.id == subs_order_pickup_location.pickup_location_id %}selected{% endif %}>
+                  {{ location.location_name }}
+                </option>
+              {% endfor %}
+            </select>
+          </div>
+          <input type="hidden" name="subs_order[subs_order_pickup_locations_attributes][][priority]" value="{{ index }}">
+          <input type="hidden" name="subs_order[subs_order_pickup_locations_attributes][][id]" value="{{ subs_order_pickup_location.id }}">
+        {% endfor %}
+
+        <!-- チャイムの選択 -->
+        <label for="doorbell">チャイム</label>
+        <select id="doorbell_select" name="subs_order[subs_order_pickup_locations_attributes_doorbell]" {% unless shipping_carrier.use_doorbell %}disabled{% endunless %}>
+          <option value="true" {% if doorbell %}selected{% endif %}>あり</option>
+          <option value="false" {% unless doorbell %}selected{% endunless %}>なし</option>
+        </select>
+
+        <!-- 送信リンク -->
+        <input type="submit" name="commit" value="保存" />
+        <!-- 戻るリンク -->
+        <a href="/shop/customer/subs_orders/{{ subs_order.number }}">戻る</a>
+
+      </form>
+    </div>
+  {% endif %}
 </div>

cart > 注文情報確認画面

ec_force/shop/orders/confirm.html.liquid
ec_force/shop/orders/confirm.html+smartphone.liquid

   {% endif %}
 
+  <!-- 店頭受取ではなく、複数のお届け先でもない -->
   {% if order.pickup_store == blank and order.multiple_shipping? == false %}
     <!-- 配送業者名 -->
     {{ order.shipping_carrier.name }}
+
+    <!-- 置き配 -->
+    {% if order.payment.payment_method.cash_on_delivery? == false and order.shipping_carrier.pickup_locations != blank and common_form_settings['pickup_location'] == true %}
+      {% assign pickup_location_count = order.shipping_carrier.pickup_location_count | minus: 1 %}
+      <!-- 受取場所希望 -->
+      {% for i in (0..pickup_location_count) %}
+        {% if order.order_pickup_locations[i].pickup_location.location_name == blank %}
+          置き配を利用しない
+        {% else %}
+          {{ order.order_pickup_locations[i].pickup_location.location_name }}
+        {% endif %}
+      {% endfor %}
+      <!-- チャイム -->
+      {% if order.shipping_carrier.use_doorbell %}
+        {% if order.order_pickup_locations.last.doorbell and order.order_pickup_locations %}
+          あり
+        {% else %}
+          なし
+        {% endif %}
+      {% endif %}
+    {% endif %}
   {% endif %}
 
   <!-- お支払い情報 -->

cart > サンクスオファー確認画面

ec_force/shop/orders/cv_confirm.html.liquid
ec_force/shop/orders/cv_confirm.html+smartphone.liquid

   <!-- 配送業者名 -->
   {{ order.shipping_carrier.name }}
 
+  <!-- 置き配 -->
+  {% if order.payment.payment_method.cash_on_delivery? == false and order.shipping_carrier.pickup_locations != blank and common_form_settings['pickup_location'] == true %}
+    {% assign pickup_location_count = order.shipping_carrier.pickup_location_count | minus: 1 %}
+    <!-- 受取場所希望 -->
+    {% for i in (0..pickup_location_count) %}
+      {% if order.order_pickup_locations[i].pickup_location.location_name == blank %}
+        置き配を利用しない
+      {% else %}
+        {{ order.order_pickup_locations[i].pickup_location.location_name }}
+      {% endif %}
+    {% endfor %}
+    <!-- チャイム -->
+    {% if order.shipping_carrier.use_doorbell %}
+      {% if order.order_pickup_locations.last.doorbell and order.order_pickup_locations %}
+        あり
+      {% else %}
+        なし
+      {% endif %}
+    {% endif %}
+  {% endif %}
+
 
   <!-- お支払い情報 -->
       <input id="scheduled_1st_delivery_time" name="order[scheduled_delivery_time]" type="hidden" value="{{ order.scheduled_delivery_time }}">
       <input id="offer_name" name="order[offer_name]" type="hidden" value="{{ order.offer_name }}">
       <input id="current_order_point_key" name="current_order_point_key" type="hidden" value="{{ preview_grant_plan_point_key }}">
+      {% for order_pickup_location in normal_order.order_pickup_locations %}
+        <input name='order[order_pickup_locations_attributes][][id]' type="hidden" value="{{ order_pickup_location.id }}">
+        <input name='order[order_pickup_locations_attributes][][_destroy]' type="hidden" value=true>
+      {% endfor %}
+      {% for order_pickup_location in order.order_pickup_locations %}
+        <input name='order[order_pickup_locations_attributes][][id]' type="hidden" value=''>
+        <input name='order[order_pickup_locations_attributes][][_destroy]' type="hidden" value=false>
+        <input name='order[order_pickup_locations_attributes][][pickup_location_id]' type="hidden" value="{{ order_pickup_location.pickup_location_id }}">
+        <input name='order[order_pickup_locations_attributes][][doorbell]' type="hidden" value="{{ order_pickup_location.doorbell }}">
+        <input name='order[order_pickup_locations_attributes][][priority]' type="hidden" value="{{ order_pickup_location.priority }}">
+      {% endfor %}
     {% endunless %}
     <div id="expired_cv_confirm" style="display: none;">
       有効期限を経過しました。

cart > サンクスクロスセル(部分テンプレート)

ec_force/shop/orders/_form_cv_xsell.html.liquid
ec_force/shop/orders/_form_cv_xsell.html+smartphone.liquid

         </div>
       </div>
       <!-- 商品を追加したときの情報 ここまで-->
+      <div id="cv-xsell-view-pickup-location" class="default-hide">
+        <!-- 受取場所の選択 -->
+        <!-- 置き配用 部分テンプレート (PC用) -->
+        {% include 'ec_force/shop/orders/view_pickup_location.html' %}
+        <!-- 置き配用 部分テンプレート (スマートフォン用) -->
+        {% include 'ec_force/shop/orders/view_pickup_location.html+smartphone' %}
+      </div>
       <div id="subs-order-settings" class="default-hide">
         お届け商品の設定
+        <!-- お届けサイクルの選択用部分テンプレート (PC用)--> 
         {% include 'ec_force/shop/orders/view_payment_schedule.html' %}
+        <!-- お届けサイクルの選択用部分テンプレート (スマートフォン用)-->
+        {% include 'ec_force/shop/orders/view_payment_schedule.html+smartphone' %}
       </div>
       <input id="submit_btn" class="default-hide" type="submit" value="申し込み内容を確認する" data-disable-with="" ></input>
     </form>

cart > 注文情報入力画面

ec_force/shop/orders/new.html.liquid
ec_force/shop/orders/new.html+smartphone.liquid

各入力フォーム部分テンプレート(PC用) の記載です。

     {% include 'ec_force/shop/orders/view_payment_information.html' %}
     <!-- 配送業者の選択 -->
     {% include 'ec_force/shop/orders/view_shipping_carrier.html' %}
+    <!-- 受取場所の選択 -->
+    {% include 'ec_force/shop/orders/view_pickup_location.html' %}
     <!-- お届けサイクルの選択 -->
     {% include 'ec_force/shop/orders/view_payment_schedule.html' %}
     <!-- 通信欄 -->

各入力フォーム部分テンプレート(スマートフォン用) の記載です。

     {% include 'ec_force/shop/orders/view_payment_information.html+smartphone' %}
     <!-- 配送業者の選択 -->
     {% include 'ec_force/shop/orders/view_shipping_carrier.html+smartphone' %}
+    <!-- 受取場所の選択 -->
+    {% include 'ec_force/shop/orders/view_pickup_location.html+smartphone' %}
     <!-- お届けサイクルの選択 -->
     {% include 'ec_force/shop/orders/view_payment_schedule.html+smartphone' %}
     <!-- 通信欄 -->

cart > 受取場所(部分テンプレート)

ec_force/shop/orders/_view_pickup_location.html.liquid
ec_force/shop/orders/_view_pickup_location.html+smartphone.liquid

新規追加ファイルです。
詳細は受取場所(部分テンプレート)をご確認ください。

cart > 配送業者(部分テンプレート)

配送業者(部分テンプレート)の更新について

今回の更新内容には、軽微な修正が含まれています。
受取場所管理機能を利用しない場合でも、更新を推奨します。

ec_force/shop/orders/_view_shipping_carrier.html.liquid
ec_force/shop/orders/_view_shipping_carrier.html+smartphone.liquid

 <!-- 部分テンプレート(配送業者の選択) -->
-{% if pickup_store_is_available == true and delivery_to_address_is_checked == false %}
+{% if display_shipping_carrier_view_flag == false %}
+  {% assign own_style = 'display: none;' %}
+{% elsif multiple_shipping_is_available and order_is_multiple_shipping %}
   {% assign own_style = 'display: none;' %}
 {% else %}
   {% assign own_style = '' %}
 {% endif %}
   
 <div id='view-shipping-carrier' style="{{ own_style }}">
-  {% if base_info.shipping_carrier_based_on == 'product' %}
-    <div style="{% unless shop_form_settings['shipping_carrier'] %}display: none;{% endunless %}">
-      <!-- 配送業者の選択 -->
-      <label>配送業者</label>
-      <select id='shipping_carrier_id' name='order[shipping_carrier_id]'>
+  <div>
+    <!-- 配送業者の選択 -->
+    <label>配送業者</label>
+    <select id='shipping_carrier_id' name='order[shipping_carrier_id]'>
+      {% if order.shipping_carrier_id != blank %}
         <option value="{{ order.shipping_carrier_id }}" {% if order.shipping_carrier_id %}selected{% endif %}>{{ order.shipping_carrier.name }}</option>
-      </select>
-      <div id='shipping_carrier_description'></div>
-    </div>
-  {% endif %}
+      {% endif %}
+    </select>
+    <div id='shipping_carrier_description'></div>
+  </div>
 </div>

軽微な更新

ダミーメールアドレスを使用している以下の顧客が、購入時にメールアドレスとパスワードを変更できるようになりました。

※管理画面でダミーメールアドレスを手動登録した顧客は対象外です。

cart > 請求先住所(部分テンプレート)

   {% if shop_form_settings['email'] %}
     <label>メールアドレス</label>
     {% if customer_signed_in %}
-      <input disabled id='email' type='email' value='{{ current_customer.email }}' class='for_password_validate'>
-      <input name='order[email]' type='hidden' value='{{ current_customer.email }}'>
-      <input name='order[customer_attributes][email]' type='hidden' value='{{ current_customer.email }}'>
+      {% if current_customer.is_auto_generated_email? %}
+        <input type="email" name='order[email]' autocomplete="email" id='email' class='js-email-autocomplete form-control input-sm validate[required,custom[email],ajax[emailCheckShop]] for_password_validate' value='' placeholder="例)○○○@example.com">
+        <input name='order[customer_attributes][email]' type='hidden' value='' id='customer_email'>
+        <input name='order[customer_attributes][is_auto_generated_email]' type='hidden' value=0>
+        <input name='order[customer_attributes][mail_delivery_stop]' type='hidden' value=0>
+      {% else %}
+        <input class='form-control input-sm for_password_validate' disabled id='email' type='email' value='{{ current_customer.email }}' placeholder="例)○○○@example.com">
+        <input name='order[email]' type='hidden' value='{{ current_customer.email }}'>
+        <input name='order[customer_attributes][email]' type='hidden' value='{{ current_customer.email }}'>
+      {% endif %}
     {% else %}
       <input type="email" name='order[email]' autocomplete="email" id='email' class='js-email-autocomplete validate[required,custom[email],ajax[emailCheckShop]] for_password_validate' value="{% if order.email %}{{ order.email }}{% elsif line_email %}{{ line_email }}{% endif %}">
       <input name='order[customer_attributes][email]' type='hidden' value='{{ order.email }}' id='customer_email'>
     {% endif %}
 
     <!-- メールアドレス(確認) -->
     <label>メールアドレス(確認)</label>
     {% if customer_signed_in %}
-      <input disabled name='order[email_confirmation]' type='email' value='{{ current_customer.email }}'>
+      {% if current_customer.is_auto_generated_email? %}
+        <input class='js-email-autocomplete form-control input-sm validate[required,custom[email],equals[email],ajax[emailCheckShop]]' name='order[email_confirmation]' type='email' value='' placeholder="例)○○○@example.com">
+      {% else %}
+        <input class='u-text--input u-color__input--bg u-color__border--input' disabled name='order[email_confirmation]' type='email' value='{{ current_customer.email }}' placeholder="{{ 'customer.placeholder.email.value' | t }}">
+      {% endif %}
     {% else %}
       <input class='js-email-autocomplete validate[required,custom[email],equals[email],ajax[emailCheckShop]]' name='order[email_confirmation]' type='email' value="{% if order.email %}{{ order.email }}{% elsif line_email %}{{ line_email }}{% endif %}">
     {% endif %}
   <!-- 同時に会員登録と購入を行う際のパスワード -->
+  {% if customer_signed_in == true and order.customer.password? == false %}
+    {% assign customer_signed_in_with_no_password = true %}
+  {% endif %}
   {% if guest_flag and customer_signed_in != true %}
+    {% assign customer_not_signed_in_guest_flag = true %}
+  {% endif %}
+
+  {% if customer_signed_in_with_no_password == true or customer_not_signed_in_guest_flag == true %}
     {% unless auth_infra and auth_infra.login_only_auth_infra == true %}
       <!-- パスワード -->
       <label>パスワード</label>