Subversion Repositories eFlore/Applications.coel

Rev

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

Rev 1329 Rev 1367
Line 20... Line 20...
20
import org.tela_botanica.client.modeles.collection.CollectionListe;
20
import org.tela_botanica.client.modeles.collection.CollectionListe;
21
import org.tela_botanica.client.modeles.projet.Projet;
21
import org.tela_botanica.client.modeles.projet.Projet;
22
import org.tela_botanica.client.modeles.projet.ProjetListe;
22
import org.tela_botanica.client.modeles.projet.ProjetListe;
23
import org.tela_botanica.client.modeles.structure.Structure;
23
import org.tela_botanica.client.modeles.structure.Structure;
24
import org.tela_botanica.client.modeles.structure.StructureListe;
24
import org.tela_botanica.client.modeles.structure.StructureListe;
-
 
25
import org.tela_botanica.client.synchronisation.Sequenceur;
25
import org.tela_botanica.client.util.Debug;
26
import org.tela_botanica.client.util.Debug;
26
import org.tela_botanica.client.vues.Formulaire;
27
import org.tela_botanica.client.vues.Formulaire;
27
import org.tela_botanica.client.vues.FormulaireOnglet;
28
import org.tela_botanica.client.vues.FormulaireOnglet;
Line 28... Line 29...
28
 
29
 
Line 79... Line 80...
79
	private TextArea historiqueChp = null;
80
	private TextArea historiqueChp = null;
80
	private ChampMultiValeurs urlsChp = null;
81
	private ChampMultiValeurs urlsChp = null;
Line 81... Line 82...
81
 
82
 
Line -... Line 83...
-
 
83
	private ChampComboBoxListeValeurs butRealisationCombo = null;
-
 
84
	
82
	private ChampComboBoxListeValeurs butRealisationCombo = null;
85
	private Sequenceur sequenceur = new Sequenceur();
83
	
86
	
84
	public CollectionFormGeneral(Formulaire formulaireCourrant) {
87
	public CollectionFormGeneral(Formulaire formulaireCourrant) {
85
		initialiserOnglet(formulaireCourrant);
88
		initialiserOnglet(formulaireCourrant);
Line 121... Line 124...
121
		modelTypeProjets.setTotalName("nbElements");
124
		modelTypeProjets.setTotalName("nbElements");
122
		modelTypeProjets.addField("cpr_nom");
125
		modelTypeProjets.addField("cpr_nom");
123
		modelTypeProjets.addField("cpr_id_projet");
126
		modelTypeProjets.addField("cpr_id_projet");
Line 124... Line 127...
124
		
127
		
125
		String displayNameProjets = "cpr_nom";
128
		String displayNameProjets = "cpr_nom";
Line 126... Line 129...
126
		ProxyProjets<ModelData> proxyProjets = new ProxyProjets<ModelData>();
129
		ProxyProjets<ModelData> proxyProjets = new ProxyProjets<ModelData>(sequenceur);
127
		
130
		
128
		projetsCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyProjets, modelTypeProjets, displayNameProjets);
131
		projetsCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyProjets, modelTypeProjets, displayNameProjets);
129
		projetsCombo.setWidth(250, 600);
132
		projetsCombo.setWidth(250, 600);
Line 160... Line 163...
160
		modelTypeStructures.setTotalName("nbElements");
163
		modelTypeStructures.setTotalName("nbElements");
161
		modelTypeStructures.addField("cs_nom");
164
		modelTypeStructures.addField("cs_nom");
162
		modelTypeStructures.addField("cs_id_structure");
165
		modelTypeStructures.addField("cs_id_structure");
Line 163... Line 166...
163
		
166
		
164
		String displayNameStructures = "cs_nom";
167
		String displayNameStructures = "cs_nom";
Line 165... Line 168...
165
		ProxyStructures<ModelData> proxyStructures = new ProxyStructures<ModelData>();
168
		ProxyStructures<ModelData> proxyStructures = new ProxyStructures<ModelData>(sequenceur);
166
		
169
		
167
		structuresCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyStructures, modelTypeStructures, displayNameStructures);
170
		structuresCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyStructures, modelTypeStructures, displayNameStructures);
168
		structuresCombo.setWidth(250, 600);
171
		structuresCombo.setWidth(250, 600);
Line 197... Line 200...
197
		ModelType modelTypeCollections = new ModelType();
200
		ModelType modelTypeCollections = new ModelType();
198
		modelTypeCollections.setRoot("collections");
201
		modelTypeCollections.setRoot("collections");
199
		modelTypeCollections.setTotalName("nbElements");
202
		modelTypeCollections.setTotalName("nbElements");
200
		modelTypeCollections.addField("cc_nom");
203
		modelTypeCollections.addField("cc_nom");
201
		modelTypeCollections.addField("cc_id_collection");
204
		modelTypeCollections.addField("cc_id_collection");
-
 
205
		modelTypeCollections.addField("cc_ce_mere");
Line 202... Line 206...
202
		
206
		
203
		String displayNameCollections = "cc_nom";
207
		String displayNameCollections = "cc_nom";
Line 204... Line 208...
204
		ProxyCollections<ModelData> proxyCollections = new ProxyCollections<ModelData>();
208
		ProxyCollections<ModelData> proxyCollections = new ProxyCollections<ModelData>(sequenceur);
205
		
209
		
206
		collectionsCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyCollections, modelTypeCollections, displayNameCollections);
210
		collectionsCombo = new ChampComboBoxRechercheTempsReelPaginable(proxyCollections, modelTypeCollections, displayNameCollections);
207
		collectionsCombo.setWidth(250, 600);
211
		collectionsCombo.setWidth(250, 600);
Line 444... Line 448...
444
		}
448
		}
445
		return valeur;
449
		return valeur;
446
	}
450
	}
447
	private void setValeurComboCollections() {
451
	private void setValeurComboCollections() {
448
		if (collectionsCombo.getCombo().getStore() != null && collection != null) {
452
		if (collectionsCombo.getCombo().getStore() != null && collection != null) {
-
 
453
			Debug.log("collection.getCollectionMereId()="+collection.getCollectionMereId());
449
			collectionsCombo.getCombo().setValue(collectionsCombo.getStore().findModel("id_collection", collection.getCollectionMereId()));
454
			collectionsCombo.getCombo().setValue(collectionsCombo.getStore().findModel("cc_ce_mere", collection.getCollectionMereId()));
450
		}
455
		}
451
	}
456
	}
Line 452... Line 457...
452
	
457
	
453
	public void rafraichir(Object nouvellesDonnees) {
458
	public void rafraichir(Object nouvellesDonnees) {