Big honkin' merge from head. Sheesh!

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3617 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2006-08-27 01:01:30 +00:00
parent e2c66899cc
commit 8031cc6574
322 changed files with 20776 additions and 6550 deletions

View File

@@ -373,6 +373,9 @@ public class VersionServiceImpl extends AbstractVersionServiceImpl
ContentModel.PROP_VERSION_LABEL,
version.getVersionLabel());
// Invoke the policy behaviour
invokeAfterCreateVersion(nodeRef, version);
// Return the data object representing the newly created version
return version;
}
@@ -384,15 +387,15 @@ public class VersionServiceImpl extends AbstractVersionServiceImpl
{
VersionHistory versionHistory = null;
if (this.nodeService.hasAspect(nodeRef, ContentModel.ASPECT_VERSIONABLE) == true)
if (this.nodeService.exists(nodeRef) == true)
{
NodeRef versionHistoryRef = getVersionHistoryNodeRef(nodeRef);
if (versionHistoryRef != null)
{
versionHistory = buildVersionHistory(versionHistoryRef, nodeRef);
}
NodeRef versionHistoryRef = getVersionHistoryNodeRef(nodeRef);
if (versionHistoryRef != null)
{
versionHistory = buildVersionHistory(versionHistoryRef, nodeRef);
}
}
return versionHistory;
}
@@ -1078,7 +1081,7 @@ public class VersionServiceImpl extends AbstractVersionServiceImpl
// Delete the version history node
this.dbNodeService.deleteNode(versionHistoryNodeRef);
if (this.nodeService.hasAspect(nodeRef, ContentModel.ASPECT_VERSIONABLE) == true)
if (this.nodeService.exists(nodeRef) == true && this.nodeService.hasAspect(nodeRef, ContentModel.ASPECT_VERSIONABLE) == true)
{
// Reset the version label property on the versionable node
this.nodeService.setProperty(nodeRef, ContentModel.PROP_VERSION_LABEL, null);