cell = hasCell.getCell();
-
+
// set the width of the text input cell
- if (value!=null&&value.getResourceType()!=null) {
- switch(value.getResourceType()){
+ if (value != null && value.getResourceType() != null) {
+ switch (value.getResourceType()) {
case CHART:
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
break;
case CODELIST:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
}
break;
case CSV:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
} else {
- if(((String)hasCell.getValue(value)).compareTo("save")==0){
+ if (((String) hasCell.getValue(value)).compareTo("save") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
@@ -491,26 +489,26 @@ public class ResourcesPanel extends FramedPanel {
sb.appendHtmlConstant("");
break;
case GENERIC_TABLE:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
}
break;
case GUESSER:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
}
break;
case JSON:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
} else {
- if(((String)hasCell.getValue(value)).compareTo("save")==0){
+ if (((String) hasCell.getValue(value)).compareTo("save") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
@@ -518,12 +516,12 @@ public class ResourcesPanel extends FramedPanel {
}
break;
case MAP:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
} else {
- if(((String)hasCell.getValue(value)).compareTo("open")==0){
+ if (((String) hasCell.getValue(value)).compareTo("open") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
@@ -531,12 +529,12 @@ public class ResourcesPanel extends FramedPanel {
}
break;
case SDMX:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
} else {
- if(((String)hasCell.getValue(value)).compareTo("open")==0){
+ if (((String) hasCell.getValue(value)).compareTo("open") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
@@ -544,25 +542,21 @@ public class ResourcesPanel extends FramedPanel {
}
break;
default:
- if(((String)hasCell.getValue(value)).compareTo("delete")==0){
+ if (((String) hasCell.getValue(value)).compareTo("delete") == 0) {
sb.appendHtmlConstant("");
cell.render(context, hasCell.getValue(value), sb);
sb.appendHtmlConstant("
");
}
break;
-
+
}
-
-
-
- }
-
-
+
+ }
+
}
};
-
ColumnConfig actionColumn = new ColumnConfig(
new IdentityValueProvider("Action"));
@@ -651,7 +645,6 @@ public class ResourcesPanel extends FramedPanel {
grid.getView().setEmptyText(msgs.gridEmptyText());
expanderColumn.initPlugin(grid);
-
createContextMenu();
@@ -674,6 +667,8 @@ public class ResourcesPanel extends FramedPanel {
private boolean select(ResourceTDDescriptor item, String searchTerm) {
if (item.getName() != null && item.getName().toLowerCase().contains(searchTerm.toLowerCase()))
return true;
+ if (item.getCreationDate() != null && item.getCreationDate().toLowerCase().contains(searchTerm.toLowerCase()))
+ return true;
return false;
}