![](/img/trans.png)
[英]Drupal's Ubercart redirecting to a custom order complete/thank you page
[英]How can I display ordered items and shipping info on Drupal Commerce 2.x complete/thank you page?
我需要編輯/完成頁面。 有沒有一種方法可以顯示當前訂單中的商品以及可能的運輸信息?
是否有類似的東西:
{{order_entity.getOrderShippingInfo}}
要么
{{order_entity.getOrderItems}}
我設法使用顯示了訂購的物品:
{% for order_item in order_entity.getItems %}
{{ order_item.getQuantity|number_format }} x
{% if order_item.hasPurchasedEntity %}
{{ order_item.getPurchasedEntity|commerce_entity_render('summary') }}
{% else %}
{{- order_item.label -}}
{% endif %}
{{- order_item.getTotalPrice|commerce_price_format -}}
{% endfor %}
雖然我仍然無法獲得訂單的帳單或運輸信息。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.