Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/ParameterList.java @ 215:e02f50a3ad59
Improved the exception handling of artifact / collection specific operations. Warning dialog are displayed after such an exception.
flys-client/trunk@1657 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Fri, 08 Apr 2011 08:51:28 +0000 |
parents | b92281182c6b |
children | a4a68b4ee2a3 |
comparison
equal
deleted
inserted
replaced
214:29c6d9573ae7 | 215:e02f50a3ad59 |
---|---|
5 | 5 |
6 import com.google.gwt.core.client.GWT; | 6 import com.google.gwt.core.client.GWT; |
7 import com.google.gwt.user.client.rpc.AsyncCallback; | 7 import com.google.gwt.user.client.rpc.AsyncCallback; |
8 | 8 |
9 import com.smartgwt.client.types.VerticalAlignment; | 9 import com.smartgwt.client.types.VerticalAlignment; |
10 import com.smartgwt.client.util.SC; | |
10 import com.smartgwt.client.widgets.Canvas; | 11 import com.smartgwt.client.widgets.Canvas; |
11 import com.smartgwt.client.widgets.layout.HLayout; | 12 import com.smartgwt.client.widgets.layout.HLayout; |
12 import com.smartgwt.client.widgets.layout.VLayout; | 13 import com.smartgwt.client.widgets.layout.VLayout; |
13 import com.smartgwt.client.widgets.tab.Tab; | 14 import com.smartgwt.client.widgets.tab.Tab; |
14 | 15 |
208 artifactService.create( | 209 artifactService.create( |
209 serverUrl, module.toLowerCase(), | 210 serverUrl, module.toLowerCase(), |
210 new AsyncCallback<Artifact>() { | 211 new AsyncCallback<Artifact>() { |
211 public void onFailure(Throwable caught) { | 212 public void onFailure(Throwable caught) { |
212 GWT.log("Could not create the new artifact."); | 213 GWT.log("Could not create the new artifact."); |
213 GWT.log(caught.getMessage()); | 214 SC.warn(MSG.getString(caught.getMessage())); |
214 } | 215 } |
215 | 216 |
216 public void onSuccess(Artifact artifact) { | 217 public void onSuccess(Artifact artifact) { |
217 GWT.log("Successfully created a new artifact."); | 218 GWT.log("Successfully created a new artifact."); |
218 | 219 |
219 forwardService.go(serverUrl, artifact, feedData, | 220 forwardService.go(serverUrl, artifact, feedData, |
220 new AsyncCallback<Artifact>() { | 221 new AsyncCallback<Artifact>() { |
221 public void onFailure(Throwable caught) { | 222 public void onFailure(Throwable caught) { |
222 GWT.log("Could not feed the artifact."); | 223 GWT.log("Could not feed the artifact."); |
223 GWT.log(caught.getMessage()); | 224 SC.warn(caught.getMessage()); |
224 } | 225 } |
225 | 226 |
226 public void onSuccess(Artifact artifact) { | 227 public void onSuccess(Artifact artifact) { |
227 GWT.log("Successfully feed the artifact."); | 228 GWT.log("Successfully feed the artifact."); |
228 setArtifact(artifact); | 229 setArtifact(artifact); |
346 | 347 |
347 forwardService.go(serverUrl, artifact, event.getData(), | 348 forwardService.go(serverUrl, artifact, event.getData(), |
348 new AsyncCallback<Artifact>() { | 349 new AsyncCallback<Artifact>() { |
349 public void onFailure(Throwable caught) { | 350 public void onFailure(Throwable caught) { |
350 GWT.log("Could not feed the artifact."); | 351 GWT.log("Could not feed the artifact."); |
351 GWT.log(caught.getMessage()); | 352 SC.warn(MSG.getString(caught.getMessage())); |
352 } | 353 } |
353 | 354 |
354 public void onSuccess(Artifact artifact) { | 355 public void onSuccess(Artifact artifact) { |
355 GWT.log("Successfully feed the artifact."); | 356 GWT.log("Successfully feed the artifact."); |
356 setArtifact(artifact); | 357 setArtifact(artifact); |
371 | 372 |
372 advanceService.advance(serverUrl, artifact, target, | 373 advanceService.advance(serverUrl, artifact, target, |
373 new AsyncCallback<Artifact>() { | 374 new AsyncCallback<Artifact>() { |
374 public void onFailure(Throwable caught) { | 375 public void onFailure(Throwable caught) { |
375 GWT.log("Could not go back to '" + target + "'"); | 376 GWT.log("Could not go back to '" + target + "'"); |
376 GWT.log(caught.getMessage()); | 377 SC.warn(MSG.getString(caught.getMessage())); |
377 } | 378 } |
378 | 379 |
379 public void onSuccess(Artifact artifact) { | 380 public void onSuccess(Artifact artifact) { |
380 GWT.log("Successfully step back to '" + target + "'"); | 381 GWT.log("Successfully step back to '" + target + "'"); |
381 | 382 |