Subversion Repositories eFlore/Applications.coel

Rev

Rev 448 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 448 Rev 453
1
package org.tela_botanica.client.vues;
1
package org.tela_botanica.client.vues;
2
 
2
 
3
import java.util.ArrayList;
3
import java.util.ArrayList;
4
import java.util.HashMap;
4
import java.util.HashMap;
5
import java.util.Iterator;
5
import java.util.Iterator;
6
 
6
 
7
import org.tela_botanica.client.ComposantClass;
7
import org.tela_botanica.client.ComposantClass;
8
import org.tela_botanica.client.ComposantId;
8
import org.tela_botanica.client.ComposantId;
9
import org.tela_botanica.client.Mediateur;
9
import org.tela_botanica.client.Mediateur;
10
import org.tela_botanica.client.i18n.Constantes;
10
import org.tela_botanica.client.i18n.Constantes;
11
import org.tela_botanica.client.interfaces.Rafraichissable;
11
import org.tela_botanica.client.interfaces.Rafraichissable;
12
import org.tela_botanica.client.modeles.Information;
12
import org.tela_botanica.client.modeles.Information;
13
import org.tela_botanica.client.modeles.Projet;
13
import org.tela_botanica.client.modeles.Projet;
14
import org.tela_botanica.client.modeles.ProjetListe;
14
import org.tela_botanica.client.modeles.ProjetListe;
15
import org.tela_botanica.client.modeles.Structure;
15
import org.tela_botanica.client.modeles.Structure;
16
import org.tela_botanica.client.modeles.StructureAPersonne;
16
import org.tela_botanica.client.modeles.StructureAPersonne;
17
import org.tela_botanica.client.modeles.StructureAPersonneListe;
17
import org.tela_botanica.client.modeles.StructureAPersonneListe;
18
import org.tela_botanica.client.modeles.StructureConservation;
18
import org.tela_botanica.client.modeles.StructureConservation;
19
import org.tela_botanica.client.modeles.StructureValorisation;
19
import org.tela_botanica.client.modeles.StructureValorisation;
20
import org.tela_botanica.client.modeles.Valeur;
20
import org.tela_botanica.client.modeles.Valeur;
21
import org.tela_botanica.client.modeles.ValeurListe;
21
import org.tela_botanica.client.modeles.ValeurListe;
22
 
22
 
23
import com.extjs.gxt.ui.client.Style.Scroll;
23
import com.extjs.gxt.ui.client.Style.Scroll;
24
import com.extjs.gxt.ui.client.util.Format;
24
import com.extjs.gxt.ui.client.util.Format;
25
import com.extjs.gxt.ui.client.util.Params;
25
import com.extjs.gxt.ui.client.util.Params;
26
import com.extjs.gxt.ui.client.widget.ContentPanel;
26
import com.extjs.gxt.ui.client.widget.ContentPanel;
27
import com.extjs.gxt.ui.client.widget.Html;
27
import com.extjs.gxt.ui.client.widget.Html;
28
import com.extjs.gxt.ui.client.widget.HtmlContainer;
28
import com.extjs.gxt.ui.client.widget.HtmlContainer;
29
import com.extjs.gxt.ui.client.widget.LayoutContainer;
29
import com.extjs.gxt.ui.client.widget.LayoutContainer;
30
import com.extjs.gxt.ui.client.widget.TabItem;
30
import com.extjs.gxt.ui.client.widget.TabItem;
31
import com.extjs.gxt.ui.client.widget.TabPanel;
31
import com.extjs.gxt.ui.client.widget.TabPanel;
32
import com.extjs.gxt.ui.client.widget.layout.AnchorLayout;
32
import com.extjs.gxt.ui.client.widget.layout.AnchorLayout;
33
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
33
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
34
import com.extjs.gxt.ui.client.widget.layout.FlowLayout;
34
import com.extjs.gxt.ui.client.widget.layout.FlowLayout;
35
import com.google.gwt.core.client.GWT;
35
import com.google.gwt.core.client.GWT;
36
 
36
 
