Subversion Repositories eFlore/Applications.coel

Compare Revisions

Ignore whitespace Rev 1427 → Rev 1428

/trunk/src/org/tela_botanica/client/vues/collection/CollectionFormGeneral.java
24,6 → 24,7
import org.tela_botanica.client.modeles.structure.StructureListe;
import org.tela_botanica.client.synchronisation.Sequenceur;
import org.tela_botanica.client.util.Debug;
import org.tela_botanica.client.util.UtilString;
import org.tela_botanica.client.vues.Formulaire;
import org.tela_botanica.client.vues.FormulaireOnglet;
 
109,6 → 110,7
}
private void creerFieldsetLiaison() {
FieldSet liaisonFieldSet = new FieldSet();
liaisonFieldSet.setHeading(i18nC.liaisonTitreCollection());
liaisonFieldSet.setCollapsible(true);
209,7 → 211,7
collectionsCombo.setWidth(250, 600);
collectionsCombo.getCombo().setTabIndex(tabIndex++);
collectionsCombo.getCombo().setFieldLabel(i18nC.lienMereCollection());
collectionsCombo.getCombo().setForceSelection(true);
collectionsCombo.getCombo().setForceSelection(true);
collectionsCombo.getCombo().setValidator(new Validator() {
public String validate(Field<?> field, String value) {
431,8 → 433,16
return valeur;
}
private void setValeurComboStructures() {
if (structuresCombo.getStore() != null && collection != null) {
/*if (structuresCombo.getStore() != null && collection != null) {
structuresCombo.getCombo().setValue(structuresCombo.getStore().findModel("cs_id_structure", collection.getIdStructure()));
}*/
if (structuresCombo.getCombo().getStore() != null
&& collection != null
&& collection.getStructureNom() != null
&& !UtilString.isEmpty(collection.getStructureNom())) {
structuresCombo.chargerValeurInitiale(collection.getStructureNom(), "cs_nom");
} else {
structuresCombo.getCombo().setValue(null);
}
}
444,9 → 454,13
}
return valeur;
}
private void setValeurComboCollections() {
if (collectionsCombo.getCombo().getStore() != null && collection != null) {
collectionsCombo.getCombo().setValue(collectionsCombo.getStore().findModel("cc_ce_mere", collection.getCollectionMereId()));
private void setValeurComboCollections() {
if (collectionsCombo.getCombo().getStore() != null
&& collection != null
&& collection.getCollectionMereNom() != null
&& !UtilString.isEmpty(collection.getCollectionMereNom())) {
collectionsCombo.chargerValeurInitiale(collection.getCollectionMereNom(), "cc_nom");
}
}