Unit test for RM-579 (The records managment team can reject an unfiled record using an UI action)

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@46058 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Tuna Aksoy
2013-01-30 18:36:59 +00:00
parent 23a18a9408
commit 1292aeb469
3 changed files with 136 additions and 2 deletions

View File

@@ -43,6 +43,9 @@ public class RejectAction extends RMActionExecuterAbstractBase
/** Parameter names */
public static final String PARAM_REASON = "reason";
/** Action name */
public static final String NAME = "reject";
/**
* @see org.alfresco.repo.action.executer.ActionExecuterAbstractBase#executeImpl(org.alfresco.service.cmr.action.Action, org.alfresco.service.cmr.repository.NodeRef)
*/

View File

@@ -428,7 +428,7 @@ public class RecordServiceImpl implements RecordService,
}
@Override
public void rejectRecord(final NodeRef nodeRef, String reason)
public void rejectRecord(final NodeRef nodeRef, final String reason)
{
ParameterCheck.mandatory("NodeRef", nodeRef);
ParameterCheck.mandatoryString("Reason", reason);
@@ -463,7 +463,7 @@ public class RecordServiceImpl implements RecordService,
// save the reject reason
Map<QName, Serializable> aspectProperties = new HashMap<QName, Serializable>(1);
aspectProperties.put(PROP_REJECT_REASON, (Serializable) parentAssoc.getParentRef());
aspectProperties.put(PROP_REJECT_REASON, reason);
nodeService.addAspect(nodeRef, ASPECT_REJECT_REASON_RECORD, aspectProperties);
// move the record into the collaboration site