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)
Main Page
Related Pages
+
Namespaces
Namespace List
+
Namespace Members
+
All
$
_
c
d
e
f
g
h
i
m
p
r
s
t
u
+
Functions
_
c
d
e
f
g
h
i
m
p
r
s
t
u
Variables
+
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
+
Data Fields
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Files
File List
+
Globals
+
All
$
(
_
a
b
c
d
e
f
g
h
i
j
m
n
o
p
q
r
s
t
u
v
w
+
Functions
_
c
d
e
f
g
m
o
r
s
t
v
+
Variables
$
(
_
a
b
c
d
e
f
g
h
i
j
m
n
o
p
q
r
s
t
u
v
w
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Pages
vendor
magento
module-bundle-graph-ql
Model
Resolver
Product
Fields
DynamicWeight.php
Go to the documentation of this file.
1
<?php
6
declare(strict_types=1);
7
8
namespace
Magento\BundleGraphQl\Model\Resolver\Product\Fields
;
9
10
use
Magento\Framework\GraphQl\Schema\Type\ResolveInfo
;
11
use
Magento\Bundle\Model\Product\Type
as Bundle;
12
use
Magento\Framework\GraphQl\Config\Element\Field
;
13
use
Magento\Framework\GraphQl\Query\ResolverInterface
;
14
18
class
DynamicWeight
implements
ResolverInterface
19
{
23
public
function
resolve
(
24
Field
$field,
25
$context,
26
ResolveInfo
$info
,
27
array
$value
=
null
,
28
array $args =
null
29
) {
30
$result
=
null
;
31
if
(
$value
[
'type_id'
] === Bundle::TYPE_CODE) {
32
$result
= isset(
$value
[
'weight_type'
]) ? !
$value
[
'weight_type'
] :
null
;
33
}
34
35
return
$result
;
36
}
37
}
$result
$result
Definition:
product_configurable_not_available_rollback.php:26
Magento\Framework\GraphQl\Query\ResolverInterface
Definition:
ResolverInterface.php:18
Magento\Bundle\Model\Product\Type
Definition:
Type.php:25
Magento\Framework\GraphQl\Schema\Type\ResolveInfo
Definition:
ResolveInfo.php:13
Magento\BundleGraphQl\Model\Resolver\Product\Fields\DynamicWeight
Definition:
DynamicWeight.php:18
Magento\Framework\GraphQl\Config\Element\Field
Definition:
Field.php:15
$value
$value
Definition:
gender.phtml:16
$info
foreach( $_productCollection as $_product)() ?>" class $info
Definition:
listing.phtml:52
Magento\BundleGraphQl\Model\Resolver\Product\Fields\DynamicWeight\resolve
resolve(Field $field, $context, ResolveInfo $info, array $value=null, array $args=null)
Definition:
DynamicWeight.php:23
Magento\BundleGraphQl\Model\Resolver\Product\Fields
Definition:
DynamicPrice.php:8