0 Votes

Changes for page Incidents list

Last modified by Ryan C on 2025/07/14 15:42

From version 6.1
edited by Ryan C
on 2025/07/14 14:14
Change comment: There is no comment for this version
To version 7.1
edited by Ryan C
on 2025/07/14 14:15
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -19,16 +19,14 @@
19 19   def headline = (rawHeadline instanceof String) ? rawHeadline.trim() : null
20 20  
21 21   def rawUrl = obj.getProperty('URL')?.value
22 - def URL = (rawUrl instanceof String) ? rawUrl.trim() : null
22 + def urlValue = (rawUrl instanceof String) ? rawUrl.trim() : null
23 23  
24 - def isValidUrl = (URL ==~ /(?i)^https?:\/\/.+/)
24 + def isValidUrl = (urlValue ==~ /(?i)^https?:\/\/.+/)
25 25   def label = (headline && headline.length() > 0) ? headline : (fallbackTitle ?: docName)
26 26  
27 27   if (isValidUrl) {
28 - // CORRECT syntax per official XWiki link rules
29 - println "* [[${label}>>${URL}]]"
28 + println "* [[${label}>>${urlValue}]]"
30 30   } else {
31 - // Fallback to internal doc
32 32   println "* [[${label}>>doc:${docName}]]"
33 33   }
34 34   }

XWiki AI Chat