branch develop updated (d7d2b33 -> 6af7c27)
This is an automated email from the git hooks/post-receive script. New change to branch develop in repository tutti. See http://git.codelutin.com/tutti.git from d7d2b33 fix doc new e868c4d refs #6930 pas de rendu en html sur les traits (trop couteux) new 0d80815 fixes #6930: [IMPORT GENERIQUE] Mauvais affichage des données existantes Merge branch 'feature/6930' into develop new daee920 refs #6936 Ajout d'une colonne par catégorie pour contenir son éventuel commentaire new 9011822 fixes #6936: [IMPORT GENERIQUE] perte des commentaires à l'import Merge branch 'feature/6936' into develop new 9b794b5 refs #6940 fix NPE when removing validation result new 0fb90db refs #6904 forbids to replay import once it has be done (you need then to revalidate import) new 6af7c27 fixes #6940: [IMPORT GENERIQUE] Interdire un réimport juste après l'import Merge branch 'feature/6940' into develop The 7 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 6af7c27fa829d2dea61167e426958fe31fe701c3 Merge: 9011822 0fb90db Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:35:27 2015 +0200 fixes #6940: [IMPORT GENERIQUE] Interdire un réimport juste après l'import Merge branch 'feature/6940' into develop commit 0fb90db254b4992f12beeaa92651f58f6bfa76ea Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:35:24 2015 +0200 refs #6904 forbids to replay import once it has be done (you need then to revalidate import) commit 9b794b5d01562f03a1d3ffa638b49f0ae1f855c0 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:34:51 2015 +0200 refs #6940 fix NPE when removing validation result commit 90118222469675b8bd40345a2614dafb31f11b01 Merge: 0d80815 daee920 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:07:37 2015 +0200 fixes #6936: [IMPORT GENERIQUE] perte des commentaires à l'import Merge branch 'feature/6936' into develop commit daee9201a582a57224d1f128a27e536c4ed9018a Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:07:28 2015 +0200 refs #6936 Ajout d'une colonne par catégorie pour contenir son éventuel commentaire commit 0d8081507f2f55aa1e30cd28501b4994c86adebd Merge: d7d2b33 e868c4d Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 15:37:02 2015 +0200 fixes #6930: [IMPORT GENERIQUE] Mauvais affichage des données existantes Merge branch 'feature/6930' into develop commit e868c4ddafd60603081360e06b88a53402a0ee08 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 15:36:58 2015 +0200 refs #6930 pas de rendu en html sur les traits (trop couteux) Summary of changes: .../consumer/CsvConsumerForCatch.java | 2 ++ .../service/genericformat/csv/CatchModel.java | 10 ++++---- .../tutti/service/genericformat/csv/CatchRow.java | 22 +--------------- .../genericformat/csv/ExportSampleCategory.java | 14 +++++++++- .../producer/CsvProducerForCatch.java | 8 +++--- .../genericformat/GenericFormatImportUI.css | 7 ++++- .../genericformat/GenericFormatImportUI.jaxx | 30 +++++++++++----------- .../genericformat/GenericFormatImportUIModel.java | 3 +-- .../genericformat/tree/DataSelectTreeModel.java | 10 +++++--- .../tree/ImportDataSelectTreeCellRenderer.java | 2 +- 10 files changed, 54 insertions(+), 54 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit e868c4ddafd60603081360e06b88a53402a0ee08 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 15:36:58 2015 +0200 refs #6930 pas de rendu en html sur les traits (trop couteux) --- .../content/genericformat/tree/ImportDataSelectTreeCellRenderer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/ImportDataSelectTreeCellRenderer.java b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/ImportDataSelectTreeCellRenderer.java index 6565122..4837924 100644 --- a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/ImportDataSelectTreeCellRenderer.java +++ b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/ImportDataSelectTreeCellRenderer.java @@ -103,7 +103,7 @@ public class ImportDataSelectTreeCellRenderer extends DefaultTreeCellRenderer { } if (node.isExist()) { - checkBox.setText(checkBox.getText() + " <i>(*)</i>"); + checkBox.setText(checkBox.getText() + " (*)"); checkBox.setToolTipText(checkBox.getToolTipText() + " (donnée existante - identifiant " + node.getOptionalId() + ")"); } -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit 0d8081507f2f55aa1e30cd28501b4994c86adebd Merge: d7d2b33 e868c4d Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 15:37:02 2015 +0200 fixes #6930: [IMPORT GENERIQUE] Mauvais affichage des données existantes Merge branch 'feature/6930' into develop .../content/genericformat/tree/ImportDataSelectTreeCellRenderer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit daee9201a582a57224d1f128a27e536c4ed9018a Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:07:28 2015 +0200 refs #6936 Ajout d'une colonne par catégorie pour contenir son éventuel commentaire --- .../consumer/CsvConsumerForCatch.java | 2 ++ .../service/genericformat/csv/CatchModel.java | 10 +++++----- .../tutti/service/genericformat/csv/CatchRow.java | 22 +--------------------- .../genericformat/csv/ExportSampleCategory.java | 14 +++++++++++++- .../producer/CsvProducerForCatch.java | 8 ++++---- 5 files changed, 25 insertions(+), 31 deletions(-) diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/consumer/CsvConsumerForCatch.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/consumer/CsvConsumerForCatch.java index bd95840..4e848c7 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/consumer/CsvConsumerForCatch.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/consumer/CsvConsumerForCatch.java @@ -254,6 +254,7 @@ public class CsvConsumerForCatch extends CsvComsumer<CatchRow, CatchModel> { batch.setSampleCategoryValue(sampleCategory.getCategoryValue()); batch.setSampleCategoryWeight(sampleCategory.getCategoryWeight()); batch.setRankOrder(sampleCategory.getRankOrder()); + batch.setComment(sampleCategory.getComment()); result = batch; operationContext.registerBatchObjectId(batch.getIdAsInt(), sampleCategory.getBatchId()); @@ -289,6 +290,7 @@ public class CsvConsumerForCatch extends CsvComsumer<CatchRow, CatchModel> { result.setSampleCategoryId(sampleCategory.getCategoryId()); result.setSampleCategoryValue(sampleCategory.getCategoryValue()); result.setSampleCategoryWeight(sampleCategory.getCategoryWeight()); + result.setComment(sampleCategory.getComment()); operationContext.registerBatchObjectId(batch.getIdAsInt(), sampleCategory.getBatchId()); if (log.isInfoEnabled()) { log.info("Create child batch for batch: " + batch.getSpecies().getName() + " - " + batch.getSampleCategoryId() + " - " + batch.getSampleCategoryValue()); diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchModel.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchModel.java index 02bf75a..f33af11 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchModel.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchModel.java @@ -89,8 +89,7 @@ public class CatchModel extends AbstractTuttiImportExportModel<CatchRow> { newColumnForExport("Code_Taxon", SpeciesBatch.PROPERTY_SPECIES, TuttiCsvUtil.SPECIES_TECHNICAL_FORMATTER); newColumnForExport("Code_Espece_Campagne", SpeciesBatch.PROPERTY_SPECIES, TuttiCsvUtil.SPECIES_SURVEY_CODE_FORMATTER); newColumnForExport("Nom_Scientifique", SpeciesBatch.PROPERTY_SPECIES, TuttiCsvUtil.SPECIES_FORMATTER); - newColumnForExport("Benthos", CatchRow.PROPOERTY_BENTHOS, TuttiCsvUtil.BOOLEAN); - newColumnForExport("Commentaire", SpeciesBatch.PROPERTY_COMMENT, TuttiCsvUtil.COMMENT_LIST_PARSER_FORMATTER); + newColumnForExport("Benthos", CatchRow.PROPERTY_BENTHOS, TuttiCsvUtil.BOOLEAN); for (SampleCategoryModelEntry entry : sampleCategoryModel.getCategory()) { @@ -103,6 +102,7 @@ public class CatchModel extends AbstractTuttiImportExportModel<CatchRow> { newIndexNullableColumnForExport("Ech_" + headerPrefix, collectionName, categoryOrder, ExportSampleCategory.PROPERTY_SAMPLE_WEIGHT, TuttiCsvUtil.FLOAT); newIndexNullableColumnForExport("Type_Volume_Poids_" + headerPrefix, collectionName, categoryOrder, ExportSampleCategory.PROPERTY_WEIGHT_OR_VOL_TYPE); newNullableColumnForExport("Unite_Volume_Poids_" + headerPrefix, CatchRow.BATCH_WEIGHT_UNIT); + newIndexNullableColumnForExport("Commentaire_" + headerPrefix, collectionName, categoryOrder, ExportSampleCategory.PROPERTY_COMMENT); } @@ -118,7 +118,6 @@ public class CatchModel extends AbstractTuttiImportExportModel<CatchRow> { newColumnForExport("Nbr", CatchRow.BATCH_NUMBER, TuttiCsvUtil.INTEGER); newColumnForExport("Nbr_Calcule", CatchRow.BATCH_NUMBER_COMPUTED, TuttiCsvUtil.BOOLEAN); - newColumnForExport("Poids_Reference", CatchRow.REFERENCE_WEIGHT, TuttiCsvUtil.PRIMITIVE_FLOAT); newColumnForExport("Coef_Elev_Espece_Capture", CatchRow.RAISING_FACTOR, TuttiCsvUtil.PRIMITIVE_FLOAT); newColumnForExport("Coef_Final_Elevation", CatchRow.FINAL_RAISING_FACTOR, TuttiCsvUtil.FLOAT); @@ -150,8 +149,7 @@ public class CatchModel extends AbstractTuttiImportExportModel<CatchRow> { newMandatoryColumn("Code_Taxon", SpeciesBatch.PROPERTY_SPECIES, parserFactory.getSpeciesParser()); newIgnoredColumn("Code_Espece_Campagne"); newIgnoredColumn("Nom_Scientifique"); - newMandatoryColumn("Benthos", CatchRow.PROPOERTY_BENTHOS, TuttiCsvUtil.BOOLEAN); - newMandatoryColumn("Commentaire", SpeciesBatch.PROPERTY_COMMENT, TuttiCsvUtil.COMMENT_LIST_PARSER_FORMATTER); + newMandatoryColumn("Benthos", CatchRow.PROPERTY_BENTHOS, TuttiCsvUtil.BOOLEAN); for (SampleCategoryModelEntry entry : sampleCategoryModel.getCategory()) { @@ -165,6 +163,8 @@ public class CatchModel extends AbstractTuttiImportExportModel<CatchRow> { newIgnoredColumn("Type_Volume_Poids_" + headerPrefix); newIgnoredColumn("Unite_Volume_Poids_" + headerPrefix); + newMandatoryColumn("Commentaire_" + headerPrefix, TuttiCsvUtil.STRING, new SampleCategoryValueSetter<String>(entry, ExportSampleCategory.PROPERTY_COMMENT)); + } // mensuration diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchRow.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchRow.java index cf73b2e..b9d54b1 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchRow.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/CatchRow.java @@ -27,7 +27,6 @@ import fr.ifremer.tutti.persistence.entities.data.SampleCategoryModelEntry; import fr.ifremer.tutti.persistence.entities.data.SpeciesAbleBatchFrequency; import fr.ifremer.tutti.persistence.entities.referential.Caracteristic; import fr.ifremer.tutti.persistence.entities.referential.Species; -import org.apache.commons.lang3.StringUtils; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; @@ -47,7 +46,7 @@ public class CatchRow extends RowWithOperationContextSupport { /** Logger. */ private static final Log log = LogFactory.getLog(CatchRow.class); - public static final String PROPOERTY_BENTHOS = "benthos"; + public static final String PROPERTY_BENTHOS = "benthos"; public static final String FREQUENCY_LENGTH_STEP = "frequencyLengthStep"; @@ -105,8 +104,6 @@ public class CatchRow extends RowWithOperationContextSupport { protected Integer frequencyRankOrder; - protected List<String> comment = new ArrayList<>(); - public void setBenthos(boolean benthos) { this.benthos = benthos; } @@ -254,28 +251,11 @@ public class CatchRow extends RowWithOperationContextSupport { result.setReferenceWeight(referenceWeight); result.setBatchNumber(batchNumber); result.setBatchWeightUnit(batchWeightUnit); - result.comment.addAll(comment); result.setFinalRaisingFactor(finalRaisingFactor); return result; } - public void addComment(String comment) { - String safeComment = StringUtils.isEmpty(comment) ? "" : comment; - if (log.isDebugEnabled()) { - log.debug("Add comment: " + safeComment); - } - this.comment.add(safeComment); - } - - public List<String> getComment() { - return comment; - } - - public void setComment(List<String> comment) { - this.comment = comment; - } - public boolean withFrequency() { return frequencyLengthStep != null; } diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/ExportSampleCategory.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/ExportSampleCategory.java index d2040d8..3f3da4f 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/ExportSampleCategory.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/csv/ExportSampleCategory.java @@ -52,7 +52,9 @@ public class ExportSampleCategory<S extends Serializable> extends SampleCategory public static final String PROPERTY_SAMPLE_WEIGHT = "sampleWeight"; - public static final java.lang.String PROPERTY_BATCH_ID = "batchId"; + public static final String PROPERTY_BATCH_ID = "batchId"; + + public static final String PROPERTY_COMMENT = "comment"; private Integer batchId; @@ -64,6 +66,8 @@ public class ExportSampleCategory<S extends Serializable> extends SampleCategory private Float sampleComputedWeight; + private String comment; + public String getWeightOrVolType() { return weightOrVolType; } @@ -104,6 +108,14 @@ public class ExportSampleCategory<S extends Serializable> extends SampleCategory this.sampleComputedWeight = sampleComputedWeight; } + public String getComment() { + return comment; + } + + public void setComment(String comment) { + this.comment = comment; + } + public Caracteristic getCategoryCaracteristic() { return categoryDef.getCaracteristic(); } diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/producer/CsvProducerForCatch.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/producer/CsvProducerForCatch.java index 1091dc2..fb899a3 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/producer/CsvProducerForCatch.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/genericformat/producer/CsvProducerForCatch.java @@ -210,8 +210,6 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { SpeciesBatch speciesBatch, float totalBatchWeight) { - currentRow.addComment(speciesBatch.getComment()); - Integer number = Numbers.getValueOrComputedValue(speciesBatch.getNumber(), speciesBatch.getComputedNumber()); Boolean numberComputed = Numbers.getValueOrComputedValueComputed(speciesBatch.getNumber(), @@ -227,6 +225,7 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { speciesBatch.getSampleCategoryWeight(), speciesBatch.getSampleCategoryComputedWeight(), speciesBatch.getWeight(), + speciesBatch.getComment(), number, numberComputed, rankOrder); @@ -336,8 +335,6 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { BenthosBatch benthosBatch, float totalBatchWeight) { - currentRow.addComment(benthosBatch.getComment()); - Integer number = Numbers.getValueOrComputedValue(benthosBatch.getNumber(), benthosBatch.getComputedNumber()); Boolean numberComputed = Numbers.getValueOrComputedValueComputed(benthosBatch.getNumber(), @@ -353,6 +350,7 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { benthosBatch.getSampleCategoryWeight(), benthosBatch.getSampleCategoryComputedWeight(), benthosBatch.getWeight(), + benthosBatch.getComment(), number, numberComputed, rankOrder); @@ -504,6 +502,7 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { Float sampleCategoryWeight, Float sampleCategoryComputedWeight, Float batchWeight, + String comment, Integer batchNumber, Boolean batchNumberComputed, Integer batchRankOrder) { @@ -517,6 +516,7 @@ public class CsvProducerForCatch extends CsvProducer<CatchRow, CatchModel> { sampleCategory.setCategoryValue(sampleCategoryValue); sampleCategory.setCategoryWeight(sampleCategoryWeight); sampleCategory.setSampleWeight(batchWeight); + sampleCategory.setComment(comment); sampleCategory.setComputedWeight(sampleCategoryComputedWeight); sampleCategory.setWeightOrVolType(CatchModel.WEIGHT_OR_VOL_TYPE); -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit 90118222469675b8bd40345a2614dafb31f11b01 Merge: 0d80815 daee920 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:07:37 2015 +0200 fixes #6936: [IMPORT GENERIQUE] perte des commentaires à l'import Merge branch 'feature/6936' into develop .../consumer/CsvConsumerForCatch.java | 2 ++ .../service/genericformat/csv/CatchModel.java | 10 +++++----- .../tutti/service/genericformat/csv/CatchRow.java | 22 +--------------------- .../genericformat/csv/ExportSampleCategory.java | 14 +++++++++++++- .../producer/CsvProducerForCatch.java | 8 ++++---- 5 files changed, 25 insertions(+), 31 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit 9b794b5d01562f03a1d3ffa638b49f0ae1f855c0 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:34:51 2015 +0200 refs #6940 fix NPE when removing validation result --- .../swing/content/genericformat/tree/DataSelectTreeModel.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/DataSelectTreeModel.java b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/DataSelectTreeModel.java index 330016c..749c012 100644 --- a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/DataSelectTreeModel.java +++ b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/tree/DataSelectTreeModel.java @@ -62,10 +62,12 @@ public class DataSelectTreeModel extends DefaultTreeModel { boolean dataSelected = false; - for (CruiseSelectTreeNode cruiseNode : getRoot()) { - if (cruiseNode.isSelected() || cruiseNode.isPartialSelected()) { - dataSelected = true; - break; + if (getRoot() != null) { + for (CruiseSelectTreeNode cruiseNode : getRoot()) { + if (cruiseNode.isSelected() || cruiseNode.isPartialSelected()) { + dataSelected = true; + break; + } } } return dataSelected; -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit 0fb90db254b4992f12beeaa92651f58f6bfa76ea Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:35:24 2015 +0200 refs #6904 forbids to replay import once it has be done (you need then to revalidate import) --- .../genericformat/GenericFormatImportUI.css | 7 ++++- .../genericformat/GenericFormatImportUI.jaxx | 30 +++++++++++----------- .../genericformat/GenericFormatImportUIModel.java | 3 +-- 3 files changed, 22 insertions(+), 18 deletions(-) diff --git a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.css b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.css index 83d49ba..85dbd86 100644 --- a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.css +++ b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.css @@ -21,6 +21,11 @@ * <http://www.gnu.org/licenses/gpl-3.0.html>. * #L% */ + +.canConfigureImport { + enabled: {model.getImportResult() == null}; +} + FileEditor { showReset:true; directoryEnabled: false; @@ -207,7 +212,7 @@ JTextField { toolTipText: "tutti.genericFormatImport.action.import.tip"; i18nMnemonic: "tutti.genericFormatImport.action.import.mnemonic"; _applicationAction: {fr.ifremer.tutti.ui.swing.content.genericformat.actions.GenericFormatImportAction.class}; - enabled: {model.isCanImport()}; + enabled: {model.isCanImport() && model.getImportResult() == null}; _help: {"tutti.genericFormatImport.action.import.help"}; } diff --git a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.jaxx b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.jaxx index 0836526..b282482 100644 --- a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.jaxx +++ b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUI.jaxx @@ -113,30 +113,30 @@ <!-- Data selection --> <JScrollPane id='dataSelectionPane' constraints='BorderLayout.CENTER'> - <JTree id='dataSelectionTree'/> + <JTree id='dataSelectionTree' styleClass='canConfigureImport'/> </JScrollPane> <!-- Import options --> <JPanel id='importOptions' layout='{new BorderLayout()}' constraints='BorderLayout.EAST'> <JPanel layout='{new GridLayout(0, 1)}' constraints='BorderLayout.NORTH'> - <JCheckBox id='updateCruisesCheckBox' onItemStateChanged='handler.setBoolean(event, "updateCruises")'/> - <JCheckBox id='updateOperationsCheckBox' onItemStateChanged='handler.setBoolean(event, "updateOperations")'/> - <JCheckBox id='importSpeciesCheckBox' onItemStateChanged='handler.setBoolean(event, "importSpecies")'/> - <JCheckBox id='importBenthosCheckBox' onItemStateChanged='handler.setBoolean(event, "importBenthos")'/> - <JCheckBox id='importMarineLitterCheckBox' onItemStateChanged='handler.setBoolean(event, "importMarineLitter")'/> - <JCheckBox id='importAccidentalCatchCheckBox' onItemStateChanged='handler.setBoolean(event, "importAccidentalCatch")'/> - <JCheckBox id='importIndividualObservationCheckBox' onItemStateChanged='handler.setBoolean(event, "importIndividualObservation")'/> - <JCheckBox id='importAttachmentsCheckBox' onItemStateChanged='handler.setBoolean(event, "importAttachments")'/> - <JCheckBox id='cleanWeightsCheckBox' onItemStateChanged='handler.setBoolean(event, "cleanWeights")'/> - <JCheckBox id='checkWeightsCheckBox' onItemStateChanged='handler.setBoolean(event, "checkWeights")'/> + <JCheckBox id='updateCruisesCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "updateCruises")'/> + <JCheckBox id='updateOperationsCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "updateOperations")'/> + <JCheckBox id='importSpeciesCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importSpecies")'/> + <JCheckBox id='importBenthosCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importBenthos")'/> + <JCheckBox id='importMarineLitterCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importMarineLitter")'/> + <JCheckBox id='importAccidentalCatchCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importAccidentalCatch")'/> + <JCheckBox id='importIndividualObservationCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importIndividualObservation")'/> + <JCheckBox id='importAttachmentsCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "importAttachments")'/> + <JCheckBox id='cleanWeightsCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "cleanWeights")'/> + <JCheckBox id='checkWeightsCheckBox' styleClass='canConfigureImport' onItemStateChanged='handler.setBoolean(event, "checkWeights")'/> </JPanel> </JPanel> <JToolBar id='dataSelectionTreeHeader' constraints='BorderLayout.SOUTH'> - <JButton id='unfoldAllButton'/> - <JButton id='foldAllButton'/> - <JButton id='selectAllButton'/> - <JButton id='unselectAllButton'/> + <JButton id='unfoldAllButton' styleClass='canConfigureImport'/> + <JButton id='foldAllButton' styleClass='canConfigureImport'/> + <JButton id='selectAllButton' styleClass='canConfigureImport'/> + <JButton id='unselectAllButton' styleClass='canConfigureImport'/> </JToolBar> </JPanel> diff --git a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUIModel.java b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUIModel.java index 2ccec2c..29475ea 100644 --- a/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUIModel.java +++ b/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/genericformat/GenericFormatImportUIModel.java @@ -370,7 +370,6 @@ public class GenericFormatImportUIModel extends AbstractSerializableBean { return importResult != null; } - public boolean isImportValid() { return importResult != null && importResult.isValid(); } @@ -380,7 +379,7 @@ public class GenericFormatImportUIModel extends AbstractSerializableBean { } public boolean computeIsCanImport() { - return isValidateDone() && isValidateValid() && isDataSelected(); + return isValidateDone() && isValidateValid() && isDataSelected() && importResult == null; } public void setRootNode(ProgramSelectTreeNode rootNode) { -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit 6af7c27fa829d2dea61167e426958fe31fe701c3 Merge: 9011822 0fb90db Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Apr 11 16:35:27 2015 +0200 fixes #6940: [IMPORT GENERIQUE] Interdire un réimport juste après l'import Merge branch 'feature/6940' into develop .../genericformat/GenericFormatImportUI.css | 7 ++++- .../genericformat/GenericFormatImportUI.jaxx | 30 +++++++++++----------- .../genericformat/GenericFormatImportUIModel.java | 3 +-- .../genericformat/tree/DataSelectTreeModel.java | 10 +++++--- 4 files changed, 28 insertions(+), 22 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
participants (1)
-
codelutin.com scm