Minor Update
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-gwt-service@93399 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
656b8122a2
commit
2ae6d737fc
|
@ -230,9 +230,6 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
}
|
}
|
||||||
logger.debug("GetTabResourceInformation():" + currentTR.toString());
|
logger.debug("GetTabResourceInformation():" + currentTR.toString());
|
||||||
|
|
||||||
TRId trId = retrieveTabularResourceType(currentTR.getTrId());
|
|
||||||
currentTR.setTrId(trId);
|
|
||||||
|
|
||||||
ArrayList<TRMetadata> trMetadatas = getTRMetadata(currentTR
|
ArrayList<TRMetadata> trMetadatas = getTRMetadata(currentTR
|
||||||
.getTrId());
|
.getTrId());
|
||||||
updateTabResourceInformation(currentTR, trMetadatas);
|
updateTabResourceInformation(currentTR, trMetadatas);
|
||||||
|
@ -265,8 +262,7 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
// ASLSession aslSession = SessionUtil.getAslSession(session);
|
// ASLSession aslSession = SessionUtil.getAslSession(session);
|
||||||
logger.debug("GetTabResourceInformation(TRId):" + trId.toString());
|
logger.debug("GetTabResourceInformation(TRId):" + trId.toString());
|
||||||
TabResource currentTR = new TabResource();
|
TabResource currentTR = new TabResource();
|
||||||
trId = retrieveTabularResourceType(trId);
|
|
||||||
currentTR.setTrId(trId);
|
|
||||||
ArrayList<TRMetadata> trMetadatas = getTRMetadata(currentTR
|
ArrayList<TRMetadata> trMetadatas = getTRMetadata(currentTR
|
||||||
.getTrId());
|
.getTrId());
|
||||||
updateTabResourceInformation(currentTR, trMetadatas);
|
updateTabResourceInformation(currentTR, trMetadatas);
|
||||||
|
@ -1397,7 +1393,7 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
* @return
|
* @return
|
||||||
* @throws TDGWTServiceException
|
* @throws TDGWTServiceException
|
||||||
*/
|
*/
|
||||||
protected TRId retrieveTabularResourceType(TRId trId)
|
protected TRId retrieveTabularResourceBasicData(TRId trId)
|
||||||
throws TDGWTServiceException {
|
throws TDGWTServiceException {
|
||||||
try {
|
try {
|
||||||
HttpSession session = this.getThreadLocalRequest().getSession();
|
HttpSession session = this.getThreadLocalRequest().getSession();
|
||||||
|
@ -1409,7 +1405,12 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
TabularResourceId tabularResourceId = new TabularResourceId(
|
TabularResourceId tabularResourceId = new TabularResourceId(
|
||||||
new Long(trId.getId()));
|
new Long(trId.getId()));
|
||||||
TabularResource tr = service.getTabularResource(tabularResourceId);
|
TabularResource tr = service.getTabularResource(tabularResourceId);
|
||||||
trId.setTableType(tr.getTableType());
|
Table table=service.getLastTable(tabularResourceId);
|
||||||
|
|
||||||
|
trId.setTabularResourceType(tr.getTableType());
|
||||||
|
trId.setTableId(String.valueOf(table.getId().getValue()));
|
||||||
|
trId.setTableType(table.getTableType().getName());
|
||||||
|
|
||||||
logger.debug("Retrieved TRId type:" + trId.toString());
|
logger.debug("Retrieved TRId type:" + trId.toString());
|
||||||
return trId;
|
return trId;
|
||||||
|
|
||||||
|
@ -1458,11 +1459,11 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
case SUCCEDED:
|
case SUCCEDED:
|
||||||
importMonitor.setProgress(task.getProgress());
|
importMonitor.setProgress(task.getProgress());
|
||||||
logger.debug("Task Result: " + task.getResult());
|
logger.debug("Task Result: " + task.getResult());
|
||||||
table = task.getResult().getPrimaryTable();
|
/*table = task.getResult().getPrimaryTable();
|
||||||
trId.setTableId(String.valueOf(table.getId()
|
trId.setTableId(String.valueOf(table.getId()
|
||||||
.getValue()));
|
.getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
sdmxImportTabResource.setTrId(trId);
|
sdmxImportTabResource.setTrId(trId);
|
||||||
SessionUtil.setSDMXImportTabResource(session,
|
SessionUtil.setSDMXImportTabResource(session,
|
||||||
|
@ -1487,11 +1488,11 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
case STOPPED:
|
case STOPPED:
|
||||||
importMonitor.setProgress(task.getProgress());
|
importMonitor.setProgress(task.getProgress());
|
||||||
logger.debug("Task Result: " + task.getResult());
|
logger.debug("Task Result: " + task.getResult());
|
||||||
table = task.getResult().getPrimaryTable();
|
/*table = task.getResult().getPrimaryTable();
|
||||||
trId.setTableId(String.valueOf(table.getId()
|
trId.setTableId(String.valueOf(table.getId()
|
||||||
.getValue()));
|
.getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
sdmxImportTabResource.setTrId(trId);
|
sdmxImportTabResource.setTrId(trId);
|
||||||
SessionUtil.setSDMXImportTabResource(session,
|
SessionUtil.setSDMXImportTabResource(session,
|
||||||
|
@ -1874,12 +1875,12 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
case SUCCEDED:
|
case SUCCEDED:
|
||||||
logger.debug("Task Result: " + task.getResult());
|
logger.debug("Task Result: " + task.getResult());
|
||||||
importMonitor.setProgress(task.getProgress());
|
importMonitor.setProgress(task.getProgress());
|
||||||
table = task.getResult().getPrimaryTable();
|
/*table = task.getResult().getPrimaryTable();
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId.setTableId(String.valueOf(table.getId()
|
trId.setTableId(String.valueOf(table.getId()
|
||||||
.getValue()));
|
.getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
csvImportTabResource.setTrId(trId);
|
csvImportTabResource.setTrId(trId);
|
||||||
SessionUtil.setCSVImportTabResource(session,
|
SessionUtil.setCSVImportTabResource(session,
|
||||||
|
@ -3123,10 +3124,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(changeColumnTypeSession.getColumnData()
|
trId.setId(changeColumnTypeSession.getColumnData()
|
||||||
.getTrId().getId());
|
.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
changeColumnTypeMonitor.setTrId(trId);
|
changeColumnTypeMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3148,10 +3149,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(changeColumnTypeSession.getColumnData()
|
trId.setId(changeColumnTypeSession.getColumnData()
|
||||||
.getTrId().getId());
|
.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
changeColumnTypeMonitor.setTrId(trId);
|
changeColumnTypeMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3271,10 +3272,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(deleteColumnSession.getColumnData()
|
trId.setId(deleteColumnSession.getColumnData()
|
||||||
.getTrId().getId());
|
.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
deleteColumnMonitor.setTrId(trId);
|
deleteColumnMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3298,10 +3299,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(deleteColumnSession.getColumnData()
|
trId.setId(deleteColumnSession.getColumnData()
|
||||||
.getTrId().getId());
|
.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
deleteColumnMonitor.setTrId(trId);
|
deleteColumnMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3422,10 +3423,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(labelColumnSession.getColumnData().getTrId()
|
trId.setId(labelColumnSession.getColumnData().getTrId()
|
||||||
.getId());
|
.getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
labelColumnMonitor.setTrId(trId);
|
labelColumnMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3449,10 +3450,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(labelColumnSession.getColumnData().getTrId()
|
trId.setId(labelColumnSession.getColumnData().getTrId()
|
||||||
.getId());
|
.getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
labelColumnMonitor.setTrId(trId);
|
labelColumnMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3574,10 +3575,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(changeTableTypeSession.getTrId().getId());
|
trId.setId(changeTableTypeSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
changeTableTypeMonitor.setTrId(trId);
|
changeTableTypeMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3600,10 +3601,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(changeTableTypeSession.getTrId().getId());
|
trId.setId(changeTableTypeSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
changeTableTypeMonitor.setTrId(trId);
|
changeTableTypeMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3899,10 +3900,8 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(deleteRowsSession.getTrId().getId());
|
trId.setId(deleteRowsSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
|
||||||
.valueOf(table.getId().getValue()));
|
retrieveTabularResourceBasicData(trId);
|
||||||
trId.setTableType(table.getTableType().getName());
|
|
||||||
retrieveTabularResourceType(trId);
|
|
||||||
|
|
||||||
deleteRowsMonitor.setTrId(trId);
|
deleteRowsMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -3925,10 +3924,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(deleteRowsSession.getTrId().getId());
|
trId.setId(deleteRowsSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
deleteRowsMonitor.setTrId(trId);
|
deleteRowsMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -4092,10 +4091,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(duplicatesSession.getTrId().getId());
|
trId.setId(duplicatesSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
duplicatesMonitor.setTrId(trId);
|
duplicatesMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
@ -4118,10 +4117,10 @@ public class TDGWTServiceImpl extends RemoteServiceServlet implements
|
||||||
logger.debug("Table retrived: " + table.toString());
|
logger.debug("Table retrived: " + table.toString());
|
||||||
trId = new TRId();
|
trId = new TRId();
|
||||||
trId.setId(duplicatesSession.getTrId().getId());
|
trId.setId(duplicatesSession.getTrId().getId());
|
||||||
trId.setTableId(String
|
/*trId.setTableId(String
|
||||||
.valueOf(table.getId().getValue()));
|
.valueOf(table.getId().getValue()));
|
||||||
trId.setTableType(table.getTableType().getName());
|
trId.setTableType(table.getTableType().getName());*/
|
||||||
retrieveTabularResourceType(trId);
|
retrieveTabularResourceBasicData(trId);
|
||||||
|
|
||||||
duplicatesMonitor.setTrId(trId);
|
duplicatesMonitor.setTrId(trId);
|
||||||
tabResource = SessionUtil.getTabResource(session);
|
tabResource = SessionUtil.getTabResource(session);
|
||||||
|
|
Loading…
Reference in New Issue