Histórico de ofertas laborales
Te facilitamos la relación de los procesos de selección cerrados y el detalle de los perfiles profesionales que hemos solicitado para incorporarse a nuestra empresa.
Se ha producido un error al procesar la plantilla.
The following has evaluated to null or missing: ==> titleSel.selectSingleNode(rootElement) [in template "20155#20195#427712" at line 67, column 50] ---- Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign title = titleSel.selectSingle... [in template "20155#20195#427712" at line 67, column 33] ----
1<#assign groupId = getterUtil.getLong(groupId)>
2<#assign group = serviceLocator.findService("com.liferay.portal.kernel.service.GroupLocalService").getGroup(groupId)>
3<#assign theme_display = request.getAttribute("LIFERAY_SHARED_THEME_DISPLAY")>
4<#assign imagesFolder = theme_display.getPathThemeImages()>
5
6<#if locale == "en_US">
7 <#assign newLocale = "ca_ES">
8<#else>
9 <#assign newLocale = locale>
10</#if>
11
12<#function miliSeconds dateString, firstDate>
13 <#assign params = dateString?split(":")>
14
15 <#if params?size == 2>
16 <#assign param1 = params[0]>
17 <#assign param2 = params[1]>
18 <#assign param1 = getterUtil.getLong(param1)*3600000>
19 <#assign param2 = getterUtil.getLong(param2)*60000>
20 <#assign finalMilSec = param1 + param2>
21 <#assign finalMilSecLong = getterUtil.getLong(finalMilSec)>
22 <#assign resultLong = firstDate + finalMilSecLong>
23
24 <#return resultLong>
25 </#if>
26</#function>
27<#if entries?has_content>
28 <#if locale != "en_US">
29 <div class="choose-ticket__search-bar">
30 <div class="form__field">
31 <div class="form__field__control f__text__6_wrapper">
32 <input id="oferta-laboral-search-input" type="text" placeholder='<@liferay.language key="offer.helperSearchHistoric"/>
33 ' value=""/>
34
35 <button id="f__button__6" type="button" class="button button--a" onclick="javascript:historicalJobOffers.search();">
36 <img class="button__icon" src="${imagesFolder}/basic/16px/svg/search-white.svg" alt="<@liferay.language key="label.search"/>
37 ">
38 <span class="button__label">
39 <@liferay.language key="label.search"/>
40 </span>
41 </button>
42 </div>
43 </div>
44 </div>
45 </#if>
46 <#assign today = .now?date>
47
48 <#if locale != "en_US">
49 <ul id="historical-job-offers-ul" class="list list--links list--links-b">
50 </#if>
51 <#assign count = 0>
52 <#foreach curEntry in entries>
53 <#assign renderer = curEntry.getAssetRenderer()>
54 <#assign className = renderer.getClassName()>
55
56 <#assign dataPub = "">
57 <#assign dataExp = "">
58 <#assign isExpired = false>
59
60 <#if className == "com.liferay.journal.model.JournalArticle">
61 <#assign journalArticle = renderer.getArticle()>
62 <#assign journalArticleId = journalArticle.getArticleId()>
63 <#assign document = saxReaderUtil.read(journalArticle.getContent())>
64 <#assign rootElement = document.getRootElement()>
65 <#assign title = "">
66 <#assign titleSel = saxReaderUtil.createXPath("dynamic-element[@name='position']/dynamic-content[@language-id='" + newLocale + "']")>
67 <#assign title = titleSel.selectSingleNode(rootElement).getStringValue()>
68
69 <#assign numReferencia = "">
70 <#assign numReferenciaSel = saxReaderUtil.createXPath("dynamic-element[@name='reference_number']/dynamic-content[@language-id='" + newLocale + "']")>
71 <#assign numReferencia = numReferenciaSel.selectSingleNode(rootElement).getStringValue()>
72 <#assign referenceSel = saxReaderUtil.createXPath("dynamic-element[@name='reference_text']/dynamic-content[@language-id='" + newLocale + "']")>
73 <#if referenceSel.selectSingleNode(rootElement)?has_content>
74 <#assign reference = referenceSel.selectSingleNode(rootElement).getStringValue()>
75 <#else>
76 <#assign reference = "">
77 </#if>
78 <#assign refNumSel = saxReaderUtil.createXPath("dynamic-element[@name='reference_text']/dynamic-element[@name='reference_number']/dynamic-content[@language-id='" + newLocale + "']")>
79 <#if refNumSel.selectSingleNode(rootElement)?has_content>
80 <#assign refNumber = refNumSel.selectSingleNode(rootElement).getStringValue()>
81 <#else>
82 <#assign refNumber = "">
83 </#if>
84 <#assign sumissionSel = saxReaderUtil.createXPath("dynamic-element[@name='text_submission']/dynamic-content[@language-id='" + newLocale + "']")>
85 <#if sumissionSel.selectSingleNode(rootElement)?has_content>
86 <#assign sumission = sumissionSel.selectSingleNode(rootElement).getStringValue()>
87 <#else>
88 <#assign sumission = "">
89 </#if>
90 <#assign requestDateSel = saxReaderUtil.createXPath("dynamic-element[@name='text_submission']/dynamic-element[@name='request_date']/dynamic-content[@language-id='" + newLocale + "']")>
91 <#if requestDateSel.selectSingleNode(rootElement)?has_content>
92 <#assign requestDate = requestDateSel.selectSingleNode(rootElement).getStringValue()>
93 <#else>
94 <#assign requestDate = "">
95 </#if>
96 <#assign link = renderer.getURLViewInContext(renderRequest, renderResponse, "")>
97 <#assign pubDateSel = saxReaderUtil.createXPath("dynamic-element[@name='pubDate']/dynamic-content[@language-id='" + newLocale + "']")>
98 <#assign dataPub = pubDateSel.selectSingleNode(rootElement).getStringValue()>
99 <#assign expDateSel = saxReaderUtil.createXPath("dynamic-element[@name='expDate']/dynamic-content[@language-id='" + newLocale + "']")>
100 <#assign dataExp = expDateSel.selectSingleNode(rootElement).getStringValue()>
101 <#assign timePubSel = saxReaderUtil.createXPath("dynamic-element[@name='pubTime']/dynamic-content[@language-id='" + newLocale + "']")>
102 <#assign timePub = timePubSel.selectSingleNode(rootElement).getStringValue()>
103 <#assign timeExpSel = saxReaderUtil.createXPath("dynamic-element[@name='expTime']/dynamic-content[@language-id='" + newLocale + "']")>
104 <#assign timeExp = timeExpSel.selectSingleNode(rootElement).getStringValue()>
105 <#assign isExpiredSel = saxReaderUtil.createXPath("dynamic-element[@name='isExpired']/dynamic-content[@language-id='" + newLocale + "']")>
106 <#assign isExpired = isExpiredSel.selectSingleNode(rootElement).getStringValue()>
107
108 <#-- Data publicació i expiració -----------------------------------------------
109 -->
110
111 <#if (dataPub?has_content)>
112 <#if timePub?? && timePub?has_content>
113 <#assign timePubDate = timePub?date["HH:mm"]>
114 <#assign timePubFormat = timePubDate?string["HH:mm"]>
115 <#else>
116 <#assign timePubDate = "">
117 <#assign timePubFormat = "">
118 </#if>
119 <#attempt>
120 <#assign dataPub = dataPub?date["yyyy-MM-dd"]>
121
122
123 <#if timePubFormat?has_content && timePubFormat != "">
124 <#assign dataPubMil = miliSeconds(timePubFormat dataPub?long)>
125 <#assign dataPub = dateUtil.newDate(getterUtil.getLong(dataPubMil))>
126 </#if>
127 <#assign dataPubMil = dataPub?long-timeZoneUtil.getTimeZone("Europe/Madrid").getOffset(dataPub?long)>
128 <#recover>
129 </#attempt>
130 </#if>
131
132
133 <#if (dataExp?has_content)>
134 <#if timeExp?? && timeExp?has_content>
135 <#assign timeExpDate = timeExp?date["HH:mm"]>
136 <#assign timeExpFormat = timeExpDate?string["HH:mm"]>
137 <#else>
138 <#assign timeExpDate = "">
139 <#assign timeExpFormat = "">
140 </#if>
141 <#attempt>
142 <#assign dataExp = dataExp?date["yyyy-MM-dd"]>
143
144 <#if timeExpFormat?has_content && timeExpFormat != "">
145 <#assign dataExpMil = miliSeconds(timeExpFormat dataExp?long)>
146 <#assign dataExp = dateUtil.newDate(getterUtil.getLong(dataExpMil))>
147 </#if>
148 <#assign dataExpMil = dataExp?long-timeZoneUtil.getTimeZone("Europe/Madrid").getOffset(dataExp?long)>
149 <#recover>
150 </#attempt>
151 </#if>
152
153
154 <#if dataPub?has_content && dataExp?has_content && (today?long>=dataPubMil) && (today?long>dataExpMil) || getterUtil.getBoolean(isExpired)>
155
156 <#if title != "">
157 <#assign count = 1>
158
159 <#if locale != "en_US">
160
161 <li class="list__item oferta-laboral" data-title="${title}" data-fechapub="${dataPubMil}">
162 <a class="list__label" href="${link}">
163
164 ${numReferencia} - ${title}
165 <#--$dataPub
166 -->
167 </a>
168 <#if reference?has_content>
169 <p>
170 ${reference}: ${refNumber} <#if sumission>- ${sumission}</#if><#if requestDate>: ${requestDate}</#if>
171 </p>
172 </#if>
173 </li>
174 </#if>
175 </#if>
176 </#if>
177 </#if>
178 </#foreach>
179 <#if locale != "en_US">
180 </ul>
181 </#if>
182 <#if locale == "en_US" && count != 0>
183 <div class="content intro">
184 <p>
185 <@liferay.language key="no.offerslaborals.redirect"/>
186 </p>
187
188 </div>
189 <#elseif count == 0>
190 <div class="content intro">
191 <p>
192 <@liferay.language key="no.offerslaborals.redirect"/>
193 </p>
194
195 </div>
196 </#if>
197<#else>
198 <div class="content intro">
199 <p>
200 <@liferay.language key="offer.laboralHistoric.noResults"/>
201 </p>
202 </div>
203</#if>
204
205<div class="content intro no-results" style="display:none;">
206 <p>
207 <@liferay.language key="offer.laboralHistoric.noResults.js"/>
208 </p>
209
210</div>
211 <script type="text/javascript">
212
213 $(document).ready(function(){
214 historicalJobOffers.init();
215 });
216
217 historicalJobOffers = {
218 init: function(){
219 if($("li.oferta-laboral").length==0){
220 return;
221 }
222
223 var maxDate = new Date("3000/06/25");
224 var orderList = $("li.oferta-laboral").sort(function(a,b){
225 var date1 = $(a).data("fechapub")==""?maxDate:new Date($(a).data("fechapub"));
226 var date2 = $(b).data("fechapub")==""?maxDate:new Date($(b).data("fechapub"));
227 //console.log($(a).data("fechapub"));
228 //console.log($(b).data("fechapub"));
229 //console.log(date1 + "----" + date2);
230 return date2 - date1;
231 });
232
233
234 var offers = [];
235 var year = null;
236 jQuery.each(orderList,function(index,li){
237 var date = new Date($(li).data("fechapub"));
238 if(year != date.getFullYear()){
239 year = date.getFullYear();
240 offers.push('<li><h2 class="title title--2" data-year-title="' + year + '">' + year + '</h2></li>');
241 }
242 //$(li).data("year",year);
243 li.dataset.year = year;
244 offers.push(li);
245 });
246
247 $("#historical-job-offers-ul").html(offers);
248
249 $('#oferta-laboral-search-input').keyup(function(event){
250 <#--if(event.which == 13)
251--> <#-- {
252--> event.preventDefault();
253 this.search();
254 <#-- }
255--> }.bind(this));
256 },
257 search: function(){
258 $('.no-results').hide();
259 var text = $("#oferta-laboral-search-input").val();
260 if(text==""){
261 $("[data-year-title]").show();
262 $(".oferta-laboral").show();
263 }else{
264 $("[data-year-title]").hide();
265 var found = false;
266 $(".oferta-laboral").each(function(index,item){
267 var title = $(item).data("title");
268 if(title.toUpperCase().includes(text.toUpperCase())){
269 var year = $(item).data("year");
270 $("[data-year-title='" + year + "']").show();
271 $(item).show();
272 found = true;
273 }else{
274 $(item).hide();
275 }
276 });
277 if(!found){
278 var txt = "<@liferay.language key="offer.laboralHistoric.noResults.js"/>";
279 txt = txt.replace("@@@@", text);
280 $('.no-results p').html(txt);
281 $('.no-results').show();
282 }
283 }
284 }
285 };
286
287 </script>
Cerrar
© OpenStreetMap contributors