Customizing the User Interface (Explorer & Share)

Referencia: capítulo 11 de "Alfresco 3 Enterprise Content Management Implementation (Packt 2009)"

The Alfresco objects available to FreeMarker

  • companyhome The Company Home template node
  • userhome The current user's Home Space template node
  • person A node representing the current user's Person object
  • space The current space template node (if you are accessing the templates through the Space Preview action)
  • document The current document's template node (if you are accessing the templates through the Document Preview action)
  • template The node representing the template itself
  • args A map of any URL parameters passed via the Template
  • Content Servlet (only available if the template was executed via the servlet)
  • session Session-related information (session.ticket for the authentication ticket)
  • classification Read access to classifications and root categories

FreeMarker template node model API

  • properties A map of the properties of the node.For example userhome, properties, name. Properties may return several different types of objects. This depends entirely on the underlying property type in the repository. If the property is multi-valued, then the result will be a sequence, which can be indexed as for any other sequence or array.
  • children A sequence (list) of the child nodes. For example, a list of the documents in a space.
  • url The URL of the content stream of this node.
  • content Returns the content of the node as a string.
  • size The size, in bytes, of content attached to this node.
  • isLocked True if the node is locked, false otherwise.
  • name Shortcut access to the name property.
  • parent The parent node, it can be null if this is the root node.
  • childrenByXPath Returns a map capable of executing an XPath query in order to find child nodes, for example, companyhome.childrenByXPath["*[@cm:name='Data Dictionary']/*"]
  • childByNamePath Returns a map capable of returning a single child node found by the name path, for example, companyhome.childByNamePath["Data Dictionary/Content Templates"]