37
public class StructureDetailVue extends LayoutContainer implements Rafraichissable {
-
 
38
 
-
 
39
	private Mediateur mediateur = null;
-
 
40
	private Constantes i18nC = null;
-
 
41
	private HashMap<String, Valeur> ontologie = null;
-
 
42
	private ProjetListe projets = null;
37
public class StructureDetailVue extends DetailVue implements Rafraichissable {
43
	
38
 
44
	private String enteteTpl = null;
39
	private String enteteTpl = null;
45
	private String identificationTpl = null;
40
	private String identificationTpl = null;
46
	private String personnelTpl = null;
41
	private String personnelTpl = null;
47
	private String tableauPersonnelTpl = null;
42
	private String tableauPersonnelTpl = null;
48
	private String lignePersonnelTpl = null;
43
	private String lignePersonnelTpl = null;
49
	private String conservationTpl = null;
44
	private String conservationTpl = null;
50
	private String traitementConservationTpl = null;
45
	private String traitementConservationTpl = null;
51
	private String valorisationTpl = null;
46
	private String valorisationTpl = null;
52
	private String sautLigneTpl = null;
-
 
53
	private String typeTraitementConservationTpl = null;
47
	private String typeTraitementConservationTpl = null;
54
	private String rechercheValorisationTpl = null;
48
	private String rechercheValorisationTpl = null;
55
	
49
	
56
	private Structure structure = null;
50
	private Structure structure = null;
57
	private StructureAPersonneListe personnel = null;
51
	private StructureAPersonneListe personnel = null;
58
	private StructureValorisation valorisation = null;
52
	private StructureValorisation valorisation = null;
59
	private StructureConservation conservation = null;
53
	private StructureConservation conservation = null;
60
	
54
	
61
	private ContentPanel panneauPrincipal = null;
55
	private ContentPanel panneauPrincipal = null;
62
	private Html entete = null;
56
	private Html entete = null;
63
	private TabPanel onglets = null;
57
	private TabPanel onglets = null;
64
	private TabItem identificationOnglet = null;
58
	private TabItem identificationOnglet = null;
65
	private TabItem personnelOnglet = null;
59
	private TabItem personnelOnglet = null;
66
	private TabItem conservationOnglet = null;
60
	private TabItem conservationOnglet = null;
67
	private TabItem valorisationOnglet = null;
61
	private TabItem valorisationOnglet = null;
68
	
62
	
69
	public StructureDetailVue(Mediateur mediateurCourant) {
63
	public StructureDetailVue(Mediateur mediateurCourant) {
70
		mediateur = mediateurCourant;
64
		super(mediateurCourant);
71
		i18nC = mediateur.i18nC; 
-
 
-
 
65
		
72
		initialiserTousLesTpl();
66
		initialiserTousLesTpl();
73
		ontologie = new HashMap<String, Valeur>();
-
 
74
		chargerOntologie();
67
		chargerOntologie();
75
		
-
 
76
		setLayout(new FitLayout());
-
 
77
		setBorders(false);
-
 
78
		setScrollMode(Scroll.AUTO);
-
 
79
		
68
		
80
		panneauPrincipal = new ContentPanel();
69
		panneauPrincipal = new ContentPanel();
81
		panneauPrincipal.setLayout(new FlowLayout());
70
		panneauPrincipal.setLayout(new FlowLayout());
82
		panneauPrincipal.setHeaderVisible(false);
71
		panneauPrincipal.setHeaderVisible(false);
83
		panneauPrincipal.setBodyBorder(false);
72
		panneauPrincipal.setBodyBorder(false);
84
			
73
			
85
	    entete = new Html();
74
	    entete = new Html();
86
	    entete.setId(ComposantId.ZONE_DETAIL_ENTETE);
75
	    entete.setId(ComposantId.ZONE_DETAIL_ENTETE);
87
	    panneauPrincipal.setTopComponent(entete);
76
	    panneauPrincipal.setTopComponent(entete);
88
		
77
		
89
		onglets = new TabPanel();
78
		onglets = new TabPanel();
90
		onglets.setId(ComposantId.ZONE_DETAIL_CORPS);
79
		onglets.setId(ComposantId.ZONE_DETAIL_CORPS);
91
		onglets.setHeight("100%");
80
		onglets.setHeight("100%");
92
		onglets.setBodyBorder(false);
81
		onglets.setBodyBorder(false);
93
 
82
 
94
		identificationOnglet = new TabItem(i18nC.structureInfoGeneral());
83
		identificationOnglet = new TabItem(i18nC.structureInfoGeneral());
95
		identificationOnglet.setLayout(new AnchorLayout());
84
		identificationOnglet.setLayout(new AnchorLayout());
96
		identificationOnglet.setScrollMode(Scroll.AUTO);
85
		identificationOnglet.setScrollMode(Scroll.AUTO);
97
		onglets.add(identificationOnglet);
86
		onglets.add(identificationOnglet);
98
		
87
		
99
		personnelOnglet = new TabItem(i18nC.structureInfoPersonnel());
88
		personnelOnglet = new TabItem(i18nC.structureInfoPersonnel());
100
		personnelOnglet.setLayout(new AnchorLayout());
89
		personnelOnglet.setLayout(new AnchorLayout());
101
		personnelOnglet.setScrollMode(Scroll.AUTO);
90
		personnelOnglet.setScrollMode(Scroll.AUTO);
102
		onglets.add(personnelOnglet);
91
		onglets.add(personnelOnglet);
103
		
92
		
104
		conservationOnglet = new TabItem(i18nC.structureInfoConservation());
93
		conservationOnglet = new TabItem(i18nC.structureInfoConservation());
105
		conservationOnglet.setLayout(new AnchorLayout());
94
		conservationOnglet.setLayout(new AnchorLayout());
106
		conservationOnglet.setScrollMode(Scroll.AUTO);
95
		conservationOnglet.setScrollMode(Scroll.AUTO);
107
		onglets.add(conservationOnglet);
96
		onglets.add(conservationOnglet);
108
		
97
		
109
		valorisationOnglet = new TabItem(i18nC.structureInfoValorisation());
98
		valorisationOnglet = new TabItem(i18nC.structureInfoValorisation());
110
		valorisationOnglet.setLayout(new AnchorLayout());
99
		valorisationOnglet.setLayout(new AnchorLayout());
111
		valorisationOnglet.setScrollMode(Scroll.AUTO);
100
		valorisationOnglet.setScrollMode(Scroll.AUTO);
112
		onglets.add(valorisationOnglet);
101
		onglets.add(valorisationOnglet);
113
		
102
		
114
		panneauPrincipal.add(onglets);
103
		panneauPrincipal.add(onglets);
115
		add(panneauPrincipal);
104
		add(panneauPrincipal);
116
	}
105
	}
117
 
106
 
118
	private void chargerOntologie() {
107
	private void chargerOntologie() {
119
		mediateur.selectionnerProjets(this);
-
 
120
		mediateur.obtenirListeValeurEtRafraichir(this, "stpr");
108
		mediateur.obtenirListeValeurEtRafraichir(this, "stpr");
121
		mediateur.obtenirListeValeurEtRafraichir(this, "stpu");
109
		mediateur.obtenirListeValeurEtRafraichir(this, "stpu");
122
		mediateur.obtenirListeValeurEtRafraichir(this, "statut");
110
		mediateur.obtenirListeValeurEtRafraichir(this, "statut");
123
		mediateur.obtenirListeValeurEtRafraichir(this, "fonction");
111
		mediateur.obtenirListeValeurEtRafraichir(this, "fonction");
124
		mediateur.obtenirListeValeurEtRafraichir(this, "pays");
112
		mediateur.obtenirListeValeurEtRafraichir(this, "pays");
125
		mediateur.obtenirListeValeurEtRafraichir(this, "localStockage");
113
		mediateur.obtenirListeValeurEtRafraichir(this, "localStockage");
126
		mediateur.obtenirListeValeurEtRafraichir(this, "meubleStockage");
114
		mediateur.obtenirListeValeurEtRafraichir(this, "meubleStockage");
127
		mediateur.obtenirListeValeurEtRafraichir(this, "parametreStockage");
115
		mediateur.obtenirListeValeurEtRafraichir(this, "parametreStockage");
128
		mediateur.obtenirListeValeurEtRafraichir(this, "autreCollection");
116
		mediateur.obtenirListeValeurEtRafraichir(this, "autreCollection");
129
		mediateur.obtenirListeValeurEtRafraichir(this, "onep");
117
		mediateur.obtenirListeValeurEtRafraichir(this, "onep");
130
		mediateur.obtenirListeValeurEtRafraichir(this, "opRestau");
118
		mediateur.obtenirListeValeurEtRafraichir(this, "opRestau");
131
		mediateur.obtenirListeValeurEtRafraichir(this, "autreMateriel");
119
		mediateur.obtenirListeValeurEtRafraichir(this, "autreMateriel");
132
		mediateur.obtenirListeValeurEtRafraichir(this, "poisonTraitement");
120
		mediateur.obtenirListeValeurEtRafraichir(this, "poisonTraitement");
133
		mediateur.obtenirListeValeurEtRafraichir(this, "insecteTraitement");
121
		mediateur.obtenirListeValeurEtRafraichir(this, "insecteTraitement");
134
		mediateur.obtenirListeValeurEtRafraichir(this, "actionValorisation");
122
		mediateur.obtenirListeValeurEtRafraichir(this, "actionValorisation");
135
		mediateur.obtenirListeValeurEtRafraichir(this, "continentEtFr");
123
		mediateur.obtenirListeValeurEtRafraichir(this, "continentEtFr");
136
		mediateur.obtenirListeValeurEtRafraichir(this, "typeRecherche");
124
		mediateur.obtenirListeValeurEtRafraichir(this, "typeRecherche");
137
	}
125
	}
138
 
126
 
139
	private void afficherDetailInstitution() {
127
	private void afficherDetailInstitution() {
140
		if (structure != null) {
128
		if (structure != null) {
141
			personnel = structure.getPersonnel();
129
			personnel = structure.getPersonnel();
142
			valorisation = structure.getValorisation();
130
			valorisation = structure.getValorisation();
143
			conservation = structure.getConservation();
131
			conservation = structure.getConservation();
144
			
132
			
145
			afficherEntete();
133
			afficherEntete();
146
			afficherIdentification();
134
			afficherIdentification();
147
			if (personnel != null) {
135
			if (personnel != null) {
148
				afficherPersonnel();
136
				afficherPersonnel();
149
			}
137
			}
150
			if (conservation != null) {
138
			if (conservation != null) {
151
				afficherConservation();
139
				afficherConservation();
152
			}
140
			}
153
			if (valorisation != null) {
141
			if (valorisation != null) {
154
				afficherValorisation();
142
				afficherValorisation();
155
			}
143
			}
156
		}
144
		}
157
		layout();
145
		layout();
158
	}
146
	}
159
	
147
	
160
	private void afficherEntete() {
148
	private void afficherEntete() {
161
		Params enteteParams = new Params();
149
		Params enteteParams = new Params();
162
		enteteParams.set("css_id", ComposantId.ZONE_DETAIL_ENTETE);
150
		enteteParams.set("css_id", ComposantId.ZONE_DETAIL_ENTETE);
163
		enteteParams.set("css_meta", ComposantClass.META);
151
		enteteParams.set("css_meta", ComposantClass.META);
164
		
152
		
165
		enteteParams.set("nom", structure.getNom());
153
		enteteParams.set("nom", structure.getNom());
166
		enteteParams.set("ville", structure.getVille());
154
		enteteParams.set("ville", structure.getVille());
167
		enteteParams.set("id", structure.getId());
155
		enteteParams.set("id", structure.getId());
168
		enteteParams.set("guid", structure.getGuid());
156
		enteteParams.set("guid", structure.getGuid());
169
		enteteParams.set("projet", construireTxtProjet(structure.getIdProjet()));
157
		enteteParams.set("projet", construireTxtProjet(structure.getIdProjet()));
170
		
158
		
171
		String eHtml = Format.substitute(enteteTpl, enteteParams);
159
		String eHtml = Format.substitute(enteteTpl, enteteParams);
172
		entete.getElement().setInnerHTML(eHtml);
160
		entete.getElement().setInnerHTML(eHtml);
173
	}
161
	}
174
	
162
	
175
	private void afficherIdentification() {
163
	private void afficherIdentification() {
176
		Params identificationParams = new Params();
164
		Params identificationParams = new Params();
177
		identificationParams.set("i18n_titre_administratif", i18nC.titreAdministratif());
165
		identificationParams.set("i18n_titre_administratif", i18nC.titreAdministratif());
178
		identificationParams.set("i18n_acronyme", i18nC.acronyme());
166
		identificationParams.set("i18n_acronyme", i18nC.acronyme());
179
		identificationParams.set("i18n_statut", i18nC.statut());
167
		identificationParams.set("i18n_statut", i18nC.statut());
180
		identificationParams.set("i18n_date_fondation", mediateur.i18nC.dateFondation());
168
		identificationParams.set("i18n_date_fondation", mediateur.i18nC.dateFondation());
181
		identificationParams.set("i18n_nbre_personnel", mediateur.i18nC.nbrePersonnel());
169
		identificationParams.set("i18n_nbre_personnel", mediateur.i18nC.nbrePersonnel());
182
		
170
		
183
		identificationParams.set("i18n_titre_description", mediateur.i18nC.description());
171
		identificationParams.set("i18n_titre_description", mediateur.i18nC.description());
184
		identificationParams.set("i18n_description", mediateur.i18nC.description());
172
		identificationParams.set("i18n_description", mediateur.i18nC.description());
185
		
173
		
186
		identificationParams.set("i18n_titre_adresse", mediateur.i18nC.adresse());
174
		identificationParams.set("i18n_titre_adresse", mediateur.i18nC.adresse());
187
		identificationParams.set("i18n_adresse", mediateur.i18nC.adresse());
175
		identificationParams.set("i18n_adresse", mediateur.i18nC.adresse());
188
		identificationParams.set("i18n_cp", mediateur.i18nC.codePostal());
176
		identificationParams.set("i18n_cp", mediateur.i18nC.codePostal());
189
		identificationParams.set("i18n_ville", mediateur.i18nC.ville());
177
		identificationParams.set("i18n_ville", mediateur.i18nC.ville());
190
		identificationParams.set("i18n_region", mediateur.i18nC.region());
178
		identificationParams.set("i18n_region", mediateur.i18nC.region());
191
		identificationParams.set("i18n_pays", mediateur.i18nC.pays());
179
		identificationParams.set("i18n_pays", mediateur.i18nC.pays());
192
		
180
		
193
		identificationParams.set("i18n_titre_communication", mediateur.i18nC.titreCommunication());
181
		identificationParams.set("i18n_titre_communication", mediateur.i18nC.titreCommunication());
194
		identificationParams.set("i18n_tel", mediateur.i18nC.telephone());
182
		identificationParams.set("i18n_tel", mediateur.i18nC.telephone());
195
		identificationParams.set("i18n_fax", mediateur.i18nC.fax());
183
		identificationParams.set("i18n_fax", mediateur.i18nC.fax());
196
		identificationParams.set("i18n_courriel", mediateur.i18nC.courriel());
184
		identificationParams.set("i18n_courriel", mediateur.i18nC.courriel());
197
		identificationParams.set("i18n_acces", mediateur.i18nC.acces());
185
		identificationParams.set("i18n_acces", mediateur.i18nC.acces());
198
		identificationParams.set("i18n_web", mediateur.i18nC.siteWeb());
186
		identificationParams.set("i18n_web", mediateur.i18nC.siteWeb());
199
 
187
 
200
		String acronyme = construireTxtTruck(structure.getIdAlternatif());
188
		String acronyme = construireTxtTruck(structure.getIdAlternatif());
201
		String typePrive = construireTxtListeOntologie(structure.getTypePrive());
189
		String typePrive = construireTxtListeOntologie(structure.getTypePrive());
202
		String typePublic = construireTxtListeOntologie(structure.getTypePublic());
190
		String typePublic = construireTxtListeOntologie(structure.getTypePublic());
203
		String pays = construireTxtListeOntologie(structure.getPays());
191
		String pays = construireTxtListeOntologie(structure.getPays());
204
		String web = construireTxtTruck(structure.getUrl());
192
		String web = construireTxtTruck(structure.getUrl());
205
		
193
		
206
		identificationParams.set("acronyme", acronyme);
194
		identificationParams.set("acronyme", acronyme);
207
		identificationParams.set("statut", typePrive+typePublic);
195
		identificationParams.set("statut", typePrive+typePublic);
208
		identificationParams.set("date_fondation", structure.getDateFondationFormatLong());
196
		identificationParams.set("date_fondation", structure.getDateFondationFormatLong());
209
		identificationParams.set("nbre_personnel", structure.getNbrePersonne());
197
		identificationParams.set("nbre_personnel", structure.getNbrePersonne());
210
		
198
		
211
		identificationParams.set("description", structure.getDescription());
199
		identificationParams.set("description", structure.getDescription());
212
		
200
		
213
		identificationParams.set("adresse", structure.getAdresse());
201
		identificationParams.set("adresse", structure.getAdresse());
214
		identificationParams.set("cp", structure.getCodePostal());
202
		identificationParams.set("cp", structure.getCodePostal());
215
		identificationParams.set("ville", structure.getVille());
203
		identificationParams.set("ville", structure.getVille());
216
		identificationParams.set("region", structure.getRegion());
204
		identificationParams.set("region", structure.getRegion());
217
		identificationParams.set("pays", pays);
205
		identificationParams.set("pays", pays);
218
		
206
		
219
		identificationParams.set("tel", structure.getTelephone());
207
		identificationParams.set("tel", structure.getTelephone());
220
		identificationParams.set("fax", structure.getFax());
208
		identificationParams.set("fax", structure.getFax());
221
		identificationParams.set("courriel", structure.getCourriel());
209
		identificationParams.set("courriel", structure.getCourriel());
222
		identificationParams.set("acces", structure.getConditionAcces());
210
		identificationParams.set("acces", structure.getConditionAcces());
223
		identificationParams.set("web", web);
211
		identificationParams.set("web", web);
224
		
212
		
225
		afficherOnglet(identificationTpl, identificationParams, identificationOnglet);
213
		afficherOnglet(identificationTpl, identificationParams, identificationOnglet);
226
	}
214
	}
227
	
215
	
228
	private void afficherPersonnel() {
216
	private void afficherPersonnel() {
229
		String tableauPersonnelHtml = "";
217
		String tableauPersonnelHtml = "";
230
		if (personnel.size() > 0) {
218
		if (personnel.size() > 0) {
231
			tableauPersonnelHtml = construireTableauDuPersonnel();
219
			tableauPersonnelHtml = construireTableauDuPersonnel();
232
		}
220
		}
233
		
221
		
234
		Params personnelParams = new Params();
222
		Params personnelParams = new Params();
235
		personnelParams.set("i18n_titre_personnel", i18nC.titrePersonnel());
223
		personnelParams.set("i18n_titre_personnel", i18nC.titrePersonnel());
236
		personnelParams.set("i18n_nbre_personnel_collection", i18nC.nbrePersonnelCollection());
224
		personnelParams.set("i18n_nbre_personnel_collection", i18nC.nbrePersonnelCollection());
237
		personnelParams.set("nbre_personnel_collection", personnel.size());
225
		personnelParams.set("nbre_personnel_collection", personnel.size());
238
		personnelParams.set("tableau_personnel", tableauPersonnelHtml);
226
		personnelParams.set("tableau_personnel", tableauPersonnelHtml);
239
		
227
		
240
		afficherOnglet(personnelTpl, personnelParams, personnelOnglet);
228
		afficherOnglet(personnelTpl, personnelParams, personnelOnglet);
241
	}
229
	}
242
	
230
	
243
	private String construireTableauDuPersonnel() {
231
	private String construireTableauDuPersonnel() {
244
		Params contenuParams = new Params();
232
		Params contenuParams = new Params();
245
		contenuParams.set("i18n_titre_membre", i18nC.titreMembre());
233
		contenuParams.set("i18n_titre_membre", i18nC.titreMembre());
246
		contenuParams.set("i18n_fonction", i18nC.fonction());
234
		contenuParams.set("i18n_fonction", i18nC.fonction());
247
		contenuParams.set("i18n_prenom", i18nC.prenom());
235
		contenuParams.set("i18n_prenom", i18nC.prenom());
248
		contenuParams.set("i18n_nom", i18nC.nom());
236
		contenuParams.set("i18n_nom", i18nC.nom());
249
		contenuParams.set("i18n_tel", i18nC.telephoneFixe());
237
		contenuParams.set("i18n_tel", i18nC.telephoneFixe());
250
		contenuParams.set("i18n_fax", i18nC.fax());
238
		contenuParams.set("i18n_fax", i18nC.fax());
251
		contenuParams.set("i18n_courriel", i18nC.courrielPrincipal());
239
		contenuParams.set("i18n_courriel", i18nC.courrielPrincipal());
252
		contenuParams.set("i18n_statut", i18nC.statut());
240
		contenuParams.set("i18n_statut", i18nC.statut());
253
		contenuParams.set("i18n_tps_w", i18nC.tpsTravail());
241
		contenuParams.set("i18n_tps_w", i18nC.tpsTravail());
254
		contenuParams.set("i18n_specialite", i18nC.specialite());
242
		contenuParams.set("i18n_specialite", i18nC.specialite());
255
		contenuParams.set("i18n_contact", i18nC.boolContact());
243
		contenuParams.set("i18n_contact", i18nC.boolContact());
256
		
244
		
257
		String lignesPersonnel = ""; 
245
		String lignesPersonnel = ""; 
258
		Iterator<String> it = personnel.keySet().iterator();
246
		Iterator<String> it = personnel.keySet().iterator();
259
		while (it.hasNext()) {
247
		while (it.hasNext()) {
260
			StructureAPersonne personne = personnel.get(it.next());
248
			StructureAPersonne personne = personnel.get(it.next());
261
			Params ligneParams = new Params();
249
			Params ligneParams = new Params();
262
			
250
			
263
			String fonction = construireTxtListeOntologie(personne.getFonction());
251
			String fonction = construireTxtListeOntologie(personne.getFonction());
264
			String statut = construireTxtListeOntologie(personne.getStatut());
252
			String statut = construireTxtListeOntologie(personne.getStatut());
265
			String contact = formaterOuiNon(personne.getContact());
253
			String contact = formaterOuiNon(personne.getContact());
266
			
254
			
267
			ligneParams.set("fonction", fonction);
255
			ligneParams.set("fonction", fonction);
268
			ligneParams.set("prenom", personne.getPrenom());
256
			ligneParams.set("prenom", personne.getPrenom());
269
			ligneParams.set("nom", personne.getNom());
257
			ligneParams.set("nom", personne.getNom());
270
			ligneParams.set("tel", personne.getTelephone());
258
			ligneParams.set("tel", personne.getTelephone());
271
			ligneParams.set("fax", personne.getFax());
259
			ligneParams.set("fax", personne.getFax());
272
			ligneParams.set("courriel", personne.getCourriel());
260
			ligneParams.set("courriel", personne.getCourriel());
273
			ligneParams.set("statut", statut);
261
			ligneParams.set("statut", statut);
274
			ligneParams.set("tps_w", personne.getBotaTravailHebdoTps());
262
			ligneParams.set("tps_w", personne.getBotaTravailHebdoTps());
275
			ligneParams.set("specialite", personne.afficherSpecialite());
263
			ligneParams.set("specialite", personne.afficherSpecialite());
276
			ligneParams.set("contact", contact);
264
			ligneParams.set("contact", contact);
277
			lignesPersonnel += Format.substitute(lignePersonnelTpl, ligneParams);
265
			lignesPersonnel += Format.substitute(lignePersonnelTpl, ligneParams);
278
		}
266
		}
279
		contenuParams.set("lignes", lignesPersonnel);
267
		contenuParams.set("lignes", lignesPersonnel);
280
		
268
		
281
		String cHtml = Format.substitute(tableauPersonnelTpl, contenuParams);
269
		String cHtml = Format.substitute(tableauPersonnelTpl, contenuParams);
282
		return cHtml;
270
		return cHtml;
283
	}
271
	}
284
	
272
	
285
	private void afficherConservation() {
273
	private void afficherConservation() {
286
		Params conservationParams  = new Params();
274
		Params conservationParams  = new Params();
287
		conservationParams.set("i18n_titre_conservation_personnel", i18nC.titreConservationPersonnel());
275
		conservationParams.set("i18n_titre_conservation_personnel", i18nC.titreConservationPersonnel());
288
		conservationParams.set("i18n_formation", i18nC.formation());
276
		conservationParams.set("i18n_formation", i18nC.formation());
289
		conservationParams.set("i18n_formation_interet", i18nC.formationInteret());
277
		conservationParams.set("i18n_formation_interet", i18nC.formationInteret());
290
		
278
		
291
		conservationParams.set("i18n_titre_local", i18nC.titreLocal());
279
		conservationParams.set("i18n_titre_local", i18nC.titreLocal());
292
		conservationParams.set("i18n_local_specifique", i18nC.localSpecifique());
280
		conservationParams.set("i18n_local_specifique", i18nC.localSpecifique());
293
		conservationParams.set("i18n_meuble_specifique", i18nC.meubleSpecifique());
281
		conservationParams.set("i18n_meuble_specifique", i18nC.meubleSpecifique());
294
		conservationParams.set("i18n_local_parametre", i18nC.localParametre());
282
		conservationParams.set("i18n_local_parametre", i18nC.localParametre());
295
		conservationParams.set("i18n_conservation_en_commun", i18nC.conservationEnCommun());
283
		conservationParams.set("i18n_conservation_en_commun", i18nC.conservationEnCommun());
296
		conservationParams.set("i18n_acces_controle", i18nC.accesControle());
284
		conservationParams.set("i18n_acces_controle", i18nC.accesControle());
297
		
285
		
298
		conservationParams.set("i18n_titre_operation", i18nC.titreOperation());
286
		conservationParams.set("i18n_titre_operation", i18nC.titreOperation());
299
		conservationParams.set("i18n_restauration", i18nC.restauration());
287
		conservationParams.set("i18n_restauration", i18nC.restauration());
300
		conservationParams.set("i18n_materiel_conservation", i18nC.materielConservation());
288
		conservationParams.set("i18n_materiel_conservation", i18nC.materielConservation());
301
		conservationParams.set("i18n_traitement", i18nC.traitement());
289
		conservationParams.set("i18n_traitement", i18nC.traitement());
302
		
290
		
303
		conservationParams.set("i18n_titre_acquisition", i18nC.titreAcquisition());
291
		conservationParams.set("i18n_titre_acquisition", i18nC.titreAcquisition());
304
		conservationParams.set("i18n_acquisition_collection", i18nC.acquisitionCollection());
292
		conservationParams.set("i18n_acquisition_collection", i18nC.acquisitionCollection());
305
		conservationParams.set("i18n_acquisition_echantillon", i18nC.acquisitionEchantillon());
293
		conservationParams.set("i18n_acquisition_echantillon", i18nC.acquisitionEchantillon());
306
		
294
		
307
		conservationParams.set("formation", formaterOuiNon(conservation.getFormation()));
295
		conservationParams.set("formation", formaterOuiNon(conservation.getFormation()));
308
		conservationParams.set("formation_info", formaterSautDeLigne(conservation.getFormationInfo()));
296
		conservationParams.set("formation_info", formaterSautDeLigne(conservation.getFormationInfo()));
309
		conservationParams.set("formation_interet", formaterOuiNon(conservation.getFormationInteret()));
297
		conservationParams.set("formation_interet", formaterOuiNon(conservation.getFormationInteret()));
310
		conservationParams.set("meuble_specifique", conservation.getStockageMeuble());
298
		conservationParams.set("meuble_specifique", conservation.getStockageMeuble());
311
		
299
		
312
		String chaineAAnalyser = conservation.getStockageLocal();
300
		String chaineAAnalyser = conservation.getStockageLocal();
313
		String chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
301
		String chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
314
		conservationParams.set("local_specifique", chaineAAfficher);
302
		conservationParams.set("local_specifique", chaineAAfficher);
315
		
303
		
316
		chaineAAnalyser = conservation.getStockageMeuble();
304
		chaineAAnalyser = conservation.getStockageMeuble();
317
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
305
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
318
		conservationParams.set("meuble_specifique", chaineAAfficher);
306
		conservationParams.set("meuble_specifique", chaineAAfficher);
319
		
307
		
320
		chaineAAnalyser = conservation.getStockageParametre();
308
		chaineAAnalyser = conservation.getStockageParametre();
321
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
309
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
322
		conservationParams.set("local_parametre", chaineAAfficher);
310
		conservationParams.set("local_parametre", chaineAAfficher);
323
		
311
		
324
		conservationParams.set("conservation_en_commun", formaterOuiNon(conservation.getCollectionCommune()));
312
		conservationParams.set("conservation_en_commun", formaterOuiNon(conservation.getCollectionCommune()));
325
		chaineAAnalyser = conservation.getCollectionAutre();
313
		chaineAAnalyser = conservation.getCollectionAutre();
326
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
314
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
327
		conservationParams.set("collection_autre", formaterParenthese(chaineAAfficher));
315
		conservationParams.set("collection_autre", formaterParenthese(chaineAAfficher));
328
		
316
		
329
		conservationParams.set("acces_controle", formaterOuiNon(conservation.getAccesControle()));
317
		conservationParams.set("acces_controle", formaterOuiNon(conservation.getAccesControle()));
330
		
318
		
331
		conservationParams.set("restauration", formaterOuiNon(conservation.getRestauration()));
319
		conservationParams.set("restauration", formaterOuiNon(conservation.getRestauration()));
332
		chaineAAnalyser = conservation.getRestaurationOperation();
320
		chaineAAnalyser = conservation.getRestaurationOperation();
333
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
321
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
334
		conservationParams.set("restauration_operation", formaterParenthese(chaineAAfficher));
322
		conservationParams.set("restauration_operation", formaterParenthese(chaineAAfficher));
335
		
323
		
336
		chaineAAnalyser = conservation.getMaterielConservation();
324
		chaineAAnalyser = conservation.getMaterielConservation();
337
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
325
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
338
		conservationParams.set("materiel_conservation", chaineAAfficher);
326
		conservationParams.set("materiel_conservation", chaineAAfficher);
339
		chaineAAnalyser = conservation.getMaterielAutre();
327
		chaineAAnalyser = conservation.getMaterielAutre();
340
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
328
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
341
		conservationParams.set("materiel_autre", formaterParenthese(chaineAAfficher));
329
		conservationParams.set("materiel_autre", formaterParenthese(chaineAAfficher));
342
		
330
		
343
		conservationParams.set("traitement", formaterOuiNon(conservation.getTraitement()));
331
		conservationParams.set("traitement", formaterOuiNon(conservation.getTraitement()));
344
		chaineAAnalyser = conservation.getTraitements();
332
		chaineAAnalyser = conservation.getTraitements();
345
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
333
		chaineAAfficher = construireTxtListeOntologie(chaineAAnalyser);
346
		conservationParams.set("traitements", formaterParenthese(chaineAAfficher));
334
		conservationParams.set("traitements", formaterParenthese(chaineAAfficher));
347
		
335
		
348
		conservationParams.set("acquisition_collection", formaterOuiNon(conservation.getAcquisitionCollection()));
336
		conservationParams.set("acquisition_collection", formaterOuiNon(conservation.getAcquisitionCollection()));
349
		conservationParams.set("acquisition_echantillon", formaterOuiNon(conservation.getAcquisitionEchantillon()));
337
		conservationParams.set("acquisition_echantillon", formaterOuiNon(conservation.getAcquisitionEchantillon()));
350
		conservationParams.set("acquisition_traitement_info", construireTraitement());
338
		conservationParams.set("acquisition_traitement_info", construireTraitement());
351
		
339
		
352
		afficherOnglet(conservationTpl, conservationParams, conservationOnglet);
340
		afficherOnglet(conservationTpl, conservationParams, conservationOnglet);
353
	}
341
	}
354
	
342
	
355
	private String construireTraitement() {
343
	private String construireTraitement() {
356
		String cHtml = "";
344
		String cHtml = "";
357
		String echantillon = conservation.getAcquisitionEchantillon();
345
		String echantillon = conservation.getAcquisitionEchantillon();
358
		
346
		
359
		if (echantillon.equals("1")) {
347
		if (echantillon.equals("1")) {
360
			Params traitementConservationParams  = new Params();
348
			Params traitementConservationParams  = new Params();
361
			traitementConservationParams.set("i18n_acquisition_traitement", i18nC.acquisitionTraitement());
349
			traitementConservationParams.set("i18n_acquisition_traitement", i18nC.acquisitionTraitement());
362
			
350
			
363
			traitementConservationParams.set("acquisition_traitement", formaterOuiNon(conservation.getAcquisitionTraitement()));
351
			traitementConservationParams.set("acquisition_traitement", formaterOuiNon(conservation.getAcquisitionTraitement()));
364
			
352
			
365
			traitementConservationParams.set("acquisition_traitement_type_info", construireTraitementType());
353
			traitementConservationParams.set("acquisition_traitement_type_info", construireTraitementType());
366
			
354
			
367
			cHtml = Format.substitute(traitementConservationTpl, traitementConservationParams);
355
			cHtml = Format.substitute(traitementConservationTpl, traitementConservationParams);
368
		}
356
		}
369
		
357
		
370
		return cHtml;
358
		return cHtml;
371
	}
359
	}
372
	
360
	
373
	private String construireTraitementType() {
361
	private String construireTraitementType() {
374
		String cHtml = "";
362
		String cHtml = "";
375
		String traitement = conservation.getAcquisitionTraitement();
363
		String traitement = conservation.getAcquisitionTraitement();
376
		
364
		
377
		if (traitement.equals("1")) {
365
		if (traitement.equals("1")) {
378
			Params typeTraitementParams  = new Params();
366
			Params typeTraitementParams  = new Params();
379
			typeTraitementParams.set("i18n_acquisition_traitement_insecte", i18nC.acquisitionTraitementInsecte());
367
			typeTraitementParams.set("i18n_acquisition_traitement_insecte", i18nC.acquisitionTraitementInsecte());
380
			typeTraitementParams.set("i18n_acquisition_traitement_poison", i18nC.acquisitionTraitementPoison());
368
			typeTraitementParams.set("i18n_acquisition_traitement_poison", i18nC.acquisitionTraitementPoison());
381
			
369
			
382
			String acquisitionTraitementInsecte = construireTxtListeOntologie(conservation.getAcquisitionTraitementInsecte());
370
			String acquisitionTraitementInsecte = construireTxtListeOntologie(conservation.getAcquisitionTraitementInsecte());
383
			typeTraitementParams.set("acquisition_traitement_insecte", acquisitionTraitementInsecte);
371
			typeTraitementParams.set("acquisition_traitement_insecte", acquisitionTraitementInsecte);
384
			String acquisitionTraitementPoison = construireTxtListeOntologie(conservation.getAcquisitionTraitementPoison());
372
			String acquisitionTraitementPoison = construireTxtListeOntologie(conservation.getAcquisitionTraitementPoison());
385
			typeTraitementParams.set("acquisition_traitement_poison", acquisitionTraitementPoison);
373
			typeTraitementParams.set("acquisition_traitement_poison", acquisitionTraitementPoison);
386
			
374
			
387
			cHtml = Format.substitute(typeTraitementConservationTpl, typeTraitementParams);
375
			cHtml = Format.substitute(typeTraitementConservationTpl, typeTraitementParams);
388
		}
376
		}
389
		
377
		
390
		return cHtml;
378
		return cHtml;
391
	}
379
	}
392
	
380
	
393
	private void afficherValorisation() {
381
	private void afficherValorisation() {
394
		Params valorisationParams  = new Params();
382
		Params valorisationParams  = new Params();
395
		valorisationParams.set("i18n_titre_action_valorisation", i18nC.titreActionValorisation());
383
		valorisationParams.set("i18n_titre_action_valorisation", i18nC.titreActionValorisation());
396
		valorisationParams.set("i18n_action", i18nC.action());
384
		valorisationParams.set("i18n_action", i18nC.action());
397
		valorisationParams.set("i18n_action_publication", i18nC.actionPublication());
385
		valorisationParams.set("i18n_action_publication", i18nC.actionPublication());
398
		valorisationParams.set("i18n_collection_autre", i18nC.collectionAutre());
386
		valorisationParams.set("i18n_collection_autre", i18nC.collectionAutre());
399
		valorisationParams.set("i18n_action_future", i18nC.actionFuture());	
387
		valorisationParams.set("i18n_action_future", i18nC.actionFuture());	
400
		
388
		
401
		valorisationParams.set("action", formaterOuiNon(valorisation.getAction()));
389
		valorisationParams.set("action", formaterOuiNon(valorisation.getAction()));
402
		String actionInfo = construireTxtListeOntologie(valorisation.getActionInfo());
390
		String actionInfo = construireTxtListeOntologie(valorisation.getActionInfo());
403
		valorisationParams.set("action_info", formaterParenthese(actionInfo));
391
		valorisationParams.set("action_info", formaterParenthese(actionInfo));
404
		valorisationParams.set("action_publication", valorisation.getPublication());
392
		valorisationParams.set("action_publication", valorisation.getPublication());
405
		String collectionAutre = construireTxtListeOntologie(valorisation.getCollectionAutre());
393
		String collectionAutre = construireTxtListeOntologie(valorisation.getCollectionAutre());
406
		valorisationParams.set("collection_autre", collectionAutre);
394
		valorisationParams.set("collection_autre", collectionAutre);
407
		valorisationParams.set("action_future", formaterOuiNon(valorisation.getActionFuture()));
395
		valorisationParams.set("action_future", formaterOuiNon(valorisation.getActionFuture()));
408
		valorisationParams.set("action_future_info", formaterParenthese(valorisation.getActionFutureInfo()));
396
		valorisationParams.set("action_future_info", formaterParenthese(valorisation.getActionFutureInfo()));
409
 
397
 
410
		valorisationParams.set("i18n_titre_recherche_scientifique", i18nC.titreRechercherScientifique());
398
		valorisationParams.set("i18n_titre_recherche_scientifique", i18nC.titreRechercherScientifique());
411
		valorisationParams.set("i18n_recherche", i18nC.recherche());
399
		valorisationParams.set("i18n_recherche", i18nC.recherche());
412
		
400
		
413
		valorisationParams.set("recherche", formaterOuiNon(valorisation.getRecherche()));
401
		valorisationParams.set("recherche", formaterOuiNon(valorisation.getRecherche()));
414
		valorisationParams.set("recherche_info", construireRecherche());
402
		valorisationParams.set("recherche_info", construireRecherche());
415
		
403
		
416
		valorisationParams.set("i18n_titre_acces_usage", i18nC.titreAccesUsage());
404
		valorisationParams.set("i18n_titre_acces_usage", i18nC.titreAccesUsage());
417
		valorisationParams.set("i18n_acces", i18nC.acces());
405
		valorisationParams.set("i18n_acces", i18nC.acces());
418
		valorisationParams.set("i18n_visite", i18nC.visite());
406
		valorisationParams.set("i18n_visite", i18nC.visite());
419
		
407
		
420
		valorisationParams.set("acces", formaterOuiNon(valorisation.getAccesSansMotif()));
408
		valorisationParams.set("acces", formaterOuiNon(valorisation.getAccesSansMotif()));
421
		valorisationParams.set("acces_info", formaterParenthese(valorisation.getAccesSansMotifInfo()));
409
		valorisationParams.set("acces_info", formaterParenthese(valorisation.getAccesSansMotifInfo()));
422
		valorisationParams.set("visite", formaterOuiNon(valorisation.getVisiteAvecMotif()));
410
		valorisationParams.set("visite", formaterOuiNon(valorisation.getVisiteAvecMotif()));
423
		valorisationParams.set("visite_info", formaterParenthese(valorisation.getVisiteAvecMotifInfo()));
411
		valorisationParams.set("visite_info", formaterParenthese(valorisation.getVisiteAvecMotifInfo()));
424
		
412
		
425
		afficherOnglet(valorisationTpl, valorisationParams, valorisationOnglet);
413
		afficherOnglet(valorisationTpl, valorisationParams, valorisationOnglet);
426
	}
414
	}
427
	
415
	
428
	private String construireRecherche() {
416
	private String construireRecherche() {
429
		String cHtml = "";
417
		String cHtml = "";
430
		String recherche = valorisation.getRecherche();
418
		String recherche = valorisation.getRecherche();
431
		
419
		
432
		if (recherche.equals("1")) {
420
		if (recherche.equals("1")) {
433
			Params rechercheParams  = new Params();
421
			Params rechercheParams  = new Params();
434
			rechercheParams.set("i18n_recherche_provenance", i18nC.rechercheProvenance());
422
			rechercheParams.set("i18n_recherche_provenance", i18nC.rechercheProvenance());
435
			rechercheParams.set("i18n_recherche_type", i18nC.rechercheType());
423
			rechercheParams.set("i18n_recherche_type", i18nC.rechercheType());
436
			
424
			
437
			String rechercheProvenance = construireTxtListeOntologie(valorisation.getRechercheProvenance());
425
			String rechercheProvenance = construireTxtListeOntologie(valorisation.getRechercheProvenance());
438
			rechercheParams.set("recherche_provenance", rechercheProvenance);
426
			rechercheParams.set("recherche_provenance", rechercheProvenance);
439
			String rechercheType = construireTxtListeOntologie(valorisation.getRechercheType());
427
			String rechercheType = construireTxtListeOntologie(valorisation.getRechercheType());
440
			rechercheParams.set("recherche_type", rechercheType);
428
			rechercheParams.set("recherche_type", rechercheType);
441
			
429
			
442
			cHtml = Format.substitute(rechercheValorisationTpl, rechercheParams);
430
			cHtml = Format.substitute(rechercheValorisationTpl, rechercheParams);
443
		}
431
		}
444
		
432
		
445
		return cHtml;
433
		return cHtml;
446
	}
434
	}
447
	
-
 
448
	private void afficherOnglet(String template, Params parametres, TabItem onglet) {
-
 
449
		String cHtml = Format.substitute(template, parametres);
-
 
450
		
-
 
451
		Params cssParams = new Params();
-
 
452
		cssParams.set("css_corps", ComposantClass.DETAIL_CORPS_CONTENU);
-
 
453
		cssParams.set("css_label", ComposantClass.LABEL);
-
 
454
		cssParams.set("css_indentation", ComposantClass.INDENTATION);
-
 
455
		cssParams.set("css_fieldset", ComposantClass.FIELDSET);
-
 
456
		cssParams.set("css_clear", ComposantClass.CLEAR);
-
 
457
		cHtml = Format.substitute(cHtml, cssParams);
-
 
458
		
-
 
459
		HtmlContainer corpsConteneurDuHtml = new HtmlContainer(cHtml);
-
 
460
		onglet.removeAll();
-
 
461
		onglet.add(corpsConteneurDuHtml);		
-
 
462
	}
-
 
463
	
435
	
464
	private void initialiserTousLesTpl() {
436
	private void initialiserTousLesTpl() {
465
		initialiserEnteteHtmlTpl();
437
		initialiserEnteteHtmlTpl();
466
		initialiserIdentificationTpl();
438
		initialiserIdentificationTpl();
467
		initialiserPersonnelTpl();
439
		initialiserPersonnelTpl();
468
		initialiserTableauPersonnelTpl();
440
		initialiserTableauPersonnelTpl();
469
		initialiserLignePersonnelTpl();
441
		initialiserLignePersonnelTpl();
470
		initialiserConservationTpl();
442
		initialiserConservationTpl();
471
		initialiserTraitementConservationTpl();
443
		initialiserTraitementConservationTpl();
472
		initialiserTypeTraitementConservationTpl();
444
		initialiserTypeTraitementConservationTpl();
473
		initialiserValorisationTpl();
445
		initialiserValorisationTpl();
474
		initialiserRechercheValorisationTpl();
446
		initialiserRechercheValorisationTpl();
475
		initialiserSautLigneTpl();
-
 
476
	}
447
	}
477
	
448
	
478
	private void initialiserEnteteHtmlTpl() {
449
	private void initialiserEnteteHtmlTpl() {
479
		enteteTpl = 	
450
		enteteTpl = 	
480
			"<div id='{css_id}'>"+
451
			"<div id='{css_id}'>"+
481
			"	<h1>{nom}</h1>"+
452
			"	<h1>{nom}</h1>"+
482
			"	<h2>{ville}<span class='{css_meta}'>{projet} - {id} - {guid}</span></h2>" +
453
			"	<h2>{ville}<span class='{css_meta}'>{projet} - {id} - {guid}</span></h2>" +
483
			"	" +
454
			"	" +
484
			"</div>";
455
			"</div>";
485
	}
456
	}
486
	
457
	
487
	private void initialiserIdentificationTpl() {
458
	private void initialiserIdentificationTpl() {
488
		identificationTpl =
459
		identificationTpl =
489
			"<div class='{css_corps}'>"+
460
			"<div class='{css_corps}'>"+
490
			"	<div class='{css_fieldset}'>"+
461
			"	<div class='{css_fieldset}'>"+
491
			"		<h2>{i18n_titre_administratif}</h2>"+
462
			"		<h2>{i18n_titre_administratif}</h2>"+
492
			"		<span class='{css_label}'>{i18n_acronyme} :</span> {acronyme}<br />"+
463
			"		<span class='{css_label}'>{i18n_acronyme} :</span> {acronyme}<br />"+
493
			"		<span class='{css_label}'>{i18n_acces} :</span> {acces}<br />"+
464
			"		<span class='{css_label}'>{i18n_acces} :</span> {acces}<br />"+
494
			"		<span class='{css_label}'>{i18n_statut} :</span> {statut}<br />"+
465
			"		<span class='{css_label}'>{i18n_statut} :</span> {statut}<br />"+
495
			"		<span class='{css_label}'>{i18n_date_fondation} :</span> {date_fondation}<br />"+
466
			"		<span class='{css_label}'>{i18n_date_fondation} :</span> {date_fondation}<br />"+
496
			"		<span class='{css_label}'>{i18n_nbre_personnel} :</span> {nbre_personnel}<br />"+
467
			"		<span class='{css_label}'>{i18n_nbre_personnel} :</span> {nbre_personnel}<br />"+
497
			"	</div>"+
468
			"	</div>"+
498
			"	<div class='{css_fieldset}'>"+
469
			"	<div class='{css_fieldset}'>"+
499
			"		<h2>{i18n_titre_description}</h2>"+
470
			"		<h2>{i18n_titre_description}</h2>"+
500
			"		{description}"+
471
			"		{description}"+
501
			"	</div>"+
472
			"	</div>"+
502
			"	<hr class='{css_clear}'/>"+
473
			"	<hr class='{css_clear}'/>"+
503
			"	<div class='{css_fieldset}'>"+
474
			"	<div class='{css_fieldset}'>"+
504
			"		<h2>{i18n_titre_adresse}</h2>"+
475
			"		<h2>{i18n_titre_adresse}</h2>"+
505
			"		<span class='{css_label}'>{i18n_adresse} :</span> {adresse}<br />" +
476
			"		<span class='{css_label}'>{i18n_adresse} :</span> {adresse}<br />" +
506
			"		<span class='{css_label}'>{i18n_cp} :</span> {cp}<br />" +
477
			"		<span class='{css_label}'>{i18n_cp} :</span> {cp}<br />" +
507
			"		<span class='{css_label}'>{i18n_ville} :</span> {ville}<br />" +
478
			"		<span class='{css_label}'>{i18n_ville} :</span> {ville}<br />" +
508
			"		<span class='{css_label}'>{i18n_region} :</span> {region}<br />" +
479
			"		<span class='{css_label}'>{i18n_region} :</span> {region}<br />" +
509
			"		<span class='{css_label}'>{i18n_pays} :</span> {pays}<br />" +
480
			"		<span class='{css_label}'>{i18n_pays} :</span> {pays}<br />" +
510
			"	</div>"+
481
			"	</div>"+
511
			"	<div class='{css_fieldset}'>"+
482
			"	<div class='{css_fieldset}'>"+
512
			"		<h2>{i18n_titre_communication}</h2>"+
483
			"		<h2>{i18n_titre_communication}</h2>"+
513
			"		<span class='{css_label}'>{i18n_tel} :</span> {tel}<br />"+
484
			"		<span class='{css_label}'>{i18n_tel} :</span> {tel}<br />"+
514
			"		<span class='{css_label}'>{i18n_fax} :</span> {fax}<br />"+
485
			"		<span class='{css_label}'>{i18n_fax} :</span> {fax}<br />"+
515
			"		<span class='{css_label}'>{i18n_courriel} :</span> {courriel}<br />"+
486
			"		<span class='{css_label}'>{i18n_courriel} :</span> {courriel}<br />"+
516
			"		<span class='{css_label}'>{i18n_web} :</span> {web}<br />"+
487
			"		<span class='{css_label}'>{i18n_web} :</span> {web}<br />"+
517
			"	</div>"+
488
			"	</div>"+
518
			"</div>";
489
			"</div>";
519
	}
490
	}
520
	
491
	
521
	private void initialiserPersonnelTpl() {
492
	private void initialiserPersonnelTpl() {
522
		personnelTpl =
493
		personnelTpl =
523
			"<div class='{css_corps}'>"+
494
			"<div class='{css_corps}'>"+
524
			"	<h2>{i18n_titre_personnel}</h2>"+
495
			"	<h2>{i18n_titre_personnel}</h2>"+
525
			"	<p><span class='{css_label}'>{i18n_nbre_personnel_collection} :</span> {nbre_personnel_collection}</p>"+
496
			"	<p><span class='{css_label}'>{i18n_nbre_personnel_collection} :</span> {nbre_personnel_collection}</p>"+
526
			"	{tableau_personnel}"+
497
			"	{tableau_personnel}"+
527
			"</div>";
498
			"</div>";
528
	}
499
	}
529
	
500
	
530
	private void initialiserTableauPersonnelTpl() {
501
	private void initialiserTableauPersonnelTpl() {
531
		tableauPersonnelTpl =
502
		tableauPersonnelTpl =
532
			"<h3>{i18n_titre_membre}</h3>"+
503
			"<h3>{i18n_titre_membre}</h3>"+
533
			"<table>"+
504
			"<table>"+
534
			"	<thead>"+
505
			"	<thead>"+
535
			"		<tr>" +
506
			"		<tr>" +
536
			"			<th>{i18n_fonction}</th>" +
507
			"			<th>{i18n_fonction}</th>" +
537
			"			<th>{i18n_prenom}</th>" +
508
			"			<th>{i18n_prenom}</th>" +
538
			"			<th>{i18n_nom}</th>" +
509
			"			<th>{i18n_nom}</th>" +
539
			"			<th>{i18n_tel}</th>" +
510
			"			<th>{i18n_tel}</th>" +
540
			"			<th>{i18n_fax}</th>" +
511
			"			<th>{i18n_fax}</th>" +
541
			"			<th>{i18n_courriel}</th>" +
512
			"			<th>{i18n_courriel}</th>" +
542
			"			<th>{i18n_statut}</th>" +
513
			"			<th>{i18n_statut}</th>" +
543
			"			<th>{i18n_tps_w}</th>" +
514
			"			<th>{i18n_tps_w}</th>" +
544
			"			<th>{i18n_specialite}</th>" +
515
			"			<th>{i18n_specialite}</th>" +
545
			"			<th>{i18n_contact}</th>" +
516
			"			<th>{i18n_contact}</th>" +
546
			"		</tr>"+
517
			"		</tr>"+
547
			"	</thead>"+
518
			"	</thead>"+
548
			"	<tbody>"+
519
			"	<tbody>"+
549
			"		{lignes}"+
520
			"		{lignes}"+
550
			"	</tbody>"+
521
			"	</tbody>"+
551
			"</table>";
522
			"</table>";
552
	}
523
	}
553
	
524
	
554
	private void initialiserLignePersonnelTpl() {
525
	private void initialiserLignePersonnelTpl() {
555
		lignePersonnelTpl =
526
		lignePersonnelTpl =
556
			"<tr>"+
527
			"<tr>"+
557
			"	<td>{fonction}</td>"+
528
			"	<td>{fonction}</td>"+
558
			"	<td>{prenom}</td>"+
529
			"	<td>{prenom}</td>"+
559
			"	<td>{nom}</td>"+
530
			"	<td>{nom}</td>"+
560
			"	<td>{tel}</td>" +
531
			"	<td>{tel}</td>" +
561
			"	<td>{fax}</td>" +
532
			"	<td>{fax}</td>" +
562
			"	<td>{courriel}</td>" +
533
			"	<td>{courriel}</td>" +
563
			"	<td>{statut}</td>" +
534
			"	<td>{statut}</td>" +
564
			"	<td>{tps_w}</td>" +
535
			"	<td>{tps_w}</td>" +
565
			"	<td>{specialite}</td>" +
536
			"	<td>{specialite}</td>" +
566
			"	<td>{contact}</td>" +
537
			"	<td>{contact}</td>" +
567
			"</tr>";
538
			"</tr>";
568
	}
539
	}
569
	
540
	
570
	private void initialiserConservationTpl() {
541
	private void initialiserConservationTpl() {
571
		conservationTpl =
542
		conservationTpl =
572
			"<div class='{css_corps}'>"+
543
			"<div class='{css_corps}'>"+
573
			"	<div class='{css_fieldset}'>"+
544
			"	<div class='{css_fieldset}'>"+
574
			"		<h2>{i18n_titre_conservation_personnel}</h2>"+
545
			"		<h2>{i18n_titre_conservation_personnel}</h2>"+
575
			"		<span class='{css_label}'>{i18n_formation} :</span> {formation}<br />"+
546
			"		<span class='{css_label}'>{i18n_formation} :</span> {formation}<br />"+
576
			"		{formation_info}<br />"+
547
			"		{formation_info}<br />"+
577
			"		<span class='{css_label}'>{i18n_formation_interet} :</span> {formation_interet}<br />"+
548
			"		<span class='{css_label}'>{i18n_formation_interet} :</span> {formation_interet}<br />"+
578
			"	</div>"+
549
			"	</div>"+
579
			"	<div class='{css_fieldset}'>"+
550
			"	<div class='{css_fieldset}'>"+
580
			"		<h2>{i18n_titre_local}</h2>"+
551
			"		<h2>{i18n_titre_local}</h2>"+
581
			"		<span class='{css_label}'>{i18n_local_specifique} :</span> {local_specifique}<br />"+
552
			"		<span class='{css_label}'>{i18n_local_specifique} :</span> {local_specifique}<br />"+
582
			"		<span class='{css_label}'>{i18n_meuble_specifique} :</span> {meuble_specifique}<br />"+
553
			"		<span class='{css_label}'>{i18n_meuble_specifique} :</span> {meuble_specifique}<br />"+
583
			"		<span class='{css_label}'>{i18n_local_parametre} :</span> {local_parametre}<br />"+
554
			"		<span class='{css_label}'>{i18n_local_parametre} :</span> {local_parametre}<br />"+
584
			"		<span class='{css_label}'>{i18n_conservation_en_commun} :</span> {conservation_en_commun} {collection_autre}<br />"+
555
			"		<span class='{css_label}'>{i18n_conservation_en_commun} :</span> {conservation_en_commun} {collection_autre}<br />"+
585
			"		<span class='{css_label}'>{i18n_acces_controle} :</span> {acces_controle}<br />"+
556
			"		<span class='{css_label}'>{i18n_acces_controle} :</span> {acces_controle}<br />"+
586
			"	</div>"+
557
			"	</div>"+
587
			"	<hr class='{css_clear}'/>"+
558
			"	<hr class='{css_clear}'/>"+
588
			"	<div class='{css_fieldset}'>"+
559
			"	<div class='{css_fieldset}'>"+
589
			"		<h2>{i18n_titre_operation}</h2>"+
560
			"		<h2>{i18n_titre_operation}</h2>"+
590
			"		<span class='{css_label}'>{i18n_restauration} :</span> {restauration} {restauration_operation}<br />"+
561
			"		<span class='{css_label}'>{i18n_restauration} :</span> {restauration} {restauration_operation}<br />"+
591
			"		<span class='{css_label}'>{i18n_materiel_conservation} :</span> {materiel_conservation} {materiel_autre}<br />"+
562
			"		<span class='{css_label}'>{i18n_materiel_conservation} :</span> {materiel_conservation} {materiel_autre}<br />"+
592
			"		<span class='{css_label}'>{i18n_traitement} :</span> {traitement} {traitements}<br />"+
563
			"		<span class='{css_label}'>{i18n_traitement} :</span> {traitement} {traitements}<br />"+
593
			"	</div>"+
564
			"	</div>"+
594
			"	<div class='{css_fieldset}'>"+
565
			"	<div class='{css_fieldset}'>"+
595
			"		<h2>{i18n_titre_acquisition}</h2>"+
566
			"		<h2>{i18n_titre_acquisition}</h2>"+
596
			"		<span class='{css_label}'>{i18n_acquisition_collection} :</span> {acquisition_collection}<br />"+
567
			"		<span class='{css_label}'>{i18n_acquisition_collection} :</span> {acquisition_collection}<br />"+
597
			"		<span class='{css_label}'>{i18n_acquisition_echantillon} :</span> {acquisition_echantillon}<br />"+
568
			"		<span class='{css_label}'>{i18n_acquisition_echantillon} :</span> {acquisition_echantillon}<br />"+
598
			"			{acquisition_traitement_info}" +	
569
			"			{acquisition_traitement_info}" +	
599
			"	</div>"+
570
			"	</div>"+
600
			"</div>";
571
			"</div>";
601
	}
572
	}
602
	
573
	
603
	private void initialiserTraitementConservationTpl() {
574
	private void initialiserTraitementConservationTpl() {
604
		traitementConservationTpl =
575
		traitementConservationTpl =
605
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement} :</span> {acquisition_traitement}<br />"+
576
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement} :</span> {acquisition_traitement}<br />"+
606
			"	<div class='{css_indentation}'>"+
577
			"	<div class='{css_indentation}'>"+
607
			"		{acquisition_traitement_type_info}"+
578
			"		{acquisition_traitement_type_info}"+
608
			"	</div>";
579
			"	</div>";
609
	}
580
	}
