Changed AVMNodeConverter.ToAVMVersionPath() to return a

Pair<Integer, String>.  
Fixed avm.jsp which got busted by last checkin.
Added implementation of AddChild to AVMNodeService.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3983 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2006-09-30 17:51:15 +00:00
parent 8f6dbe4920
commit a985ba7723
2 changed files with 3 additions and 3 deletions

View File

@@ -395,7 +395,7 @@ public class ImportWebsiteDialog
{ {
if (file.isFile()) if (file.isFile())
{ {
String avmPath = (String)AVMNodeConverter.ToAVMVersionPath(root)[1]; String avmPath = AVMNodeConverter.ToAVMVersionPath(root).getSecond();
avmService.createFile(avmPath, file.getName(), new BufferedInputStream(new FileInputStream(file), BUFFER_SIZE)); avmService.createFile(avmPath, file.getName(), new BufferedInputStream(new FileInputStream(file), BUFFER_SIZE));
// create content node based on the filename // create content node based on the filename
/*FileInfo contentFile = fileFolderService.create(root, fileName, ContentModel.TYPE_AVM_PLAIN_CONTENT); /*FileInfo contentFile = fileFolderService.create(root, fileName, ContentModel.TYPE_AVM_PLAIN_CONTENT);
@@ -418,7 +418,7 @@ public class ImportWebsiteDialog
else else
{ {
//FileInfo fileInfo = fileFolderService.create(root, file.getName(), ContentModel.TYPE_AVM_PLAIN_FOLDER); //FileInfo fileInfo = fileFolderService.create(root, file.getName(), ContentModel.TYPE_AVM_PLAIN_FOLDER);
String avmPath = (String)AVMNodeConverter.ToAVMVersionPath(root)[1]; String avmPath = AVMNodeConverter.ToAVMVersionPath(root).getSecond();
avmService.createDirectory(avmPath, file.getName()); avmService.createDirectory(avmPath, file.getName());
importDirectory(file.getPath(), AVMNodeConverter.ToNodeRef(-1, avmPath + '/' + file.getName()));//fileInfo.getNodeRef() importDirectory(file.getPath(), AVMNodeConverter.ToNodeRef(-1, avmPath + '/' + file.getName()));//fileInfo.getNodeRef()

View File

@@ -119,7 +119,7 @@ public class OutputUtil
String generatedFileName = (String) String generatedFileName = (String)
nodeService.getProperty(generatedNodeRef, nodeService.getProperty(generatedNodeRef,
ContentModel.PROP_NAME); ContentModel.PROP_NAME);
String avmPath = (String)AVMNodeConverter.ToAVMVersionPath(nodeRef)[1]; String avmPath = AVMNodeConverter.ToAVMVersionPath(nodeRef).getSecond();
String avmStore = avmPath.substring(0, avmPath.indexOf(":/")); String avmStore = avmPath.substring(0, avmPath.indexOf(":/"));
String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore); String sandBoxUrl = AVMConstants.buildAVMStoreUrl(avmStore);