Updated pom at 6.9.0
Locked rename operation git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace-tree-widget@117584 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
a7141cfde9
commit
1607946a42
2
pom.xml
2
pom.xml
|
@ -10,7 +10,7 @@
|
|||
|
||||
<groupId>org.gcube.portlets.user</groupId>
|
||||
<artifactId>workspace-tree-widget</artifactId>
|
||||
<version>6.8.0-SNAPSHOT</version>
|
||||
<version>6.9.0-SNAPSHOT</version>
|
||||
<name>gCube Workspace Tree Widget</name>
|
||||
<description>
|
||||
gCube Workspace Tree Widget.
|
||||
|
|
|
@ -1090,9 +1090,6 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
explorerPanel.getAsycTreePanel().removeAllAndRecoveryRoot();
|
||||
}
|
||||
}
|
||||
|
||||
// markItemInTreeAsRead(fileDownloadEvent.getItemIdentifier(), true);
|
||||
|
||||
notifySubscriber(fileDownloadEvent);
|
||||
}
|
||||
|
||||
|
@ -1120,14 +1117,6 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
}
|
||||
else
|
||||
fileUploader = new FileUploader(eventBus, folder, ConstantsExplorer.FILE);
|
||||
|
||||
// new DialogUpload(ConstantsExplorer.FILEUPLOADHEADER, folder.getName(), folder, ConstantsExplorer.FILE);
|
||||
|
||||
// if(fileUploadEvent.getUploadTypeToString().equals(UploadType.ARCHIVE.toString()))
|
||||
// new DialogUpload(ConstantsExplorer.ARCHIVEUPLOADHEADER, folder.getName(), folder, ConstantsExplorer.ARCHIVE);
|
||||
// else
|
||||
// new DialogUpload(ConstantsExplorer.FILEUPLOADHEADER, folder.getName(), folder, ConstantsExplorer.FILE);
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -1142,11 +1131,8 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
try {
|
||||
|
||||
String normalizedFileName = fileName;
|
||||
|
||||
// com.google.gwt.user.client.Window.alert("fileUploadField.getValue() "+fileUploadField.getValue());
|
||||
if (normalizedFileName.contains("\\")) {
|
||||
normalizedFileName = normalizedFileName.substring(normalizedFileName.lastIndexOf("\\")+1); //remove C:\fakepath\ if exists
|
||||
// com.google.gwt.user.client.Window.alert("normalizedFileName= "+normalizedFileName);
|
||||
}
|
||||
|
||||
final String label = normalizedFileName;
|
||||
|
@ -1159,22 +1145,16 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
public void onSuccess(final String itemId) {
|
||||
|
||||
if(itemId!=null){
|
||||
|
||||
boolean result = Window.confirm(label + " exists in folder "+fileUploader.getFolderParent().getName() + ". Overwrite?");
|
||||
|
||||
if(result){
|
||||
|
||||
fileUploader.overwrite();
|
||||
fileUploader.submitForm();
|
||||
}
|
||||
|
||||
}else
|
||||
fileUploader.submitForm(); //ITEM does NOT EXIST SO SUBMIT FORM;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public void onFailure(Throwable caught) {
|
||||
Info.display("Error", "Sorry an error occurred on the server "+caught.getLocalizedMessage() + ". Please try again later");
|
||||
|
@ -1315,13 +1295,8 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
|
||||
@Override
|
||||
public void onSuccess(SmartFolderModel smart) {
|
||||
|
||||
// System.out.println("In client: " + smart.getIdentifier());
|
||||
|
||||
explorerPanel.getShortuctsPanel().loadSmartFolder(smart);
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1366,14 +1341,13 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
final String newName = dgt.getTxtValue();
|
||||
|
||||
if(dgt.isValidForm()){
|
||||
|
||||
dgt.mask("Renaming...");
|
||||
rpcWorkspaceService.renameItem(target.getIdentifier(), newName, target.getName(), new AsyncCallback<Boolean>(){
|
||||
|
||||
@Override
|
||||
public void onFailure(Throwable caught) {
|
||||
|
||||
explorerPanel.getAsycTreePanel().unmask();
|
||||
|
||||
dgt.unmask();
|
||||
dgt.hide();
|
||||
if(caught instanceof SessionExpiredException){
|
||||
GWT.log("Session expired");
|
||||
eventBus.fireEvent(new SessionExpiredEvent());
|
||||
|
@ -1387,13 +1361,12 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
|
||||
@Override
|
||||
public void onSuccess(Boolean result) {
|
||||
dgt.unmask();
|
||||
dgt.hide();
|
||||
explorerPanel.getAsycTreePanel().renameItem(target.getIdentifier(), newName, null);
|
||||
event.setNewName(newName);
|
||||
// event.setExtension(extension);
|
||||
notifySubscriber(event);
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -1636,8 +1609,6 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
@Override
|
||||
public void onClickPreview(ImagePreviewEvent imagePreviewEvent) {
|
||||
|
||||
// System.out.println("x e y " + imagePreviewEvent.getClientX() + " e " + imagePreviewEvent.getClientY());
|
||||
|
||||
if(imagePreviewEvent.getClientX() > 0 && imagePreviewEvent.getClientY() > 0)
|
||||
doClickPreview(imagePreviewEvent, imagePreviewEvent.getClientX(), imagePreviewEvent.getClientY() );
|
||||
else
|
||||
|
@ -1807,10 +1778,6 @@ public class AppControllerExplorer implements EventHandler, TreeAppControllerInt
|
|||
|
||||
private void doClickOpenReportTemplate(OpenReportsEvent openReportTemplateEvent) {
|
||||
|
||||
// System.out.println("IDTEMPLATE " + ConstantsExplorer.IDTEMPLATE);
|
||||
// System.out.println("id " +openReportTemplateEvent.getSourceFileModel().getIdentifier());
|
||||
// System.out.println("name " +openReportTemplateEvent.getSourceFileModel().getName());
|
||||
|
||||
rpcWorkspaceService.getURLFromApplicationProfile(openReportTemplateEvent.getSourceFileModel().getIdentifier(), new AsyncCallback<String>() {
|
||||
|
||||
@Override
|
||||
|
|
|
@ -61,9 +61,8 @@ public class DialogText extends Dialog {
|
|||
|
||||
@Override
|
||||
public void componentSelected(ButtonEvent ce) {
|
||||
|
||||
if (isValidForm())
|
||||
hide();
|
||||
// if (isValidForm()) COMMENTED TO PREVENT BACK END EXCEPTION
|
||||
// hide();
|
||||
}
|
||||
|
||||
});
|
||||
|
@ -72,16 +71,12 @@ public class DialogText extends Dialog {
|
|||
|
||||
@Override
|
||||
public void componentSelected(ButtonEvent ce) {
|
||||
|
||||
hide();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
setFocusWidget(txt);
|
||||
|
||||
add(txt);
|
||||
|
||||
this.show();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue