Tony CHEMIT pushed to branch develop-7.x at ultreiaio / ird-observe Commits: d986e1a1 by tchemit at 2020-02-19T16:40:58+01:00 [SYNCHRO AVANCEE] Double connexion à la même base - Closes #1441 - - - - - 2 changed files: - client-core/src/main/java/fr/ird/observe/client/ui/admin/config/ConfigModel.java - client-core/src/main/java/fr/ird/observe/client/ui/admin/synchronize/referential/ng/ReferentialSynchroModel.java Changes: ===================================== client-core/src/main/java/fr/ird/observe/client/ui/admin/config/ConfigModel.java ===================================== @@ -333,17 +333,12 @@ public class ConfigModel extends AdminActionModel { if (validate && uiModel.containsOperation(AdminStep.REFERENTIAL_SYNCHRONIZE)) { - // les deux bases (source et referentiel) doivent etre different - validate = validateNotSameDataSources(); - ObserveDataSourceInformation leftDataSourceInformation = getLocalSourceInformation(); if (leftDataSourceInformation == null) { return false; } if (!(leftDataSourceInformation.canReadReferential())) { - if (log.isDebugEnabled()) { - log.debug("can not read and write referential on left data source"); - } + log.info("can not read and write referential on left data source"); return false; } @@ -353,12 +348,16 @@ public class ConfigModel extends AdminActionModel { } if (!(rightDataSourceInformation.canReadReferential())) { - if (log.isDebugEnabled()) { - log.debug("can not read and write referential on right data source"); - } + log.info("can not read and write referential on right data source"); return false; } + // les deux bases (source et referentiel) doivent etre different + validate = validateNotSameDataSources(); + if (!validate) { + log.info("Data sources are equals!"); + return false; + } ReferentialSynchronizeMode synchronizeMode = uiModel.getReferentialSynchroModel().getSynchronizeMode(); if (synchronizeMode == null) { return false; ===================================== client-core/src/main/java/fr/ird/observe/client/ui/admin/synchronize/referential/ng/ReferentialSynchroModel.java ===================================== @@ -366,4 +366,6 @@ public class ReferentialSynchroModel extends AdminActionModel { setShowProperties(true); ((ReferentialSynchroUI)ui.getStepUI(AdminStep.REFERENTIAL_SYNCHRONIZE)).getApplyAction().setEnabled(false); } + + } View it on GitLab: https://gitlab.com/ultreiaio/ird-observe/-/commit/d986e1a1e24001f7e61b1d817c... -- View it on GitLab: https://gitlab.com/ultreiaio/ird-observe/-/commit/d986e1a1e24001f7e61b1d817c... You're receiving this email because of your account on gitlab.com.