branch develop-4.x updated (10da863 -> e851d74)
This is an automated email from the git hooks/post-receive script. New change to branch develop-4.x in repository observe. See http://git.codelutin.com/observe.git from 10da863 Ajout de la migration pour supprimer le champs datearriveeport (termine #7542) new 2d37aac Cacher la barre d'actions une fois l'action d'ouverture de base lancée (See #7673) new e851d74 Des clics multiples sur "Charger la source de données/Utiliser" provoquent une exception (termine #7673) Merge branch 'feature/7673' into develop-4.x The 2 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit e851d7413b36f0b488366ded3bd4b92e28f7e4ed Merge: 10da863 2d37aac Author: Tony CHEMIT <chemit@codelutin.com> Date: Tue Nov 3 17:52:28 2015 +0100 Des clics multiples sur "Charger la source de données/Utiliser" provoquent une exception (termine #7673) Merge branch 'feature/7673' into develop-4.x commit 2d37aac4c4c970b133ee9c977cbb15a22ea21254 Author: Tony CHEMIT <chemit@codelutin.com> Date: Tue Nov 3 17:52:24 2015 +0100 Cacher la barre d'actions une fois l'action d'ouverture de base lancée (See #7673) Summary of changes: .../java/fr/ird/observe/ui/storage/StorageUI.css | 4 ++++ .../java/fr/ird/observe/ui/storage/StorageUI.jaxx | 2 +- .../ird/observe/ui/storage/StorageUIHandler.java | 2 ++ .../fr/ird/observe/ui/storage/StorageUIModel.java | 24 ++++++++++++++++++++++ 4 files changed, 31 insertions(+), 1 deletion(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@list.forge.codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop-4.x in repository observe. See http://git.codelutin.com/observe.git commit 2d37aac4c4c970b133ee9c977cbb15a22ea21254 Author: Tony CHEMIT <chemit@codelutin.com> Date: Tue Nov 3 17:52:24 2015 +0100 Cacher la barre d'actions une fois l'action d'ouverture de base lancée (See #7673) --- .../java/fr/ird/observe/ui/storage/StorageUI.css | 4 ++++ .../java/fr/ird/observe/ui/storage/StorageUI.jaxx | 2 +- .../ird/observe/ui/storage/StorageUIHandler.java | 2 ++ .../fr/ird/observe/ui/storage/StorageUIModel.java | 24 ++++++++++++++++++++++ 4 files changed, 31 insertions(+), 1 deletion(-) diff --git a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.css b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.css index 1fb9545..173ea78 100644 --- a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.css +++ b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.css @@ -69,3 +69,7 @@ enabled:{getModel().isValidStep()}; visible:{getModel().getNextStep() == null}; } + +#actions { + visible:{!getModel().isAlreadyApplied()}; +} \ No newline at end of file diff --git a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.jaxx b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.jaxx index b46f1d1..404516d 100644 --- a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.jaxx +++ b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUI.jaxx @@ -161,7 +161,7 @@ void $afterCompleteSetup() { onStateChanged='if (getSelectedStep() != null) { getModel().gotoStep(getSelectedStep()); }'/> <!-- les actions --> - <Table weightx='1' fill='both' constraints='BorderLayout.SOUTH'> + <Table id='actions' weightx='1' fill='both' constraints='BorderLayout.SOUTH'> <row> <cell weightx='0.5' fill="both"> <!-- pour annuler --> diff --git a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIHandler.java b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIHandler.java index 360f72f..e74d350 100644 --- a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIHandler.java +++ b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIHandler.java @@ -317,6 +317,8 @@ public class StorageUIHandler { public void launchApply(final StorageUI ui) { + ui.getModel().setAlreadyApplied(true); + Runnable action = WizardUILancher.APPLY_DEF.getContextValue(ui); if (action == null) { diff --git a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIModel.java b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIModel.java index 5b1a8af..74635ff 100644 --- a/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIModel.java +++ b/observe-swing/src/main/java/fr/ird/observe/ui/storage/StorageUIModel.java @@ -113,6 +113,8 @@ public class StorageUIModel extends WizardModel<StorageStep> { public static final String VALID_PROPERTY_NAME = "valid"; + public static final String ALREADY_APPLIED_PROPERTY_NAME = "alreadyApplied"; + private static final char[] EMPTY_PASSWORD = new char[0]; private static final String LOGIN_REFERENTIEL = "referentiel"; @@ -133,6 +135,12 @@ public class StorageUIModel extends WizardModel<StorageStep> { protected boolean doBackup; /** + * Un drapeau pour savoir si on a déjà lancé l'action Appliquer (pour éviter le code ré-entrant). + * @since 4.0.4 + */ + protected boolean alreadyApplied; + + /** * le fichier ou effectuer la sauvegarde de la base locale si le drapeau * doBackup est active. */ @@ -207,6 +215,12 @@ public class StorageUIModel extends WizardModel<StorageStep> { securityModel = new SecurityModel(); } + @Override + public void setStep(StorageStep step) { + setAlreadyApplied(false); + super.setStep(step); + } + /** * La méthode pour initialiser le modèle à partir du context applicatif et * d'un service existant. @@ -946,6 +960,16 @@ public class StorageUIModel extends WizardModel<StorageStep> { firePropertyChange(VALID_PROPERTY_NAME, isValid()); } + public boolean isAlreadyApplied() { + return alreadyApplied; + } + + public void setAlreadyApplied(boolean alreadyApplied) { + boolean oldValue = isAlreadyApplied(); + this.alreadyApplied = alreadyApplied; + firePropertyChange(ALREADY_APPLIED_PROPERTY_NAME, oldValue, alreadyApplied); + } + public boolean isValid() { boolean result = false; if (dbMode != null) { -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@list.forge.codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop-4.x in repository observe. See http://git.codelutin.com/observe.git commit e851d7413b36f0b488366ded3bd4b92e28f7e4ed Merge: 10da863 2d37aac Author: Tony CHEMIT <chemit@codelutin.com> Date: Tue Nov 3 17:52:28 2015 +0100 Des clics multiples sur "Charger la source de données/Utiliser" provoquent une exception (termine #7673) Merge branch 'feature/7673' into develop-4.x .../java/fr/ird/observe/ui/storage/StorageUI.css | 4 ++++ .../java/fr/ird/observe/ui/storage/StorageUI.jaxx | 2 +- .../ird/observe/ui/storage/StorageUIHandler.java | 2 ++ .../fr/ird/observe/ui/storage/StorageUIModel.java | 24 ++++++++++++++++++++++ 4 files changed, 31 insertions(+), 1 deletion(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@list.forge.codelutin.com>.
participants (1)
-
codelutin.com scm