... |
... |
@@ -93,31 +93,20 @@ |
93 |
93 |
|
94 |
94 |
== Images and Videos == |
95 |
95 |
|
96 |
|
-{{carousel/}} |
97 |
|
- |
98 |
98 |
{{velocity}} |
99 |
|
-#panelheader('Gallery') |
100 |
|
- |
101 |
101 |
#set($attachments = $doc.getAttachmentList()) |
102 |
|
-#set($imageCount = 0) |
103 |
103 |
|
104 |
|
-#foreach($attachment in $attachments) |
105 |
|
- #if($attachment.filename.endsWith(".jpg") || $attachment.filename.endsWith(".png") || $attachment.filename.endsWith(".webp")) |
106 |
|
- #set($imageCount = $imageCount + 1) |
107 |
|
- #end |
|
99 |
+#macro(imageentry $filename) |
|
100 |
+#if($filename.endsWith(".jpg") || $filename.endsWith(".png") || $filename.endsWith(".webp")) |
|
101 |
+ image:$doc.space/$doc.name/WebHome@$escapetool.url($filename) |
108 |
108 |
#end |
109 |
|
- |
110 |
|
-#if($imageCount > 0) |
111 |
|
- {{gallery}} |
112 |
|
- #foreach($attachment in $attachments) |
113 |
|
- #if($attachment.filename.endsWith(".jpg") || $attachment.filename.endsWith(".png") || $attachment.filename.endsWith(".webp")) |
114 |
|
- image:$attachment.filename |
115 |
|
- #end |
116 |
|
- #end |
117 |
|
- {{/gallery}} |
118 |
118 |
#end |
119 |
119 |
|
120 |
|
-#panelfooter() |
|
105 |
+{{gallery}} |
|
106 |
+#foreach($attachment in $attachments) |
|
107 |
+ #imageentry($attachment.filename) |
|
108 |
+#end |
|
109 |
+{{/gallery}} |
121 |
121 |
{{/velocity}} |
122 |
122 |
|
123 |
123 |
|