added a listener in order to not change a table name. Class GxtBorderLayoutPanel changed.
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/databases-manager-portlet@99891 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
a460e30453
commit
d4165113b8
|
@ -1826,7 +1826,10 @@ public class GxtBorderLayoutPanel extends ContentPanel {
|
||||||
private void displayTableName(String tableName) {
|
private void displayTableName(String tableName) {
|
||||||
rootLogger.log(Level.INFO, "displaying table name " + tableName
|
rootLogger.log(Level.INFO, "displaying table name " + tableName
|
||||||
+ " in the panel");
|
+ " in the panel");
|
||||||
Result table = new Result("Selected table", tableName);
|
final Result table = new Result("Selected table", tableName);
|
||||||
|
final ListStore<Result> store = new ListStore<Result>();
|
||||||
|
store.add(table);
|
||||||
|
|
||||||
// create column configuration
|
// create column configuration
|
||||||
List<ColumnConfig> configs = new ArrayList<ColumnConfig>();
|
List<ColumnConfig> configs = new ArrayList<ColumnConfig>();
|
||||||
ColumnConfig column = new ColumnConfig();
|
ColumnConfig column = new ColumnConfig();
|
||||||
|
@ -1842,13 +1845,22 @@ public class GxtBorderLayoutPanel extends ContentPanel {
|
||||||
|
|
||||||
TextField<String> textValue = new TextField<String>();
|
TextField<String> textValue = new TextField<String>();
|
||||||
// text.setAllowBlank(false);
|
// text.setAllowBlank(false);
|
||||||
column.setEditor(new CellEditor(textValue));
|
// column.setEditor(new CellEditor(textValue));
|
||||||
|
column.setEditor(new CellEditor(textValue){
|
||||||
|
// public Object preProcessValue(Object value) {
|
||||||
|
// System.out.println("value 1: " + store.getModels().get(0).getValue());
|
||||||
|
// return store.getModels().get(0).getValue();
|
||||||
|
// }
|
||||||
|
public Object postProcessValue(Object value) {
|
||||||
|
// System.out.println("value: " + store.findModel(table).getValue());
|
||||||
|
return store.findModel(table).getValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
configs.add(column);
|
configs.add(column);
|
||||||
ColumnModel cm = new ColumnModel(configs);
|
ColumnModel cm = new ColumnModel(configs);
|
||||||
|
|
||||||
ListStore<Result> store = new ListStore<Result>();
|
|
||||||
store.add(table);
|
|
||||||
|
|
||||||
// grid
|
// grid
|
||||||
EditorGrid<Result> grid = new EditorGrid<Result>(store, cm);
|
EditorGrid<Result> grid = new EditorGrid<Result>(store, cm);
|
||||||
// display information in the panel
|
// display information in the panel
|
||||||
|
|
Loading…
Reference in New Issue