Änderungen von Dokument Blog category RSS Feed Generator

Zuletzt geändert von Anton Bittner (Admin) am 26.11.2025

Von Version 2.1
bearbeitet von Anton Bittner (Admin)
am 26.11.2025
Änderungskommentar: Install extension [org.xwiki.contrib.blog:application-blog-ui/9.15.7]
Auf Version 1.1
bearbeitet von Carina Enke (Admin)
am 30.01.2024
Änderungskommentar: Install extension [org.xwiki.contrib.blog:application-blog-ui/9.13.6]

Zusammenfassung

Details

Seiteneigenschaften
Dokument-Autor
... ... @@ -1,1 +1,1 @@
1 -XWiki.anbit_admin
1 +XWiki.carina_admin
Syntax
... ... @@ -1,1 +1,1 @@
1 -XWiki 2.1
1 +XWiki 2.0
Inhalt
... ... @@ -12,24 +12,8 @@
12 12  #macro(getTargetCategory $categoryDoc)
13 13   #set($category = "$!{request.category}")
14 14   #if($category == '')
15 - #set ($categoryDoc = $doc)
16 - ## Since 9.15, category data may exist in Blog or Blog.Categories. Code supports both paths to maintain backward compatibility.
17 - ## This code checks whether a category exists in its original location (e.g., Blog.News).
18 - ## If the category is not found, it assumes a migration has occurred and automatically sets the category to its new location in the Blog.Categories namespace (e.g., Blog.Categories.News).
19 - #if (!$services.blog.hasLegacyCategoryAssignments())
20 - #set ($oldCategoryRef = $categoryDoc.documentReference)
21 - ## When accessing "Blog/News?xpage=plain&sheet=Blog.CategoryRss" and the Blog.News document is missing, the current doc is Blog.News.WebHome and that needs to be translated into the migrated category Blog.Categories.News.
22 - #if ($oldCategoryRef.name == 'WebHome')
23 - #set ($oldCategoryRef = $categoryDoc.documentReference.parent)
24 - #end
25 - #set ($newCategoriesSpaceRef = $services.model.createSpaceReference('Categories', $oldCategoryRef.parent))
26 - #set ($newCategoryRef = $services.model.createDocumentReference($oldCategoryRef.name, $newCategoriesSpaceRef))
27 - #if ($xwiki.exists($newCategoryRef))
28 - #set ($categoryDoc = $xwiki.getDocument($newCategoryRef))
29 - #end
30 - #end
31 - #if("$!categoryDoc.getObject($blogCategoryClassname)" != '' || $categoryDoc.getObject('XWiki.DocumentSheetBinding').sheet == 'Blog.CategoriesSheet')
32 - #set ($category = $categoryDoc.fullName)
15 + #if("$!doc.getObject($blogCategoryClassname)" != '' || $doc.getObject('XWiki.DocumentSheetBinding').sheet == 'Blog.CategoriesSheet')
16 + #set ($category = $doc.fullName)
33 33   #else
34 34   #set($category = $defaultCategoryParent)
35 35   #end