Изменения документа test
Редактировал(а) Jip-jan Alunkel марта 13, 19:02
От версии 98.9
отредактировано Jip-jan Alunkel
на января 27, 20:10
на января 27, 20:10
Изменить комментарий:
Updated class property
К версии 98.18
отредактировано Jip-jan Alunkel
на января 30, 16:04
на января 30, 16:04
Изменить комментарий:
Updated class property
Сводка
-
Свойства страницы (1 изменено, 0 добавлено, 0 удалено)
Подробности
- Свойства страницы
-
- Содержимое
-
... ... @@ -5,7 +5,7 @@ 5 5 #set($docrefArray = $dr.split("\.")) 6 6 #set($docrefArrayB = []) 7 7 #foreach($elem in $dr.split("\.")) 8 - #set($discard = $docrefArrayB.add("$elem")) 8 + #set($discard = $docrefArrayB.add("${elem}")) 9 9 #end 10 10 #set($docrefa = $services.model.createDocumentReference($xcontext.mainWikiName, ['bladibla','vinnymossel','hahahha','hohjoho'], 'WebHome')) 11 11 #set($docrefb = $services.model.createDocumentReference($xcontext.mainWikiName, $docrefArrayB, 'WebHome')) ... ... @@ -12,11 +12,25 @@ 12 12 $docrefa 13 13 <br /> 14 14 $docrefb 15 +#set($page = $xwiki.getDocument($docrefb)) 16 +#set($parentReference = $services.model.resolveDocument('', 'default', $page.documentReference.lastSpaceReference).parent) 17 +#set($parent = $xwiki.getDocument($parentReference)) 18 +<br /> 15 15 20 +$parent 21 +<br /> 22 +#set($parentTitle = $docrefb.getName()) 23 +$parentTitle 24 +<br /> 25 +#set($pageb = $xwiki.getDocument($dr)) 26 +#set($parentReference = $services.model.resolveDocument('', 'default', $pageb.documentReference.lastSpaceReference).parent) 27 +#set($parent = $xwiki.getDocument($parentReference)) 28 +<br /> 16 16 17 - 18 - 19 - 30 +$parent 31 +<br /> 32 +#set($parentTitle = $docrefb.getName()) 33 +$parentTitle 20 20 ##set($obj = $doc.getObject('test.WebHome')) 21 21 ##set($class = $obj.xWikiClass) ## access the class object representing SomeSpace.SomeClass 22 22 $doc.display("blaat")