refs 6548: TDM - Migrate TabMan to new PortalContext
Task-Url: https://support.d4science.org/issues/6548 Updated to new PortalContext git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-csv-import-widget@141739 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
5b12756205
commit
d55f686b43
|
@ -1,12 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" output="target/tabular-data-csv-import-widget-2.8.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
||||
<classpathentry kind="src" path="src/main/java">
|
||||
<attributes>
|
||||
<attribute name="optional" value="true"/>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry excluding="**" kind="src" output="target/tabular-data-csv-import-widget-2.8.0-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
|
||||
<classpathentry excluding="**" kind="src" path="src/main/resources">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
|
@ -33,5 +33,5 @@
|
|||
<attribute name="org.eclipse.jst.component.nondependency" value=""/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry kind="output" path="target/tabular-data-csv-import-widget-2.8.0-SNAPSHOT/WEB-INF/classes"/>
|
||||
<classpathentry kind="output" path="target/tabular-data-csv-import-widget-2.9.0-SNAPSHOT/WEB-INF/classes"/>
|
||||
</classpath>
|
||||
|
|
|
@ -1,45 +1,60 @@
|
|||
<ReleaseNotes>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-8-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-9-0"
|
||||
date="2017-02-15">
|
||||
<Change>Updated to PortalContext [ticket #6548]</Change>
|
||||
</Changeset>
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-8-0"
|
||||
date="2015-10-15">
|
||||
<Change>Updated support to WorkspaceExplorer [ticket #428]</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-7-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-7-0"
|
||||
date="2015-07-03">
|
||||
<Change>Updated Licenses</Change>
|
||||
<Change>Updated dependencies</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-6-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-6-0"
|
||||
date="2015-02-16">
|
||||
<Change>Updated dependency</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-5-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-5-0"
|
||||
date="2015-02-16">
|
||||
<Change>Added more feedback on csv import [issue #3218]</Change>
|
||||
<Change>Updated to GWT 2.6.1</Change>
|
||||
<Change>Updated to GXT 3.1.1</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-4-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-4-0"
|
||||
date="2014-10-31">
|
||||
<Change>Fixed Final and Lock error</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-3-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-3-0"
|
||||
date="2014-09-12">
|
||||
<Change>Updated monitor</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-2-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-2-0"
|
||||
date="2014-06-05">
|
||||
<Change>Updated Import</Change>
|
||||
<Change>Updated Pom</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-1-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-1-0"
|
||||
date="2014-04-04">
|
||||
<Change>Added exclude and include column</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-0-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-0-0"
|
||||
date="2014-02-01">
|
||||
<Change>Updated interacting with workspace</Change>
|
||||
</Changeset>
|
||||
<Changeset component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-6-0.1-0-0"
|
||||
<Changeset
|
||||
component="org.gcube.portlets-user.tabular-data-csv-import-widget.2-6-0.1-0-0"
|
||||
date="2013-10-18">
|
||||
<Change>First Release</Change>
|
||||
</Changeset>
|
||||
|
|
2
pom.xml
2
pom.xml
|
@ -13,7 +13,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.gcube.portlets.user</groupId>
|
||||
<artifactId>tabular-data-csv-import-widget</artifactId>
|
||||
<version>2.8.0-SNAPSHOT</version>
|
||||
<version>2.9.0-SNAPSHOT</version>
|
||||
|
||||
<name>tabular-data-csv-import-widget</name>
|
||||
<description>tabular-data-csv-import-widget allows csv import from file and workspace</description>
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
*/
|
||||
package org.gcube.portlets.user.td.csvimportwidget.client;
|
||||
|
||||
import org.gcube.portal.clientcontext.client.GCubeClientContext;
|
||||
import org.gcube.portlets.user.td.csvimportwidget.client.progress.FileUploadProgressBarUpdater;
|
||||
import org.gcube.portlets.user.td.csvimportwidget.client.progress.FileUploadProgressListener;
|
||||
import org.gcube.portlets.user.td.csvimportwidget.client.progress.FileUploadProgressUpdater;
|
||||
import org.gcube.portlets.user.td.gwtservice.shared.Constants;
|
||||
import org.gcube.portlets.user.td.gwtservice.shared.csv.CSVImportSession;
|
||||
import org.gcube.portlets.user.td.wizardwidget.client.dataresource.ResourceBundle;
|
||||
import org.gcube.portlets.user.td.wizardwidget.client.util.UtilsGXT3;
|
||||
|
@ -14,6 +16,7 @@ import com.allen_sauer.gwt.log.client.Log;
|
|||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.event.dom.client.ChangeEvent;
|
||||
import com.google.gwt.event.dom.client.ChangeHandler;
|
||||
import com.google.gwt.user.client.ui.Hidden;
|
||||
import com.sencha.gxt.core.client.Style.HideMode;
|
||||
import com.sencha.gxt.core.client.util.Padding;
|
||||
import com.sencha.gxt.widget.core.client.ProgressBar;
|
||||
|
@ -36,7 +39,6 @@ import com.sencha.gxt.widget.core.client.form.FormPanel;
|
|||
*/
|
||||
public class FileUploadPanel extends FormPanel {
|
||||
|
||||
private static final String UPLOAD_SERVLET = "LocalUploadServlet";
|
||||
|
||||
private static final int STATUS_POLLING_DELAY = 1000;
|
||||
|
||||
|
@ -68,7 +70,13 @@ public class FileUploadPanel extends FormPanel {
|
|||
}
|
||||
});
|
||||
|
||||
setAction(GWT.getModuleBaseURL() + UPLOAD_SERVLET);
|
||||
|
||||
StringBuilder actionUrl = new StringBuilder();
|
||||
actionUrl.append(GWT.getModuleBaseURL());
|
||||
actionUrl.append(Constants.LOCAL_UPLOAD_SERVLET);
|
||||
setAction(actionUrl.toString());
|
||||
Log.info("Start Upload action Url " + actionUrl.toString());
|
||||
|
||||
setWidth("100%");
|
||||
|
||||
setEncoding(Encoding.MULTIPART);
|
||||
|
@ -77,7 +85,13 @@ public class FileUploadPanel extends FormPanel {
|
|||
VerticalLayoutContainer content = new VerticalLayoutContainer();
|
||||
content.setWidth("100%");
|
||||
add(content);
|
||||
|
||||
|
||||
Hidden currGroupID = new Hidden();
|
||||
currGroupID.setName(Constants.CURR_GROUP_ID);
|
||||
currGroupID.setValue(GCubeClientContext.getCurrentContextId());
|
||||
|
||||
content.add(currGroupID);
|
||||
|
||||
fUpField = new FileUploadField();
|
||||
fUpField.setName("uploadFormElement");
|
||||
fUpField.setWidth("100%");
|
||||
|
@ -181,12 +195,7 @@ public class FileUploadPanel extends FormPanel {
|
|||
|
||||
protected void startUpload() {
|
||||
disableUpload();
|
||||
|
||||
StringBuilder actionUrl = new StringBuilder();
|
||||
actionUrl.append(GWT.getModuleBaseURL());
|
||||
actionUrl.append(UPLOAD_SERVLET);
|
||||
setAction(actionUrl.toString());
|
||||
Log.info("Start Upload action Url " + actionUrl.toString());
|
||||
|
||||
submit();
|
||||
|
||||
progressUpdater.scheduleRepeating(STATUS_POLLING_DELAY);
|
||||
|
|
Loading…
Reference in New Issue