Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
recomputeSingleEntityChangeSet example
// Entity Insertions
foreach
(
$uow
->
getScheduledEntityInsertions
(
)
as
$category
)
{
if
(
!
(
$category
instanceof Category
)
)
{
continue
;
}
$category
=
$this
->
setPathForCategory
(
$category
)
;
$md
=
$em
->
getClassMetadata
(
\
get_class
(
$category
)
)
;
$uow
->
recomputeSingleEntityChangeSet
(
$md
,
$category
)
;
}
// Entity updates
foreach
(
$uow
->
getScheduledEntityUpdates
(
)
as
$category
)
{
if
(
!
(
$category
instanceof Category
)
)
{
continue
;
}
$changeSet
=
$uow
->
getEntityChangeSet
(
$category
)
;
if
(
!
isset
(
$changeSet
[
'parent'
]
)
)
{