Trailer Rear Drive Assist
Virhe tapahtui prosessoidessa esitysmallia.
The following has evaluated to null or missing:
==> assetEntryQuery  [in template "20116#20152#50391" at line 270, column 31]

----
Tip: If the failing expression is known to be 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 search = assetEntryQuery.setC...  [in template "20116#20152#50391" at line 270, column 13]
----
1<!-- START: Project Template --> 
2 
3<style> 
4    /*START: Related Projects*/ 
5    .b-related-projects-container{ 
6        background: #f4f4f4; 
7        padding: 0px 20px 30px 20px; 
8        margin-bottom: 20px; 
9
10 
11    .b-related-project { 
12        margin-bottom: 10px; 
13
14 
15    .b-related-project a{ 
16        color: #444; 
17        font-weight: 700; 
18
19    /*END: Related Projects*/ 
20 
21    .researchAreaHeader{ 
22        font-family: Georgia, serif; 
23        font-size: 24px!important; 
24        color: #cd1129!important; 
25        font-weight: 400; 
26        line-height: 1.4; 
27
28 
29    .researchAreaTitle{ 
30        font-family: 'Open Sans', arial, sans-serif; 
31        font-weight: 700; 
32        font-size: 16px; 
33        line-height: 1.1em; 
34        color: #444; 
35
36 
37    .b-related-researchAreas{ 
38        margin-bottom: 10px; 
39
40 
41    #titleContainer .title h1{ 
42        font-family: 'Open Sans', Arial, sans-serif; 
43        font-weight: 700; 
44        font-size: 38px; 
45        line-height: 1em; 
46
47 
48    #contentType{ 
49        color: #999; 
50        margin-bottom: 30px; 
51        font-size: 18px; 
52        font-weight: 700; 
53        margin-top: -8px; 
54        font-family: 'open sans', arial, sans-serif; 
55        line-height: 1.4; 
56
57 
58    .item h3, .b-publications--title{ 
59        font-family: Georgia, serif; 
60        font-size: 24px; 
61        color: #cd1129; 
62        font-weight: 400; 
63        margin-bottom: 5px; 
64        line-height: 1.4; 
65
66 
67    .media-item{ 
68        margin-right: 20px; 
69        margin-bottom: 10px; 
70        height: 100%; 
71
72 
73    .pull-left{ 
74        float: left; 
75        display: block; 
76
77 
78    .media{ 
79        zoom: 1; 
80        overflow: hidden; 
81        margin-top: 15px; 
82        width: 145px; 
83        height: 100px; 
84        background: #0a7cbc; 
85        position: relative; 
86
87 
88    .media:first-child { 
89        margin-top: 0; 
90
91 
92    .media-item .glyphicon{ 
93        font-size: 45px; 
94        color: #fff; 
95        margin: 25px 48px; 
96
97 
98    .itemLink{ 
99        position: absolute; 
100        top: 0; 
101        bottom: 0; 
102        left: 0; 
103        right: 0; 
104
105 
106    .hidden{ 
107        display: none; 
108
109 
110    button.media-item.pull-left{ 
111        padding:0; 
112        border:0; 
113
114 
115    .yui3-resize-handle.yui3-resize-handle-br{ 
116        display: none; 
117
118 
119    .modal-content{ 
120        width: 100%; 
121        height: 100%; 
122
123 
124    .modal-dialog:focus{ 
125        outline: none; 
126
127 
128</style> 
129 
130<div class="row"> 
131    <div id="titleContainer" class="col-md-12"> 
132       <div class="title" id="contentTitle"> 
133          <h1>${DisplayTitle.getData()}</h1> 
134       </div> 
135       <div class="type" id="contentType">Research Project</div> 
136    </div> 
137 
138    <div class="col-md-9"> 
139        <div class="item"> 
140            <div class="imagefull"> 
141              <img src="${Image.getData()}" data-themekey="#"> 
142            </div> 
143            <div class="bodycontainer"> 
144              <div class="b-widget__title">Project Goals</div> 
145              ${Description.getData()} 
146            </div> 
147            <div class="b-widget__title"> Research Area </div> 
148 
149             
150 
151            <#assign serviceContext = staticUtil["com.liferay.portal.kernel.service.ServiceContextThreadLocal"].getServiceContext()> 
152            <#assign themeDisplay = serviceContext.getThemeDisplay() /> 
153            <#assign viewInContext = (themeDisplay.getURLCurrent()?index_of("control_panel") gte 0)?then(false, true) /> 
154 
155            <#if viewInContext == true> 
156                <!-- START: Related Projects --> 
157                <#import "liferay-hri-theme_SERVLET_CONTEXT_/templates/base22/freemarker-utils.ftl" as utils> 
158                <#assign OrderByComparatorFactoryUtil = staticUtil["com.liferay.portal.kernel.util.OrderByComparatorFactoryUtil"] /> 
159 
160                <#assign categoriesOrderBy = OrderByComparatorFactoryUtil.create("AssetCategory", ["modifiedDate", false]) />  
161 
162                <#--Obtain domain of Liferay instance --> 
163 
164                <#assign splittedURL = themeDisplay.getURLCurrent()?split("/") /> 
165                 
166                <#--Obtain the categories of the current content --> 
167                <#assign journalArticleId = .vars['reserved-article-id'].data> 
168 
169                <#assign journalArticleResourceLocalServiceUtil = staticUtil["com.liferay.journal.service.JournalArticleResourceLocalServiceUtil"]> 
170 
171                <#assign assetCategoryLocalServiceUtil = staticUtil["com.liferay.asset.kernel.service.AssetCategoryLocalServiceUtil"]> 
172 
173                <#assign articleResourcePK = journalArticleResourceLocalServiceUtil.getArticleResourcePrimKey(groupId, journalArticleId)/> 
174 
175                <#assign categoryList=assetCategoryLocalServiceUtil.getCategories("com.liferay.journal.model.JournalArticle", articleResourcePK) /> 
176 
177                <#--Obtain the VocabularyID of 'All Projects'--> 
178                <#assign allProjectsVocabularyId = getVocabularyId('All Projects') /> 
179                <#assign projectCategoryOfCurrentContent = getCategoriesByVocabularyId(allProjectsVocabularyId) /> 
180 
181                <#--Obtain the VocabularyID of 'All Research Areas'--> 
182                <#assign allResearchAreasVocabularyId = getVocabularyId('All Research Areas') /> 
183                <#assign allResearchAreasCategoriesOfCurrentContent = getCategoriesByVocabularyId(allResearchAreasVocabularyId) /> 
184 
185                <#if allResearchAreasCategoriesOfCurrentContent?has_content> 
186 
187                    <#-- Search Projects by Research Areas --> 
188                    <#assign assetEntryQueryService = objectUtil('com.liferay.asset.kernel.service.AssetEntryLocalServiceUtil')> 
189 
190                    <#assign assetEntryQuery = objectUtil('com.liferay.asset.kernel.service.persistence.AssetEntryQuery')> 
191 
192                    <#assign search = assetEntryQuery.setAnyCategoryIds(allResearchAreasCategoriesOfCurrentContent)> 
193 
194                    <#assign researchAreasStructureId = utils.getStructureIdByName("Research Area") /> 
195                    <#assign search = assetEntryQuery.setClassTypeIds([researchAreasStructureId])> 
196 
197                    <#assign entries = assetEntryQueryService.getEntries(assetEntryQuery)> 
198                    <#if entries?has_content> 
199                        <#list entries as entry> 
200                            <#assign renderer = entry.getAssetRenderer()> 
201                            <#assign className = renderer.getClassName() > 
202 
203                            <#assign classPK = renderer.getClassPK() /> 
204 
205                            <#if className == "com.liferay.journal.model.JournalArticle" > 
206                                <#assign journalArticle = renderer.getArticle() > 
207                                <#assign document = saxReaderUtil.read(journalArticle.getContent()) > 
208 
209                                <#assign entryDisplayTitle = document.valueOf("//dynamic-element[@name='DisplayTitle']") /> 
210                                 
211                                <!-- start item html --> 
212                                <div class="b-related-researchAreas"> 
213                                    <div class="researchAreaTitle"> ${entryDisplayTitle} </div> 
214                                    <a class="researchAreaURL" href="${buildURLResearchAreas()}"> 
215                                        View details 
216                                    </a> 
217                                </div> 
218                                <!-- end item html --> 
219                            </#if> 
220                        </#list> 
221                    </#if> 
222                </#if> 
223            </#if> 
224 
225            <#if Media?has_content> 
226 
227                <div class="b-widget__title"> Media </div> 
228                <#if Media.getSiblings()?has_content> 
229                    <#list Media.getSiblings() as MediaBox> 
230                        <#if MediaBox.getData()?? && MediaBox.getData() != ""> 
231                            <#assign mediaBoxInfo = generateAttachmentElement(MediaBox.getData()) > 
232                            <#assign mimeType = mediaBoxInfo[0]> 
233                            <#assign fileName = mediaBoxInfo[1]> 
234                            <#if mimeType != ""> 
235                                <#if mimeType?contains("video/mp4")>  
236                                    <button class="video-modal media-item pull-left" data-videoLink="${MediaBox.getData()}" data-toggle="tooltip" data-target="top" title="${fileName}" > 
237 
238                                        <div class="media mp4"> 
239                                          <span class="glyphicon glyphicon-file" aria-hidden="true"></span> 
240                                        </div> 
241 
242                                    </button> 
243                                <#else> 
244                                    <div class="media-item pull-left" alt = "..." data-videoLink="${MediaBox.getData()}" data-toggle="tooltip" data-target="top"> 
245                                        <div class="media mp4"> 
246                                            <span class="glyphicon glyphicon-file" aria-hidden="true"></span> 
247                                            <a class="itemLink" href="${MediaBox.getData()}" title= "..."></a> 
248                                        </div> 
249 
250                                    </div> 
251 
252                                </#if> 
253                            </#if> 
254                        </#if> 
255 
256                    </#list> 
257                </#if> 
258            </#if> 
259 
260 
261                        <div class="yui3-skin-sam"> 
262                            <div id="modal"></div> 
263                        </div> 
264                         
265        </div> 
266    </div> 
267    <div class="col-md-3"> 
268        <#if projectCategoryOfCurrentContent?has_content> 
269            <#assign projectsStructureId = utils.getStructureIdByName("Project") /> 
270            <#assign search = assetEntryQuery.setClassTypeIds([projectsStructureId])> 
271            <#assign search = assetEntryQuery.setNotAnyCategoryIds(projectCategoryOfCurrentContent)> 
272            <#assign entries = assetEntryQueryService.getEntries(assetEntryQuery)> 
273             
274            <#if entries?has_content> 
275                <!-- start header html --> 
276                <div class="b-related-projects-container clearfix"> 
277                    <div class="b-widget__title">Related Projects</div> 
278 
279                <!-- end header html --> 
280 
281                    <!-- start item loop --> 
282                    <#list entries as entry> 
283                        <#assign renderer = entry.getAssetRenderer()> 
284                        <#assign className = renderer.getClassName() > 
285 
286                        <#assign classPK = renderer.getClassPK() /> 
287 
288                        <#if className == "com.liferay.journal.model.JournalArticle" > 
289                            <#assign journalArticle = renderer.getArticle() > 
290                            <#assign document = saxReaderUtil.read(journalArticle.getContent()) > 
291 
292                            <#assign entryDisplayTitle = document.valueOf("//dynamic-element[@name='DisplayTitle']") /> 
293 
294                            <!-- start item html --> 
295                            <div class="b-related-project"> 
296                                <a href="${buildURLProjects()}"> 
297                                    ${entryDisplayTitle} 
298                                </a> 
299                            </div> 
300 
301                            <!-- end item html --> 
302 
303                        </#if> 
304                    </#list> 
305                    <!-- end item loop --> 
306                <!-- start footer -->         
307                </div> 
308                <!-- end footer --> 
309            </#if> 
310        </#if> 
311 
312 
313    </div> 
314 
315    <!-- start functions --> 
316    <#function getVocabularyId categoryName> 
317 
318        <#assign categoriesTest = assetCategoryLocalServiceUtil.getCategories() /> 
319         
320        <#list categoriesTest as categoryEntry> 
321            <#if categoryEntry.getName() == categoryName> 
322                <#return categoryEntry.getVocabularyId()> 
323            </#if> 
324        </#list> 
325    </#function> 
326 
327    <#function getCategoriesByVocabularyId vocabularyId> 
328       <#assign vocabularyCategoryList=assetCategoryLocalServiceUtil.getVocabularyCategories(getterUtil.getLong(vocabularyId), 0, 999, categoriesOrderBy)/> 
329       <#local vocabularyCategories = [] /> 
330       <#list vocabularyCategoryList as vocabularyCategoryEntry> 
331           <#list categoryList as categoryEntry>                                 
332               <#if categoryEntry.getName() == vocabularyCategoryEntry.getName() > 
333 
334                    <#local vocabularyCategories = vocabularyCategories + [ getterUtil.getLong(categoryEntry.getCategoryId()) ] /> 
335 
336               </#if> 
337           </#list> 
338       </#list> 
339       <#return vocabularyCategories> 
340    </#function> 
341 
342    <#function buildURLProjects> 
343         
344        <#assign projectCategoryId = getCategoryIdByVocabularyId(allProjectsVocabularyId) /> 
345        <#assign projectCategoryIdParam = "" /> 
346        <#if projectCategoryId+"" != ""> 
347            <#assign projectCategoryIdParam = "?p_r_p_categoryId=" + projectCategoryId /> 
348        </#if> 
349       <#local url = "/" + splittedURL[1] + "/" + renderer.getUrlTitle() + projectCategoryIdParam /> 
350       <#return url /> 
351    </#function> 
352 
353    <#function buildURLResearchAreas> 
354         
355        <#assign researchAreaCategoryId = getCategoryIdByVocabularyId(allResearchAreasVocabularyId) /> 
356        <#assign researchAreaIdParam = "" /> 
357        <#if researchAreaCategoryId+"" != ""> 
358            <#assign researchAreaIdParam = "?p_r_p_categoryId=" + researchAreaCategoryId /> 
359        </#if> 
360       <#local url = "/" + splittedURL[1] + "/" + renderer.getUrlTitle() + researchAreaIdParam /> 
361       <#return url /> 
362    </#function> 
363 
364    <#function getCategoryIdByVocabularyId vocabularyId> 
365        <#assign vocabularyCategoryList=assetCategoryLocalServiceUtil.getVocabularyCategories(getterUtil.getLong(vocabularyId), 0, 999, categoriesOrderBy)/> 
366        <#assign categoryList=assetCategoryLocalServiceUtil.getCategories(className, classPK)/> 
367        <#list vocabularyCategoryList as vocabularyCategoryEntry> 
368            <#list categoryList as categoryEntry>                                 
369                <#if categoryEntry.getName() == vocabularyCategoryEntry.getName() > 
370                    <#return categoryEntry.getCategoryId()> 
371                </#if> 
372            </#list> 
373        </#list> 
374        <#return ""> 
375    </#function> 
376 
377 
378 
379 
380 
381<#function generateAttachmentElement attachmentURL> 
382    <#assign counter = 0 > 
383    <#list attachmentURL?split("/") as chunkURL> 
384        <#if counter == 2> 
385            <#assign groupId = chunkURL?number > 
386        </#if> 
387        <#if counter == 5> 
388            <#if chunkURL?index_of("?") != -1> 
389                <#assign uuId = chunkURL?substring(0, chunkURL?index_of("?")) > 
390            <#else> 
391                <#assign uuId = chunkURL > 
392            </#if> 
393        </#if> 
394        <#assign counter = counter+1 > 
395    </#list> 
396 
397    <#assign fileEntry = serviceLocator.findService('com.liferay.document.library.kernel.service.DLFileEntryService') />  
398    <#attempt> 
399        <#assign file=fileEntry.getFileEntryByUuidAndGroupId(uuId, getterUtil.getLong(groupId)) /> 
400        <#assign fileMimeType = file.getMimeType()> 
401        <#assign fileName = file.getFileName()> 
402    <#recover> 
403        <#assign fileMimeType = ""> 
404        <#assign fileName = ""> 
405    </#attempt> 
406 
407    <#assign fileInfo = [fileMimeType, fileName]> 
408    <#return fileInfo /> 
409</#function> 
410 
411 
412 
413 
414 
415 
416 
417</div> 
418 
419 
420 
421 
422 
423<script type="text/javascript"> 
424 
425   (function($){ 
426       AUI().ready("aui-module", function() { 
427 
428           $(".researchAreaURL").on('touchend', function(e) { 
429               debugger; 
430               window.location.href = $(this).attr("href"); 
431           }); 
432 
433        var $source = $('<source>'); 
434 
435        $(".video-modal").on("click", function(){ 
436            var videoUrl = $(this).data( "videolink" ); 
437            var videoName = $(this).attr("title") 
438 
439            var $video = $('.yui3-widget-bd.modal-body video'); 
440            var video = $video[0]; 
441 
442            console.log(videoUrl, videoName); 
443            $(".modalVideoTitle").html(videoName); 
444 
445            if($video.html() == ""){ 
446                $source.attr('src', videoUrl); 
447                $source.appendTo($video); 
448                video.play(); 
449            }else{ 
450                video.pause(); 
451                $source.attr("src", videoUrl); 
452                video.load(); 
453                video.play(); 
454
455 
456 
457 
458            /*$('.yui3-widget-bd.modal-body video source').attr('src', videoUrl);*/ 
459        }); 
460 
461       }); 
462 
463 
464 
465 
466   })(jQuery); 
467 
468 
469 
470</script> 
471 
472 
473<script> 
474    YUI().use( 
475  'aui-modal', 
476  function(Y) { 
477    var modal = new Y.Modal( 
478
479        bodyContent: '<video width="720" height="480" controls>' + 
480                                 
481                           '</video>', 
482        centered: true, 
483        destroyOnHide: false, 
484        headerContent: '<h3 class="modalVideoTitle"></h3>', 
485        modal: true, 
486        render: '#modal', 
487        zIndex: 1100, 
488        visible: false, 
489        width: 760 
490
491    ).render();  
492 
493 
494    Y.all('.video-modal').on( 
495      'click', 
496      function() { 
497 
498        modal.show(); 
499
500    ); 
501
502); 
503</script> 
504<!-- END: Related Projects --> 
505<!-- END: Project Template --> 

Publications

The 11th International Symposium on Advanced Vehicle Control (AVEC) 2012
J. Chiu, A. Goswami