Bonjour,

Comment faire un MultiActionController avec spring mvc 3.0?

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
@Controller
@SessionAttributes("listeStationRegion")
public final class DonneJournalierController {

	
//J'affiche la liste des regions

	@RequestMapping(value = "/donn.html", method = RequestMethod.GET)
	public ModelAndView displayAddDonneeMeteo(@RequestParam("contactId") String contact) {

...

		model.put("Region", listRegion());

		return new ModelAndView("donneejournalier", model);
	}

@InitBinder("listeStationRegion")
	public void initBinder(WebDataBinder binder) {
		binder.setAllowedFields(new String[] { "region" });
	}
	
//J'affiche la liste des stations de la region 
	
	@RequestMapping(value = "/donn.html", method = RequestMethod.POST)
	public String addPermission(ListeStationRegion lis,
			BindingResult result, ModelMap model) {

		...
         String region = lis.getRegion();
				
		
	Region reg= rr.getRegion(region);

		model.put("Station", listStation(reg));

		return "donneejournalier";
	}

//Comment afficher la station .

...


}
Merci.