Subversion Repositories eFlore/Applications.coel

Rev

Rev 439 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 439 Rev 472
Line 9... Line 9...
9
 
9
 
10
import org.tela_botanica.client.ComposantClass;
10
import org.tela_botanica.client.ComposantClass;
11
import org.tela_botanica.client.ComposantId;
11
import org.tela_botanica.client.ComposantId;
12
import org.tela_botanica.client.Mediateur;
12
import org.tela_botanica.client.Mediateur;
13
import org.tela_botanica.client.RegistreId;
-
 
14
import org.tela_botanica.client.i18n.Constantes;
13
import org.tela_botanica.client.RegistreId;
15
import org.tela_botanica.client.interfaces.Rafraichissable;
14
import org.tela_botanica.client.interfaces.Rafraichissable;
16
import org.tela_botanica.client.modeles.Configuration;
15
import org.tela_botanica.client.modeles.Configuration;
17
import org.tela_botanica.client.modeles.Personne;
16
import org.tela_botanica.client.modeles.Personne;
18
import org.tela_botanica.client.modeles.Valeur;
17
import org.tela_botanica.client.modeles.Valeur;
19
import org.tela_botanica.client.modeles.ValeurListe;
18
import org.tela_botanica.client.modeles.ValeurListe;
20
import org.tela_botanica.client.util.UtilTruk;
-
 
21
 
19
import org.tela_botanica.client.util.UtilTruk;
22
import com.extjs.gxt.ui.client.Registry;
20
import com.extjs.gxt.ui.client.Registry;
23
import com.extjs.gxt.ui.client.Style.Scroll;
-
 
24
import com.extjs.gxt.ui.client.Style.VerticalAlignment;
21
import com.extjs.gxt.ui.client.Style.Scroll;
25
import com.extjs.gxt.ui.client.util.Format;
22
import com.extjs.gxt.ui.client.util.Format;
26
import com.extjs.gxt.ui.client.util.Params;
23
import com.extjs.gxt.ui.client.util.Params;
27
import com.extjs.gxt.ui.client.widget.ContentPanel;
24
import com.extjs.gxt.ui.client.widget.ContentPanel;
28
import com.extjs.gxt.ui.client.widget.Html;
25
import com.extjs.gxt.ui.client.widget.HtmlContainer;
29
import com.extjs.gxt.ui.client.widget.LayoutContainer;
26
import com.extjs.gxt.ui.client.widget.LayoutContainer;
30
import com.extjs.gxt.ui.client.widget.TabItem;
27
import com.extjs.gxt.ui.client.widget.TabItem;
31
import com.extjs.gxt.ui.client.widget.TabPanel;
-
 
32
import com.extjs.gxt.ui.client.widget.Text;
28
import com.extjs.gxt.ui.client.widget.TabPanel;
33
import com.extjs.gxt.ui.client.widget.form.FieldSet;
29
import com.extjs.gxt.ui.client.widget.form.FieldSet;
34
import com.extjs.gxt.ui.client.widget.form.LabelField;
-
 
35
import com.extjs.gxt.ui.client.widget.layout.ColumnData;
-
 
36
import com.extjs.gxt.ui.client.widget.layout.ColumnLayout;
30
import com.extjs.gxt.ui.client.widget.form.LabelField;
37
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
31
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
38
import com.extjs.gxt.ui.client.widget.layout.FlowLayout;
32
import com.extjs.gxt.ui.client.widget.layout.FlowLayout;
39
import com.extjs.gxt.ui.client.widget.layout.FormLayout;
33
import com.extjs.gxt.ui.client.widget.layout.FormLayout;
40
import com.extjs.gxt.ui.client.widget.layout.RowData;
34
import com.extjs.gxt.ui.client.widget.layout.RowData;
41
import com.extjs.gxt.ui.client.widget.layout.RowLayout;
-
 
42
import com.extjs.gxt.ui.client.widget.layout.TableData;
-
 
43
import com.extjs.gxt.ui.client.widget.layout.TableLayout;
-
 
44
 
-
 
