Subversion Repositories eFlore/Applications.coel

Rev

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

Rev 277 Rev 279
Line 457... Line 457...
457
			// VISITE AVEC MOTIF
457
			// VISITE AVEC MOTIF
458
			avecMotifAccesMarkRGrpChp.get((valorisation.getVisiteAvecMotif().equals("1") ? 0 : 1)).setValue(true);
458
			avecMotifAccesMarkRGrpChp.get((valorisation.getVisiteAvecMotif().equals("1") ? 0 : 1)).setValue(true);
459
			// VISITE AVEC MOTIF INFO
459
			// VISITE AVEC MOTIF INFO
460
			avecMotifAccesChp.setValue(valorisation.getVisiteAvecMotifInfo());
460
			avecMotifAccesChp.setValue(valorisation.getVisiteAvecMotifInfo());
Line 461... Line -...
461
			
-
 
462
			valorisationOnglet.layout();
-
 
463
			
461
			
464
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter... 
462
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter... 
465
			valorisationOnglet.setData("acces", true);
463
			valorisationOnglet.setData("acces", true);
466
		}
464
		}
Line 616... Line 614...
616
			// ACQUISITION TRAITEMENT POISON
614
			// ACQUISITION TRAITEMENT POISON
617
			peuplerCasesACocher(conservation.getAcquisitionTraitementPoison(), poisonTraitementTrukCacGrpChp, poisonTraitementAutreChp);
615
			peuplerCasesACocher(conservation.getAcquisitionTraitementPoison(), poisonTraitementTrukCacGrpChp, poisonTraitementAutreChp);
618
			// ACQUISITION TRAITEMENT INSECTE
616
			// ACQUISITION TRAITEMENT INSECTE
619
			peuplerCasesACocher(conservation.getAcquisitionTraitementInsecte(), insecteTraitementTrukCacGrpChp, insecteTraitementAutreChp);
617
			peuplerCasesACocher(conservation.getAcquisitionTraitementInsecte(), insecteTraitementTrukCacGrpChp, insecteTraitementAutreChp);
Line 620... Line -...
620
			
-
 
621
			conservationOnglet.layout();
-
 
622
			
618
			
623
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
619
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
624
			conservationOnglet.setData("acces", true);
620
			conservationOnglet.setData("acces", true);
625
		}
621
		}
Line 685... Line 681...
685
	
681
	