610
	
581
	
611
	private void initialiserTypeTraitementConservationTpl() {
582
	private void initialiserTypeTraitementConservationTpl() {
612
		typeTraitementConservationTpl =
583
		typeTraitementConservationTpl =
613
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement_insecte} :</span> {acquisition_traitement_insecte}<br />"+
584
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement_insecte} :</span> {acquisition_traitement_insecte}<br />"+
614
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement_poison} :</span> {acquisition_traitement_poison}<br />";
585
			"<span class='{css_indentation} {css_label}'>{i18n_acquisition_traitement_poison} :</span> {acquisition_traitement_poison}<br />";
615
	}
586
	}
616
	
587
	
617
	private void initialiserValorisationTpl() {
588
	private void initialiserValorisationTpl() {
618
		valorisationTpl =
589
		valorisationTpl =
619
			"<div class='{css_corps}'>"+
590
			"<div class='{css_corps}'>"+
620
			"	<div class='{css_fieldset}'>"+
591
			"	<div class='{css_fieldset}'>"+
621
			"		<h2>{i18n_titre_action_valorisation}</h2>"+
592
			"		<h2>{i18n_titre_action_valorisation}</h2>"+
622
			"		<span class='{css_label}'>{i18n_action} :</span> {action} {action_info}<br />"+
593
			"		<span class='{css_label}'>{i18n_action} :</span> {action} {action_info}<br />"+
623
			"		<span class='{css_label}'>{i18n_action_publication} :</span> {action_publication}<br />"+
594
			"		<span class='{css_label}'>{i18n_action_publication} :</span> {action_publication}<br />"+
624
			"		<span class='{css_label}'>{i18n_collection_autre} :</span> {collection_autre}<br />"+
595
			"		<span class='{css_label}'>{i18n_collection_autre} :</span> {collection_autre}<br />"+
625
			"		<span class='{css_label}'>{i18n_action_future} :</span> {action_future} {action_future_info}<br />"+	
596
			"		<span class='{css_label}'>{i18n_action_future} :</span> {action_future} {action_future_info}<br />"+	
626
			"	</div>"+
597
			"	</div>"+
627
			"	<div class='{css_fieldset}'>"+
598
			"	<div class='{css_fieldset}'>"+
628
			"		<h2>{i18n_titre_recherche_scientifique}</h2>"+
599
			"		<h2>{i18n_titre_recherche_scientifique}</h2>"+
629
			"		<span class='{css_label}'>{i18n_recherche} :</span> {recherche}<br />"+
600
			"		<span class='{css_label}'>{i18n_recherche} :</span> {recherche}<br />"+
630
			"			{recherche_info}"+
601
			"			{recherche_info}"+
631
			"	</div>"+
602
			"	</div>"+
632
			"	<hr class='{css_clear}'/>"+
603
			"	<hr class='{css_clear}'/>"+
633
			"	<div class='{css_fieldset}'>"+
604
			"	<div class='{css_fieldset}'>"+
634
			"		<h2>{i18n_titre_acces_usage}</h2>"+
605
			"		<h2>{i18n_titre_acces_usage}</h2>"+
635
			"		<span class='{css_label}'>{i18n_visite} :</span> {visite} {visite_info}<br />"+
606
			"		<span class='{css_label}'>{i18n_visite} :</span> {visite} {visite_info}<br />"+
636
			"		<span class='{css_label}'>{i18n_acces} :</span> {acces} {acces_info}<br />"+
607
			"		<span class='{css_label}'>{i18n_acces} :</span> {acces} {acces_info}<br />"+
637
			"	</div>"+
608
			"	</div>"+
638
			"</div>";
609
			"</div>";
639
	}
610
	}
640
	
611
	
641
	private void initialiserRechercheValorisationTpl() {
612
	private void initialiserRechercheValorisationTpl() {
642
		rechercheValorisationTpl =
613
		rechercheValorisationTpl =
643
			"<span class='{css_indentation} {css_label}'>{i18n_recherche_provenance} :</span> {recherche_provenance}<br />"+
614
			"<span class='{css_indentation} {css_label}'>{i18n_recherche_provenance} :</span> {recherche_provenance}<br />"+
644
			"<span class='{css_indentation} {css_label}'>{i18n_recherche_type} :</span> {recherche_type}<br />";
615
			"<span class='{css_indentation} {css_label}'>{i18n_recherche_type} :</span> {recherche_type}<br />";
645
	}
616
	}
646
	
-
 
647
	private void initialiserSautLigneTpl() {
-
 
648
		sautLigneTpl = "<br />\n";
-
 
649
	}
-
 
650
		
617
	
651
	public void rafraichir(Object nouvelleDonnees) {
618
	public void rafraichir(Object nouvelleDonnees) {
652
		if (nouvelleDonnees instanceof Structure) {
619
		if (nouvelleDonnees instanceof Structure) {
653
			structure = (Structure) nouvelleDonnees;
620
			structure = (Structure) nouvelleDonnees;
654
			afficherDetailInstitution();
621
			afficherDetailInstitution();
655
		} else if (nouvelleDonnees instanceof ProjetListe) {
622
		} else if (nouvelleDonnees instanceof ProjetListe) {
656
			projets = (ProjetListe) nouvelleDonnees;
623
			projets = (ProjetListe) nouvelleDonnees;
657
		} else if (nouvelleDonnees instanceof ValeurListe) {
624
		} else if (nouvelleDonnees instanceof ValeurListe) {
658
			ValeurListe ontologieReceptionnee = (ValeurListe) nouvelleDonnees;
625
			ValeurListe ontologieReceptionnee = (ValeurListe) nouvelleDonnees;
659
			ajouterListeValeursAOntologie(ontologieReceptionnee);
626
			ajouterListeValeursAOntologie(ontologieReceptionnee);
660
		} else if (nouvelleDonnees instanceof Information) {
627
		} else if (nouvelleDonnees instanceof Information) {
661
			Information info = (Information) nouvelleDonnees;
628
			Information info = (Information) nouvelleDonnees;
662
			if (info.getType().equals("liste_structure_a_personne")) {
629
			if (info.getType().equals("liste_structure_a_personne")) {
663
				allouerPersonnelAStructure((StructureAPersonneListe) info.getDonnee(0));
630
				allouerPersonnelAStructure((StructureAPersonneListe) info.getDonnee(0));
664
				afficherDetailInstitution();
631
				afficherDetailInstitution();
665
			}
632
			}
666
		} else {
633
		} else {
667
			GWT.log("Pas de correspondance dans la méthode rafraichir() de la classe "+this.getClass(), null);
634
			GWT.log("Pas de correspondance dans la méthode rafraichir() de la classe "+this.getClass(), null);
668
		}
635
		}
669
	}
636
	}
