Merge branch 'master' into feature/RM-4921_ExceptionsDoneOnTransactionCommit

This commit is contained in:
Ramona Popa
2017-05-09 14:23:05 +03:00
5 changed files with 7 additions and 7 deletions

View File

@@ -223,7 +223,7 @@ public class RecordFolderAPI extends RMModelRequest
/**
* Create a record from file resource
*
* @param electronicRecordModel {@link Record} for electronic record to be created
* @param recordModel {@link Record} for electronic record to be created
* @param recordContent {@link File} pointing to the content of the electronic record to be created
* @param recordFolderId The identifier of a record folder
* @return newly created {@link Record}

View File

@@ -488,7 +488,7 @@ public class RecordCategoryTests extends BaseRMRestTest
{
// The record category to be created
RecordCategory recordCategoryModel = RecordCategory.builder()
.name(RECORD_CATEGORY_NAME)
.name(RECORD_CATEGORY_NAME + getRandomAlphanumeric())
.nodeType(RECORD_CATEGORY_TYPE)
.build();
FilePlanAPI filePlansAPI = getRestAPIFactory().getFilePlansAPI();
@@ -593,7 +593,7 @@ public class RecordCategoryTests extends BaseRMRestTest
{
// The record category to be created
RecordCategory recordCategoryModel = RecordCategory.builder()
.name(RECORD_CATEGORY_NAME+getRandomAlphanumeric())
.name(RECORD_CATEGORY_NAME + getRandomAlphanumeric())
.nodeType(RECORD_CATEGORY_TYPE)
.build();
FilePlanAPI filePlansAPI = getRestAPIFactory().getFilePlansAPI();

View File

@@ -131,7 +131,7 @@ public class RecordFolderTests extends BaseRMRestTest
/**
* <pre>
* Given that RM site is created
* When I use the API to create a children inside a record folder with wron types
* When I use the API to create a children of wrong type inside a record folder
* Then the operation fails
* </pre>
*/
@@ -141,7 +141,7 @@ public class RecordFolderTests extends BaseRMRestTest
dataProvider = "childrenNotAllowedForFolder"
)
public void createRecordFolderIntoSpecialContainers(String nodeType) throws Exception
public void createInvalidChildrenForFolder(String nodeType) throws Exception
{
//create a record folder
RecordCategoryChild folder = createCategoryFolderInFilePlan();

View File

@@ -106,7 +106,7 @@ public class UnfiledRecordsFolderTests extends BaseRMRestTest
{ getRestAPIFactory().getUnfiledContainersAPI().getUnfiledContainer(UNFILED_RECORDS_CONTAINER_ALIAS).getId() },
{ getRestAPIFactory().getTransferContainerAPI().getTransferContainer(TRANSFERS_ALIAS).getId() },
// an arbitrary record category
{ createRootCategory(RECORD_CATEGORY_NAME).getId() },
{ createRootCategory(RECORD_CATEGORY_NAME + getRandomAlphanumeric()).getId() },
// an arbitrary unfiled records folder
{createCategoryFolderInFilePlan().getId()},
{createUnfiledContainerChild(UNFILED_RECORDS_CONTAINER_ALIAS, "Unfiled Record " + getRandomAlphanumeric(), CONTENT_TYPE).getId() }

View File

@@ -1798,7 +1798,7 @@ public class RecordServiceImpl extends BaseBehaviourBean
)
public void onContentUpdate(NodeRef nodeRef, boolean newContent)
{
if (!nodeService.hasAspect(nodeRef, ContentModel.ASPECT_HIDDEN) && !nodeService.hasAspect(nodeRef, ContentModel.ASPECT_LOCKABLE))
if (nodeService.exists(nodeRef) && !nodeService.hasAspect(nodeRef, ContentModel.ASPECT_HIDDEN) && !nodeService.hasAspect(nodeRef, ContentModel.ASPECT_LOCKABLE))
{
appendIdentifierToName(nodeService, nodeRef);
}