Commit 1bb01cf1 authored by 杜科's avatar 杜科

update

parent e7d75b33
......@@ -20,6 +20,7 @@ import wt.epm.EPMDocumentMasterIdentity;
import wt.epm.workspaces.EPMWorkspace;
import wt.fc.*;
import wt.fc.collections.WTCollection;
import wt.fc.collections.WTValuedHashMap;
import wt.folder.Folder;
import wt.folder.FolderEntry;
import wt.folder.FolderHelper;
......@@ -765,6 +766,26 @@ public class CommonUtil implements RemoteAccess {
}
return folderList;
}
/**
* @描述 对象关联文件夹
* @作者 Pengfei,Li
* @时间 2015-9-11上午10:58:38
*/
public static void setFolder(String folderName, WTContainerRef containerRef, Persistable persistable) throws WTException {
Folder location = null;
try {
location = FolderHelper.service.getFolder(folderName, containerRef);
} catch (WTException e) {
location = null;
}
if (location == null)
location = FolderHelper.service.saveFolderPath(folderName, containerRef);
if (location != null) {
WTValuedHashMap map = new WTValuedHashMap();
map.put(persistable, location);
FolderHelper.assignLocations(map);
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment