Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/ParameterList.java @ 1425:bc06a671ef60
Removed the URL parameter from service calls. The service
implementations read the URL from the web.xml config file now.
flys-client/trunk@3367 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Thu, 08 Dec 2011 09:12:27 +0000 |
parents | 4b177fd52f06 |
children | 07b9404d7170 |
comparison
equal
deleted
inserted
replaced
1424:8974e220b193 | 1425:bc06a671ef60 |
---|---|
350 final String locale = config.getLocale(); | 350 final String locale = config.getLocale(); |
351 | 351 |
352 final Data[] feedData = new Data[] { data[1] }; | 352 final Data[] feedData = new Data[] { data[1] }; |
353 | 353 |
354 artifactService.create( | 354 artifactService.create( |
355 url, locale, module.toLowerCase(), null, | 355 locale, module.toLowerCase(), null, |
356 new AsyncCallback<Artifact>() { | 356 new AsyncCallback<Artifact>() { |
357 public void onFailure(Throwable caught) { | 357 public void onFailure(Throwable caught) { |
358 GWT.log("Could not create the new artifact."); | 358 GWT.log("Could not create the new artifact."); |
359 SC.warn(MSG.getString(caught.getMessage())); | 359 SC.warn(MSG.getString(caught.getMessage())); |
360 } | 360 } |
361 | 361 |
362 public void onSuccess(Artifact artifact) { | 362 public void onSuccess(Artifact artifact) { |
363 GWT.log("Successfully created a new artifact."); | 363 GWT.log("Successfully created a new artifact."); |
364 | 364 |
365 forwardService.go(url, locale, artifact, feedData, | 365 forwardService.go(locale, artifact, feedData, |
366 new AsyncCallback<Artifact>() { | 366 new AsyncCallback<Artifact>() { |
367 public void onFailure(Throwable caught) { | 367 public void onFailure(Throwable caught) { |
368 GWT.log("Could not feed the artifact."); | 368 GWT.log("Could not feed the artifact."); |
369 SC.warn(caught.getMessage()); | 369 SC.warn(caught.getMessage()); |
370 } | 370 } |
576 */ | 576 */ |
577 public void onStepForward(StepForwardEvent event) { | 577 public void onStepForward(StepForwardEvent event) { |
578 GWT.log("CollectionView - onStepForward()"); | 578 GWT.log("CollectionView - onStepForward()"); |
579 | 579 |
580 Config config = Config.getInstance(); | 580 Config config = Config.getInstance(); |
581 String serverUrl = config.getServerUrl(); | |
582 String locale = config.getLocale(); | 581 String locale = config.getLocale(); |
583 | 582 |
584 forwardService.go(serverUrl, locale, artifact, event.getData(), | 583 forwardService.go(locale, artifact, event.getData(), |
585 new AsyncCallback<Artifact>() { | 584 new AsyncCallback<Artifact>() { |
586 public void onFailure(Throwable caught) { | 585 public void onFailure(Throwable caught) { |
587 GWT.log("Could not feed the artifact."); | 586 GWT.log("Could not feed the artifact."); |
588 SC.warn(MSG.getString(caught.getMessage())); | 587 SC.warn(MSG.getString(caught.getMessage())); |
589 } | 588 } |
606 */ | 605 */ |
607 public void onStepBack(StepBackEvent e) { | 606 public void onStepBack(StepBackEvent e) { |
608 final String target = e.getTarget(); | 607 final String target = e.getTarget(); |
609 | 608 |
610 Config config = Config.getInstance(); | 609 Config config = Config.getInstance(); |
611 final String serverUrl = config.getServerUrl(); | |
612 final String locale = config.getLocale(); | 610 final String locale = config.getLocale(); |
613 | 611 |
614 advanceService.advance(serverUrl, locale, artifact, target, | 612 advanceService.advance(locale, artifact, target, |
615 new AsyncCallback<Artifact>() { | 613 new AsyncCallback<Artifact>() { |
616 public void onFailure(Throwable caught) { | 614 public void onFailure(Throwable caught) { |
617 GWT.log("Could not go back to '" + target + "'"); | 615 GWT.log("Could not go back to '" + target + "'"); |
618 SC.warn(MSG.getString(caught.getMessage())); | 616 SC.warn(MSG.getString(caught.getMessage())); |
619 } | 617 } |
630 } | 628 } |
631 | 629 |
632 | 630 |
633 public void onAdvance(final String target) { | 631 public void onAdvance(final String target) { |
634 Config config = Config.getInstance(); | 632 Config config = Config.getInstance(); |
635 final String serverUrl = config.getServerUrl(); | |
636 final String locale = config.getLocale(); | 633 final String locale = config.getLocale(); |
637 | 634 |
638 advanceService.advance(serverUrl, locale, artifact, target, | 635 advanceService.advance(locale, artifact, target, |
639 new AsyncCallback<Artifact>() { | 636 new AsyncCallback<Artifact>() { |
640 public void onFailure(Throwable caught) { | 637 public void onFailure(Throwable caught) { |
641 GWT.log("Could not go to '" + target + "'"); | 638 GWT.log("Could not go to '" + target + "'"); |
642 SC.warn(MSG.getString(caught.getMessage())); | 639 SC.warn(MSG.getString(caught.getMessage())); |
643 } | 640 } |
802 reportPanel.setContents(""); | 799 reportPanel.setContents(""); |
803 return; | 800 return; |
804 } | 801 } |
805 | 802 |
806 Config config = Config.getInstance(); | 803 Config config = Config.getInstance(); |
807 String url = config.getServerUrl(); | |
808 String locale = config.getLocale(); | 804 String locale = config.getLocale(); |
809 | 805 |
810 String cid = c.identifier(); | 806 String cid = c.identifier(); |
811 | 807 |
812 for (ReportMode report: reports) { | 808 for (ReportMode report: reports) { |
813 GWT.log("report '" + report.toString() + "'"); | 809 GWT.log("report '" + report.toString() + "'"); |
814 | 810 |
815 reportService.report(cid, url, locale, report.getName(), | 811 reportService.report(cid, locale, report.getName(), |
816 new AsyncCallback<String>() { | 812 new AsyncCallback<String>() { |
817 public void onFailure(Throwable caught) { | 813 public void onFailure(Throwable caught) { |
818 SC.warn(caught.getMessage()); | 814 SC.warn(caught.getMessage()); |
819 } | 815 } |
820 | 816 |