Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
validateAttributeScope example
if
(
$list
->length === 0
)
{
return
[
]
;
}
$elements
=
[
]
;
foreach
(
$list
as
$item
)
{
$element
=
[
]
;
// attributes
$element
[
'scope'
]
= self::
validateAttributeScope
(
$item
->
getAttribute
(
'scope'
)
)
;
$element
[
'isRequired'
]
= self::
validateBooleanAttribute
(
$item
->
getAttribute
(
'required'
)
,
false
)
;
$element
[
'type'
]
= self::
validateTextAttribute
(
$item
->
getAttribute
(
'type'
)
,
'text'
)
;