関数
DeliveryForm::getDeliveryMethodValue()
$usces_entries['order']['delivery_method']
から配達方法IDを返す
戻り値 戻り値
ファイル: src/Components/DeliveryForm/DeliveryForm.php
public function getDeliveryMethodValue() { global $usces; $sessionVal = isset($_SESSION['usces_entry']['order']['delivery_method']) ? $_SESSION['usces_entry']['order']['delivery_method'] : 0; /** * Mirrored Welcart filter * * @ignore */ $deli_id = apply_filters( 'usces_filter_get_available_delivery_method', $usces->get_available_delivery_method() ); if (empty($deli_id)) { return 1; } $cdeliid = count($deli_id); foreach ($deli_id as $id) { $index = $usces->get_delivery_method_index($id); if (0 <= $index) { if ((int)$id === (int)$sessionVal || 1 === $cdeliid) { return $id; } } } return 1; }