-
Bug
-
Resolution: Unresolved
-
Neutral
-
None
-
1.2
-
None
-
demoauthor.magnolia-cms.com
When you use a (YAML) page definition prototype referenced in a site definition, (some of?) its values are not available in the page definitions of that site
Steps to reproduce
- Go to demoauthor.magnolia-cms.com
- Navigate to /modules/multisite/config/sites/travel/templates and make sure that the prototypeId property is pointing to travel-demo:pages/prototype
- Open the prototype in the Web Dev > Resource Files app: The "renderType" is set to "site" here in the prototype
- Edit the standard.yaml page definition of travel-demo, and remove the "renderType" entry
Expected behaviour
Since the renderType is defined in the prototype, this value should be used for all page definitions that don't overwrite it. The same applies to any other definition in the prototype (e.g. "type").
Experienced behaviour
When you open the "/travel/about" page, you will see the following error:
javax.servlet.ServletException: info.magnolia.rendering.engine.RenderException: No renderType defined for definition [info.magnolia.module.site.templates.PageTemplateDefinition@3a97f6af[id=travel-demo:pages/standard,name=standard,renderType=<null>,description=<null>,title=<null>,templateScript=<null>,autoGeneration=info.magnolia.rendering.template.configured.ConfiguredAutoGeneration@1d733e61[content={},generatorClass=<null>]]]
When you leave the renderType in the standard.yaml page template definition, but remove the "type", you would expect the type to be set to the value of the prototype. Instead the default type value ("content") is set.
The behaviour is the same in CE with the site module and in EE Pro with the multisite module.
Strangely enough, the inheritance from the prototype works for instance for the "templateScript" attribute.