45
import com.google.gwt.core.client.GWT;
-
 
46
import com.google.gwt.i18n.client.DateTimeFormat;
35
import com.extjs.gxt.ui.client.widget.layout.RowLayout;
Line 47... Line 36...
47
import com.google.gwt.user.client.ui.Image;
36
import com.google.gwt.user.client.ui.Image;
Line 55... Line 44...
55
	private TabPanel tabPanel;
44
	private TabPanel tabPanel;
Line 56... Line 45...
56
	
45
	
57
	// Onglet 1 : identite & contact
46
	// Onglet 1 : identite & contact
Line 58... Line -...
58
	private TabItem tabIdentite;
-
 
59
	
-
 
Line 60... Line 47...
60
	private FieldSet fsIdentite;
47
	private TabItem tabIdentite;
61
	private FieldSet fsContact;
48
	
62
	
-
 
63
	// Onglet 2 : Adresses
-
 
Line 64... Line 49...
64
	private TabItem tabAdresse;
49
	
65
	private FieldSet fsAdressePerso;
50
	// Onglet 2 : Adresses
66
		// contient : adresse perso / adresse pro
51
	private TabItem tabAdresse;
Line 73... Line 58...
73
	private TabItem tabLogos;
58
	private TabItem tabLogos;
Line 74... Line 59...
74
	
59
	
Line 75... Line -...
75
	
-
 
76
	private Mediateur mediateur = (Mediateur) Registry.get(RegistreId.MEDIATEUR);
-
 
77
	
-
 
78
	
-
 
79
	//Templatesstyle='display:inline-block; padding-left:15px; width:70%; font-size:11px'
-
 
80
	private String enteteTpl = "<div id='{css_id}'>"+
-
 
81
							   "<h1>{nom}</h1>"+
-
 
82
							   "<h2><a href='{mail}'>{mail}</a></h2>" +
-
 
83
							   "</div>";
-
 
84
	
-
 
85
	
-
 
86
	private String tabIdentiteTpl = "<div class='coel-fieldset'>" +
-
 
87
									"		<span><b>Nom Complet:</b></span> {nom_complet}<br />" +
-
 
88
									"		<span><b>Autres noms:</b></span> {nom_autre}<br />" +
-
 
89
									"		<span><b>Abréviation:</b></span> {abreviation}<br />" +
-
 
90
									"		<span><b>Autres Abréviations:</b></b></span> {abreviation_autre}<br /><br />" +
-
 
91
									"		<span><b>Date de naissance</b></span> {naissance_date}<br />" +
-
 
92
									"		<span><b>Lieu de naissance:</b></span> {naissance_lieu}<br /><br />" +
-
 
93
									"		<span><b>Date de décès:</b></span> {deces_date}<br />" +
-
 
94
									"		<span><b>Lieu de décès:</b></span> {deces_lieu}<br /><br />" +
-
 
95
									"</div>" +
-
 
96
									"<div class='coel-fieldset'>" +
-
 
97
									"		<span style='vertical-align:top'><b>Description:</b></span> {description}<br />" +
-
 
98
									"</div>";
60
	
Line 99... Line 61...
99
	
61
	private Mediateur mediateur = (Mediateur) Registry.get(RegistreId.MEDIATEUR);
Line 100... Line 62...
100
	
62
	
Line 118... Line 80...
118
		
80
		
119
		//Constructeur de la classe
81
		//Constructeur de la classe
120
		Registry.register(RegistreId.PANNEAU_PERSONNE_DETAIL, this);
82
		Registry.register(RegistreId.PANNEAU_PERSONNE_DETAIL, this);
Line 121... Line 83...
121
		//setLayout(new FitLayout());
83
		//setLayout(new FitLayout());
122
		
84
		
123
		tabIdentite = new TabItem("Identité");
85
		tabIdentite = new TabItem(mediateur.i18nC.personneIdentite());
Line 124... Line -...
124
		tabIdentite.setLayout(new FitLayout());
-
 
125
		tabIdentite.setScrollMode(Scroll.AUTO);
-
 
