- Fix to some issues created after recent changes to preview url generation code

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3959 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2006-09-28 09:49:59 +00:00
parent 0f2bf9a3e0
commit 842729f1bc
5 changed files with 32 additions and 23 deletions

View File

@@ -63,9 +63,9 @@ public class OutputUtil
OutputStream fileOut = avmService.createFile(parentPath, generatedFileName);
String fullAvmPath = parentPath + '/' + generatedFileName;
String avmStore = parentPath.substring(0, parentPath.indexOf(":/"));
String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore);
String avmStore = parentPath.substring(0, parentPath.indexOf(":/"));
String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore);
if (LOGGER.isDebugEnabled())
LOGGER.debug("Created file node for file: " +
@@ -119,14 +119,13 @@ public class OutputUtil
String generatedFileName = (String)
nodeService.getProperty(generatedNodeRef,
ContentModel.PROP_NAME);
String avmPath = (String)AVMNodeConverter.ToAVMVersionPath(nodeRef)[1];
String avmStore = avmPath.substring(0, avmPath.indexOf(":/"));
String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore);
String avmPath = (String)AVMNodeConverter.ToAVMVersionPath(nodeRef)[1];
String avmStore = avmPath.substring(0, avmPath.indexOf(":/"));
String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore);
if (LOGGER.isDebugEnabled())
LOGGER.debug("regenerating file node for : " + fileName + " (" +
nodeRef.toString() + ") to " + generatedNodeRef.toString());
// get a writer for the content and put the file
ContentWriter writer = contentService.getWriter(generatedNodeRef,