Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-dhl
Model
Source
Method
Generic.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Dhl\Model\Source\Method
;
7
8
class
Generic
9
{
13
protected
$_shippingDhl
;
14
18
protected
$_code
=
''
;
19
23
public
function
__construct
(\
Magento
\Dhl\Model\
Carrier
$shippingDhl)
24
{
25
$this->_shippingDhl = $shippingDhl;
26
}
27
33
public
function
toOptionArray
()
34
{
35
$configData
= $this->_shippingDhl->getCode($this->_code);
36
$arr = [];
37
foreach
(
$configData
as
$code
=>
$title
) {
38
$arr[] = [
'value'
=>
$code
,
'label'
=>
$title
];
39
}
40
return
$arr;
41
}
42
}
$title
$title
Definition:
default.phtml:14
Magento\Dhl\Model\Source\Method\Generic\$_code
$_code
Definition:
Generic.php:18
Magento\Dhl\Model\Source\Method
Definition:
AbstractMethod.php:6
Magento\Dhl\Model\Source\Method\Generic
Definition:
Generic.php:8
Magento\Dhl\Model\Source\Method\Generic\toOptionArray
toOptionArray()
Definition:
Generic.php:33
Magento\Dhl\Model\Source\Method\Generic\$_shippingDhl
$_shippingDhl
Definition:
Generic.php:13
Magento\Dhl\Model\Source\Method\Generic\__construct
__construct(\Magento\Dhl\Model\Carrier $shippingDhl)
Definition:
Generic.php:23
Magento\Dhl\Model\Carrier
Definition:
Carrier.php:26
$configData
$configData
Definition:
payment_configuration.php:26
Magento
$code
$code
Definition:
info.phtml:12