You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The route scheme for Page is /{menuElement.slug}/{slug} (and just /{slug} for MenuElement). So, when I modify the $slug on a MenuElement instance, I need a redirection to be added to umanit_seo_url_history for both my MenuElement and the Pages linked to it.
I've looked at the UrlHistoryWriter->postLoad() method that adds entities related to the entity being updated to the cache, to allow historization of dependencies on onFlush event and I'm not quite sure the way it's written now allows it to work.
From what I gather, using my example:
we get the Route for the current entity (MenuElement, or rather MenuElementInstit in my case) and create a reflection entity
we then loop on the route parameters (in my case, for MenuElementInstit, it's just slug), get the reflection property for each one from the reflection entity
for each annotation on $slug, we look for the targetEntity property...
Which $slug doesn't have, because the targetEntity is on the $pages property.
I'm not sure why we are looking for a dependency through the route parameters.
The text was updated successfully, but these errors were encountered:
develop
I have these two entities, with a
ManyToOne
relationship, bidirectionnal:The route scheme for
Page
is/{menuElement.slug}/{slug}
(and just/{slug}
forMenuElement
). So, when I modify the$slug
on aMenuElement
instance, I need a redirection to be added toumanit_seo_url_history
for both myMenuElement
and thePages
linked to it.I've looked at the
UrlHistoryWriter->postLoad()
method that adds entities related to the entity being updated to the cache, to allow historization of dependencies ononFlush
event and I'm not quite sure the way it's written now allows it to work.From what I gather, using my example:
Route
for the current entity (MenuElement
, or ratherMenuElementInstit
in my case) and create a reflection entityMenuElementInstit
, it's justslug
), get the reflection property for each one from the reflection entity$slug
, we look for thetargetEntity
property...Which
$slug
doesn't have, because thetargetEntity
is on the$pages
property.I'm not sure why we are looking for a dependency through the route parameters.
The text was updated successfully, but these errors were encountered: