refs 2521: Explore the possibility to port the StatMan interface onto Dataminer

https://support.d4science.org/issues/2521

Fixed default value selected for columns field

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/data-miner-manager@129052 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2016-06-10 13:06:52 +00:00
parent 5ac6e03356
commit 87fc6763bd
2 changed files with 11 additions and 8 deletions

View File

@ -13,6 +13,7 @@ import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnParameter;
import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.cell.core.client.form.ComboBoxCell.TriggerAction;
@ -73,7 +74,6 @@ public class ColumnFld extends AbstractFld implements
comboBox.setEditable(false);
comboBox.setTriggerAction(TriggerAction.ALL);
comboBox.setEnabled(false);
HtmlLayoutContainer descr;
if (columnParameter.getDescription() == null) {
@ -159,18 +159,22 @@ public class ColumnFld extends AbstractFld implements
} else {
store.clear();
store.commitChanges();
comboBox.clear();
ArrayList<ColumnItem> columns = tableItemSimple.getColumns();
if (columns != null) {
store.addAll(columns);
store.commitChanges();
Log.debug("DefaultColumn: "+defaultColumn);
for (ColumnItem columnItem : columns) {
if (columnItem.getName().compareTo(defaultColumn) == 0) {
Log.debug("ColumnItem: "+ columnItem);
if (columnItem.getName().compareToIgnoreCase(defaultColumn) == 0) {
comboBox.setValue(columnItem);
break;
}
}
store.commitChanges();
}
comboBox.clear();
comboBox.setEnabled(true);
showFieldWithSelection(tableItemSimple);
}

View File

@ -40,15 +40,14 @@
<entry-point
class='org.gcube.portlets.user.dataminermanager.client.DataMinerManager' />
<!--
<set-property name="log_ConsoleLogger" value="ENABLED" /> <set-property
<!-- <set-property name="log_ConsoleLogger" value="ENABLED" /> <set-property
name="log_DivLogger" value="ENABLED" /> <set-property name="log_GWTLogger"
value="ENABLED" /> <set-property name="log_SystemLogger" value="ENABLED"
/> -->
/> -->
<!-- Not in GWT 2.6 <set-property name="log_FirebugLogger" value="ENABLED"
/> -->
<set-property name="log_ConsoleLogger" value="DISABLED" />
<set-property name="log_DivLogger" value="DISABLED" />
<set-property name="log_GWTLogger" value="DISABLED" />