Changes for page Per A.Y.
From version 52.1
edited by Andrea Omicini
on 27/08/2023 18:53
on 27/08/2023 18:53
Change comment:
There is no comment for this version
To version 51.5
edited by Andrea Omicini
on 27/08/2023 18:29
on 27/08/2023 18:29
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -38,8 +38,8 @@ 38 38 #foreach( $year in $yearList ) 39 39 #set( $year1 = $year + 1 ) 40 40 #set( $ayear = $year + "/" + $year1 ) 41 - #set( $query = ", BaseObject as objCourse, StringProperty as prop Name, StringProperty as propYear, LargeStringProperty as propProfessor, LargeStringProperty as propOtherprofessors, LargeStringProperty as propTutors42 - where objCourse.name = doc.fullName and objCourse.className = '${mainSpace}.Class' and objCourse.name <> '${objectPool}.Template' and prop Name.id.id = objCourse.id and propYear.id.id = objCourse.id and propProfessor.id.id = objCourse.id and propOtherprofessors.id.id = objCourse.id and propTutors.id.id = objCourse.id and propName.name = #if( $services.localization.currentLocale == 'it' )'ita'#{else}'eng'#end and propYear.name = 'ay' and propProfessor.name = 'professor' and propOtherprofessors.name = 'otherProfessors' and propTutors.name = 'tutors' and propYear.value = '$ayear' #if( $oneUser )and ( propProfessor.value like '%$userName%' or propOtherprofessors.value like '%$userName%' or propTutors.value like '%$userName%' )#endorder by propName.value asc")41 + #set( $query = ", BaseObject as objCourse, StringProperty as propYear, LargeStringProperty as propProfessor, LargeStringProperty as propOtherprofessors, LargeStringProperty as propTutors 42 + where objCourse.name = doc.fullName and objCourse.className = '${mainSpace}.Class' and objCourse.name <> '${objectPool}.Template' and propYear.id.id = objCourse.id and propProfessor.id.id = objCourse.id and propOtherprofessors.id.id = objCourse.id and propTutors.id.id = objCourse.id and propYear.name = 'ay' and propProfessor.name = 'professor' and propOtherprofessors.name = 'otherProfessors' and propTutors.name = 'tutors' and propYear.value = '$ayear' #if( $oneUser )and ( propProfessor.value like '%$userName%' or propOtherprofessors.value like '%$userName%' or propTutors.value like '%$userName%' )#end ") 43 43 ## execute query 44 44 #set( $itemFound = $xwiki.searchDocuments($query) ) 45 45 ## set counters ... ... @@ -110,18 +110,22 @@ 110 110 ## year top / end 111 111 ## 112 112 ## year display / start 113 - <div class='menumainbody' style='margin-top: .25em'> 114 - #foreach( $item in $itemMap[$year] ) 115 - #if( $oneUser) 116 - #coursename($item) (#coursecycle($item)) 117 - #else 118 - #coursename($item) <span class='textsecondary'>(#coursecycle($item)) — </span>#courseprofessor($item) 113 + #if( $oneUser) 114 + <div class='menumainbody'> 115 + #foreach( $item in $itemMap[$year] ) 116 + #courseperyear($item) 117 + #if( !$foreach.last ) 118 +  •  119 + #end 119 119 #end 120 - #if( !$foreach.last ) 121 -  •  121 + </div> 122 + #else 123 + <div style="font-style: normal"><ul> 124 + #foreach( $item in $itemMap[$year] ) 125 + <li>#courselinked($item)</li> 122 122 #end 127 +</ul></div> 123 123 #end 124 - </div> 125 125 ## year display / end 126 126 ## 127 127 ## year bottom / start