686
	private void peuplerStructureIdentification() {
682
	private void peuplerStructureIdentification() {
687
		if (mode.equals("AJOUT")) {
683
		if (mode.equals("AJOUT")) {
688
			// Indique que l'ongleta pu être modifié pour la méthode collecter...
684
			// Indique que l'ongleta pu être modifié pour la méthode collecter...
-
 
685
			identificationOnglet.setData("acces", true);
-
 
686
			// Indication du projet sélectionné par défaut
-
 
687
			String projetCourantId = ((Mediateur) Registry.get(RegistreId.MEDIATEUR)).getProjetId();
-
 
688
			if (!projetCourantId.equals("0")) {
-
 
689
				projetsCombo.setValue(projetsCombo.getStore().findModel("id_projet", projetCourantId));
689
			identificationOnglet.setData("acces", true);
690
			}
690
		}
691
		}
691
		if (mode.equals("MODIF") && identification != null && identificationOnglet.getData("acces").equals(false)) {
692
		if (mode.equals("MODIF") && identification != null && identificationOnglet.getData("acces").equals(false)) {
692
			idStructureChp.setValue(identification.getId());
693
			idStructureChp.setValue(identification.getId());
693
			nomStructureChp.setValue(identification.getNom());
694
			nomStructureChp.setValue(identification.getNom());
Line 733... Line 734...
733
			emailChp.setValue(identification.getCourriel());
734
			emailChp.setValue(identification.getCourriel());
734
			urlChp.setValue(identification.getUrl("WEB"));
735
			urlChp.setValue(identification.getUrl("WEB"));
Line 735... Line 736...
735
			
736
			
Line 736... Line -...
736
			nbreTotalPersonneStructureChp.setValue(identification.getNbrePersonne());
-
 
737
			
-
 
738
			identificationOnglet.layout();
737
			nbreTotalPersonneStructureChp.setValue(identification.getNbrePersonne());
739
			
738
			
740
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
739
			// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
741
			identificationOnglet.setData("acces", true);
740
			identificationOnglet.setData("acces", true);
Line 825... Line 824...
825
		conservationOnglet.setLayout(creerFormLayout(650, LabelAlign.TOP, null));
824
		conservationOnglet.setLayout(creerFormLayout(650, LabelAlign.TOP, null));
826
		conservationOnglet.setData("acces", false);
825
		conservationOnglet.setData("acces", false);
827
		conservationOnglet.addListener(Events.Select, new Listener<ComponentEvent>() {  
826
		conservationOnglet.addListener(Events.Select, new Listener<ComponentEvent>() {  
828
			public void handleEvent(ComponentEvent be) {
827
			public void handleEvent(ComponentEvent be) {
829
				peuplerStructureConservation();
828
				peuplerStructureConservation();
-
 
829
				conservationOnglet.layout();
830
			}  
830
			}  
831
		});  
831
		});  
Line 832... Line 832...
832
		
832
		
833
		formationMarkRGrpChp = creerChoixUniqueRadioGroupe("formation_mark", "ouiNon");
833
		formationMarkRGrpChp = creerChoixUniqueRadioGroupe("formation_mark", "ouiNon");
Line 1060... Line 1060...
1060
				personnes.add(personnel.get(index));
1060
				personnes.add(personnel.get(index));
1061
			}
1061
			}
1062
			personnelGrilleMagazin.removeAll();
1062
			personnelGrilleMagazin.removeAll();
1063
			personnelGrilleMagazin.add(personnes);
1063
			personnelGrilleMagazin.add(personnes);
Line 1064... Line -...
1064
			
-
 
1065
			personnelOnglet.layout();
1064
			
1066
			// Nous vidons la variable personnel une fois qu'elle a remplie la grille
1065
			// Nous vidons la variable personnel une fois qu'elle a remplie la grille
1067
			personnel = null;
1066
			personnel = null;
1068
		}
1067
		}
Line 1079... Line 1078...
1079
				// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
1078
				// Indique que l'onglet a été rempli et a pu être modifié pour la méthode collecter...
1080
				personnelOnglet.setData("acces", true);
1079
				personnelOnglet.setData("acces", true);
Line 1081... Line 1080...
1081
				
1080
				
1082
				// Peuplement du formulaire
1081
				// Peuplement du formulaire
-
 
1082
				peuplerStructurePersonnel();
-
 
1083
				
1083
				peuplerStructurePersonnel();
1084
				personnelOnglet.layout();
Line 1084... Line 1085...
1084
			}
1085
			}
Line 1085... Line 1086...
1085
 
1086
 
Line 1419... Line 1420...
1419
		identificationOnglet.setLayout(new FormLayout());
1420
		identificationOnglet.setLayout(new FormLayout());
1420
		identificationOnglet.setData("acces", false);
1421
		identificationOnglet.setData("acces", false);
1421
		identificationOnglet.addListener(Events.Select, new Listener<ComponentEvent>() {  
1422
		identificationOnglet.addListener(Events.Select, new Listener<ComponentEvent>() {  
1422
			public void handleEvent(ComponentEvent be) {  
1423
			public void handleEvent(ComponentEvent be) {  
1423
				peuplerStructureIdentification();
1424
				peuplerStructureIdentification();
-
 
1425
				identificationOnglet.layout();
1424
			}  
1426
			}  
1425
		});
1427
		});
Line 1426... Line 1428...
1426
		
1428
		
1427
		//+-----------------------------------------------------------------------------------------------------------+
1429
		//+-----------------------------------------------------------------------------------------------------------+
Line 1442... Line 1444...
1442
		nomStructureChp.getMessages().setBlankText("Ce champ est obligatoire.");
1444
		nomStructureChp.getMessages().setBlankText("Ce champ est obligatoire.");
1443
		fieldSetIdentite.add(nomStructureChp, new FormData(450, 0));
1445
		fieldSetIdentite.add(nomStructureChp, new FormData(450, 0));
Line 1444... Line 1446...
1444
		
1446
		
1445
		modele.selectionnerProjets(this);
1447
		modele.selectionnerProjets(this);
1446
		projetsMagazin = new ListStore<Projet>();
-
 
1447
		projetsMagazin.add(new ArrayList<Projet>());
1448
		projetsMagazin = new ListStore<Projet>();
1448
		projetsCombo = new ComboBox<Projet>();
1449
		projetsCombo = new ComboBox<Projet>();
1449
		projetsCombo.setTabIndex(tabIndex++);
1450
		projetsCombo.setTabIndex(tabIndex++);
1450
		projetsCombo.setFieldLabel("Projet");
1451
		projetsCombo.setFieldLabel("Projet");
1451
		projetsCombo.setLabelSeparator("");
1452
		projetsCombo.setLabelSeparator("");
Line 1555... Line 1556...
1555
        });
1556
        });
1556
		gaucheTs.add(comboTypeStructure);
1557
		gaucheTs.add(comboTypeStructure);
Line 1557... Line 1558...
1557
		
1558
		
1558
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("stpu"));
1559
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("stpu"));
1559
		magazinLstpu = new ListStore<Valeur>();
-
 
1560
		magazinLstpu.add(new ArrayList<Valeur>());
1560
		magazinLstpu = new ListStore<Valeur>();
1561
		comboLstpu = new ComboBox<Valeur>();
1561
		comboLstpu = new ComboBox<Valeur>();
1562
		comboLstpu.setTabIndex(tabIndex++);
1562
		comboLstpu.setTabIndex(tabIndex++);
1563
		//comboLstpu.setFieldLabel("Statut des structures publiques");
1563
		//comboLstpu.setFieldLabel("Statut des structures publiques");
1564
		comboLstpu.setLabelSeparator("");
1564
		comboLstpu.setLabelSeparator("");
Line 1569... Line 1569...
1569
		comboLstpu.hide();
1569
		comboLstpu.hide();
1570
		droiteTs.add(comboLstpu);
1570
		droiteTs.add(comboLstpu);
Line 1571... Line 1571...
1571
		
1571
		
1572
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("stpr"));
1572
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("stpr"));
1573
		magazinLstpr = new ListStore<Valeur>();
-
 
1574
		magazinLstpr.add(new ArrayList<Valeur>());
1573
		magazinLstpr = new ListStore<Valeur>();
1575
		comboLstpr = new ComboBox<Valeur>();
1574
		comboLstpr = new ComboBox<Valeur>();
1576
		comboLstpr.setTabIndex(tabIndex++);
1575
		comboLstpr.setTabIndex(tabIndex++);
1577
		//comboLstpr.setFieldLabel("Statut des structures privées");
1576
		//comboLstpr.setFieldLabel("Statut des structures privées");
1578
		comboLstpr.setLabelSeparator("");
1577
		comboLstpr.setLabelSeparator("");
Line 1599... Line 1598...
1599
		nbreTotalPersonneStructureChp.setFieldLabel("Nombre de personne travaillant dans l'institution");
1598
		nbreTotalPersonneStructureChp.setFieldLabel("Nombre de personne travaillant dans l'institution");
1600
		nbreTotalPersonneStructureChp.setFormat(NumberFormat.getFormat("#"));
1599
		nbreTotalPersonneStructureChp.setFormat(NumberFormat.getFormat("#"));
1601
		nbreTotalPersonneStructureChp.setToolTip("Ce champ doit contenir un nombre");
1600
		nbreTotalPersonneStructureChp.setToolTip("Ce champ doit contenir un nombre");
1602
		fieldSetIdentite.add(nbreTotalPersonneStructureChp);
1601
		fieldSetIdentite.add(nbreTotalPersonneStructureChp);
Line 1603... Line -...
1603
 
-
 
