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-braintree
Block
Adminhtml
Form
Field
Countries.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Braintree\Block\Adminhtml\Form\Field
;
7
8
use
Magento\Braintree\Helper\Country
;
9
use
Magento\Framework\View\Element\Context
;
10
use
Magento\Framework\View\Element\Html\Select
;
11
15
class
Countries
extends
Select
16
{
20
private
$countryHelper;
21
29
public
function
__construct
(
Context
$context,
Country
$countryHelper, array
$data
= [])
30
{
31
parent::__construct($context,
$data
);
32
$this->countryHelper = $countryHelper;
33
}
34
40
protected
function
_toHtml
()
41
{
42
if
(!$this->
getOptions
()) {
43
$this->
setOptions
($this->countryHelper->getCountries());
44
}
45
return
parent::_toHtml();
46
}
47
54
public
function
setInputName
(
$value
)
55
{
56
return
$this->setName(
$value
);
57
}
58
}
Magento\Framework\View\Element\Html\Select\setOptions
setOptions($options)
Definition:
Select.php:36
Magento\Framework\View\Element\Html\Select
Definition:
Select.php:11
Magento\Framework\View\Element\Html\Select\getOptions
getOptions()
Definition:
Select.php:25
Magento\Braintree\Block\Adminhtml\Form\Field\Countries\__construct
__construct(Context $context, Country $countryHelper, array $data=[])
Definition:
Countries.php:29
$data
$data
Definition:
attribute_set_with_image_attribute.php:16
$value
$value
Definition:
gender.phtml:16
Magento\Braintree\Helper\Country
Definition:
Country.php:14
Magento\Braintree\Block\Adminhtml\Form\Field
Definition:
CcTypes.php:6
Magento\Braintree\Block\Adminhtml\Form\Field\Countries\_toHtml
_toHtml()
Definition:
Countries.php:40
Magento\Braintree\Block\Adminhtml\Form\Field\Countries
Definition:
Countries.php:15
Magento\Framework\View\Element\Context
Definition:
Context.php:25
Magento\Braintree\Block\Adminhtml\Form\Field\Countries\setInputName
setInputName($value)
Definition:
Countries.php:54