function uc_address_property_info in Ubercart 7.3
Helper function for hook_entity_property_info() and hook_rules_data_info().
Should be used by implementations of those hooks that wish to wrap address selectors.
2 calls to uc_address_property_info()
- uc_order_entity_property_info in uc_order/
uc_order.info.inc - Implements hook_entity_property_info().
- uc_shipping_rules_data_info in shipping/
uc_shipping/ uc_shipping.rules.inc - Implements hook_rules_data_info().
File
- uc_store/
uc_store.module, line 775 - Contains global Ubercart functions and store administration functionality.
Code
function uc_address_property_info() {
return array(
'first_name' => array(
'type' => 'text',
'label' => t('First name'),
'description' => t('First name of the addressee.'),
),
'last_name' => array(
'type' => 'text',
'label' => t('Last name'),
'description' => t('Last name of the addressee.'),
),
'company' => array(
'type' => 'text',
'label' => t('Company'),
'description' => t('Name of the company at the address.'),
),
'street1' => array(
'type' => 'text',
'label' => t('Street line 1'),
'description' => t('First line of the street address.'),
),
'street2' => array(
'type' => 'text',
'label' => t('Street line 2'),
'description' => t('Second line of the street address.'),
),
'city' => array(
'type' => 'text',
'label' => t('City'),
'description' => t('Address city.'),
),
'zone' => array(
'type' => 'integer',
'label' => t('Zone'),
'description' => t('Address state/province/zone.'),
'options list' => 'uc_zone_option_list',
),
'postal_code' => array(
'type' => 'text',
'label' => t('Postal code'),
'description' => t('Address post code.'),
),
'country' => array(
'type' => 'integer',
'label' => t('Country'),
'description' => t('Address country.'),
'options list' => 'uc_country_option_list',
),
'phone' => array(
'type' => 'text',
'label' => t('Phone'),
'description' => t('Contact phone number.'),
),
'email' => array(
'type' => 'text',
'label' => t('Email'),
'description' => t('Contact email address.'),
),
);
}