Internationalisation JEE

lafolle24320 Messages postés 406 Date d'inscription samedi 26 mars 2005 Statut Membre Dernière intervention 29 juin 2009 - 5 déc. 2008 à 13:05
lafolle24320 Messages postés 406 Date d'inscription samedi 26 mars 2005 Statut Membre Dernière intervention 29 juin 2009 - 5 déc. 2008 à 15:30
Bonjour,
Voilà une semaine que je bloque sur l'internationalisation de mon application J2EE.
Si mon pc est en français la locale est bien en français, et si mon pc est en anglais la locale est bien en anglais.
Jusque là tout va bien. Maintenant j'essaye de faire 2 boutons (drapeaux) pour que l'utilisateur puisse changer la langue comme il veut.
Donc pour ce faire j'ai une méthode localeChoose qui fait ceci :

public
void chooseLocale(ActionEvent _evt) {String id = _evt.getComponent().getId();

FacesContext.getCurrentInstance().getApplication().setDefaultLocale((Locale)

locales.get(id));
}

Le problème c'est que ma jsp ne se rafraichit pas avec la nouvelle langue choisie. Si je teste la locale du bundle celle-ci est bien modifié. J'ai l'impression que la jsp ne reload pas le bundle. Dois je faire quelque chose de particulier pour reforcer le load du bon fichier de properties ??

Merci de votre aide

lafolle

6 réponses

lafolle24320 Messages postés 406 Date d'inscription samedi 26 mars 2005 Statut Membre Dernière intervention 29 juin 2009 7
5 déc. 2008 à 13:51
Pouvez vous me dire si ce pb vous parait très bizarre ???? genre normalement la jsp se racfraichie toute seule NORMALEMENT....

Merci

lafolle
0
dvoraky Messages postés 744 Date d'inscription dimanche 1 avril 2007 Statut Membre Dernière intervention 9 mai 2010 8
5 déc. 2008 à 14:06
Salut,

Je ne sais pas avec quel framework tu travailles mais bon...
Je ne peux donc pas te répondre si le reload doit se lancer tout seul ou pas.

Mais si tu lances "à la main" le reload de la page? Pourquoi pas?
Après, je suis d'accord avec toi, qui si le reload devrait se lancer tout seul et que ben c'est pas le cas, il doit y avoir un soucis...

<hr width="100%" size="2" />
 C'est après des heures de codage que j'ai compris pourquoi les créateurs de Java ont choisi une tasse de café comme logo...
0
lafolle24320 Messages postés 406 Date d'inscription samedi 26 mars 2005 Statut Membre Dernière intervention 29 juin 2009 7
5 déc. 2008 à 14:19
Peut être le faces-config qui bloque :










com.sun.facelets.FaceletViewHandler



wilos.resources.messages



org.springframework.web.jsf.DelegatingVariableResolver



en








localeBean

wilos.resources.LocaleBean

request




LoginBean

wilos.presentation.web.wilosuser.LoginBean

session

loginService
#{LoginService}


roleService
#{RoleService}




ParticipantBean

wilos.presentation.web.wilosuser.ParticipantBean

request

participantService
#{ParticipantService}


loginService
#{LoginService}


concreteRoleDescriptorService
#{ConcreteRoleDescriptorService}




WilosUserBean

wilos.presentation.web.wilosuser.WilosUserBean

request

wilosUserService
#{WilosUserService}


roleService
#{RoleService}


affectedtoService
#{AffectedtoService}


loginService
#{LoginService}




RoleBean

wilos.presentation.web.wilosuser.RoleBean

request

roleService
#{RoleService}




ProcessManagerBean

wilos.presentation.web.wilosuser.ProcessManagerBean

request

processManagerService
#{ProcessManagerService}


loginService
#{LoginService}




ProjectDirectorBean

wilos.presentation.web.wilosuser.ProjectDirectorBean

request

projectDirectorService
#{ProjectDirectorService}


loginService
#{LoginService}





ProjectBean

wilos.presentation.web.project.ProjectBean

request

projectService
#{ProjectService}


projectDirectorService
#{ProjectDirectorService}


processService
#{ProcessService}


participantService
#{ParticipantService}


concreteRoleDescriptorService
#{ConcreteRoleDescriptorService}


concreteTaskDescriptorService
#{ConcreteTaskDescriptorService}


concreteActivityService
#{ConcreteActivityService}


roleDescriptorService
#{RoleDescriptorService}




ProjectAdvancementBean

wilos.presentation.web.project.ProjectAdvancementBean

session

projectService
#{ProjectService}


concreteActivityService
#{ConcreteActivityService}


concreteTaskDescriptor
#{ConcreteTaskDescriptorService}




participantService
#{ParticipantService}





concreteBreakdownElementService

#{ConcreteBreakdownElementService}





ProjectAdvancementWorkProductBean

wilos.presentation.web.project.ProjectAdvancementWorkProductBean

session

projectService
#{ProjectService}


concreteActivityService
#{ConcreteActivityService}


concreteTaskDescriptor
#{ConcreteTaskDescriptorService}




participantService
#{ParticipantService}




concreteWorkProductDescriptorService

#{ConcreteWorkProductDescriptorService}



workProductDescriptorService
#{WorkProductDescriptorService}




concreteBreakdownElementService

#{ConcreteBreakdownElementService}




ActionBean

wilos.presentation.web.template.ActionBean

session



AboutBean

wilos.presentation.web.template.AboutBean

session



menu

wilos.presentation.web.template.MenuBean

session



connect

wilos.presentation.web.template.ConnectViewBean

session

webSessionService
#{WebSessionService}






ConcreteRoleAffectationBean


wilos.presentation.web.role.ConcreteRoleAffectationBean

request


concreteRoleAffectationService

#{ConcreteRoleAffectationService}


participantService
#{ParticipantService}


projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}





ConcreteTaskBean

wilos.presentation.web.task.ConcreteTaskBean

session

projectService
#{ProjectService}


roleDescriptorService
#{RoleDescriptorService}


concreteActivityService
#{ConcreteActivityService}


activityService
#{ActivityService}





ProcessBean

wilos.presentation.web.process.ProcessBean

session

processService
#{ProcessService}


projectService
#{ProjectService}


processManagementService
#{ProcessManagementService}


processManagerService
#{ProcessManagerService}





XmlFileImportBean

wilos.presentation.web.upload.XmlFileImportBean

session

processService
#{ProcessService}





TreeBean

wilos.presentation.web.tree.TreeBean

session

projectService
#{ProjectService}


processService
#{ProcessService}


loginService
#{LoginService}


participantService
#{ParticipantService}


projectDirectorService
#{ProjectDirectorService}





ConcreteRoleViewerBean

wilos.presentation.web.viewer.ConcreteRoleViewerBean

session

concreteRoleDescriptorService
#{ConcreteRoleDescriptorService}


participantService
#{ParticipantService}


projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}





ConcreteWorkProductViewerBean


wilos.presentation.web.viewer.ConcreteWorkProductViewerBean

session


concreteWorkProductDescriptorService

#{ConcreteWorkProductDescriptorService}



workProductDescriptorService
#{WorkProductDescriptorService}



concreteRoleDescriptorService
#{ConcreteRoleDescriptorService}



roleDescriptorService
#{RoleDescriptorService}



participantService
#{ParticipantService}



projectService
#{ProjectService}




concreteBreakdownElementService

#{ConcreteBreakdownElementService}




ViewerBean

wilos.presentation.web.viewer.ViewerBean

session

projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}




ConcreteTaskViewerBean

wilos.presentation.web.viewer.ConcreteTaskViewerBean

session

concreteTaskDescriptorService
#{ConcreteTaskDescriptorService}


taskDescriptorService
#{TaskDescriptorService}


concreteRoleDescriptorService
#{ConcreteRoleDescriptorService}


roleDescriptorService
#{RoleDescriptorService}


workProductDescriptorService
#{WorkProductDescriptorService}



concreteWorkProductDescriptorService

#{ConcreteWorkProductDescriptorService}


participantService
#{ParticipantService}


projectService
#{ProjectService}


dailyRemainingTimeService
#{DailyRemainingTimeService}



concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}




ConcretePhaseViewerBean

wilos.presentation.web.viewer.ConcretePhaseViewerBean

session

concretePhaseService
#{ConcretePhaseService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}


projectService
#{ProjectService}



concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}





ConcreteActivityViewerBean


wilos.presentation.web.viewer.ConcreteActivityViewerBean

session

concreteActivityService
#{ConcreteActivityService}


projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}



concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}





ConcreteIterationViewerBean


wilos.presentation.web.viewer.ConcreteIterationViewerBean

session

concreteIterationService
#{ConcreteIterationService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}


projectService
#{ProjectService}



concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}




ProjectViewerBean