126
				
-
 
127
		fsIdentite = new FieldSet();
-
 
128
		fsIdentite.setLayout(new FormLayout());
-
 
129
		
-
 
130
		
-
 
131
		fsContact = new FieldSet();
86
		tabIdentite.setLayout(new FitLayout());
Line 132... Line 87...
132
		fsContact.setLayout(new FormLayout());
87
		tabIdentite.setScrollMode(Scroll.AUTO);
133
		
88
				
134
		tabPanel.add(tabIdentite);
89
		tabPanel.add(tabIdentite);
135
		
90
		
136
		//Onglet Adresse:
-
 
137
		tabAdresse = new TabItem("Adresses");
91
		//Onglet Adresse:
Line 138... Line 92...
138
		fsAdressePerso = new FieldSet();
92
		tabAdresse = new TabItem(mediateur.i18nC.personneAdresses());
139
		fsAdressePerso.setLayout(new FormLayout());
93
		tabAdresse.setLayout(new FitLayout());
140
		
94
		tabAdresse.setScrollMode(Scroll.AUTO);
141
		tabPanel.add(tabAdresse);
95
		tabPanel.add(tabAdresse);
142
		
96
		
Line 143... Line 97...
143
		//Onglet info naturalistes
97
		//Onglet info naturalistes
Line 144... Line 98...
144
		tabInfosNat = new TabItem("Informations naturalistes");
98
		tabInfosNat = new TabItem(mediateur.i18nC.personneInfoNat());
145
		fsSpec = new FieldSet();
99
		fsSpec = new FieldSet();
Line 146... Line 100...
146
		fsSpec.setLayout(new FormLayout());
100
		fsSpec.setLayout(new FormLayout());
147
		tabInfosNat.setScrollMode(Scroll.AUTO);
101
		tabInfosNat.setScrollMode(Scroll.AUTO);
Line 158... Line 112...
158
	private HashMap hmLabelFieldRegion = new HashMap();
112
	private HashMap hmLabelFieldRegion = new HashMap();
Line 159... Line 113...
159
	
113
	
160
	public void afficherDetailPersonne(Personne personne) {
114
	public void afficherDetailPersonne(Personne personne) {
Line 161... Line 115...
161
		if (personne != null) {
115
		if (personne != null) {
-
 
116
			
-
 
117
			String enteteTpl = "<div id='{css_id}'>"+
-
 
118
			   "<h1>{nom}</h1>"+
Line -... Line 119...
-
 
119
			   "<h2><a href='{mail}'>{mail}</a></h2>" +
162
			
120
			   "</div>";
163
			//MAJ Identité : Configurer les fieldSet
121
			
164
			
-
 
165
			Params enteteParams = new Params();
122
			//MAJ Identité : Configurer les fieldSet
166
			enteteParams.set("css_id", ComposantId.ZONE_DETAIL_ENTETE);
123
			Params enteteParams = new Params();
Line 167... Line 124...
167
			enteteParams.set("css_meta", ComposantClass.META);
124
			enteteParams.set("css_id", ComposantId.ZONE_DETAIL_ENTETE);
168
			enteteParams.set("nom", (String) personne.get("fmt_nom_complet"));
125
			enteteParams.set("nom", (String) personne.get("fmt_nom_complet"));
Line 185... Line 142...
185
					tabLogos.add(imgCourante);		
142
					tabLogos.add(imgCourante);		
186
				}
143
				}
Line 187... Line 144...
187
				
144
				
188
				tabLogos.enable();			
145
				tabLogos.enable();			
-
 
146
			} else {
189
			} else {
147
				enteteParams.set("image", "");
190
				tabLogos.disable();
148
				tabLogos.disable();
Line 191... Line 149...
191
			}	
149
			}
Line -... Line 150...
-
 
150
			
-
 
151
			lcDetailHaut.el().setInnerHtml(Format.substitute(enteteTpl, enteteParams));
-
 
152
			
-
 
153
			String tabIdentiteTpl = "<div class='{css_id}'>" +
-
 