670
	
-
 
671
	private void ajouterListeValeursAOntologie(ValeurListe ontologieReceptionnee) {
-
 
672
		Iterator<String> it = ontologieReceptionnee.keySet().iterator();
-
 
673
		while (it.hasNext()) {
-
 
674
			String cle = it.next();
-
 
675
			Valeur valeur = ontologieReceptionnee.get(cle);
-
 
676
			if (valeur != null) {
-
 
677
				ontologie.put(cle, valeur);
-
 
678
			}
-
 
679
		}
-
 
680
	}
-
 
681
 
637
 
682
	protected void allouerPersonnelAStructure(StructureAPersonneListe personnel) {
638
	protected void allouerPersonnelAStructure(StructureAPersonneListe personnel) {
683
		structure.setPersonnel(personnel);
639
		structure.setPersonnel(personnel);
684
	}
640
	}
685
 
641
 
686
	protected String construireTxtProjet(String idProjet) {
642
	protected String construireTxtProjet(String idProjet) {
687
		String chaineARetourner = idProjet;
643
		String chaineARetourner = idProjet;
688
		
644
		
689
		if (projets != null) {
645
		if (projets != null) {
690
			Projet projet = projets.get(idProjet);
646
			Projet projet = projets.get(idProjet);
691
			String nomDuProjet = projet.getNom();
647
			String nomDuProjet = projet.getNom();
692
			if  (!nomDuProjet.equals("")) {
648
			if  (!nomDuProjet.equals("")) {
693
				chaineARetourner = nomDuProjet;
649
				chaineARetourner = nomDuProjet;
694
			}
650
			}
695
		}
651
		}
696
		
652
		
697
		return chaineARetourner;
653
		return chaineARetourner;
698
	}
654
	}
