mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Fixes for AWC-1160 and AWC-1161
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@5389 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -314,7 +314,7 @@
|
|||||||
</permissionGroup>
|
</permissionGroup>
|
||||||
|
|
||||||
<!-- An editor can read and write to the object; they can not create -->
|
<!-- An editor can read and write to the object; they can not create -->
|
||||||
<!-- new nodes. They can cehck out content into a space to which they have -->
|
<!-- new nodes. They can check out content into a space to which they have -->
|
||||||
<!-- create permission. -->
|
<!-- create permission. -->
|
||||||
<permissionGroup name="Editor" expose="true" allowFullControl="false" >
|
<permissionGroup name="Editor" expose="true" allowFullControl="false" >
|
||||||
<includePermissionGroup type="cm:cmobject" permissionGroup="Consumer"/>
|
<includePermissionGroup type="cm:cmobject" permissionGroup="Consumer"/>
|
||||||
|
@@ -284,28 +284,17 @@ public class LockServiceImpl implements LockService
|
|||||||
// Check for lock aspect
|
// Check for lock aspect
|
||||||
checkForLockApsect(nodeRef);
|
checkForLockApsect(nodeRef);
|
||||||
|
|
||||||
// Get the current user name
|
this.ignoreNodeRefs.add(nodeRef);
|
||||||
//String userName = getUserName();
|
try
|
||||||
|
{
|
||||||
//LockStatus lockStatus = getLockStatus(nodeRef, userName);
|
// Clear the lock owner
|
||||||
//if (LockStatus.LOCKED.equals(lockStatus) == true)
|
this.nodeService.setProperty(nodeRef, ContentModel.PROP_LOCK_OWNER, null);
|
||||||
// {
|
this.nodeService.setProperty(nodeRef, ContentModel.PROP_LOCK_TYPE, null);
|
||||||
// // Error since the lock can only be released by the lock owner
|
}
|
||||||
// throw new UnableToReleaseLockException(nodeRef);
|
finally
|
||||||
// }
|
{
|
||||||
// else if (LockStatus.LOCK_OWNER.equals(lockStatus) == true)
|
this.ignoreNodeRefs.remove(nodeRef);
|
||||||
// {
|
}
|
||||||
this.ignoreNodeRefs.add(nodeRef);
|
|
||||||
try
|
|
||||||
{
|
|
||||||
// Clear the lock owner
|
|
||||||
this.nodeService.setProperty(nodeRef, ContentModel.PROP_LOCK_OWNER, null);
|
|
||||||
this.nodeService.setProperty(nodeRef, ContentModel.PROP_LOCK_TYPE, null);
|
|
||||||
} finally
|
|
||||||
{
|
|
||||||
this.ignoreNodeRefs.remove(nodeRef);
|
|
||||||
}
|
|
||||||
//}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -361,7 +350,6 @@ public class LockServiceImpl implements LockService
|
|||||||
LockStatus result = LockStatus.NO_LOCK;
|
LockStatus result = LockStatus.NO_LOCK;
|
||||||
|
|
||||||
if (this.nodeService.hasAspect(nodeRef, ContentModel.ASPECT_LOCKABLE) == true)
|
if (this.nodeService.hasAspect(nodeRef, ContentModel.ASPECT_LOCKABLE) == true)
|
||||||
|
|
||||||
{
|
{
|
||||||
// Get the current lock owner
|
// Get the current lock owner
|
||||||
String currentUserRef = (String) this.nodeService.getProperty(nodeRef, ContentModel.PROP_LOCK_OWNER);
|
String currentUserRef = (String) this.nodeService.getProperty(nodeRef, ContentModel.PROP_LOCK_OWNER);
|
||||||
|
Reference in New Issue
Block a user