mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Minor fixes for the hold service
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@64903 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -160,7 +160,7 @@ public interface RMPermissionModel
|
|||||||
|
|
||||||
String MANAGE_ACCESS_CONTROLS = "ManageAccessControls";
|
String MANAGE_ACCESS_CONTROLS = "ManageAccessControls";
|
||||||
|
|
||||||
final String CREATE_HOLD = "CreateHold";
|
String CREATE_HOLD = "CreateHold";
|
||||||
final String ADD_TO_HOLD = "AddToHold";
|
String ADD_TO_HOLD = "AddToHold";
|
||||||
final String REMOVE_FROM_HOLD = "RemoveFromHold";
|
String REMOVE_FROM_HOLD = "RemoveFromHold";
|
||||||
}
|
}
|
||||||
|
@@ -450,7 +450,7 @@ public class HoldServiceImpl extends ServiceBaseImpl
|
|||||||
}
|
}
|
||||||
|
|
||||||
// check that the node isn't already in the hold
|
// check that the node isn't already in the hold
|
||||||
if (getHeld(hold).contains(nodeRef) == false)
|
if (!getHeld(hold).contains(nodeRef))
|
||||||
{
|
{
|
||||||
// Link the record to the hold
|
// Link the record to the hold
|
||||||
nodeService.addChild(hold, nodeRef, ASSOC_FROZEN_RECORDS, ASSOC_FROZEN_RECORDS);
|
nodeService.addChild(hold, nodeRef, ASSOC_FROZEN_RECORDS, ASSOC_FROZEN_RECORDS);
|
||||||
@@ -544,7 +544,7 @@ public class HoldServiceImpl extends ServiceBaseImpl
|
|||||||
throw new AlfrescoRuntimeException("Can't remove from hold, because it isn't a hold. (hold=" + hold + ")");
|
throw new AlfrescoRuntimeException("Can't remove from hold, because it isn't a hold. (hold=" + hold + ")");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getHeld(hold).contains(nodeRef) == true)
|
if (getHeld(hold).contains(nodeRef))
|
||||||
{
|
{
|
||||||
// remove from hold
|
// remove from hold
|
||||||
nodeService.removeChild(hold, nodeRef);
|
nodeService.removeChild(hold, nodeRef);
|
||||||
|
@@ -92,7 +92,7 @@ public class ServiceBaseImpl implements RecordsManagementModel
|
|||||||
/**
|
/**
|
||||||
* Indicates whether the given node reference is a hold or not.
|
* Indicates whether the given node reference is a hold or not.
|
||||||
* <p>
|
* <p>
|
||||||
* Exposed publically in the {@link HoldService}
|
* Exposed publicly in the {@link HoldService}
|
||||||
*
|
*
|
||||||
* @param nodeRef node reference
|
* @param nodeRef node reference
|
||||||
* @return boolean true if rma:hold or sub-type, false otherwise
|
* @return boolean true if rma:hold or sub-type, false otherwise
|
||||||
|
Reference in New Issue
Block a user