mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Merge from HEAD to WCM-DEV2.
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3659 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -1,42 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<rss version="2.0">
|
||||
<channel>
|
||||
<title>Alfresco</title>
|
||||
<copyright>Copyright (c) 2005 Alfresco Software, Inc. All rights reserved.</copyright>
|
||||
<#assign hostname="http://localhost:8080/alfresco">
|
||||
<#assign spaceref="${hostname}/navigate/browse/${space.nodeRef.storeRef.protocol}/${space.nodeRef.storeRef.identifier}/${space.nodeRef.id}">
|
||||
<#assign datetimeformat="EEE, dd MMM yyyy HH:mm:ss zzz">
|
||||
<link>${spaceref}</link>
|
||||
<description>Recent Changes to '${space.name}'</description>
|
||||
<language>en-us</language>
|
||||
<lastBuildDate>${date?string(datetimeformat)}</lastBuildDate>
|
||||
<pubDate>${date?string(datetimeformat)}</pubDate>
|
||||
<ttl>120</ttl>
|
||||
<generator>Alfresco 1.2</generator>
|
||||
<image>
|
||||
<title>${space.name}</title>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
<link>${spaceref}</link>
|
||||
<url>${hostname}${space.icon32}</url>
|
||||
</image>
|
||||
<#assign weekms=1000*60*60*24*7>
|
||||
<#list space.childrenByXPath[".//*[subtypeOf('cm:content')]"] as child>
|
||||
<#if (dateCompare(child.properties["cm:modified"], date, weekms) == 1) || (dateCompare(child.properties["cm:created"], date, weekms) == 1)>
|
||||
<item>
|
||||
<title>${child.properties.name}</title>
|
||||
<link>${hostname}${child.url}</link>
|
||||
<description>
|
||||
${"<a href='${hostname}${child.url}'>"?xml}${child.properties.name}${"</a>"?xml}
|
||||
<#if child.properties["cm:description"]?exists && child.properties["cm:description"] != "">
|
||||
${child.properties["cm:description"]}
|
||||
</#if>
|
||||
</description>
|
||||
<pubDate>${child.properties["cm:modified"]?string(datetimeformat)}</pubDate>
|
||||
<guid isPermaLink="false">${hostname}${child.url}</guid>
|
||||
</item>
|
||||
</#if>
|
||||
</#list>
|
||||
|
||||
</channel>
|
||||
</rss>
|
@@ -1,20 +0,0 @@
|
||||
<#-- Table of the images found in a folder under Company Home called "Company Logos" -->
|
||||
<#-- Shows each image found as inline content -->
|
||||
<table>
|
||||
<#list companyhome.children as child>
|
||||
<#if child.isContainer && child.name = "Company Logos">
|
||||
<#list child.children as image>
|
||||
<#switch image.mimetype>
|
||||
<#case "image/jpeg">
|
||||
<#case "image/gif">
|
||||
<#case "image/png">
|
||||
<tr>
|
||||
<td><img src="/alfresco${image.url}"></td>
|
||||
</tr>
|
||||
<#break>
|
||||
<#default>
|
||||
</#switch>
|
||||
</#list>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
@@ -1,18 +1,47 @@
|
||||
<#-- Shows some general info about the current document, including NodeRef and aspects applied -->
|
||||
<h3>General document info</h3>
|
||||
<#if document?exists>
|
||||
<h4>Current Document Info:</h4>
|
||||
<b>Name:</b> ${document.name}<br>
|
||||
<b>Ref:</b> ${document.nodeRef}<br>
|
||||
<b>Type:</b> ${document.type}<br>
|
||||
<b>DBID:</b> ${document.properties["sys:node-dbid"]}<br>
|
||||
<b>Content URL:</b> <a href="/alfresco${document.url}">/alfresco${document.url}</a><br>
|
||||
<b>Locked:</b> <#if document.isLocked>Yes<#else>No</#if><br>
|
||||
<#if hasAspect(document, "cm:countable") == 1 && document.properties['cm:counter']?exists>
|
||||
<b>Counter:</b> ${document.properties['cm:counter']}<br>
|
||||
</#if>
|
||||
<b>Aspects:</b>
|
||||
<table>
|
||||
<#list document.aspects as aspect>
|
||||
<tr><td>${aspect}</td></tr>
|
||||
</#list>
|
||||
</table>
|
||||
<b>Properties:</b>
|
||||
<table>
|
||||
<#-- Get a list of all the property names for the document -->
|
||||
<#assign props = document.properties?keys>
|
||||
<#list props as t>
|
||||
<#-- If the property exists -->
|
||||
<#if document.properties[t]?exists>
|
||||
<#-- If it is a date, format it accordingly -->
|
||||
<#if document.properties[t]?is_date>
|
||||
<tr><td>${t} = ${document.properties[t]?datetime}</td></tr>
|
||||
|
||||
<#-- If it is a boolean, format it accordingly -->
|
||||
<#elseif document.properties[t]?is_boolean>
|
||||
<tr><td>${t} = ${document.properties[t]?string("yes", "no")}</td></tr>
|
||||
|
||||
<#-- If it is a collection, enumerate it -->
|
||||
<#elseif document.properties[t]?is_enumerable>
|
||||
<tr><td>${t} = <#list document.properties[t] as i>${i} </#list></td></tr>
|
||||
|
||||
<#-- Otherwise treat it as a string -->
|
||||
<#else>
|
||||
<tr><td>${t} = ${document.properties[t]}</td></tr>
|
||||
</#if>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
||||
<#else>
|
||||
No document found!
|
||||
</#if>
|
||||
|
@@ -1,47 +0,0 @@
|
||||
<h3>=====Example Template Start=====</h3>
|
||||
|
||||
<b>Company Home Space:</b> ${companyhome.properties.name}
|
||||
<br>
|
||||
<b>My Home Space:</b> ${userhome.properties.name}
|
||||
<br>
|
||||
<b>Company Home children count:</b> ${companyhome.children?size}
|
||||
<br>
|
||||
<b>Company Home first child node name:</b> ${companyhome.children[0].properties.name}
|
||||
<br>
|
||||
<b>Current Document Name:</b> ${document.name}
|
||||
<br>
|
||||
<b>Current Space Name:</b> ${space.name}
|
||||
|
||||
<h4>List of child spaces in my Home Space:</h4>
|
||||
<table>
|
||||
<#list userhome.children as child>
|
||||
<#if child.isContainer>
|
||||
<tr>
|
||||
<td><img src="/alfresco${child.icon32}"></td>
|
||||
<td><b>${child.properties.name}</b> (${child.children?size})</td>
|
||||
<td><b>Path:</b> ${child.displayPath}</td>
|
||||
</tr>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
||||
|
||||
<h4>List of docs in my Home Space (text only content shown inline, JPG images shown as thumbnails):</h4>
|
||||
<table>
|
||||
<#list userhome.children as child>
|
||||
<#if child.isDocument>
|
||||
<tr><td><img src="/alfresco${child.icon16}"></td><td><a href="/alfresco${child.url}">${child.properties.name}</a></td></tr>
|
||||
<#if child.mimetype = "text/plain">
|
||||
<tr><td></td><td>${child.content}</td></tr>
|
||||
<#elseif child.mimetype = "image/jpeg">
|
||||
<tr><td></td><td><img width=100 height=65 src="/alfresco${child.url}"></td></tr>
|
||||
</#if>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
||||
|
||||
<h4>Assoc example:</h4>
|
||||
<#if userhome.children[0].assocs["cm:contains"]?exists>
|
||||
${userhome.children[0].assocs["cm:contains"][0].name}
|
||||
</#if>
|
||||
|
||||
<h3>=====Example Template End=====</h3>
|
@@ -1,22 +0,0 @@
|
||||
<#-- Displays a table of all the documents from a "Press Releases" folder under Company Home -->
|
||||
<#-- Obviously this folder needs to exist and the docs in it should have the title and description fields set -->
|
||||
<table>
|
||||
<#list companyhome.children as child>
|
||||
<#if child.isContainer && child.name = "Press Releases">
|
||||
<#list child.children as doc>
|
||||
<#if doc.isDocument>
|
||||
<tr>
|
||||
<td><h3>${doc.properties.title}</h3></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding-left:4px"><b>${doc.properties.description}</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding-left:8px"><small>${doc.content}</small></td>
|
||||
</tr>
|
||||
<tr><td><div style="padding:6px"></div></td></tr>
|
||||
</#if>
|
||||
</#list>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
@@ -1,15 +0,0 @@
|
||||
<#-- List of docs in the Home Space for current user -->
|
||||
<#-- If the doc mimetype is plain/text then the content is shown inline -->
|
||||
<#-- If the doc mimetype is JPEG then the image is shown inline as a small thumbnail image -->
|
||||
<table>
|
||||
<#list userhome.children as child>
|
||||
<#if child.isDocument>
|
||||
<tr><td>${child.properties.name}</td></tr>
|
||||
<#if child.mimetype = "text/plain">
|
||||
<tr><td style='padding-left:16px'>${child.content}</td></tr>
|
||||
<#elseif child.mimetype = "image/jpeg">
|
||||
<tr><td style='padding-left:16px'><img width=100 height=65 src="/alfresco${child.url}"><td></tr>
|
||||
</#if>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
@@ -1,26 +0,0 @@
|
||||
<#-- Shows use of the childByNamePath, childrenByXPath and childrenByLuceneSearch API -->
|
||||
|
||||
<h3>Template Documents in 'Company Home/Data Dictionary/Presentation Templates':</h3>
|
||||
<table>
|
||||
<#list companyhome.childByNamePath["Data Dictionary/Presentation Templates"].children as child>
|
||||
<#if child.isDocument>
|
||||
<tr><td><a href="/alfresco${child.url}" target="new">${child.properties.name}</a></td></tr>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
||||
|
||||
<h3>Folders in 'Company Home/Data Dictionary/Space Templates/Software Engineering Project':</h3>
|
||||
<table>
|
||||
<#list companyhome.childrenByXPath["*[@cm:name='Data Dictionary']/*[@cm:name='Space Templates']/*[@cm:name='Software Engineering Project']/*"] as child>
|
||||
<#if child.isContainer>
|
||||
<tr><td><img src="/alfresco${child.icon32}"> ${child.properties.name}</td></tr>
|
||||
</#if>
|
||||
</#list>
|
||||
</table>
|
||||
|
||||
<h3>Lucene Search - documents containing the text 'Alfresco'</h3>
|
||||
<table>
|
||||
<#list companyhome.childrenByLuceneSearch["TEXT:alfresco"] as child>
|
||||
<tr><td><a href="/alfresco${child.url}" target="new">${child.properties.name}</a></td></tr>
|
||||
</#list>
|
||||
</table>
|
@@ -7,8 +7,8 @@
|
||||
</view:aspects>
|
||||
<view:properties>
|
||||
<app:editInline>true</app:editInline>
|
||||
<cm:description>Displays basic information about the current document</cm:description>
|
||||
<cm:content>contentUrl=classpath:alfresco/templates/content/examples/doc_info.ftl|mimetype=text/plain|size=636|encoding=UTF-8</cm:content>
|
||||
<cm:description>Displays useful information about the current document</cm:description>
|
||||
<cm:content>contentUrl=classpath:alfresco/templates/content/examples/doc_info.ftl|mimetype=text/plain|size=1884|encoding=UTF-8</cm:content>
|
||||
<cm:title>doc_info.ftl</cm:title>
|
||||
<cm:name>doc_info.ftl</cm:name>
|
||||
</view:properties>
|
||||
@@ -84,20 +84,6 @@
|
||||
</view:properties>
|
||||
<view:associations></view:associations>
|
||||
</cm:content>
|
||||
<cm:content xmlns:alf="http://www.alfresco.org" xmlns:d="http://www.alfresco.org/model/dictionary/1.0" xmlns:view="http://www.alfresco.org/view/repository/1.0" xmlns:sys="http://www.alfresco.org/model/system/1.0" xmlns:act="http://www.alfresco.org/model/action/1.0" xmlns:rule="http://www.alfresco.org/model/rule/1.0" xmlns:fm="http://www.alfresco.org/model/forum/1.0" xmlns:app="http://www.alfresco.org/model/application/1.0" xmlns:usr="http://www.alfresco.org/model/user/1.0" xmlns:ver="http://www.alfresco.org/model/versionstore/1.0" xmlns:cm="http://www.alfresco.org/model/content/1.0" xmlns="" view:childName="cm:RSS_2.0_recent_docs.ftl">
|
||||
<view:aspects>
|
||||
<cm:titled></cm:titled>
|
||||
<app:inlineeditable></app:inlineeditable>
|
||||
</view:aspects>
|
||||
<view:properties>
|
||||
<app:editInline>true</app:editInline>
|
||||
<cm:description>Renders a valid RSS2.0 XML document showing the documents in the current space created or modified in the last 7 days. The template should be configured to use the appropriate server and port before use.</cm:description>
|
||||
<cm:content>contentUrl=classpath:alfresco/templates/content/examples/RSS_2.0_recent_docs.ftl|mimetype=text/plain|size=1917|encoding=UTF-8</cm:content>
|
||||
<cm:title>RSS_2.0_recent_docs.ftl</cm:title>
|
||||
<cm:name>RSS_2.0_recent_docs.ftl</cm:name>
|
||||
</view:properties>
|
||||
<view:associations></view:associations>
|
||||
</cm:content>
|
||||
<cm:content xmlns:alf="http://www.alfresco.org" xmlns:d="http://www.alfresco.org/model/dictionary/1.0" xmlns:view="http://www.alfresco.org/view/repository/1.0" xmlns:sys="http://www.alfresco.org/model/system/1.0" xmlns:act="http://www.alfresco.org/model/action/1.0" xmlns:rule="http://www.alfresco.org/model/rule/1.0" xmlns:fm="http://www.alfresco.org/model/forum/1.0" xmlns:app="http://www.alfresco.org/model/application/1.0" xmlns:usr="http://www.alfresco.org/model/user/1.0" xmlns:ver="http://www.alfresco.org/model/versionstore/1.0" xmlns:cm="http://www.alfresco.org/model/content/1.0" xmlns="" view:childName="cm:recent_docs.ftl">
|
||||
<view:aspects>
|
||||
<cm:titled></cm:titled>
|
||||
@@ -140,18 +126,4 @@
|
||||
</view:properties>
|
||||
<view:associations></view:associations>
|
||||
</cm:content>
|
||||
<cm:content xmlns:alf="http://www.alfresco.org" xmlns:d="http://www.alfresco.org/model/dictionary/1.0" xmlns:view="http://www.alfresco.org/view/repository/1.0" xmlns:sys="http://www.alfresco.org/model/system/1.0" xmlns:act="http://www.alfresco.org/model/action/1.0" xmlns:rule="http://www.alfresco.org/model/rule/1.0" xmlns:fm="http://www.alfresco.org/model/forum/1.0" xmlns:app="http://www.alfresco.org/model/application/1.0" xmlns:usr="http://www.alfresco.org/model/user/1.0" xmlns:ver="http://www.alfresco.org/model/versionstore/1.0" xmlns:cm="http://www.alfresco.org/model/content/1.0" xmlns="" view:childName="cm:xpath_search.ftl">
|
||||
<view:aspects>
|
||||
<cm:titled></cm:titled>
|
||||
<app:inlineeditable></app:inlineeditable>
|
||||
</view:aspects>
|
||||
<view:properties>
|
||||
<app:editInline>true</app:editInline>
|
||||
<cm:description>Example of using XPath and Lucene searches within a template.</cm:description>
|
||||
<cm:content>contentUrl=classpath:alfresco/templates/content/examples/xpath_search.ftl|mimetype=text/plain|size=1109|encoding=UTF-8</cm:content>
|
||||
<cm:title>xpath_search.ftl</cm:title>
|
||||
<cm:name>xpath_search.ftl</cm:name>
|
||||
</view:properties>
|
||||
<view:associations></view:associations>
|
||||
</cm:content>
|
||||
</view:view>
|
Reference in New Issue
Block a user