[MAGNOLIA-6042] Add TemplateCategory and related Utils to main so developers can use template categories without having to install STK Created: 13/Jan/15  Updated: 16/Apr/19  Resolved: 19/Jan/15

Status: Closed
Project: Magnolia
Component/s: rendering, templating
Affects Version/s: None
Fix Version/s: 5.4

Type: Task Priority: Neutral
Reporter: Philip Mundt Assignee: Philip Mundt
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Relates
dependency
is depended upon by MGNLRSSAGG-189 Remove implicit dependency to STK Closed
is depended upon by MGNLCAT-147 Remove dependency to STK Closed
is depended upon by MGNLSTK-1462 Adjust all templates to templateType ... Closed
duplicate
is duplicated by MAGNOLIA-6037 Add default categorization for templa... Closed
Template:
Acceptance criteria:
Empty
Task DoR:
Empty
Date of First Response:
Epic Link: Extract STK functionality

 Description   

"Template category support" and related utils are currently residing in STK, which makes it difficult to use any form of categorization of templates e.g. for template availability without having STK installed.

These classes info.magnolia.module.templatingkit.templates.category.TemplateCategory and info.magnolia.module.templatingkit.templates.category.TemplateCategoryUtil should therefore move to magnolia_main and we should also add a PageTemplateDefinition adding a "contract" for category and subcategory.

Todos:

  • Rename "Template Category" to "Template Type"
  • TemplateCategoryUtil should be a component – stick to pattern of "TemplatingFunctions"


 Comments   
Comment by Christopher Zimmermann [ 19/Jan/15 ]

In TemplatingFunctions#siteRoot methods, Correct comments by updating name in mentions of "template categories"

Why are DefaultTemplateType constants changed to lowercase? I would have expected upper. home vs HOME?

In TemplateTypeFunctionsTest#findParentWithTemplateType, I think this node should be added to childNode, not pageNode
Node childChildPageNode = pageNode.addNode("some-child-of-a-child-path", NodeTypes.Page.NAME);

Generated at Mon Feb 12 04:10:46 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.