class DeliveryAddressPane in Ubercart 8.4
Gets the user's delivery information.
Plugin annotation
@CheckoutPane(
id = "delivery",
title = @Translation("Delivery information"),
weight = 3,
shippable = TRUE
)
Hierarchy
- class \Drupal\Component\Plugin\PluginBase implements DerivativeInspectionInterface, PluginInspectionInterface
- class \Drupal\Core\Plugin\PluginBase uses DependencySerializationTrait, MessengerTrait, StringTranslationTrait
- class \Drupal\uc_cart\CheckoutPanePluginBase implements CheckoutPanePluginInterface
- class \Drupal\uc_cart\Plugin\Ubercart\CheckoutPane\AddressPaneBase
- class \Drupal\uc_cart\Plugin\Ubercart\CheckoutPane\DeliveryAddressPane
- class \Drupal\uc_cart\Plugin\Ubercart\CheckoutPane\AddressPaneBase
- class \Drupal\uc_cart\CheckoutPanePluginBase implements CheckoutPanePluginInterface
- class \Drupal\Core\Plugin\PluginBase uses DependencySerializationTrait, MessengerTrait, StringTranslationTrait
Expanded class hierarchy of DeliveryAddressPane
File
- uc_cart/
src/ Plugin/ Ubercart/ CheckoutPane/ DeliveryAddressPane.php, line 15
Namespace
Drupal\uc_cart\Plugin\Ubercart\CheckoutPaneView source
class DeliveryAddressPane extends AddressPaneBase {
/**
* {@inheritdoc}
*/
protected function getDescription() {
return $this
->t('Enter your delivery address and information here.');
}
/**
* {@inheritdoc}
*/
protected function getCopyAddressText() {
return $this
->t('My delivery information is the same as my billing information.');
}
/**
* {@inheritdoc}
*/
public function defaultConfiguration() {
return [
'delivery_not_shippable' => TRUE,
];
}
/**
* {@inheritdoc}
*/
public function settingsForm() {
$form['delivery_not_shippable'] = [
'#type' => 'checkbox',
'#title' => $this
->t('Hide delivery information when carts have no shippable items.'),
'#default_value' => $this->configuration['delivery_not_shippable'],
];
return $form;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AddressPaneBase:: |
protected static | property | Source pane for "copy address" checkbox. | |
AddressPaneBase:: |
public | function | Ajax callback to re-render the full address element. | |
AddressPaneBase:: |
public | function |
Processes a checkout pane. Overrides CheckoutPanePluginBase:: |
|
AddressPaneBase:: |
public | function |
Returns the review contents of a checkout pane. Overrides CheckoutPanePluginInterface:: |
|
AddressPaneBase:: |
protected | function | Returns the ID of the source (first) address pane for copying. | |
AddressPaneBase:: |
public | function |
Returns the contents of a checkout pane. Overrides CheckoutPanePluginInterface:: |
|
CheckoutPanePluginBase:: |
protected | property | Whether the pane is enabled or not. | |
CheckoutPanePluginBase:: |
protected | property | The weight of the checkout pane. | |
CheckoutPanePluginBase:: |
public | function |
Gets this plugin's configuration. Overrides ConfigurableInterface:: |
|
CheckoutPanePluginBase:: |
public | function |
Returns the title of the pane, to be displayed on the checkout form. Overrides CheckoutPanePluginInterface:: |
|
CheckoutPanePluginBase:: |
public | function |
Returns the weight of the checkout pane. Overrides CheckoutPanePluginInterface:: |
|
CheckoutPanePluginBase:: |
public | function |
Returns whether the checkout pane is enabled. Overrides CheckoutPanePluginInterface:: |
|
CheckoutPanePluginBase:: |
public | function |
Prepares a pane for display. Overrides CheckoutPanePluginInterface:: |
1 |
CheckoutPanePluginBase:: |
public | function |
Sets the configuration for this plugin instance. Overrides ConfigurableInterface:: |
|
CheckoutPanePluginBase:: |
public | function |
Constructs a \Drupal\Component\Plugin\PluginBase object. Overrides PluginBase:: |
1 |
DeliveryAddressPane:: |
public | function |
Gets default configuration for this plugin. Overrides CheckoutPanePluginBase:: |
|
DeliveryAddressPane:: |
protected | function |
Returns text to display for the 'copy address' field. Overrides AddressPaneBase:: |
|
DeliveryAddressPane:: |
protected | function |
Returns additional text to display as a description. Overrides AddressPaneBase:: |
|
DeliveryAddressPane:: |
public | function |
Returns the settings form for a checkout pane. Overrides CheckoutPanePluginBase:: |
|
DependencySerializationTrait:: |
protected | property | An array of entity type IDs keyed by the property name of their storages. | |
DependencySerializationTrait:: |
protected | property | An array of service IDs keyed by property name used for serialization. | |
DependencySerializationTrait:: |
public | function | 1 | |
DependencySerializationTrait:: |
public | function | 2 | |
MessengerTrait:: |
protected | property | The messenger. | 29 |
MessengerTrait:: |
public | function | Gets the messenger. | 29 |
MessengerTrait:: |
public | function | Sets the messenger. | |
PluginBase:: |
protected | property | Configuration information passed into the plugin. | 1 |
PluginBase:: |
protected | property | The plugin implementation definition. | 1 |
PluginBase:: |
protected | property | The plugin_id. | |
PluginBase:: |
constant | A string which is used to separate base plugin IDs from the derivative ID. | ||
PluginBase:: |
public | function |
Gets the base_plugin_id of the plugin instance. Overrides DerivativeInspectionInterface:: |
|
PluginBase:: |
public | function |
Gets the derivative_id of the plugin instance. Overrides DerivativeInspectionInterface:: |
|
PluginBase:: |
public | function |
Gets the definition of the plugin implementation. Overrides PluginInspectionInterface:: |
3 |
PluginBase:: |
public | function |
Gets the plugin_id of the plugin instance. Overrides PluginInspectionInterface:: |
|
PluginBase:: |
public | function | Determines if the plugin is configurable. | |
StringTranslationTrait:: |
protected | property | The string translation service. | 1 |
StringTranslationTrait:: |
protected | function | Formats a string containing a count of items. | |
StringTranslationTrait:: |
protected | function | Returns the number of plurals supported by a given language. | |
StringTranslationTrait:: |
protected | function | Gets the string translation service. | |
StringTranslationTrait:: |
public | function | Sets the string translation service to use. | 2 |
StringTranslationTrait:: |
protected | function | Translates a string to the current language or to a given language. |