154
			" <span><b>" + mediateur.i18nC.personneNomComplet() + ":</b></span> {nom_complet}<br />" +
-
 
155
			" <span><b>" + mediateur.i18nC.personneNomAutre() + ":</b></span> {nom_autre}<br />" +
-
 
156
			" <span><b>" + mediateur.i18nC.personneAbreviation() + ":</b></span> {abreviation}<br />" +
-
 
157
			" <span><b>" + mediateur.i18nC.personneAbreviationAutre() + ":</b></b></span> {abreviation_autre}<br /><br />" +
-
 
158
			" <span><b>" + mediateur.i18nC.personneDateNaissance() + "</b></span> {naissance_date}<br />" +
-
 
159
			" <span><b>" + mediateur.i18nC.personneLieuNaissance() + ":</b></span> {naissance_lieu}<br /><br />" +
-
 
160
			" <span><b>" + mediateur.i18nC.personneDateDeces() + ":</b></span> {deces_date}<br />" +
-
 
161
			" <span><b>" + mediateur.i18nC.personneLieuDeces() + ":</b></span> {deces_lieu}<br /><br />" +
-
 
162
			"</div>" +
-
 
163
			"<div class='{css_id}'>" +
192
			
164
			" 	<span style='vertical-align:top'><b>" + mediateur.i18nC.description() + ":</b><br /></span> {description}<br />" +
-
 
165
			"<br />";
193
			lcDetailHaut.el().setInnerHtml(Format.substitute(enteteTpl, enteteParams));
166
			
194
			
167
			Params tabIdentiteParams = new Params();
195
			Params tabIdentiteParams = new Params();
168
			tabIdentiteParams.set("css_id", "coel-fieldset");
196
			tabIdentiteParams.set("nom_complet", personne.getString("fmt_nom_complet"));
169
			tabIdentiteParams.set("nom_complet", personne.getString("fmt_nom_complet"));
197
			tabIdentiteParams.set("abreviation", personne.getString("abreviation"));
170
			tabIdentiteParams.set("abreviation", personne.getString("abreviation"));
198
			tabIdentiteParams.set("naissance_date", personne.getString("naissance_date"));
171
			tabIdentiteParams.set("naissance_date", personne.getString("naissance_date"));
199
			tabIdentiteParams.set("naissance_lieu", personne.getString("naissance_lieu"));
172
			tabIdentiteParams.set("naissance_lieu", personne.getString("naissance_lieu"));
Line 200... Line -...
200
			tabIdentiteParams.set("deces_date", personne.getString("deces_date"));
-
 
201
			tabIdentiteParams.set("deces_lieu", personne.getString("deces_lieu"));
-
 
202
			tabIdentiteParams.set("description", personne.getString("description"));
173
			tabIdentiteParams.set("deces_date", personne.getString("deces_date"));
Line 203... Line 174...
203
			
174
			tabIdentiteParams.set("deces_lieu", personne.getString("deces_lieu"));
204
			fsAdressePerso.removeAll();
175
			tabIdentiteParams.set("description", personne.getString("description"));
205
			fsSpec.removeAll();
176
			
Line 219... Line 190...
219
			if ((abrevAutres != null)&&(abrevAutres.size() > 0))	{
190
			if ((abrevAutres != null)&&(abrevAutres.size() > 0))	{
220
				listeAbrev = UtilTruk.traiterTrukListe(abrevAutres, ", ");
191
				listeAbrev = UtilTruk.traiterTrukListe(abrevAutres, ", ");
221
			}
192
			}
222
			tabIdentiteParams.set("abreviation_autre", listeAbrev);
193
			tabIdentiteParams.set("abreviation_autre", listeAbrev);
Line 223... Line -...
223
			
-
 
224
			tabIdentite.el().setInnerHtml(Format.substitute(tabIdentiteTpl, tabIdentiteParams));
-
 
225
			
-
 
226
			// CONTACT > Plusieurs téléphones possible, typés
-
 
227
			Constantes constantesI18n = (Constantes) GWT.create(Constantes.class);
-
 
228
			
-
 
229
			
194
			
230
			HashMap<String, String> mapTelephones = (HashMap<String, String>) personne.getChaineDenormaliseAsMapOrList("truk_telephone");
195
			HashMap<String, String> mapTelephones = (HashMap<String, String>) personne.getChaineDenormaliseAsMapOrList("truk_telephone");
Line 231... Line 196...
231
			if ((mapTelephones != null)&&(mapTelephones.size() > 0))	{
196
			if ((mapTelephones != null)&&(mapTelephones.size() > 0))	{
232
				
197
				
Line 233... Line 198...
233
				Collection<String> telephoneKeys = mapTelephones.keySet();
198
				Collection<String> telephoneKeys = mapTelephones.keySet();
234
				Iterator<String> itTelephones = telephoneKeys.iterator();
199
				Iterator<String> itTelephones = telephoneKeys.iterator();
235
				
-
 
236
				while (itTelephones.hasNext())	{
200
				
237
					String key = itTelephones.next();
201
				while (itTelephones.hasNext())	{
238
					LabelField telephoneLabel = new LabelField();
202
					String key = itTelephones.next();
239
					String label = "";
203
					String label = mapTelephones.get(key);
240
					try {
204
					try {
241
						label = constantesI18n.getString(key);
205
						label = mediateur.i18nC.getString(label);
242
					}
206
					}
Line 243... Line 207...
243
					catch (MissingResourceException e)	{
207
					catch (MissingResourceException e)	{
244
						label = key;
-
 
245
					}
-
 
246
					
-
 
247
					telephoneLabel.setFieldLabel( label + ":");
208
						label = key;
248
					
209
					}
249
					telephoneLabel.setValue(mapTelephones.get(key));
210
					
Line 250... Line -...
250
					
-
 
251
					fsContact.add(telephoneLabel);
-
 
252
				}
-
 
253
			}
-
 
254
			
-
 
255
			// Fax
-
 
256
			// > Plusieurs fax possible, typés
-
 
257
			
-
 
258
			HashMap<String, String> mapFax = (HashMap<String, String>) personne.getChaineDenormaliseAsMapOrList("truk_fax");
-
 
259
			if ((mapFax != null)&&(mapFax.size() > 0))	{
211
					tabIdentiteTpl += "<b>" + label + ":</b> " + key;
260
				
-
 
261
				Collection<String> faxKeys = mapFax.keySet();
-
 
262
				Iterator<String> itFax = faxKeys.iterator();
-
 
263
				
-
 
264
				while (itFax.hasNext())	{
-
 
265
					String key = itFax.next();
-
 
266
					LabelField faxLabel = new LabelField();
-
 
267
					String label = "";
-
 
268
					try {
-
 
269
						label = constantesI18n.getString(key);
-
 
270
					}
-
 
271
					catch (MissingResourceException e)	{
-
 
272
						label = key;
-
 
273
					}
-
 
274
					
-
 
275
					faxLabel.setFieldLabel( label + ":");
-
 
276
					
-
 
277
					faxLabel.setValue(mapTelephones.get(key));
-
 
278
					
-
 
279
					fsContact.add(faxLabel);
-
 
Line -... Line 212...
-
 
212
					tabIdentiteTpl += "<br />";
280
				}
213
				}
281
			}
214
			}
282
			
215
			
283
			// Courriel
216
			// FAX > TYPE Téléphone
284
			// Courriel est un champ truk de la forme "Adresse@adr.com;; adr2@adr.fr ..."
217
			
285
			
218
			// Courriel :Champ truk de la forme "Adresse@adr.com;; adr2@adr.fr ..."
Line 286... Line -...
286
			LinkedList<String> listeCourriel = (LinkedList<String>) personne.getChaineDenormaliseAsMapOrList("truk_courriel");
-
 
