| Line 116... |
Line 116... |
| 116 |
initialiserPersonneForm(mediateurCourrant, personneId);
|
116 |
initialiserPersonneForm(mediateurCourrant, personneId);
|
| 117 |
}
|
117 |
}
|
| Line 118... |
Line 118... |
| 118 |
|
118 |
|
| 119 |
public PersonneForm(Mediateur mediateurCourrant, String personneId, Rafraichissable vueARafraichirApresValidation) {
|
119 |
public PersonneForm(Mediateur mediateurCourrant, String personneId, Rafraichissable vueARafraichirApresValidation) {
|
| 120 |
vueExterneARafraichirApresValidation = vueARafraichirApresValidation;
|
120 |
vueExterneARafraichirApresValidation = vueARafraichirApresValidation;
|
| 121 |
initialiserPersonneForm(mediateurCourrant, personneId);
|
121 |
initialiserPersonneForm(mediateurCourrant, personneId);
|
| Line 122... |
Line 122... |
| 122 |
}
|
122 |
}
|
| - |
|
123 |
|
| 123 |
|
124 |
private void initialiserPersonneForm(Mediateur mediateurCourrant, String personneIdCourrant) {
|
| 124 |
private void initialiserPersonneForm(Mediateur mediateurCourrant, String personneIdCourrant) {
|
125 |
|
| 125 |
personne = new Personne();
|
126 |
personne = new Personne();
|
| Line 126... |
Line 127... |
| 126 |
personne.setId(personneIdCourrant);
|
127 |
personne.setId(personneIdCourrant);
|
| 127 |
personneId = personneIdCourrant;
|
128 |
personneId = personneIdCourrant;
|
| Line 128... |
Line 129... |
| 128 |
|
129 |
|
| 129 |
String modeDeCreation = (UtilString.isEmpty(personneId) ? Formulaire.MODE_AJOUTER : Formulaire.MODE_MODIFIER);
|
130 |
String modeDeCreation = (UtilString.isEmpty(personneId) ? Formulaire.MODE_AJOUTER : Formulaire.MODE_MODIFIER);
|
| Line -... |
Line 131... |
| - |
|
131 |
initialiserFormulaire(mediateurCourrant, modeDeCreation, MenuApplicationId.PERSONNE);
|
| 130 |
initialiserFormulaire(mediateurCourrant, modeDeCreation, MenuApplicationId.PERSONNE);
|
132 |
|
| 131 |
|
133 |
initialiserComposants();
|
| 132 |
initialiserComposants();
|
- |
|
| 133 |
genererTitreFormulaire();
|
134 |
genererTitreFormulaire();
|
| 134 |
|
135 |
|
| Line 135... |
Line 136... |
| 135 |
if (modeDeCreation.equals(Formulaire.MODE_MODIFIER)) {
|
136 |
mediateur.obtenirListeValeurEtRafraichir(this, "relationPersonnePublication");
|
| 136 |
mediateur.selectionnerPersonne(this, personne, null);
|
137 |
if (modeDeCreation.equals(Formulaire.MODE_MODIFIER)) {
|
| Line 766... |
Line 767... |
| 766 |
Information info = new Information();
|
767 |
Information info = new Information();
|
| 767 |
info.setType("publication_liees");
|
768 |
info.setType("publication_liees");
|
| 768 |
info.setDonnee(0, (PublicationAPersonneListe) nouvellesDonnees);
|
769 |
info.setDonnee(0, (PublicationAPersonneListe) nouvellesDonnees);
|
| 769 |
tiPubli.rafraichir(info);
|
770 |
tiPubli.rafraichir(info);
|
| 770 |
} else if (nouvellesDonnees instanceof ValeurListe) {
|
771 |
} else if (nouvellesDonnees instanceof ValeurListe) {
|
| - |
|
772 |
|
| 771 |
ValeurListe listeValeurs = (ValeurListe) nouvellesDonnees;
|
773 |
ValeurListe listeValeurs = (ValeurListe) nouvellesDonnees;
|
| Line 772... |
Line 774... |
| 772 |
|
774 |
|
| 773 |
// Créer une liste de valeurs
|
775 |
// Créer une liste de valeurs
|
| 774 |
List<Valeur> liste = new ArrayList<Valeur>();
|
776 |
List<Valeur> liste = new ArrayList<Valeur>();
|
| 775 |
for (Iterator<String> it = listeValeurs.keySet().iterator(); it.hasNext();) {
|
777 |
for (Iterator<String> it = listeValeurs.keySet().iterator(); it.hasNext();) {
|
| 776 |
liste.add(listeValeurs.get(it.next()));
|
778 |
liste.add(listeValeurs.get(it.next()));
|
| 777 |
}
|
- |
|
| 778 |
|
- |
|
| - |
|
779 |
}
|
| - |
|
780 |
if (listeValeurs.getId().equals(config.getListeId("relationPersonnePublication"))) {
|
| 779 |
|
781 |
tiPubli.rafraichir(nouvellesDonnees);
|
| 780 |
if (listeValeurs.getId().equals(config.getListeId("prefixe"))) {
|
782 |
} else if (listeValeurs.getId().equals(config.getListeId("prefixe"))) {
|
| 781 |
remplirCombobox("cbPrefixe", liste, "hmIdentite");
|
783 |
remplirCombobox("cbPrefixe", liste, "hmIdentite");
|
| 782 |
} else if (listeValeurs.getId().equals(config.getListeId("suffixes"))) {
|
784 |
} else if (listeValeurs.getId().equals(config.getListeId("suffixes"))) {
|
| 783 |
remplirCombobox("cbSuffixe", liste, "hmIdentite");
|
785 |
remplirCombobox("cbSuffixe", liste, "hmIdentite");
|
| 784 |
} else if (listeValeurs.getId().equals(config.getListeId("sexe"))) {
|
786 |
} else if (listeValeurs.getId().equals(config.getListeId("sexe"))) {
|
| Line 1103... |
Line 1105... |
| 1103 |
|
1105 |
|
| 1104 |
return strValeur;
|
1106 |
return strValeur;
|
| Line 1105... |
Line 1107... |
| 1105 |
}
|
1107 |
}
|
| - |
|
1108 |
|
| 1106 |
|
1109 |
public boolean soumettreFormulaire() {
|
| 1107 |
public boolean soumettreFormulaire() {
|
- |
|
| 1108 |
if (verifierFormulaire()) {
|
1110 |
tiPubli.collecter();
|
| 1109 |
tiPubli.collecter();
|
1111 |
if (verifierFormulaire()) {
|
| 1110 |
tiPubli.soumettre();
|
1112 |
tiPubli.soumettre();
|
| 1111 |
mediateur.enregistrerPersonne(this, personneSelectionnee);
|
1113 |
mediateur.enregistrerPersonne(this, personneSelectionnee);
|
| 1112 |
}
|
1114 |
}
|
| Line 1213... |
Line 1215... |
| 1213 |
personneSelectionnee.set("truk_recolte", recolte);
|
1215 |
personneSelectionnee.set("truk_recolte", recolte);
|
| Line 1214... |
Line 1216... |
| 1214 |
|
1216 |
|
| 1215 |
String specialite = ((ChampMultiValeurs) hmInfosNat.get("specialite")).getValeurs();
|
1217 |
String specialite = ((ChampMultiValeurs) hmInfosNat.get("specialite")).getValeurs();
|
| Line -... |
Line 1218... |
| - |
|
1218 |
personneSelectionnee.set("ce_truk_specialite", specialite);
|
| Line 1216... |
Line 1219... |
| 1216 |
personneSelectionnee.set("ce_truk_specialite", specialite);
|
1219 |
|
| 1217 |
|
1220 |
lstMessageErreur.addAll(tiPubli.verifier());
|
| 1218 |
|
1221 |
|
| 1219 |
if (lstMessageErreur.size() != 0) {
|
1222 |
if (lstMessageErreur.size() != 0) {
|