699
	
655
	
700
	protected String construireTxtListeOntologie(String chaineAAnalyser) {
656
	protected String construireTxtListeOntologie(String chaineAAnalyser) {
701
		ArrayList<String> termes = new ArrayList<String>();
657
		ArrayList<String> termes = new ArrayList<String>();
702
		ArrayList<String> autres = new ArrayList<String>();
658
		ArrayList<String> autres = new ArrayList<String>();
703
		if ((chaineAAnalyser != null) && (!chaineAAnalyser.trim().equals("")))	{
659
		if ((chaineAAnalyser != null) && (!chaineAAnalyser.trim().equals("")))	{
704
			String[] valeurs = chaineAAnalyser.split(";;");
660
			String[] valeurs = chaineAAnalyser.split(";;");
705
			int nbreValeurs = valeurs.length;
661
			int nbreValeurs = valeurs.length;
706
			if (nbreValeurs > 0)	{
662
			if (nbreValeurs > 0)	{
707
				for (int i = 0; i < nbreValeurs; i++)	{
663
				for (int i = 0; i < nbreValeurs; i++)	{
708
					String id = valeurs[i];
664
					String id = valeurs[i];
709
					if (id.contains("AUTRE##"))	{
665
					if (id.contains("AUTRE##"))	{
710
						String txt = id.replaceFirst("^AUTRE##", "");
666
						String txt = id.replaceFirst("^AUTRE##", "");
711
						if (!txt.equals("")) {
667
						if (!txt.equals("")) {
712
							autres.add(txt);
668
							autres.add(txt);
713
						}
669
						}
714
					} else if (id.matches("^[0-9]+$"))	{
670
					} else if (id.matches("^[0-9]+$"))	{
715
						if (ontologie != null) {
671
						if (ontologie != null) {
716
							Valeur valeur = ontologie.get(id);
672
							Valeur valeur = ontologie.get(id);
717
							if (valeur != null) {
673
							if (valeur != null) {
718
								String termeOntologie = valeur.getNom();
674
								String termeOntologie = valeur.getNom();
719
								termes.add(termeOntologie);
675
								termes.add(termeOntologie);
720
							}
676
							}
721
						}
677
						}
722
					}
678
					}
723
				}
679
				}
724
			}
680
			}
725
		}
681
		}
726
		
682
		
727
		String chaineTermes = formaterTableauDeTxt(termes);
683
		String chaineTermes = formaterTableauDeTxt(termes);
728
		String chaineAutres = formaterTableauDeTxt(autres);
684
		String chaineAutres = formaterTableauDeTxt(autres);
729
		String chaineARetourner = chaineTermes+formaterAutre(chaineAutres);
685
		String chaineARetourner = chaineTermes+formaterAutre(chaineAutres);
730
		
686
		
731
		return chaineARetourner;
687
		return chaineARetourner;
732
	}
688
	}
