An error occurred while processing the template.
Expression imatge is undefined on line 166, column 100 in 10155#10193#6192246.
1<#-- Carreguem la macro getPathForPlugins per obtenir les rutes a les carpetes css, images i js dels plugins que necessitem-->
2<#assign serviceContext = staticUtil["com.liferay.portal.service.ServiceContextThreadLocal"].getServiceContext() />
3<#assign layout = serviceContext.getThemeDisplay() />
4
5
6<#assign fullTemplatesPath = layout.getPathThemeRoot() + "_SERVLET_CONTEXT_/templates" />
7<#include "${fullTemplatesPath}/util/getPathForPlugins.ftl" />
8
9<#assign jsJQueryPath = getPathForPlugins('jquery','js','')?trim />
10
11<style>
12
13.edit-article{
14 margin-top:10px !important;
15 position:absolute;
16 z-index:10;
17 right:0px;
18}
19 /*Navegació pròpia de Liferay, no adjuntar*/
20 .aui .clearfix::before, .aui .clearfix::after {
21 content: "";
22 display: table;
23 line-height: 0;
24}
25.taglib-page-iterator .search-results {
26 float: left;
27 line-height: 46px;
28 margin-left: 10px;
29}
30.aui small {
31 font-size: 85%;
32}
33
34.titol-bold {
35 font-weight: bold;
36}
37
38.taglib-page-iterator .lfr-pagination-buttons {
39 float: right;
40 margin: 0;
41}
42.taglib-page-iterator .lfr-pagination-config {
43 float: left;
44 line-height: 46px;
45}
46 /*FI navegació Liferay*/
47 .article-seguit {
48 width:100%;
49 box-sizing: content-box;
50 }
51 .article-seguit .noticia {
52 display: inline-table;
53 margin-bottom: 5px;
54 width: 32.9%;
55 }
56 /*Cercador i categories*/
57 .noticia .data {
58 color: #fff;
59 padding: 5px;
60 position: absolute;
61 right: 0;
62 text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.8);
63 z-index: 9;
64 }
65 .noticia div.imatge {
66 background-position: center;
67 }
68 .categories select {
69 width: 100%;
70 }
71 .cercador {
72 margin-bottom:10px;}
73 .cercador .navbar-search {
74 width:100%;
75 margin-top:0px;}
76 .cercador input {
77 font-family:"FontAwesome" !important;
78 }
79 @media (min-width: 979px) and (max-width: 1200px) {
80 .article-seguit .noticia {
81 width:49.5%;}
82 }
83 @media (max-width: 978px) {
84 .article-seguit .noticia {
85 width:49.5%;}
86 }
87 @media (max-width: 480px) {
88 .article-seguit .noticia {
89 width:100%;}
90 .noticia .data {
91 left: 0;
92 bottom: 0;
93 }
94 }
95
96</style>
97
98<#if entries?has_content >
99
100 <div class="article-seguit">
101
102 <#list entries as entry >
103 <#assign renderer = entry.getAssetRenderer() />
104 <#assign className = renderer.getClassName() />
105
106 <#if (className == "com.liferay.portlet.journal.model.JournalArticle" ) >
107
108 <#--plantilla de URL de la vista -->
109 <#include "${fullTemplatesPath}/assets/viewURL.ftl" />
110
111
112 <#assign journalArticle = renderer.getArticle() />
113 <#assign document = saxReaderUtil.read(journalArticle.getContentByLocale(localeUtil.toLanguageId(locale))) />
114 <#assign rootElement = document.getRootElement() />
115
116 <#-- plantilla de URL de la edición -->
117 <#include "${fullTemplatesPath}/assets/editURL.ftl" />
118
119 <#list rootElement.elements() as dynamicElement >
120
121 <#if "Noticia" == dynamicElement.attributeValue("name") >
122 <#assign noticia = dynamicElement.element("dynamic-content").getText() />
123 </#if>
124
125 <#if "Resum" == dynamicElement.attributeValue("name") >
126 <#assign resum = dynamicElement.element("dynamic-content").getText() />
127 </#if>
128
129 <#if "imatge" == dynamicElement.attributeValue("name") >
130 <#assign imatge = dynamicElement.element("dynamic-content").getText() />
131 <#if imatge == "" >
132 <#assign imatge = themeDisplay.getPathThemeImages() + "/sensefoto.png" />
133 </#if>
134 </#if>
135 </#list>
136
137 <#-- Obtenim la categoria pare si és notícia
138 Després del parse tenim definida una variable $cat
139 amb el valor de la categoria de primer nivell de notícies-->
140
141 <#include "${fullTemplatesPath}/assets/getCat1stLevelNews.ftl" />
142
143 <#-- Preparació url dels enllaços a les categories -->
144 <#assign wordCategories = languageUtil.format(locale,'categories-nom-page','') />
145 <#assign catUrl = "/web/focus/" + wordCategories + "?p_p_id=122_INSTANCE_4xkc6d8xhKAC&p_p_lifecycle=0&p_p_state=normal&p_p_mode=view&p_p_col_id=column-1&p_r_p_564233524_resetCur=true&p_r_p_564233524_categoryId=" />
146
147
148 <#-- Obtenim la data de publicació -->
149 <#assign dataPub = entry.getPublishDate()?datetime?string("dd.MM.yyyy") />
150
151 <div class="noticia">
152 <#if (cat != "") >
153 <div class="tipus"><a href="${catUrl}${categoriaObj.getCategoryId()}">${cat}</a></div>
154 </#if>
155
156 <div class="lfr-meta-actions asset-actions edit-article">
157 <#-- plantilla de la vista del botón -->
158 <#assign template_view_button = fullTemplatesPath + "/assets/viewEditButton.ftl" />
159 <#include template_view_button >
160 </div>
161
162 <#if (dataPub?length == 10) >
163 <div class="data">${dataPub}</div>
164 </#if>
165 <a href="${viewURL}/maximized">
166 <div class="imatge" style='background-image:url("${imatge}");'></div>
167 <div class="titular titol-bold">${entry.getTitle(locale)}</div>
168 </a>
169 </div>
170 </#if>
171 </#list>
172
173</div>
174</#if> <#-- Final entries?has_content -->
175
176<script src="${jsJQueryPath}/jquery-1.11.3.min.js"></script>
177<script>
178// Per treure el text que indica que s'està filtrant per categoria
179var catObj = $(".taglib-categorization-filter em").get(0);
180$(".taglib-categorization-filter").html($(catObj).html());
181</script>
—
30 Items per page