287
			if ((listeCourriel!=null)&&(listeCourriel.size() > 0))	{
-
 
288
				String strLabelCourriel = "Courriel";
-
 
289
				if (listeCourriel.size() > 1)	{
219
			LinkedList<String> listeCourriel = (LinkedList<String>) personne.getChaineDenormaliseAsMapOrList("truk_courriel");
290
					strLabelCourriel += "s";	
220
			if ((listeCourriel!=null)&&(listeCourriel.size() > 0))	{
291
				}
221
				String strLabelCourriel = "Courriel";
292
				
222
				if (listeCourriel.size() > 1)	{
293
				LabelField labelCourriel = new LabelField();
223
					strLabelCourriel += "s";	
Line 294... Line 224...
294
				labelCourriel.setFieldLabel(strLabelCourriel);
224
				}
Line 295... Line 225...
295
				
225
				
296
				String valeurCourriel = "";
-
 
297
				Iterator<String> itCourriel = listeCourriel.iterator();
226
				String valeurCourriel = "";
298
				while (itCourriel.hasNext())	{
-
 
299
					String valeurCourante = itCourriel.next();
227
				Iterator<String> itCourriel = listeCourriel.iterator();
300
					valeurCourriel += "<a href=\"mailto:" + valeurCourante + "\">" + valeurCourante + "</a><br />";
228
				while (itCourriel.hasNext())	{
301
										
229
					String valeurCourante = itCourriel.next();
302
				}
230
					valeurCourriel += "<br /><a href=\"mailto:" + valeurCourante + "\">" + valeurCourante + "</a>";
-
 
231
										
-
 
232
				}
303
				
233
				
304
				labelCourriel.setValue(valeurCourriel);
234
				tabIdentiteTpl += valeurCourriel;
305
				fsContact.add(labelCourriel);
235
			}
306
			}
236
 
307
			
237
			// Url Site Webs
308
			
-
 
309
			// Url Site Webs
-
 
310
			LinkedList listeUrl = (LinkedList) personne.getChaineDenormaliseAsMapOrList("truk_url");
238
			LinkedList listeUrl = (LinkedList) personne.getChaineDenormaliseAsMapOrList("truk_url");
Line 311... Line 239...
311
			if (listeUrl!=null && listeUrl.size() > 0)	{
239
			if (listeUrl!=null && listeUrl.size() > 0)	{
312
				String strUrl = "";
-
 
313
				Iterator<String> urlIt = listeUrl.iterator();
-
 
314
				while (urlIt.hasNext())	{
-
 
315
					String urlCourante = urlIt.next();
240
				
316
					strUrl += "<a href=\""+urlCourante+"\">" + urlCourante + "</a> <br/>";
-
 
317
					
-
 
318
					
-
 
Line -... Line 241...
-
 
241
				tabIdentiteTpl += "<br /><br /><b>Sites web:</b><br /><span style='display:inline-block'>";
Line 319... Line -...
319
				}
-
 
320
				
-
 
321
				LabelField urlLabelField = new LabelField();
-
 
322
				urlLabelField.setFieldLabel("Url:");
-
 
323
				urlLabelField.setValue(strUrl);
-
 
324
				fsContact.add(urlLabelField);
-
 
325
			}
-
 
326
			
-
 
327
			tabIdentite.setStyleAttribute("padding", "15px");
-
 
328
			//tabIdentite.add(fsContact);
-
 
329
			
-
 
330
			
-
 
331
			fsAdressePerso.setHeading("Adresse personnelle");
-
 
332
			
-
 
333
			/*
-
 
334
			 * Adresses :
242
				String strUrl = "";
335
			 * */
-
 
336
			String adresse01 = (String) personne.obtenirValeurChamp("adresse_01");
-
 
337
			ajouterLabelField(fsAdressePerso, "Adresse", adresse01);
-
 
338
			
-
 
339
			String adresse02 = (String) personne.obtenirValeurChamp("adresse_02");
-
 
340
			ajouterLabelField(fsAdressePerso, "", adresse02);
243
				Iterator<String> urlIt = listeUrl.iterator();
341
			
-
 
342
			String boitePostale = (String) personne.obtenirValeurChamp("bp");
-
 
343
			ajouterLabelField(fsAdressePerso, "Boite Postale", boitePostale);
-
 
344
			
-
 
345
			String codePostal = (String) personne.obtenirValeurChamp("code_postal");
-
 
346
			ajouterLabelField(fsAdressePerso, "Code postal", codePostal);
-
 
Line -... Line 244...
-
 
244
				while (urlIt.hasNext())	{
-
 
245
					String urlCourante = urlIt.next();
-
 
246
					strUrl += "<a href=\""+urlCourante+"\">" + urlCourante + "</a> <br/>";
-
 
247
				}
-
 
248
				
-
 
249
				tabIdentiteTpl += strUrl + "</span><br />";
-
 
250
			}			