wilos.presentation.web.viewer.ProjectViewerBean

session

projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}





DailyRemainingTimeViewerBean


wilos.presentation.web.viewer.DailyRemainingTimeViewerBean

session

dailyRemainingTimeService
#{DailyRemainingTimeService}


concreteTaskDescriptorService
#{ConcreteTaskDescriptorService}


projectService
#{ProjectService}


concreteActivityService
#{ConcreteActivityService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}





ConcreteMilestoneViewerBean


wilos.presentation.web.viewer.ConcreteMilestoneViewerBean

session

concreteMilestoneService
#{ConcreteMilestoneService}


projectService
#{ProjectService}



concreteBreakdownElementService

#{ConcreteBreakdownElementService}



concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}





TasksExpTableBean

wilos.presentation.web.expandabletable.TasksExpTableBean

session

processService
#{ProcessService}


projectService
#{ProjectService}


activityService
#{ActivityService}




RolesExpTableBean

wilos.presentation.web.expandabletable.RolesExpTableBean

session

processService
#{ProcessService}


projectService
#{ProjectService}


activityService
#{ActivityService}


roleDescriptorService
#{RoleDescriptorService}


breakdownElementService
#{BreakdownElementService}




WorkProductsExpTableBean

wilos.presentation.web.expandabletable.WorkProductsExpTableBean

session

processService
#{ProcessService}


projectService
#{ProjectService}


activityService
#{ActivityService}


workProductDescriptorService
#{WorkProductDescriptorService}


concreteActivityService
#{ConcreteActivityService}


roleDescriptorService
#{RoleDescriptorService}


concreteTaskDescriptorService
#{ConcreteTaskDescriptorService}


concreteWorkProductDescriptorService
#{ConcreteWorkProductDescriptorService}





DependenciesBean

wilos.presentation.web.expandabletable.DependenciesBean

session


concreteWorkBreakdownElementService

#{ConcreteWorkBreakdownElementService}


concreteWorkOrderService
#{ConcreteWorkOrderService}


workBreakdownElementService
#{WorkBreakdownElementService}


workOrderService
#{WorkOrderService}


concreteActivityService
#{ConcreteActivityService}


projectService
#{ProjectService}






CommonBean

wilos.presentation.web.utils.CommonBean

session

projectService
#{ProjectService}








Theme Reload

reload
/index.jsp









ProjectViewerTabChangeListener


wilos.presentation.web.project.ProjectViewerTabChangeListener

session







Custom Page for Wilos


connect
/connect.iface



createParticipant
/participantSubscribe.iface



admin_main
/admin_main.iface



welcome
/welcome.iface



welcomeProjectDirector
/welcomeProjectDirector.iface



welcomeProcessManager
/welcomeProcessManager.iface



processManager_create
/processManager_create.iface



projectDirector_create
/projectDirector_create.iface



project_create
/project_create.iface



process_create
/process_create.iface



affect_roles
/affect_roles.iface



createProject
/project_create.iface





0
dvoraky Messages postés 744 Date d'inscription dimanche 1 avril 2007 Statut Membre Dernière intervention 9 mai 2010 8
5 déc. 2008 à 14:23
J'ai failli m'évanouir en voyant tout ça!

Je ne sais pas, je ne connais pas ce framework... JSF?

<hr width="100%" size="2" />
 C'est après des heures de codage que j'ai compris pourquoi les créateurs de Java ont choisi une tasse de café comme logo...
0

Vous n’avez pas trouvé la réponse que vous recherchez ?

Posez votre question
sheorogath Messages postés 2448 Date d'inscription samedi 21 février 2004 Statut Modérateur Dernière intervention 29 janvier 2010 17
5 déc. 2008 à 14:41
moi je me suis evanoui ^^

Plus serieusement evite de poster un gros pate comme ca, ca donne vraiment pas envie ^^

Bonne chance

"n'est pas mort ce qui semble a jamais dormir et en d'etrange temps meme la mort peut mourrir"
0
lafolle24320 Messages postés 406 Date d'inscription samedi 26 mars 2005 Statut Membre Dernière intervention 29 juin 2009 7
5 déc. 2008 à 15:30
Désolè de vous avoir fait peur.....
Bon du coup je sais vraiment pas comment corrigé ce truc.... :-(
Si y en as qui sont motivé c'est un projet open source, les sources sont sur un svn. Je lance le défi du changement de langue ;-)

merci quand même

laure
0
Rejoignez-nous