Updated in order to use setPublic(boolean bool)

Updated icons

git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace@131399 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Francesco Mangiacrapa 2016-09-15 14:42:41 +00:00
parent 53ea8e8d5f
commit ccdf36480c
8 changed files with 389 additions and 339 deletions

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<classpath> <classpath>
<classpathentry kind="src" output="target/workspace-6.13.1-SNAPSHOT/WEB-INF/classes" path="src/main/java"> <classpathentry kind="src" output="target/workspace-6.14.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
<attributes> <attributes>
<attribute name="optional" value="true"/> <attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/> <attribute name="maven.pomderived" value="true"/>
@ -26,5 +26,5 @@
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="con" path="com.google.gwt.eclipse.core.GWT_CONTAINER"/> <classpathentry kind="con" path="com.google.gwt.eclipse.core.GWT_CONTAINER"/>
<classpathentry kind="output" path="target/workspace-6.13.1-SNAPSHOT/WEB-INF/classes"/> <classpathentry kind="output" path="target/workspace-6.14.0-SNAPSHOT/WEB-INF/classes"/>
</classpath> </classpath>

View File

@ -557,7 +557,7 @@ public class AppController implements SubscriberInterface {
} }
GWT.log("FILE MODEL DOUBLE CLICK: "+fileModel); GWT.log("FILE MODEL DOUBLE CLICK: "+fileModel);
FolderModel folder = new FolderModel(fileModel.getIdentifier(), fileModel.getName(), fileModel.getParentFileModel(), true, fileModel.isShared(),fileModel.isVreFolder()); FolderModel folder = new FolderModel(fileModel.getIdentifier(), fileModel.getName(), fileModel.getParentFileModel(), true, fileModel.isShared(),fileModel.isVreFolder(), fileModel.isPublic());
updateStoreByRpc(folder); updateStoreByRpc(folder);
wsPortlet.getGridGroupContainer().setCurrentFolderView(folder); wsPortlet.getGridGroupContainer().setCurrentFolderView(folder);
loadBreadcrumbByFileModel(fileModel, true); loadBreadcrumbByFileModel(fileModel, true);
@ -867,7 +867,7 @@ public class AppController implements SubscriberInterface {
List<FileModel> ingnoreFile = new ArrayList<FileModel>(size); List<FileModel> ingnoreFile = new ArrayList<FileModel>(size);
for (FileModel file : targets) { for (FileModel file : targets) {
GWT.log("Checking file "+file); GWT.log("Checking file "+file);
if(file.getType()!=null && file.getType().equals(GXTFolderItemTypeEnum.SHARED_FOLDER.toString()) || file.isSpecialFolder()){ if(file.getType()!=null && file.getType().equals(GXTFolderItemTypeEnum.FOLDER_SHARED.toString()) || file.isSpecialFolder()){
ingnoreFile.add(file); ingnoreFile.add(file);
clearTargets.remove(file); clearTargets.remove(file);
} }
@ -1498,7 +1498,7 @@ public class AppController implements SubscriberInterface {
return; return;
//CREATE FOLDER PARENT FOR RPC //CREATE FOLDER PARENT FOR RPC
final FileModel parent = new FolderModel(folder.getIdentifier(), folder.getName(), folder.getParentFileModel(), true, folder.isShared(), folder.isVreFolder()); final FileModel parent = new FolderModel(folder.getIdentifier(), folder.getName(), folder.getParentFileModel(), true, folder.isShared(), folder.isVreFolder(), folder.isPublic());
wsPortlet.getGridGroupContainer().mask(ConstantsExplorer.LOADING,ConstantsExplorer.LOADINGSTYLE); wsPortlet.getGridGroupContainer().mask(ConstantsExplorer.LOADING,ConstantsExplorer.LOADINGSTYLE);
appContrExplorer.getRpcWorkspaceService().getFolderChildrenForFileGrid(parent, new AsyncCallback<List<FileGridModel>>() { appContrExplorer.getRpcWorkspaceService().getFolderChildrenForFileGrid(parent, new AsyncCallback<List<FileGridModel>>() {

View File

@ -1,7 +1,6 @@
package org.gcube.portlets.user.workspace.client.view; package org.gcube.portlets.user.workspace.client.view;
import org.gcube.portlets.user.workspace.client.ConstantsExplorer;
import org.gcube.portlets.user.workspace.client.ConstantsPortlet; import org.gcube.portlets.user.workspace.client.ConstantsPortlet;
import org.gcube.portlets.user.workspace.client.model.FileGridModel; import org.gcube.portlets.user.workspace.client.model.FileGridModel;
import org.gcube.portlets.user.workspace.client.model.FileModel; import org.gcube.portlets.user.workspace.client.model.FileModel;
@ -35,7 +34,7 @@ public class GxtListView extends LayoutContainer {
ListView<FileGridModel> view = new ListView<FileGridModel>() { ListView<FileGridModel> view = new ListView<FileGridModel>() {
@Override @Override
protected FileGridModel prepareData(FileGridModel model) { protected FileGridModel prepareData(FileGridModel model) {
String s = model.get(ConstantsExplorer.NAME); String s = model.get(FileModel.NAME);
model.set("shortName", Format.ellipse(s, 15)); model.set("shortName", Format.ellipse(s, 15));
return model; return model;
} }

View File

@ -173,7 +173,7 @@ public class WorkspaceFeaturesView extends Composite {
overFolderlk.setAnimation(false); overFolderlk.setAnimation(false);
overFolderlk.setWidget(flk); overFolderlk.setWidget(flk);
overFolderlk.setHeading("Workspace Folder Link"); overFolderlk.setHeading("Workspace Folder Link");
String icon = "<span style=\"margin-right:5px\">"+Resources.getIconFolderLink().getSafeHtml().asString()+"</span>"; String icon = "<span style=\"margin-right:5px\">"+Resources.getIconFolderPublic().getSafeHtml().asString()+"</span>";
overFolderlk.setText(icon+"The owner or administrator can create the Folder Link as public link in order to allow 'guest' users to access to the content of the folder (and its sub-folders). " + overFolderlk.setText(icon+"The owner or administrator can create the Folder Link as public link in order to allow 'guest' users to access to the content of the folder (and its sub-folders). " +
"The 'guest' user will access in read-only mode and it will can navigate and download files of the Folder Link (and its subfolders). You can send the Folder Link to anyone by pasting it into Workspace Message, your emails, instant messages, etc."); "The 'guest' user will access in read-only mode and it will can navigate and download files of the Folder Link (and its subfolders). You can send the Folder Link to anyone by pasting it into Workspace Message, your emails, instant messages, etc.");
overFolderlk.setHtml(true); overFolderlk.setHtml(true);

View File

@ -82,15 +82,15 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
public GxtGridFilterGroupPanel(boolean group) { public GxtGridFilterGroupPanel(boolean group) {
// setLayout(new FitLayout()); // setLayout(new FitLayout());
setId("GxtGridFilterGroupPanel "+Random.nextInt()); setId("GxtGridFilterGroupPanel "+Random.nextInt());
ColumnConfig icon = new ColumnConfig(ConstantsExplorer.ICON, "", 25); ColumnConfig icon = new ColumnConfig(FileModel.ICON, "", 25);
icon.setSortable(false); icon.setSortable(false);
ColumnConfig name = new ColumnConfig(ConstantsExplorer.NAME, ConstantsExplorer.NAME, 300); ColumnConfig name = new ColumnConfig(FileGridModel.NAME, FileGridModel.NAME, 300);
ColumnConfig type = new ColumnConfig(ConstantsExplorer.TYPE, ConstantsExplorer.TYPE, 50); ColumnConfig type = new ColumnConfig(FileGridModel.TYPE, FileGridModel.TYPE, 50);
ColumnConfig lastUpdate = new ColumnConfig(ConstantsExplorer.LASTMODIFIED, "Last Update", 100); ColumnConfig lastUpdate = new ColumnConfig(FileGridModel.LASTMODIFIED, "Last Update", 100);
lastUpdate.setDateTimeFormat(DateTimeFormat.getFormat("dd MMM hh:mm aaa yyyy")); lastUpdate.setDateTimeFormat(DateTimeFormat.getFormat("dd MMM hh:mm aaa yyyy"));
ColumnConfig category = new ColumnConfig(ConstantsExplorer.SHORTCUTCATEGORY, ConstantsExplorer.SHORTCUTCATEGORY, 100); ColumnConfig category = new ColumnConfig(FileModel.SHORTCUTCATEGORY, FileModel.SHORTCUTCATEGORY, 100);
ColumnConfig size = new ColumnConfig(ConstantsExplorer.SIZE, ConstantsExplorer.SIZE, 50); ColumnConfig size = new ColumnConfig(FileGridModel.SIZE, FileGridModel.SIZE, 50);
ColumnConfig ownerFullName = new ColumnConfig(ConstantsExplorer.OWNERFULLNAME, ConstantsExplorer.OWNER, 100); ColumnConfig ownerFullName = new ColumnConfig(FileGridModel.OWNERFULLNAME, FileGridModel.OWNER, 100);
size.setEditor(new CellEditor(new NumberField())); size.setEditor(new CellEditor(new NumberField()));
@ -113,10 +113,10 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
view.setShowGroupedColumn(false); view.setShowGroupedColumn(false);
view.setForceFit(true); view.setForceFit(true);
grid.setView(view); grid.setView(view);
view.setEmptyText(ConstantsExplorer.EMPTY); view.setEmptyText(FileGridModel.EMPTY);
if(group){ if(group){
store.groupBy(ConstantsExplorer.SHORTCUTCATEGORY); store.groupBy(FileGridModel.SHORTCUTCATEGORY);
groupingEnabled = true; groupingEnabled = true;
} }
@ -161,10 +161,10 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
GridFilters filters = new GridFilters(); GridFilters filters = new GridFilters();
filters.setLocal(true); filters.setLocal(true);
StringFilter nameFilter = new StringFilter(ConstantsExplorer.NAME); StringFilter nameFilter = new StringFilter(FileGridModel.NAME);
StringFilter authorFilter = new StringFilter(ConstantsExplorer.TYPE); StringFilter authorFilter = new StringFilter(FileGridModel.TYPE);
DateFilter dateFilter = new DateFilter(ConstantsExplorer.LASTMODIFIED); DateFilter dateFilter = new DateFilter(FileGridModel.LASTMODIFIED);
NumericFilter sizeFilter = new NumericFilter(ConstantsExplorer.SIZE); NumericFilter sizeFilter = new NumericFilter(FileGridModel.SIZE);
filters.addFilter(nameFilter); filters.addFilter(nameFilter);
filters.addFilter(authorFilter); filters.addFilter(authorFilter);
@ -172,7 +172,7 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
filters.addFilter(sizeFilter); filters.addFilter(sizeFilter);
// grid.setStyleAttribute("borderTop", "none"); // grid.setStyleAttribute("borderTop", "none");
grid.setAutoExpandColumn(ConstantsExplorer.NAME); grid.setAutoExpandColumn(FileGridModel.NAME);
grid.setBorders(false); grid.setBorders(false);
grid.setStripeRows(true); grid.setStripeRows(true);
grid.setColumnLines(true); grid.setColumnLines(true);
@ -262,7 +262,7 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
public void disableGrouping() { public void disableGrouping() {
GroupingStore<FileGridModel> groupingStore = null; GroupingStore<FileGridModel> groupingStore = null;
if (this.getStore() instanceof GroupingStore) { if (this.getStore() instanceof GroupingStore) {
groupingStore = (GroupingStore<FileGridModel>) this.getStore(); groupingStore = this.getStore();
if (groupingStore != null) { if (groupingStore != null) {
groupingStore.clearGrouping(); groupingStore.clearGrouping();
} }
@ -276,9 +276,9 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
public void enableGrouping() { public void enableGrouping() {
GroupingStore<FileGridModel> groupingStore = null; GroupingStore<FileGridModel> groupingStore = null;
if (this.getStore() instanceof GroupingStore) { if (this.getStore() instanceof GroupingStore) {
groupingStore = (GroupingStore<FileGridModel>) this.getStore(); groupingStore = this.getStore();
if (groupingStore != null) { if (groupingStore != null) {
groupingStore.groupBy(ConstantsExplorer.SHORTCUTCATEGORY); groupingStore.groupBy(FileGridModel.SHORTCUTCATEGORY);
} }
this.groupingEnabled = true; this.groupingEnabled = true;
} }
@ -449,9 +449,9 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
Record record = store.getRecord(fileTarget); Record record = store.getRecord(fileTarget);
if(record!=null){ if(record!=null){
if(extension!= null) if(extension!= null)
record.set(ConstantsExplorer.NAME, newName+extension); record.set(FileGridModel.NAME, newName+extension);
else else
record.set(ConstantsExplorer.NAME, newName); record.set(FileGridModel.NAME, newName);
return true; return true;
} }
@ -501,9 +501,9 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
Record record = store.getRecord(fileTarget); Record record = store.getRecord(fileTarget);
if(record!=null){ if(record!=null){
if(extension!= null) if(extension!= null)
record.set(ConstantsExplorer.NAME, newName+extension); record.set(FileGridModel.NAME, newName+extension);
else else
record.set(ConstantsExplorer.NAME, newName); record.set(FileGridModel.NAME, newName);
return true; return true;
} }
@ -525,7 +525,7 @@ public class GxtGridFilterGroupPanel extends LayoutContainer {
* @return the file grid model by identifier * @return the file grid model by identifier
*/ */
public FileGridModel getFileGridModelByIdentifier(String id){ public FileGridModel getFileGridModelByIdentifier(String id){
return (FileGridModel) store.findModel(ConstantsExplorer.IDENTIFIER, id); return store.findModel(FileGridModel.IDENTIFIER, id);
} }
/** /**

View File

@ -4,7 +4,6 @@ import java.util.Arrays;
import java.util.List; import java.util.List;
import org.gcube.portlets.user.workspace.client.AppController; import org.gcube.portlets.user.workspace.client.AppController;
import org.gcube.portlets.user.workspace.client.ConstantsExplorer;
import org.gcube.portlets.user.workspace.client.ConstantsPortlet; import org.gcube.portlets.user.workspace.client.ConstantsPortlet;
import org.gcube.portlets.user.workspace.client.event.GridElementSelectedEvent; import org.gcube.portlets.user.workspace.client.event.GridElementSelectedEvent;
import org.gcube.portlets.user.workspace.client.event.GridElementUnSelectedEvent; import org.gcube.portlets.user.workspace.client.event.GridElementUnSelectedEvent;
@ -31,12 +30,13 @@ import com.extjs.gxt.ui.client.widget.grid.filters.GridFilters;
import com.extjs.gxt.ui.client.widget.grid.filters.StringFilter; import com.extjs.gxt.ui.client.widget.grid.filters.StringFilter;
import com.extjs.gxt.ui.client.widget.layout.FitLayout; import com.extjs.gxt.ui.client.widget.layout.FitLayout;
/**
* This class is not used
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
/**
* The Class GxtGridFilterPanel.
*
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
* Sep 15, 2016
*/
public class GxtGridFilterPanel extends LayoutContainer { public class GxtGridFilterPanel extends LayoutContainer {
private ContentPanel cp = new ContentPanel(); private ContentPanel cp = new ContentPanel();
@ -44,12 +44,15 @@ public class GxtGridFilterPanel extends LayoutContainer {
private FileGridModel currenItemSelected = null; private FileGridModel currenItemSelected = null;
private FileModel currentFolderView = null; private FileModel currentFolderView = null;
/**
* Instantiates a new gxt grid filter panel.
*/
public GxtGridFilterPanel() { public GxtGridFilterPanel() {
setLayout(new FitLayout()); setLayout(new FitLayout());
ColumnConfig name = new ColumnConfig(ConstantsExplorer.NAME, ConstantsExplorer.NAME, 400); ColumnConfig name = new ColumnConfig(FileGridModel.NAME, FileGridModel.NAME, 400);
ColumnConfig type = new ColumnConfig(ConstantsExplorer.TYPE, ConstantsExplorer.TYPE, 100); ColumnConfig type = new ColumnConfig(FileGridModel.TYPE, FileGridModel.TYPE, 100);
ColumnConfig creationDate = new ColumnConfig(ConstantsExplorer.GRIDCOLUMNCREATIONDATE, ConstantsExplorer.GRIDCOLUMNCREATIONDATE, 100); ColumnConfig creationDate = new ColumnConfig(FileGridModel.GRIDCOLUMNCREATIONDATE, FileGridModel.GRIDCOLUMNCREATIONDATE, 100);
ColumnConfig size = new ColumnConfig(ConstantsExplorer.SIZE, ConstantsExplorer.SIZE, 50); ColumnConfig size = new ColumnConfig(FileGridModel.SIZE, FileGridModel.SIZE, 50);
ColumnModel cm = new ColumnModel(Arrays.asList(name, type, creationDate, size)); ColumnModel cm = new ColumnModel(Arrays.asList(name, type, creationDate, size));
@ -61,9 +64,9 @@ public class GxtGridFilterPanel extends LayoutContainer {
GridFilters filters = new GridFilters(); GridFilters filters = new GridFilters();
filters.setLocal(true); filters.setLocal(true);
StringFilter nameFilter = new StringFilter(ConstantsExplorer.NAME); StringFilter nameFilter = new StringFilter(FileGridModel.NAME);
StringFilter authorFilter = new StringFilter(ConstantsExplorer.TYPE); StringFilter authorFilter = new StringFilter(FileGridModel.TYPE);
StringFilter sizeFilter = new StringFilter(ConstantsExplorer.SIZE); StringFilter sizeFilter = new StringFilter(FileGridModel.SIZE);
filters.addFilter(nameFilter); filters.addFilter(nameFilter);
filters.addFilter(authorFilter); filters.addFilter(authorFilter);
@ -75,7 +78,7 @@ public class GxtGridFilterPanel extends LayoutContainer {
setAlphanumericStoreSorter(grid); setAlphanumericStoreSorter(grid);
grid.setAutoExpandColumn(ConstantsExplorer.NAME); grid.setAutoExpandColumn(FileGridModel.NAME);
grid.setBorders(false); grid.setBorders(false);
grid.setStripeRows(true); grid.setStripeRows(true);
grid.setColumnLines(true); grid.setColumnLines(true);
@ -121,11 +124,20 @@ public class GxtGridFilterPanel extends LayoutContainer {
add(cp); add(cp);
} }
/**
* Reset store.
*/
private void resetStore(){ private void resetStore(){
store.removeAll(); store.removeAll();
} }
/**
* Update store.
*
* @param result the result
* @return true, if successful
*/
public boolean updateStore(List<FileGridModel> result){ public boolean updateStore(List<FileGridModel> result){
resetStore(); resetStore();
@ -136,6 +148,11 @@ public class GxtGridFilterPanel extends LayoutContainer {
return false; return false;
} }
/**
* Gets the selected item.
*
* @return the selected item
*/
public FileGridModel getSelectedItem(){ public FileGridModel getSelectedItem(){
return currenItemSelected; return currenItemSelected;
@ -144,9 +161,10 @@ public class GxtGridFilterPanel extends LayoutContainer {
/** /**
* Delete item.
* *
* @param identifier (MANDATORY) * @param identifier (MANDATORY)
* @return * @return true, if successful
*/ */
public boolean deleteItem(String identifier) { public boolean deleteItem(String identifier) {
@ -165,16 +183,34 @@ public class GxtGridFilterPanel extends LayoutContainer {
} }
/**
* Gets the current folder view.
*
* @return the current folder view
*/
public FileModel getCurrentFolderView() { public FileModel getCurrentFolderView() {
return currentFolderView; return currentFolderView;
} }
/**
* Sets the current folder view.
*
* @param currentFolderView the new current folder view
*/
public void setCurrentFolderView(FileModel currentFolderView) { public void setCurrentFolderView(FileModel currentFolderView) {
this.currentFolderView = currentFolderView; this.currentFolderView = currentFolderView;
} }
/**
* Rename item.
*
* @param itemIdentifier the item identifier
* @param newName the new name
* @param extension the extension
* @return true, if successful
*/
public boolean renameItem(String itemIdentifier, String newName, String extension) { public boolean renameItem(String itemIdentifier, String newName, String extension) {
if(itemIdentifier!=null){ if(itemIdentifier!=null){
@ -184,9 +220,9 @@ public class GxtGridFilterPanel extends LayoutContainer {
Record record = store.getRecord(fileTarget); Record record = store.getRecord(fileTarget);
if(record!=null){ if(record!=null){
if(extension!= null) if(extension!= null)
record.set(ConstantsExplorer.NAME, newName+extension); record.set(FileGridModel.NAME, newName+extension);
else else
record.set(ConstantsExplorer.NAME, newName); record.set(FileGridModel.NAME, newName);
return true; return true;
} }
@ -201,6 +237,11 @@ public class GxtGridFilterPanel extends LayoutContainer {
} }
/**
* Sets the alphanumeric store sorter.
*
* @param grid the new alphanumeric store sorter
*/
private void setAlphanumericStoreSorter(Grid<FileGridModel> grid){ private void setAlphanumericStoreSorter(Grid<FileGridModel> grid){
// Sorting files // Sorting files
@ -222,10 +263,21 @@ public class GxtGridFilterPanel extends LayoutContainer {
}); });
} }
/**
* Gets the file grid model by identifier.
*
* @param id the id
* @return the file grid model by identifier
*/
public FileGridModel getFileGridModelByIdentifier(String id){ public FileGridModel getFileGridModelByIdentifier(String id){
return (FileGridModel) store.findModel(ConstantsExplorer.IDENTIFIER, id); return store.findModel(FileGridModel.IDENTIFIER, id);
} }
/**
* Gets the store.
*
* @return the store
*/
public ListStore<FileGridModel> getStore(){ public ListStore<FileGridModel> getStore(){
return store; return store;
} }

View File

@ -217,7 +217,7 @@ public class GxtToolBarItemFunctionality {
toolBar.add(new SeparatorToolItem()); toolBar.add(new SeparatorToolItem());
btnFolderLink = new Button("Folder Link", Resources.getIconFolderLink()); btnFolderLink = new Button("Folder Link", Resources.getIconFolderPublic());
btnFolderLink.setScale(ButtonScale.SMALL); btnFolderLink.setScale(ButtonScale.SMALL);
btnFolderLink.setIconAlign(IconAlign.TOP); btnFolderLink.setIconAlign(IconAlign.TOP);
btnFolderLink.setArrowAlign(ButtonArrowAlign.BOTTOM); btnFolderLink.setArrowAlign(ButtonArrowAlign.BOTTOM);

View File

@ -5,7 +5,6 @@ import java.util.Arrays;
import java.util.List; import java.util.List;
import org.gcube.portlets.user.workspace.client.AppController; import org.gcube.portlets.user.workspace.client.AppController;
import org.gcube.portlets.user.workspace.client.ConstantsExplorer;
import org.gcube.portlets.user.workspace.client.event.TrashEvent; import org.gcube.portlets.user.workspace.client.event.TrashEvent;
import org.gcube.portlets.user.workspace.client.interfaces.GXTFolderItemTypeEnum; import org.gcube.portlets.user.workspace.client.interfaces.GXTFolderItemTypeEnum;
import org.gcube.portlets.user.workspace.client.model.FileGridModel; import org.gcube.portlets.user.workspace.client.model.FileGridModel;
@ -269,9 +268,9 @@ public class TrashInfoContainer extends LayoutContainer {
public void initGrid() { public void initGrid() {
ColumnConfig icon = new ColumnConfig(ConstantsExplorer.ICON, "", 25); ColumnConfig icon = new ColumnConfig(FileGridModel.ICON, "", 25);
ColumnConfig name = createSortableColumnConfig(ConstantsExplorer.NAME, ConstantsExplorer.NAME, 200); ColumnConfig name = createSortableColumnConfig(FileGridModel.NAME, FileGridModel.NAME, 200);
ColumnConfig type = createSortableColumnConfig(ConstantsExplorer.TYPE, ConstantsExplorer.TYPE, 80); ColumnConfig type = createSortableColumnConfig(FileGridModel.TYPE, FileGridModel.TYPE, 80);
ColumnConfig originalPath = createSortableColumnConfig(FileTrashedModel.STOREINFO.ORIGINALPATH.toString(), "Original Path", 200); ColumnConfig originalPath = createSortableColumnConfig(FileTrashedModel.STOREINFO.ORIGINALPATH.toString(), "Original Path", 200);
ColumnConfig deleteDate = createSortableColumnConfig(FileTrashedModel.STOREINFO.DELETEDATE.toString(), "Deleted Date", 90); ColumnConfig deleteDate = createSortableColumnConfig(FileTrashedModel.STOREINFO.DELETEDATE.toString(), "Deleted Date", 90);
deleteDate.setDateTimeFormat(DateTimeFormat.getFormat("dd MMM hh:mm aaa yyyy")); deleteDate.setDateTimeFormat(DateTimeFormat.getFormat("dd MMM hh:mm aaa yyyy"));
@ -313,8 +312,8 @@ public class TrashInfoContainer extends LayoutContainer {
filters.setLocal(true); filters.setLocal(true);
StringFilter nameFilter = new StringFilter(ConstantsExplorer.NAME); StringFilter nameFilter = new StringFilter(FileGridModel.NAME);
StringFilter typeFilter = new StringFilter(ConstantsExplorer.TYPE); StringFilter typeFilter = new StringFilter(FileGridModel.TYPE);
DateFilter dateFilter = new DateFilter(FileTrashedModel.STOREINFO.DELETEDATE.toString()); DateFilter dateFilter = new DateFilter(FileTrashedModel.STOREINFO.DELETEDATE.toString());
filters.addFilter(nameFilter); filters.addFilter(nameFilter);
@ -421,7 +420,7 @@ public class TrashInfoContainer extends LayoutContainer {
*/ */
public FileTrashedModel getFileModelByIdentifier(String identifier){ public FileTrashedModel getFileModelByIdentifier(String identifier){
return store.findModel(ConstantsExplorer.IDENTIFIER, identifier); return store.findModel(FileGridModel.IDENTIFIER, identifier);
} }