-
 
251
			
-
 
252
			tabIdentiteTpl += "</div>";
347
			
253
			
-
 
254
			afficherOnglet(tabIdentiteTpl, tabIdentiteParams, tabIdentite);
-
 
255
			tabIdentite.setStyleAttribute("padding", "15px");
-
 
256
			
-
 
257
			String tabAdresseTpl = 	"<div id='css_id'>" +
-
 
258
									"	<h1>Adresse personnelle:</h1>" +
-
 
259
									"	{adresse01} <br />" +
-
 
260
									"	{adresse02} <br />" +
Line -... Line 261...
-
 
261
									"	{boitePostale}<br />" +
-
 
262
									"	{codePostal} {region}<br />" +
Line 348... Line -...
348
			String ville = (String) personne.obtenirValeurChamp("ville");
-
 
349
			ajouterLabelField(fsAdressePerso, "Ville", ville);
-
 
350
			
-
 
351
			String region = (String) personne.obtenirValeurChamp("region");
263
									"	<span style='uppercase'>{pays}</span><br />" +
Line 352... Line 264...
352
			ajouterLabelField(fsAdressePerso, "Région", region);
264
									"</div>";
353
			
265
			//Adresses :
Line 354... Line 266...
354
			String pays = (String) personne.obtenirValeurChamp("pays");
266
			Params paramAdresseTpl = new Params();
Line 377... Line 289...
377
				while (itSpec.hasNext())	{
289
				while (itSpec.hasNext())	{
378
					String key = itSpec.next();
290
					String key = itSpec.next();
379
					LabelField specLabel = new LabelField();
291
					LabelField specLabel = new LabelField();
380
					String label = "";
292
					String label = "";
381
					try {
293
					try {
382
						label = constantesI18n.getString(key);
294
						label = mediateur.i18nC.getString(key);
383
					}
295
					}
384
					catch (MissingResourceException e)	{
296
					catch (MissingResourceException e)	{
385
						label = key;
297
						label = key;
386
					}
298
					}
Line 434... Line 346...
434
			// tabInfosNat
346
			// tabInfosNat
435
			layout();
347
			layout();
436
		} 
348
		} 
437
	}
349
	}
Line -... Line 350...
-
 
350
	
-
 
351
	protected void afficherOnglet(String template, Params parametres, TabItem onglet) {
-
 
352
		String cHtml = Format.substitute(template, parametres);
-
 
353
		
-
 
354
		Params cssParams = new Params();
-
 
355
		cssParams.set("css_corps", ComposantClass.DETAIL_CORPS_CONTENU);
-
 
356
		cssParams.set("css_label", ComposantClass.LABEL);
-
 
357
		cssParams.set("css_indentation", ComposantClass.INDENTATION);
-
 
358
		cssParams.set("css_fieldset", ComposantClass.FIELDSET);
-
 
359
		cssParams.set("css_clear", ComposantClass.CLEAR);
-
 
360
		cHtml = Format.substitute(cHtml, cssParams);
-
 
361
		
-
 
362
		HtmlContainer corpsConteneurDuHtml = new HtmlContainer(cHtml);
-
 
363
		onglet.removeAll();
-
 
364
		onglet.add(corpsConteneurDuHtml);		
-
 
365
	}
Line 438... Line 366...
438
	
366
	
Line 439... Line 367...
439
	
367
	
440
	private void changerLabelRegions()	{
368
	private void changerLabelRegions()	{