Home
处理模板时发生错误。
Syntax error in template "20095#20120#43515" in line 142, column 6: Unexpected end of file reached. You have an unclosed #function or #macro.
1<#macro buildChildrenNavItems
2 displayDepth
3 navItem
4 menuItem = true
5 navItemLevel = 2
6>
7 <#assign
8 portletDisplay = themeDisplay.getPortletDisplay()
9 />
10
11 <#list navItem.getChildren() as childNavigationItem>
12 <#assign
13 nav_child_css_class = ""
14 />
15
16 <#if !childNavigationItem.isChildSelected() && childNavigationItem.isSelected()>
17 <#assign
18 nav_child_css_class = "active selected"
19 />
20 </#if>
21
22 <li class="${nav_child_css_class}" id="layout_${portletDisplay.getId()}_${childNavigationItem.getLayoutId()}" role="presentation">
23 <#if childNavigationItem.isBrowsable()>
24 <#if menuItem>
25 <a class="dropdown-item" href="${childNavigationItem.getURL()}" ${childNavigationItem.getTarget()} role="menuitem">${childNavigationItem.getName()}</a>
26 <#else>
27 <a class="dropdown-item" href="${childNavigationItem.getURL()}" ${childNavigationItem.getTarget()}>${childNavigationItem.getName()}</a>
28 </#if>
29 <#else>
30 <span class="dropdown-item font-weight-semi-bold navigation-menu__submenu">${childNavigationItem.getName()}</span>
31 </#if>
32 </li>
33
34 <#if childNavigationItem.hasBrowsableChildren() && ((displayDepth == 0) || (navItemLevel < displayDepth))>
35 <ul class="list-unstyled pl-3">
36 <@buildChildrenNavItems
37 displayDepth=displayDepth
38 menuItem=false
39 navItem=childNavigationItem
40 navItemLevel=(navItemLevel + 1)
41 />
42 </ul>
43 </#if>
44 </#list>
45</#macro>
46
47<#macro buildNavigation
48 branchNavItems
49 cssClass
50 displayDepth
51 includeAllChildNavItems
52 navItemLevel
53 navItems
54>
55
56<#if !entries?has_content>
57 <#if themeDisplay.isSignedIn()>
58 <div class="alert alert-info">
59 <@liferay.language key="there-are-no-menu-items-to-display" />
60 </div>
61 </#if>
62<#else>
63 <#assign
64 portletDisplay = themeDisplay.getPortletDisplay()
65
66 navbarId = "navbar_" + portletDisplay.getId()
67 />
68
69 <div id="${navbarId}">
70 <ul aria-label="<@liferay.language key="site-pages" />" class="navbar-blank navbar-nav navbar-site" role="menubar">
71 <#assign navItems = entries />
72
73 <#list navItems as navItem>
74 <#assign showChildrenNavItems = (displayDepth != 1) && navItem.hasBrowsableChildren() />
75
76 <#if navItem.isBrowsable() || showChildrenNavItems>
77 <#assign
78 nav_item_attr_has_popup = ""
79 nav_item_caret = ""
80 nav_item_css_class = "lfr-nav-item nav-item"
81 nav_item_href_link = ""
82 nav_item_link_css_class = "nav-link text-truncate"
83 />
84
85 <#if showChildrenNavItems>
86 <#assign nav_item_attr_has_popup = "aria-haspopup='true'" />
87
88 <#assign nav_item_caret>
89 <span class="lfr-nav-child-toggle">
90 <@liferay_aui.icon
91 image="angle-down"
92 markupView="lexicon"
93 />
94 </span>
95 </#assign>
96
97 <#assign
98 nav_item_css_class = "${nav_item_css_class} dropdown"
99 nav_item_link_css_class = "${nav_item_link_css_class} dropdown-toggle"
100 />
101 </#if>
102
103 <#if navItem.isBrowsable()>
104 <#assign nav_item_href_link = "href='${navItem.getURL()}'" />
105 </#if>
106
107 <#if !navItem.isChildSelected() && navItem.isSelected()>
108 <#assign
109 nav_item_css_class = "${nav_item_css_class} selected active"
110 />
111 </#if>
112
113 <li class="${nav_item_css_class}" id="layout_${portletDisplay.getId()}_${navItem.getLayoutId()}" role="presentation">
114 <a ${nav_item_attr_has_popup} class="${nav_item_link_css_class}" ${nav_item_href_link} ${navItem.getTarget()} role="menuitem">
115 <span class="text-truncate"><@liferay_theme["layout-icon"] layout=navItem.getLayout() /> ${navItem.getName()} ${nav_item_caret}</span>
116 </a>
117
118 <#if showChildrenNavItems>
119 <ul aria-expanded="false" class="child-menu dropdown-menu" role="menu">
120 <@buildChildrenNavItems
121 displayDepth=displayDepth
122 navItem=navItem
123 />
124 </ul>
125 </#if>
126 </li>
127 </#if>
128 </#list>
129 </ul>
130 </div>
131
132 <@liferay_aui.script use="liferay-navigation-interaction">
133 var navigation = A.one('#${navbarId}');
134
135 Liferay.Data.NAV_INTERACTION_LIST_SELECTOR = '.navbar-site';
136 Liferay.Data.NAV_LIST_SELECTOR = '.navbar-site';
137
138 if (navigation) {
139 navigation.plug(Liferay.NavigationInteraction);
140 }
141 </@>
142</#if>
欢迎来到Liferay
Your portal for all things OceanX