1604
		
1602
 
1605
		identificationOnglet.add(fieldSetIdentite);
1603
		identificationOnglet.add(fieldSetIdentite);
1606
 
1604
		
1607
		//+-----------------------------------------------------------------------------------------------------------+		
1605
		//+-----------------------------------------------------------------------------------------------------------+		
1608
		// Fieldset ADRESSE
1606
		// Fieldset ADRESSE
1609
		LayoutContainer principalFdAdresse = new LayoutContainer();  
1607
		LayoutContainer principalFdAdresse = new LayoutContainer();  
Line 1644... Line 1642...
1644
		//paysChp = new TextField<String>();
1642
		//paysChp = new TextField<String>();
1645
		//paysChp.setTabIndex(112);
1643
		//paysChp.setTabIndex(112);
1646
		//paysChp.setFieldLabel("Pays");
1644
		//paysChp.setFieldLabel("Pays");
1647
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("pays"));
1645
		modele.obtenirListeValeurs(this, ((Configuration) Registry.get(RegistreId.CONFIG)).getListeId("pays"));
1648
		magazinPays = new ListStore<Valeur>();
1646
		magazinPays = new ListStore<Valeur>();
1649
		magazinPays.add(new ArrayList<Valeur>());
-
 
1650
		comboPays = new ComboBox<Valeur>();
1647
		comboPays = new ComboBox<Valeur>();
1651
		comboPays.setTabIndex(tabIndex++);
1648
		comboPays.setTabIndex(tabIndex++);
1652
		comboPays.setFieldLabel("Pays");
1649
		comboPays.setFieldLabel("Pays");
1653
		comboPays.setEmptyText("Sélectioner un pays...");
1650
		comboPays.setEmptyText("Sélectioner un pays...");
1654
		comboPays.setEditable(true);
1651
		comboPays.setEditable(true);
Line 1661... Line 1658...
1661
		droiteFdAdresse.add(comboPays);
1658
		droiteFdAdresse.add(comboPays);
Line 1662... Line 1659...
1662
		
1659
		
1663
		principalFdAdresse.add(gaucheFdAdresse, new ColumnData(.5));
1660
		principalFdAdresse.add(gaucheFdAdresse, new ColumnData(.5));
1664
		principalFdAdresse.add(droiteFdAdresse, new ColumnData(.5));
1661
		principalFdAdresse.add(droiteFdAdresse, new ColumnData(.5));
-
 
1662
		fieldSetAdresse.add(principalFdAdresse);
1665
		fieldSetAdresse.add(principalFdAdresse);
1663
		
1666
		identificationOnglet.add(fieldSetAdresse);
1664
		identificationOnglet.add(fieldSetAdresse);
1667
 
1665
		
1668
		//+-----------------------------------------------------------------------------------------------------------+
1666
		//+-----------------------------------------------------------------------------------------------------------+
1669
		// Fieldset TÉLÉPHONE et EMAIL
1667
		// Fieldset TÉLÉPHONE et EMAIL
1670
		LayoutContainer principalFdTelMail = new LayoutContainer();  
1668
		LayoutContainer principalFdTelMail = new LayoutContainer();  
Line 1704... Line 1702...
1704
		droiteFdTelMail.add(urlChp);
1702
		droiteFdTelMail.add(urlChp);
Line 1705... Line 1703...
1705
		
1703
		
1706
		principalFdTelMail.add(gaucheFdTelMail, new ColumnData(.5));
1704
		principalFdTelMail.add(gaucheFdTelMail, new ColumnData(.5));
1707
		principalFdTelMail.add(droiteFdTelMail, new ColumnData(.5));
1705
		principalFdTelMail.add(droiteFdTelMail, new ColumnData(.5));
-
 
1706
		fieldSetTelMail.add(principalFdTelMail);
1708
		fieldSetTelMail.add(principalFdTelMail);
1707
		
Line 1709... Line 1708...
1709
		identificationOnglet.add(fieldSetTelMail);
1708
		identificationOnglet.add(fieldSetTelMail);
1710
		
1709