As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
elCell.innerHTML = '<span class="folder">' + (isLink ? '<span class="link"></span>' : '') + (scope.dragAndDropEnabled ? '<span class="droppable"></span>' : '') + Alfresco.DocumentList.generateFileFolderLinkMarkup(scope, record) + '<img id="' + imgId + '" src="' + Alfresco.constants.URL_RESCONTEXT + 'components/documentlibrary/images/folder-64.png" /></a>';
var folderIcon = "folder-64.png"; if(jsNode.typeShort != "cm:folder") { folderIcon = jsNode.typeShort.replace(":","-") + "-64.png"; } elCell.innerHTML = '<span class="folder">' + (isLink ? '<span class="link"></span>' : '') + (scope.dragAndDropEnabled ? '<span class="droppable"></span>' : '') + Alfresco.DocumentList.generateFileFolderLinkMarkup(scope, record) + '<img id="' + imgId + '" src="' + Alfresco.constants.URL_RESCONTEXT + 'components/documentlibrary/images/' + folderIcon + '" /></a>';
<?xml version="1.0" encoding="UTF-8"?> <!– Definition of new Model –> <model name="ci:customicon" xmlns="http://www.alfresco.org/model/dictionary/1.0"> <!– Optional meta-data about the model –> <description>CustomIcon Model</description> <author>Mark Goldenstein</author> <version>1.0</version> <!– Imports are required to allow references to definitions in other models –> <imports> <!– Import Alfresco Dictionary Definitions –> <import uri="http://www.alfresco.org/model/dictionary/1.0" prefix="d"/> <!– Import Alfresco Content Domain Model Definitions –> <import uri="http://www.alfresco.org/model/content/1.0" prefix="cm"/> </imports> <!– Introduction of new namespaces defined by this model –> <!– NOTE: The following namespace my.new.model should be changed to reflect your own namespace –> <namespaces> <namespace uri="extension.customicon" prefix="ci"/> </namespaces> <types> <type name="ci:iconFolder"> <title>Folder (with icon)</title> <description>A folder with an icon.</description> <parent>cm:folder</parent> <associations> <association name="ci:icon"> <target> <class>cm:content</class> <mandatory>false</mandatory> <many>false</many> </target> </association> </associations> </type> </types> </model>
<webscript kind="org.alfresco.repository.content.stream"> <shortname>Get Folder Icon</shortname> <description> Returns the content of the associated Icon file </description> <url>/someco/get-folder-icon</url> <format default="html">extension</format> <authentication runas="system">none</authentication> <transaction>required</transaction> <family>Someco</family> </webscript>