[MGNLSTK-938] Search result generate FTL exception Created: 04/Apr/12  Updated: 27/Apr/12  Resolved: 12/Apr/12

Status: Closed
Project: Magnolia Standard Templating Kit (closed)
Component/s: None
Affects Version/s: 2.0.2
Fix Version/s: 2.0.3

Type: Bug Priority: Major
Reporter: Eric Hechinger Assignee: Federico Grilli
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screen Shot 2012-04-04 at 2.42.17 PM.png    
Template:
Acceptance criteria:
Empty

 Description   

Accessing the following search result :
http://demoauthor.magnolia-cms.com/demo-project/service/search-result.html?queryStr=features

FreeMarker template error!

Error on line 18, column 5 in templating-kit/components/features/searchResult.ftl
item.title!item.@name is undefined.
It cannot be assigned to itemTitle
The problematic instruction:
----------
==> assignment: itemTitle=item.title!item.@name [on line 18, column 5 in templating-kit/components/features/searchResult.ftl]
in user-directive assignItemValues [on line 46, column 17 in templating-kit/components/features/searchResult.ftl]
----------

Java backtrace for programmers:
----------
freemarker.core.InvalidReferenceException: Error on line 18, column 5 in templating-kit/components/features/searchResult.ftl
item.title!item.@name is undefined.
It cannot be assigned to itemTitle
at freemarker.core.Assignment.accept(Assignment.java:111)
at freemarker.core.Environment.visit(Environment.java:221)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:221)
at freemarker.core.Macro$Context.runMacro(Macro.java:172)
at freemarker.core.Environment.visit(Environment.java:614)
at freemarker.core.UnifiedCall.accept(UnifiedCall.java:106)
at freemarker.core.Environment.visit(Environment.java:221)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:221)
at freemarker.core.Iter


Generated at Mon Feb 12 07:31:50 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.