mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Fixed CMIS object parents collection
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@29621 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -781,13 +781,18 @@ public class CMISNodeInfoImpl implements CMISNodeInfo
|
|||||||
{
|
{
|
||||||
parents = new ArrayList<CMISNodeInfo>();
|
parents = new ArrayList<CMISNodeInfo>();
|
||||||
|
|
||||||
List<ChildAssociationRef> nodeParents = connector.getNodeService().getParentAssocs(nodeRef,
|
NodeRef nodeRefForParent = (isCurrentVersion() ? getCurrentNodeNodeRef() : nodeRef);
|
||||||
|
|
||||||
|
List<ChildAssociationRef> nodeParents = connector.getNodeService().getParentAssocs(nodeRefForParent,
|
||||||
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
ContentModel.ASSOC_CONTAINS, RegexQNamePattern.MATCH_ALL);
|
||||||
if (nodeParents != null)
|
if (nodeParents != null)
|
||||||
{
|
{
|
||||||
for (ChildAssociationRef parent : nodeParents)
|
for (ChildAssociationRef parent : nodeParents)
|
||||||
{
|
{
|
||||||
parents.add(new CMISNodeInfoImpl(connector, parent.getParentRef()));
|
if (connector.getType(parent.getParentRef()) instanceof FolderTypeDefintionWrapper)
|
||||||
|
{
|
||||||
|
parents.add(new CMISNodeInfoImpl(connector, parent.getParentRef()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user