From 125f5911c01b27f9a8f4bee5a41fc097d7f44018 Mon Sep 17 00:00:00 2001 From: Luke Taylor Date: Mon, 23 Jun 2008 13:27:08 +0000 Subject: [PATCH] Heavyduty sample additions to check multiple-parameter values --- sandbox/heavyduty/pom.xml | 4 ++-- .../java/heavyduty/web/TestMultiActionController.java | 8 +++++++- .../main/webapp/WEB-INF/freemarker/multi-action-test.ftl | 4 +++- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/sandbox/heavyduty/pom.xml b/sandbox/heavyduty/pom.xml index d83036c881..8dbdb580e5 100755 --- a/sandbox/heavyduty/pom.xml +++ b/sandbox/heavyduty/pom.xml @@ -4,7 +4,7 @@ spring-security-heavyduty Spring Security - Heavy Duty Sample war - 2.0.2-SNAPSHOT + 2.0.3-SNAPSHOT org.springframework.security @@ -166,7 +166,7 @@ 2.5.4 - 2.0.2-SNAPSHOT + 2.0.3-SNAPSHOT diff --git a/sandbox/heavyduty/src/main/java/heavyduty/web/TestMultiActionController.java b/sandbox/heavyduty/src/main/java/heavyduty/web/TestMultiActionController.java index 9315cca8b1..8f281cf06f 100644 --- a/sandbox/heavyduty/src/main/java/heavyduty/web/TestMultiActionController.java +++ b/sandbox/heavyduty/src/main/java/heavyduty/web/TestMultiActionController.java @@ -1,6 +1,7 @@ package heavyduty.web; import java.io.IOException; +import java.util.Arrays; import java.util.HashMap; import java.util.Map; @@ -23,10 +24,15 @@ public class TestMultiActionController extends MultiActionController { } public void step1(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { - request.getRequestDispatcher("/testMulti.htm?action=step1xtra").forward(request, response); + String[] x = request.getParameterValues("x"); + logger.info("x= " + (x == null ? "null" : Arrays.asList(x))); + String[] y = request.getParameterValues("y"); + logger.info("y = " + (y == null ? "null" : Arrays.asList(y))); + request.getRequestDispatcher("/testMulti.htm?action=step1xtra&x=5&x=5").forward(request, response); } public ModelAndView step1xtra(HttpServletRequest request, HttpServletResponse response) throws ServletRequestBindingException { + logger.info("x = " + Arrays.asList(request.getParameterValues("x"))); return createView("step2"); } diff --git a/sandbox/heavyduty/src/main/webapp/WEB-INF/freemarker/multi-action-test.ftl b/sandbox/heavyduty/src/main/webapp/WEB-INF/freemarker/multi-action-test.ftl index bac2503081..0c73d37961 100644 --- a/sandbox/heavyduty/src/main/webapp/WEB-INF/freemarker/multi-action-test.ftl +++ b/sandbox/heavyduty/src/main/webapp/WEB-INF/freemarker/multi-action-test.ftl @@ -6,7 +6,9 @@
- +
+
+