mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged V3.1 to HEAD
14628: Second attempt at ETHREEOH-2144 fix - tested against several known good webforms. 14854: Fix for ETHREEOH-2206. Also fixes minor issue where rule condition selection box was not reset after adding a condition to a composite. 14862: Fix for ETHREEOH-1946 - correctly coerce nodes returned from javascript into AVMTemplateNode objects if they are AVM NodeRef objects. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14864 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -35,6 +35,7 @@ import org.alfresco.processor.ProcessorExtension;
|
||||
import org.alfresco.repo.processor.BaseProcessor;
|
||||
import org.alfresco.service.cmr.repository.AssociationRef;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.repository.StoreRef;
|
||||
import org.alfresco.service.cmr.repository.TemplateException;
|
||||
import org.alfresco.service.cmr.repository.TemplateImageResolver;
|
||||
import org.alfresco.service.cmr.repository.TemplateProcessor;
|
||||
@@ -328,9 +329,17 @@ public class FreeMarkerProcessor extends BaseProcessor implements TemplateProces
|
||||
private Object convertValue(Object value, TemplateImageResolver imageResolver)
|
||||
{
|
||||
if (value instanceof NodeRef)
|
||||
{
|
||||
NodeRef ref = (NodeRef)value;
|
||||
if (StoreRef.PROTOCOL_AVM.equals(ref.getStoreRef().getProtocol()))
|
||||
{
|
||||
return new AVMTemplateNode((NodeRef)value, this.services, imageResolver);
|
||||
}
|
||||
else
|
||||
{
|
||||
return new TemplateNode((NodeRef)value, this.services, imageResolver);
|
||||
}
|
||||
}
|
||||
|
||||
else if (value instanceof AssociationRef)
|
||||
{
|
||||
|
Reference in New Issue
Block a user