733
	
-
 
734
	protected String construireTxtTruck(String chaineAAnalyser) {
-
 
735
		ArrayList<String> termes = new ArrayList<String>();
-
 
736
		
-
 
737
		if ((chaineAAnalyser != null) && (!chaineAAnalyser.trim().equals("")))	{
-
 
738
			String[] valeurs = chaineAAnalyser.split(";;");
-
 
739
			int nbreValeurs = valeurs.length;
-
 
740
			if (nbreValeurs > 0)	{
-
 
741
				for (int i = 0; i < nbreValeurs; i++)	{
-
 
742
					String valeur = valeurs[i];
-
 
743
					String valeurFormatee = formaterValeurTruck(valeur);
-
 
744
					termes.add(valeurFormatee);
-
 
745
				}
-
 
746
			}
-
 
747
		}
-
 
748
		
-
 
749
		String chaineARetourner = formaterTableauDeTxt(termes);
-
 
750
		return chaineARetourner;
-
 
751
	}
-
 
752
	
-
 
753
	private String formaterParenthese(String chaineAAfficher) {
-
 
754
		if (!chaineAAfficher.equals("")) {
-
 
755
			chaineAAfficher = "("+chaineAAfficher+")";
-
 
756
		}
-
 
757
		return chaineAAfficher;
-
 
758
	}
