# HG changeset patch # User Ingo Weinzierl # Date 1315832607 0 # Node ID 3b034bb5fce7e8fb2b3ff6b663ea7754705df7ca # Parent 0398c2b8dbaf8cecd078e26622edf569ffbe96f3 Add status message for queued WSPLGEN jobs to notify users. flys-artifacts/trunk@2705 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/ChangeLog --- a/flys-artifacts/ChangeLog Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/ChangeLog Mon Sep 12 13:03:27 2011 +0000 @@ -1,3 +1,15 @@ +2011-09-12 Ingo Weinzierl + + * src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java: + Add a first WSPLGEN status message (notifies the user about a + queued job) after the job has been added to the Scheduler. + + * src/main/resources/messages.properties, + src/main/resources/messages_de_DE.properties, + src/main/resources/messages_en.properties, + src/main/resources/messages_de.properties: Added english and german + status message text. + 2011-09-12 Ingo Weinzierl * src/main/java/de/intevation/flys/utils/GeometryUtils.java: Write diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java --- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java Mon Sep 12 13:03:27 2011 +0000 @@ -35,6 +35,7 @@ import de.intevation.flys.model.RiverAxis; import de.intevation.flys.artifacts.FLYSArtifact; +import de.intevation.flys.artifacts.model.CalculationMessage; import de.intevation.flys.artifacts.model.CalculationResult; import de.intevation.flys.artifacts.model.FacetTypes; import de.intevation.flys.artifacts.model.WQKms; @@ -42,11 +43,13 @@ import de.intevation.flys.artifacts.model.WSPLGENCalculation; import de.intevation.flys.artifacts.model.WSPLGENJob; import de.intevation.flys.artifacts.model.WSPLGENReportFacet; +import de.intevation.flys.artifacts.resources.Resources; import de.intevation.flys.artifacts.states.DefaultState.ComputeType; import de.intevation.flys.exports.WstWriter; import de.intevation.flys.utils.FLYSUtils; import de.intevation.flys.utils.GeometryUtils; import de.intevation.flys.utils.MapfileGenerator; +import de.intevation.flys.wsplgen.JobObserver; import de.intevation.flys.wsplgen.Scheduler; @@ -209,6 +212,14 @@ facets.addAll(facetCreator.getFacets()); context.afterCall(CallContext.BACKGROUND); + context.addBackgroundMessage(new CalculationMessage( + JobObserver.STEPS.length, + 0, + Resources.getMsg( + context.getMeta(), + "wsplgen.job.queued", + "wsplgen.job.queued") + )); return null; } diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/src/main/resources/messages.properties --- a/flys-artifacts/src/main/resources/messages.properties Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/src/main/resources/messages.properties Mon Sep 12 13:03:27 2011 +0000 @@ -75,3 +75,5 @@ floodmap.wmsbackground = Background Map floodmap.riveraxis = River Axis + +wsplgen.job.queued = WSPLGEN job in queue. diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/src/main/resources/messages_de.properties --- a/flys-artifacts/src/main/resources/messages_de.properties Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/src/main/resources/messages_de.properties Mon Sep 12 13:03:27 2011 +0000 @@ -76,3 +76,5 @@ floodmap.wmsbackground = Hintergrundkarte floodmap.riveraxis = Flussachse + +wsplgen.job.queued = WSPLGEN Berechnung befindet sich in Warteschlange. diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/src/main/resources/messages_de_DE.properties --- a/flys-artifacts/src/main/resources/messages_de_DE.properties Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/src/main/resources/messages_de_DE.properties Mon Sep 12 13:03:27 2011 +0000 @@ -75,3 +75,5 @@ floodmap.wmsbackground = Hintergrundkarte floodmap.riveraxis = Flussachse + +wsplgen.job.queued = WSPLGEN Berechnung befindet sich in Warteschlange. diff -r 0398c2b8dbaf -r 3b034bb5fce7 flys-artifacts/src/main/resources/messages_en.properties --- a/flys-artifacts/src/main/resources/messages_en.properties Mon Sep 12 11:40:04 2011 +0000 +++ b/flys-artifacts/src/main/resources/messages_en.properties Mon Sep 12 13:03:27 2011 +0000 @@ -73,3 +73,5 @@ floodmap.wmsbackground = Background Map floodmap.riveraxis = River Axis + +wsplgen.job.queued = WSPLGEN job in queue.