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-backend
Model
Menu
Config
Converter.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Backend\Model\Menu\Config
;
7
13
class
Converter
implements
\Magento\Framework\Config\ConverterInterface
14
{
21
public
function
convert
($dom)
22
{
23
$extractedData = [];
24
25
$attributeNamesList = [
26
'id'
,
27
'title'
,
28
'toolTip'
,
29
'module'
,
30
'sortOrder'
,
31
'action'
,
32
'parent'
,
33
'resource'
,
34
'dependsOnModule'
,
35
'dependsOnConfig'
,
36
'target'
37
];
38
$xpath = new \DOMXPath($dom);
39
$nodeList = $xpath->query(
'/config/menu/*'
);
40
for
(
$i
= 0;
$i
< $nodeList->length;
$i
++) {
41
$item
= [];
42
$node = $nodeList->item(
$i
);
43
$item
[
'type'
] = $node->nodeName;
44
foreach
($attributeNamesList as
$name
) {
45
if
($node->hasAttribute(
$name
)) {
46
$item
[
$name
] = $node->getAttribute(
$name
);
47
}
48
}
49
$extractedData[] =
$item
;
50
}
51
return
$extractedData;
52
}
53
}
Magento\Backend\Model\Menu\Config
Definition:
Converter.php:6
Magento\Backend\Model\Menu\Config\Converter\convert
convert($dom)
Definition:
Converter.php:21
$item
$item
Definition:
partial_invoice.php:27
Magento\Backend\Model\Menu\Config\Converter
Definition:
Converter.php:13
$i
$i
Definition:
gallery.phtml:31
Magento\Framework\Config\ConverterInterface
Definition:
ConverterInterface.php:14
$name
if(!isset($_GET['name'])) $name
Definition:
log.php:14