bug fixed on searching
git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace-tree-widget@92217 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
39d116792d
commit
8fe2a21347
|
@ -1034,10 +1034,13 @@ public class GWTWorkspaceBuilder {
|
|||
|
||||
case SHARED_FOLDER:
|
||||
|
||||
WorkspaceSharedFolder shared = (WorkspaceSharedFolder) item;
|
||||
String name = shared.isVreFolder()?shared.getDisplayName():item.getName();
|
||||
//ATTENTION: SEARCH ITEM IS NOT CASTABLE AT WorkspaceSharedFolder
|
||||
|
||||
// WorkspaceSharedFolder shared = (WorkspaceSharedFolder) item;
|
||||
// String name = shared.isVreFolder()?shared.getDisplayName():item.getName();
|
||||
|
||||
// fileGridModel = (FolderGridModel) new FolderGridModel(item.getId(), item.getName(), toDate(item.getCreationDate()), parentFileModel, -1, true, false);
|
||||
fileGridModel = (FolderGridModel) new FolderGridModel(item.getId(), name, toDate(item.getLastModified()), parentFileModel, -1, true, true,shared.isVreFolder());
|
||||
fileGridModel = (FolderGridModel) new FolderGridModel(item.getId(), item.getName(), toDate(item.getLastModified()), parentFileModel, -1, true, true, item.isVreFolder());
|
||||
fileGridModel.setType(GXTFolderItemTypeEnum.SHARED_FOLDER.toString());
|
||||
fileGridModel.setShortcutCategory(GXTCategoryItemInterface.SMF_DOCUMENTS);
|
||||
fileGridModel.setShareable(true);
|
||||
|
@ -1053,14 +1056,14 @@ public class GWTWorkspaceBuilder {
|
|||
|
||||
}
|
||||
|
||||
//TODO ISSHARED IN SEARCH ITEM IN HL
|
||||
//TODO ISSHARED IN SEARCH ITEM IN HL TO RETRIEVE SHARE ON WORKSPACEITEM
|
||||
|
||||
//ACCOUNTING
|
||||
// fileGridModel.setMarkAsRead(item.isMarkedAsRead());
|
||||
|
||||
/*
|
||||
|
||||
//OWNER
|
||||
if(fileGridModel.isShared()){ //IS READ FROM HL ONLY IF THE ITEM IS SHARED
|
||||
/*if(fileGridModel.isShared()){ //IS READ FROM HL ONLY IF THE ITEM IS SHARED
|
||||
String portalLogin = item.getOwner();
|
||||
if(portalLogin!=null){
|
||||
String fullName = portalLogin;
|
||||
|
@ -1074,8 +1077,8 @@ public class GWTWorkspaceBuilder {
|
|||
else{
|
||||
if(userLogged!=null)
|
||||
fileGridModel.setOwnerFullName(userLogged.getName());
|
||||
}
|
||||
*/
|
||||
}*/
|
||||
|
||||
|
||||
return fileGridModel;
|
||||
|
||||
|
|
|
@ -360,6 +360,8 @@ public class LocalUploadServlet extends HttpServlet {
|
|||
if(!isOverwrite){
|
||||
//we need to recalculate the item name
|
||||
itemName = WorkspaceUtil.getUniqueName(itemName, destinationFolder);
|
||||
logger.trace("before calling createExternalFile - itemName is: "+itemName);
|
||||
logger.trace("before calling createExternalFile - contentType is: "+contentType);
|
||||
createdItem = WorkspaceUtil.createExternalFile(destinationFolder, itemName, "", contentType, uploadItem);
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue