[tutti] branch develop updated (af10d2f -> 0fc43c7)
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 af10d2f Merge branch 'feature/updatesLibs' into develop new cb004aa updates libs (nuiton-converter) new f4198e8 fixes #5656: Les engins d'une campagne ne sont plus remontés new bbb6d03 fixes #5175: [EXPORT GENERIQUE] la numérotation des lots Hors vrac dans Num_Ordre_V_HV_H2 à partir de 1001 n'est pas active new 0fc43c7 Merge branch 'feature/5175' into develop The 4 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 0fc43c7d54add1d8934a2d287f1ecb77fa9f1e36 Merge: af10d2f bbb6d03 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:48:14 2014 +0200 Merge branch 'feature/5175' into develop commit bbb6d034e3b104e4eb4acb9297cee3fec93523bb Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:42:50 2014 +0200 fixes #5175: [EXPORT GENERIQUE] la numérotation des lots Hors vrac dans Num_Ordre_V_HV_H2 à partir de 1001 n'est pas active commit f4198e89d2a276c6d85b3b1afd2486251dd769f4 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:42:24 2014 +0200 fixes #5656: Les engins d'une campagne ne sont plus remontés commit cb004aaef6d2e8a5f052cb394041706d7981553b Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:41:48 2014 +0200 updates libs (nuiton-converter) Summary of changes: pom.xml | 6 +++ tutti-persistence/pom.xml | 4 ++ .../data/SampleCategoryModelConverter.java | 7 ++- .../service/CruisePersistenceServiceImpl.java | 42 ++++++++--------- .../tutti/persistence/test/DatabaseResource.java | 3 +- ...verter => org.nuiton.converter.NuitonConverter} | 0 tutti-service/pom.xml | 4 ++ .../service/export/generic/CatchExportModel.java | 55 +++++++++++++++------- tutti-ui-swing/pom.xml | 4 ++ 9 files changed, 79 insertions(+), 46 deletions(-) rename tutti-persistence/src/main/resources/META-INF/services/{org.apache.commons.beanutils.Converter => org.nuiton.converter.NuitonConverter} (100%) -- 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 f4198e89d2a276c6d85b3b1afd2486251dd769f4 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:42:24 2014 +0200 fixes #5656: Les engins d'une campagne ne sont plus remontés --- .../service/CruisePersistenceServiceImpl.java | 42 +++++++++++----------- 1 file changed, 20 insertions(+), 22 deletions(-) diff --git a/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/CruisePersistenceServiceImpl.java b/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/CruisePersistenceServiceImpl.java index e358298..389e1bc 100644 --- a/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/CruisePersistenceServiceImpl.java +++ b/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/CruisePersistenceServiceImpl.java @@ -239,30 +239,28 @@ public class CruisePersistenceServiceImpl extends AbstractPersistenceService imp // surverPart result.setSurveyPart((String) source[index]); - // get secondary gears from fishingOperation (first load from Allegro DB only) - if (result.getGear() == null) { - Iterator<Object[]> list = queryList( - "allCruiseGears", - "cruiseId", IntegerType.INSTANCE, Integer.valueOf(id), - "pmfmIdTrawlNet", IntegerType.INSTANCE, PmfmId2.MULTIRIG_NUMBER.getValue()); + // get cruise gears + Iterator<Object[]> list = queryList( + "allCruiseGears", + "cruiseId", IntegerType.INSTANCE, Integer.valueOf(id), + "pmfmIdTrawlNet", IntegerType.INSTANCE, PmfmId2.MULTIRIG_NUMBER.getValue()); - List<GearWithOriginalRankOrder> gears = Lists.newArrayList(); - int maxMultirigNumberFound = 0; - while (list.hasNext()) { - Object[] gearRow = list.next(); - Gear simpleGear = referentialService.getGear((Integer) gearRow[0]); - GearWithOriginalRankOrder target = GearWithOriginalRankOrders.newGearWithOriginalRankOrder(simpleGear); - target.setRankOrder((Short) gearRow[1]); - Float multirigNumber = (Float) gearRow[2]; - if (multirigNumber != null && multirigNumber.intValue() > maxMultirigNumberFound) { - maxMultirigNumberFound = multirigNumber.intValue(); - } - gears.add(target); - } - result.setGear(gears); - if (maxMultirigNumberFound > 0) { - result.setMultirigNumber(maxMultirigNumberFound); + List<GearWithOriginalRankOrder> gears = Lists.newArrayList(); + int maxMultirigNumberFound = 0; + while (list.hasNext()) { + Object[] gearRow = list.next(); + Gear simpleGear = referentialService.getGear((Integer) gearRow[0]); + GearWithOriginalRankOrder target = GearWithOriginalRankOrders.newGearWithOriginalRankOrder(simpleGear); + target.setRankOrder((Short) gearRow[1]); + Float multirigNumber = (Float) gearRow[2]; + if (multirigNumber != null && multirigNumber.intValue() > maxMultirigNumberFound) { + maxMultirigNumberFound = multirigNumber.intValue(); } + gears.add(target); + } + result.setGear(gears); + if (maxMultirigNumberFound > 0) { + result.setMultirigNumber(maxMultirigNumberFound); } Iterator<Object[]> vesselPersonFeaturesList = queryList( -- 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 bbb6d034e3b104e4eb4acb9297cee3fec93523bb Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:42:50 2014 +0200 fixes #5175: [EXPORT GENERIQUE] la numérotation des lots Hors vrac dans Num_Ordre_V_HV_H2 à partir de 1001 n'est pas active --- .../service/export/generic/CatchExportModel.java | 55 +++++++++++++++------- 1 file changed, 37 insertions(+), 18 deletions(-) diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/export/generic/CatchExportModel.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/export/generic/CatchExportModel.java index 46c45ac..7f10062 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/export/generic/CatchExportModel.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/export/generic/CatchExportModel.java @@ -144,7 +144,8 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc row, rows, speciesBatch, - totalBatchWeight); + totalBatchWeight, + vracBatch); } for (BenthosBatch benthosBatch : rootBenthosBatch.getChildren()) { @@ -175,7 +176,8 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc row, rows, benthosBatch, - totalBatchWeight); + totalBatchWeight, + vracBatch); } // compute final raising factor @@ -223,12 +225,25 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc CatchExportRow currentRow, List<CatchExportRow> rows, SpeciesBatch speciesBatch, - float totalBatchWeight) { + float totalBatchWeight, + boolean vracBatch) { currentRow.addComment(speciesBatch.getComment()); Integer number = TuttiEntities.getValueOrComputedValue(speciesBatch.getNumber(), speciesBatch.getComputedNumber()); + + Integer rankOrder = speciesBatch.getRankOrder(); + + if (!vracBatch && currentRow.getSampleCategory().isEmpty()) { + + //FIXME Remove this when improve export for import + // See http://forge.codelutin.com/issues/5175 + // Add 1000 to each hors-vrac batch rankOrder + + rankOrder += 1000; + } + addBatchSampleCategory(currentRow, speciesBatch.getSampleCategoryId(), speciesBatch.getSampleCategoryValue(), @@ -236,7 +251,7 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc speciesBatch.getSampleCategoryComputedWeight(), speciesBatch.getWeight(), number, - speciesBatch.getRankOrder()); + rankOrder); if (speciesBatch.isChildBatchsEmpty()) { @@ -317,8 +332,8 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc childRow, rows, childBatch, - totalBatchWeight - ); + totalBatchWeight, + vracBatch); ExportSampleCategory exportSampleCategory = childRow.getSampleCategory().get(categoryIndex); if (exportSampleCategory != null) { float categoryWeight = TuttiEntities.getValueOrComputedValue( @@ -335,7 +350,8 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc CatchExportRow currentRow, List<CatchExportRow> rows, BenthosBatch benthosBatch, - final float totalBatchWeight) { + float totalBatchWeight, + boolean vracBatch) { currentRow.addComment(benthosBatch.getComment()); @@ -343,6 +359,17 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc benthosBatch.getNumber(), benthosBatch.getComputedNumber()); + Integer rankOrder = benthosBatch.getRankOrder(); + + if (!vracBatch && currentRow.getSampleCategory().isEmpty()) { + + //FIXME Remove this when improve export for import + // See http://forge.codelutin.com/issues/5175 + // Add 1000 to each hors-vrac batch rank-order + + rankOrder += 1000; + } + addBatchSampleCategory(currentRow, benthosBatch.getSampleCategoryId(), benthosBatch.getSampleCategoryValue(), @@ -350,16 +377,7 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc benthosBatch.getSampleCategoryComputedWeight(), benthosBatch.getWeight(), number, - benthosBatch.getRankOrder()); - - if (currentRow.getSampleCategory().size() == 1) { - - //FIXME Remove this when improve export for import - // See https://forge.codelutin.com/issues/4923 - ExportSampleCategory exportSampleCategory = currentRow.getSampleCategory().get(0); - Integer rankOrder = exportSampleCategory.getRankOrder(); - exportSampleCategory.setRankOrder(100 + rankOrder); - } + rankOrder); if (benthosBatch.isChildBatchsEmpty()) { @@ -440,7 +458,8 @@ public class CatchExportModel extends TuttiCsvUtil.AbstractTuttiExportModel<Catc childRow, rows, childBatch, - totalBatchWeight); + totalBatchWeight, + vracBatch); ExportSampleCategory exportSampleCategory = childRow.getSampleCategory().get(categoryIndex); float categoryWeight = TuttiEntities.getValueOrComputedValue( exportSampleCategory.getCategoryWeight(), -- 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 0fc43c7d54add1d8934a2d287f1ecb77fa9f1e36 Merge: af10d2f bbb6d03 Author: Tony CHEMIT <chemit@codelutin.com> Date: Sat Aug 23 15:48:14 2014 +0200 Merge branch 'feature/5175' into develop pom.xml | 6 +++ tutti-persistence/pom.xml | 4 ++ .../data/SampleCategoryModelConverter.java | 7 ++- .../service/CruisePersistenceServiceImpl.java | 42 ++++++++--------- .../tutti/persistence/test/DatabaseResource.java | 3 +- ...verter => org.nuiton.converter.NuitonConverter} | 0 tutti-service/pom.xml | 4 ++ .../service/export/generic/CatchExportModel.java | 55 +++++++++++++++------- tutti-ui-swing/pom.xml | 4 ++ 9 files changed, 79 insertions(+), 46 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
participants (1)
-
codelutin.com scm