안산환경운동연합에서
최종인 선생님과 함께하는 갈대습지 탐방을 진행합니다.
회원 또는 비회원 누구나 신청가능하며,
지인 또는 가족 동반도 가능합니다!
▲ 일시 : 2019.11.23(토) 오전10시10분-12시
▲ 장소 : 안산갈대습지 환경생태관앞
▲ 신청 : 031)486-5120 또는 문자
use Drupal\commerce_order\Entity\Order; /** * Implements hook_preprocess_HOOK() for commerce_checkout_order_summary. */ function bootstrap_barrio_subtheme_preprocess_commerce_checkout_order_summary(&$variables) { $order = $variables['order_entity']; // 주문 엔터티 $product_ids = []; if ($order instanceof Order) { foreach ($order->getItems() as $order_item) { $purchased_entity = $order_item->getPurchasedEntity(); if ($purchased_entity && $purchased_entity->getProduct()) { $product = $purchased_entity->getProduct(); $product_ids[] = $product->id(); } } } // Twig 템플릿에서 사용할 변수 추가 $variables['product_ids'] = $product_ids; }
댓글 달기