mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-10-08 14:51:49 +00:00
ACE-4699: Document preview is changed to the physical location after "Edit Offline \ Cancel Editing" action
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@118256 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -144,7 +144,10 @@ public class VirtualCheckOutCheckInServiceExtension extends
|
|||||||
@Override
|
@Override
|
||||||
public NodeRef cancelCheckout(NodeRef workingCopyNodeRef)
|
public NodeRef cancelCheckout(NodeRef workingCopyNodeRef)
|
||||||
{
|
{
|
||||||
return getTrait().cancelCheckout(virtualStore.materializeIfPossible(workingCopyNodeRef));
|
NodeRef materialOriginalNode = getTrait().cancelCheckout(virtualStore.materializeIfPossible(workingCopyNodeRef));
|
||||||
|
|
||||||
|
return virtualizeOriginalIfNeeded(workingCopyNodeRef,
|
||||||
|
materialOriginalNode);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@@ -375,4 +375,16 @@ public class VirtualCheckOutCheckInServiceExtensionTest extends VirtualizationIn
|
|||||||
sourceAssocs.get(0).getSourceRef());
|
sourceAssocs.get(0).getSourceRef());
|
||||||
checkOutCheckInService.cancelCheckout(workingCopyVirtualContext);
|
checkOutCheckInService.cancelCheckout(workingCopyVirtualContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void test_ACE_4699() throws Exception
|
||||||
|
{
|
||||||
|
checkOutCheckInService.checkout(originalContentNodeRef);
|
||||||
|
NodeRef workingCopyVirtualContext = nodeService.getChildByName(node,
|
||||||
|
ContentModel.ASSOC_CONTAINS,
|
||||||
|
PROP_WORKING_COPY_NAME);
|
||||||
|
assertNotNull(workingCopyVirtualContext);
|
||||||
|
NodeRef cancelCheckoutNodeRef = checkOutCheckInService.cancelCheckout(workingCopyVirtualContext);
|
||||||
|
assertEquals(originalContentNodeRef,
|
||||||
|
cancelCheckoutNodeRef);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user