[MGNLUI-387] TemplateSelectorField queries for available templates using the wrong node Created: 10/Dec/12  Updated: 11/Feb/13  Resolved: 13/Dec/12

Status: Closed
Project: Magnolia UI
Component/s: forms
Affects Version/s: None
Fix Version/s: 5.0

Type: Bug Priority: Critical
Reporter: Tobias Mattsson Assignee: Federico Grilli
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
relation
is related to MGNLSTK-1050 Template availability no longer worki... Closed
is related to MGNLSTK-1052 Template availability expects to be p... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled

 Description   

In 4.5 the node was created and assigned the default template, only afterwards did the user make a selection by changing the template in the template column.

In 5.0 we're instead presenting a dialog first where the user can select the template to assign to the node once its created.

This has produced a bug in the current code base where TemplateSelectorField queries for available templates using the parent node.

info.magnolia.rendering.template.assignment.TemplateDefinitionAssignment#getAvailableTemplates(Node) is not supposed to be used to test for available nodes in children of the passed node.



 Comments   
Comment by Tobias Mattsson [ 10/Dec/12 ]

The problems reported in MGNLSTK-1050 is a direct consequence of this and its fix only compensates for this bug.

Generated at Mon Feb 12 08:36:23 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.