You are here

public static function UPSUtilities::packageTypes in Ubercart 8.4

Convenience function to get UPS codes for their package types.

6 calls to UPSUtilities::packageTypes()
uc_ups_form_node_form_alter in shipping/uc_ups/uc_ups.module
Implements hook_form_BASE_FORM_ID_alter() for node_form().
uc_ups_fulfill_order in shipping/uc_ups/src/Plugin/Ubercart/FulfillmentMethod/uc_ups.ship.inc
Shipment creation callback.
uc_ups_shipment_request in shipping/uc_ups/src/Plugin/Ubercart/FulfillmentMethod/uc_ups.ship.inc
Constructs an XML shipment request.
uc_ups_shipping_quote in shipping/uc_ups/uc_ups.module
Constructs an XML quote request.
uc_ups_uc_shipping_method in shipping/uc_ups/uc_ups.module
Implements hook_uc_shipping_method().

... See full list

File

shipping/uc_ups/src/UPSUtilities.php, line 43

Class

UPSUtilities
Utility routines for UPS Shipping.

Namespace

Drupal\uc_ups

Code

public static function packageTypes() {
  return [
    // Customer Supplied Page is first so it will be the default.
    '02' => t('Customer Supplied Package'),
    '01' => t('UPS Letter'),
    '03' => t('Tube'),
    '04' => t('PAK'),
    '21' => t('UPS Express Box'),
    '24' => t('UPS 25KG Box'),
    '25' => t('UPS 10KG Box'),
    '30' => t('Pallet'),
    '2a' => t('Small Express Box'),
    '2b' => t('Medium Express Box'),
    '2c' => t('Large Express Box'),
  ];
}