Details
-
Bug
-
Resolution: Won't Fix
-
High
-
5.2-alpha1
Description
Testing demo I've came across an weird (imho) behaviour, where I've trashed the footer, and recover it (to the same location) and demo was throwing an exception:
An exception has been thrown during the rendering of a template ("Could not find 'location' with identifier '60'") in "{% extends "eZDemoBundle::pagelayout.html.twig" %} {% block content %} {{ viewResult|raw }} {% endblock %}". 500 Internal Server Error - Twig_Error_Runtime 1 linked Exception: NotFoundException
I know its possible to change in the twig template the location id for the new id.
However this can happen to an object that is used across the system in multiple templates and controllers.
Shouldn't there be an option to "undo" or restore to the exact location (id)?
Or a warning in case the object is specific loaded.
steps:
1 - install demo w/o content 2 - open demo home page 3 - verify page displays as expected 4 - on admin interface verify that content object "footer" as location id = 60 5 - trash Content object "footer" 6 - open demo home page 7 - verify an (expected) twig exception was thrown 8 - on admin interface recover Content object "footer" from trash to the original location (or a new one) 9 - verify the id as changed 10- open demo home page 11- verify the twig exception still happens