Je sais c'est une question complètement idiote, mais bon, je me lance.

Comme vous le savez peut être, je développe une application de gestion horaire.

Dans un premier temps, on sélectionne l'unité auquel on veut avoir les personnes. A partir de là, je récupère la liste de personne rattachée à l'unité.

J'aimerai que lorsque je sélectionne une personne et que je récupère les information de la personne, j'aimerai que la valeur de l'unité reste sélectionnée. Egalement, j'aimerai garder la liste des personnes avec l'unité selectionnée au départ....

Je vous remercie beaucoup de votre aide

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
 
 
 
 
	public String searchPersonneUnite() throws Exception {
 
		this.listPersonneDto = this.personneService.getPersonneDTOPasCDDByUniteId(this.getUniteSelected());
		return Action.SUCCESS;
 
 
	}
 
public void prepare() throws Exception {
		HttpServletRequest request = ServletActionContext.getRequest();
		HttpSession session = request.getSession();
		this.personneInSession = (PersonneDTO) session.getAttribute("personne");
		if (personneInSession != null){
			this.droitPersonneInSession = personneInSession.getDroitDTO();
			//logger.debug("droitPersonneInSession ****** : "+droitPersonneInSession.getIdDroit());
		}
 
		//int idPersonneConnecte = personneInSession.getIdPersonne();
 
		boolean superUser = personneService.isSuperUser(personneInSession);
 
		ServiceDTO serviceChefService = this.serviceService.getServiceByIdPersonne(personneInSession.getIdPersonne());		
		//logger.debug("serviceChefService : "+serviceChefService.getNomService());
 
		UniteDTO uniteChefService = this.serviceService.getUniteDtoByIdService(serviceChefService.getIdService());
 
 
		if(this.getUniteSelected()== null){
			this.listPersonneDto = this.personneService.getListPersonnePasEnCdd();
		}else{
			this.listPersonneDto = this.personneService.getPersonneDTOPasCDDByUniteId(this.getUniteSelected());
		}
 
		this.listUniteDto = this.uniteService.getListAllUnite();
 
		this.listMounts = this.listMois();
		this.years = this.yearList();
		}