-
 
759
	
-
 
760
	private String formaterAutre(String chaineAAfficher) {
-
 
761
		if (!chaineAAfficher.equals("")) {
-
 
762
			chaineAAfficher = " ["+i18nC.autres()+" : "+chaineAAfficher+"]";
-
 
763
		}
-
 
764
		return chaineAAfficher;
-
 
765
	}
-
 
766
	
-
 
767
	private String formaterTableauDeTxt(ArrayList<String> tableauDeTxt) {
-
 
768
		String chaineAAfficher = "";
-
 
769
		int tailleDuTableau = tableauDeTxt.size();
-
 
770
		if (tailleDuTableau > 0) {
-
 
771
			int indexAvtDernier = tailleDuTableau - 1;
-
 
772
			for (int i = 0; i < tailleDuTableau; i++)	{
-
 
773
				String mot = tableauDeTxt.get(i);
-
 
774
				if (i != indexAvtDernier) {
-
 
775
					chaineAAfficher += mot+", ";
-
 
776
				} else {
-
 
777
					chaineAAfficher += nettoyerPointFinal(mot)+".";
-
 
778
				}
-
 
779
			}
-
 
780
		}
-
 
781
		return chaineAAfficher;
-
 
782
	}
-
 
783
	
-
 
784
	private String formaterOuiNon(String chaineAFormater) {
-
 
785
		String txtARetourner = "";
-
 
786
		if (chaineAFormater.equals("0")) {
-
 
787
			txtARetourner = i18nC.non();
-
 
788
		} else if (chaineAFormater.equals("1")) {
-
 
789
			txtARetourner = i18nC.oui();
-
 
790
		}
-
 
791
		return txtARetourner;
-
 
792
	}
-
 
793
	
-
 
794
	private String formaterSautDeLigne(String chaineAFormater) {
-
 
795
		String txtARetourner = chaineAFormater.replaceAll("\n", sautLigneTpl);
-
 
796
		return txtARetourner;
-
 
797
	}
-
 
798
 
-
 
799
	private String formaterValeurTruck(String valeur) {
-
 
800
		String chaineARetourner = "";
-
 
801
		
-
 
802
		if (valeur.matches("^[^#]+##[^$]+$"))	{
-
 
803
			String[] cleValeur = valeur.split("##");
-
 
804
			chaineARetourner = cleValeur[1]+" "+formaterParenthese(cleValeur[0]);
-
 
805
		} else if (!valeur.equals(""))	{
-
 
806
			chaineARetourner = valeur;
-
 
807
		} else {
-
 
808
			GWT.log("Valeur truck posant problèlme :"+valeur, null);
-
 
809
		}
-
 
810
		
-
 
811
		return chaineARetourner;
-
 
812
	}
-
 
813
 
-
 
814
	private String nettoyerPointFinal(String mot) {
-
 
815
		mot = mot.replaceAll("[.]$", "");
-
 
816
		return mot;
-
 
817
	}
-
 
818
	
-
 
819
}
689
}
820
690