branch develop updated (67e7379 -> f14ecbf)
This is an automated email from the git hooks/post-receive script. New change to branch develop in repository echobase. See https://gitlab.nuiton.org/codelutin/echobase.git from 67e7379 From scmwebeditor -- fg new 2b9173a #8724 Modify latitude and longitude for hauling new f14ecbf Merge branch 'develop' of gitlab.nuiton.org:codelutin/echobase into develop 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 f14ecbf59900e34eb2f0e5c0ad08280bcb7011ae Merge: 2b9173a 67e7379 Author: Julien Ruchaud <julien.ruchaud@debux.org> Date: Wed Nov 2 17:09:21 2016 +0100 Merge branch 'develop' of gitlab.nuiton.org:codelutin/echobase into develop commit 2b9173a3fa25a57333db0dc001fbe1de2c9115cc Author: Julien Ruchaud <julien.ruchaud@debux.org> Date: Wed Nov 2 17:07:34 2016 +0100 #8724 Modify latitude and longitude for hauling Summary of changes: ...WorkingDbMigrationCallBackForVersion3_912.java} | 6 +++--- ...ge-ports.sql => 3.912-0-atlantos-operation.sql} | 15 +++++++++------ .../3.912-0-atlantos-operation.sql} | 15 +++++++++------ echobase-domain/src/main/xmi/echobase.properties | 2 +- echobase-domain/src/main/xmi/echobase.zargo | Bin 100339 -> 100352 bytes .../service/atlantos/xml/XmlBioticExport.java | 4 ++-- ...VoyageOperationsOperationImportExportModel.java | 8 ++++---- .../csv/VoyageOperationsOperationImportRow.java | 16 ++++++++-------- .../import-data/operation/operation.csv.gz | Bin 6053 -> 6056 bytes src/site/en/rst/importData.rst | 8 ++++---- src/site/rst/importData.rst | 8 ++++---- 11 files changed, 44 insertions(+), 38 deletions(-) copy echobase-domain/src/main/java/fr/ifremer/echobase/persistence/migration/workingDb/{WorkingDbMigrationCallBackForVersion3_911.java => WorkingDbMigrationCallBackForVersion3_912.java} (89%) copy echobase-domain/src/main/resources/migration/workingDb/h2/{3.905-2-migrate-voyage-ports.sql => 3.912-0-atlantos-operation.sql} (62%) copy echobase-domain/src/main/resources/migration/workingDb/{h2/3.905-2-migrate-voyage-ports.sql => pg/3.912-0-atlantos-operation.sql} (63%) -- 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 echobase. See https://gitlab.nuiton.org/codelutin/echobase.git commit 2b9173a3fa25a57333db0dc001fbe1de2c9115cc Author: Julien Ruchaud <julien.ruchaud@debux.org> Date: Wed Nov 2 17:07:34 2016 +0100 #8724 Modify latitude and longitude for hauling --- .../WorkingDbMigrationCallBackForVersion3_912.java | 53 +++++++++++++++++++++ .../workingDb/h2/3.912-0-atlantos-operation.sql | 31 ++++++++++++ .../workingDb/pg/3.912-0-atlantos-operation.sql | 31 ++++++++++++ echobase-domain/src/main/xmi/echobase.properties | 2 +- echobase-domain/src/main/xmi/echobase.zargo | Bin 100339 -> 100352 bytes .../service/atlantos/xml/XmlBioticExport.java | 4 +- ...VoyageOperationsOperationImportExportModel.java | 8 ++-- .../csv/VoyageOperationsOperationImportRow.java | 16 +++---- .../import-data/operation/operation.csv.gz | Bin 6053 -> 6056 bytes src/site/en/rst/importData.rst | 8 ++-- src/site/rst/importData.rst | 8 ++-- 11 files changed, 138 insertions(+), 23 deletions(-) diff --git a/echobase-domain/src/main/java/fr/ifremer/echobase/persistence/migration/workingDb/WorkingDbMigrationCallBackForVersion3_912.java b/echobase-domain/src/main/java/fr/ifremer/echobase/persistence/migration/workingDb/WorkingDbMigrationCallBackForVersion3_912.java new file mode 100644 index 0000000..272c337 --- /dev/null +++ b/echobase-domain/src/main/java/fr/ifremer/echobase/persistence/migration/workingDb/WorkingDbMigrationCallBackForVersion3_912.java @@ -0,0 +1,53 @@ +package fr.ifremer.echobase.persistence.migration.workingDb; + +/* + * #%L + * EchoBase :: Domain + * %% + * Copyright (C) 2011 - 2016 Ifremer, Codelutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * #L% + */ + +import org.nuiton.topia.persistence.TopiaException; +import org.nuiton.topia.persistence.support.TopiaSqlSupport; +import org.nuiton.version.Version; +import org.nuiton.version.Versions; + +import java.util.List; + +/** + * Created on 26/04/16. + * + * @author Julien Ruchaud - ruchaud@codelutin.com + * @since 4.0 + */ +public class WorkingDbMigrationCallBackForVersion3_912 extends WorkingDbMigrationCallBackForVersionSupport { + + @Override + public Version getVersion() { + return Versions.valueOf("3.912"); + } + + @Override + protected void prepareMigrationScript(TopiaSqlSupport sqlSupport, + List<String> queries, + boolean showSql, + boolean showProgression) throws TopiaException { + + addSpecificScript("3.912-0-atlantos-operation.sql", queries); + } + +} diff --git a/echobase-domain/src/main/resources/migration/workingDb/h2/3.912-0-atlantos-operation.sql b/echobase-domain/src/main/resources/migration/workingDb/h2/3.912-0-atlantos-operation.sql new file mode 100644 index 0000000..ed51bc5 --- /dev/null +++ b/echobase-domain/src/main/resources/migration/workingDb/h2/3.912-0-atlantos-operation.sql @@ -0,0 +1,31 @@ +--- +-- #%L +-- EchoBase :: Domain +-- %% +-- Copyright (C) 2011 - 2016 Ifremer, Codelutin +-- %% +-- This program is free software: you can redistribute it and/or modify +-- it under the terms of the GNU Affero General Public License as published by +-- the Free Software Foundation, either version 3 of the License, or +-- (at your option) any later version. +-- +-- This program is distributed in the hope that it will be useful, +-- but WITHOUT ANY WARRANTY; without even the implied warranty of +-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +-- GNU General Public License for more details. +-- +-- You should have received a copy of the GNU Affero General Public License +-- along with this program. If not, see <http://www.gnu.org/licenses/>. +-- #L% +--- + +alter table importlog alter column importtext type LONGVARCHAR; + +alter table operation add column gearHaulingEndLatitude real; +alter table operation add column gearHaulingEndLongitude real; + +update operation SET gearHaulingEndLatitude = gearShootingEndLatitude; +update operation SET gearHaulingEndLongitude = gearShootingEndLongitude; + +alter table operation drop column gearShootingEndLatitude; +alter table operation drop column gearShootingEndLongitude; diff --git a/echobase-domain/src/main/resources/migration/workingDb/pg/3.912-0-atlantos-operation.sql b/echobase-domain/src/main/resources/migration/workingDb/pg/3.912-0-atlantos-operation.sql new file mode 100644 index 0000000..1735ec2 --- /dev/null +++ b/echobase-domain/src/main/resources/migration/workingDb/pg/3.912-0-atlantos-operation.sql @@ -0,0 +1,31 @@ +--- +-- #%L +-- EchoBase :: Domain +-- %% +-- Copyright (C) 2011 - 2016 Ifremer, Codelutin +-- %% +-- This program is free software: you can redistribute it and/or modify +-- it under the terms of the GNU Affero General Public License as published by +-- the Free Software Foundation, either version 3 of the License, or +-- (at your option) any later version. +-- +-- This program is distributed in the hope that it will be useful, +-- but WITHOUT ANY WARRANTY; without even the implied warranty of +-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +-- GNU General Public License for more details. +-- +-- You should have received a copy of the GNU Affero General Public License +-- along with this program. If not, see <http://www.gnu.org/licenses/>. +-- #L% +--- + +alter table importlog alter column importtext type text; + +alter table operation add column gearHaulingEndLatitude real; +alter table operation add column gearHaulingEndLongitude real; + +update operation SET gearHaulingEndLatitude = gearShootingEndLatitude; +update operation SET gearHaulingEndLongitude = gearShootingEndLongitude; + +alter table operation drop column gearShootingEndLatitude; +alter table operation drop column gearShootingEndLongitude; diff --git a/echobase-domain/src/main/xmi/echobase.properties b/echobase-domain/src/main/xmi/echobase.properties index 4cf2ff5..3dff6fd 100644 --- a/echobase-domain/src/main/xmi/echobase.properties +++ b/echobase-domain/src/main/xmi/echobase.properties @@ -23,7 +23,7 @@ model.tagValue.notGenerateToString=true model.tagValue.generateOperatorForDAOHelper=true -model.tagValue.version=3.911 +model.tagValue.version=3.912 model.tagValue.generatePropertyChangeSupport=false model.tagValue.generateBooleanGetMethods=false model.tagValue.indexForeignKeys=true diff --git a/echobase-domain/src/main/xmi/echobase.zargo b/echobase-domain/src/main/xmi/echobase.zargo index d9f8c64..6df5581 100644 Binary files a/echobase-domain/src/main/xmi/echobase.zargo and b/echobase-domain/src/main/xmi/echobase.zargo differ diff --git a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/atlantos/xml/XmlBioticExport.java b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/atlantos/xml/XmlBioticExport.java index 7d1f8a7..74e96d5 100644 --- a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/atlantos/xml/XmlBioticExport.java +++ b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/atlantos/xml/XmlBioticExport.java @@ -210,8 +210,8 @@ public class XmlBioticExport implements EchoBaseService { Float startLatitude = operation.getGearShootingStartLatitude(); Float startLongitude = operation.getGearShootingStartLongitude(); - Float endLatitude = operation.getGearShootingEndLatitude(); - Float endLongitude = operation.getGearShootingEndLongitude(); + Float endLatitude = operation.getGearHaulingEndLatitude(); + Float endLongitude = operation.getGearHaulingEndLongitude(); int distance = (int) (Math.sqrt(Math.pow(startLatitude - startLatitude, 2) + Math.pow(endLongitude - startLongitude, 2)) * 60 * 1852); diff --git a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportExportModel.java b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportExportModel.java index cb975d4..2d398d6 100644 --- a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportExportModel.java +++ b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportExportModel.java @@ -51,9 +51,9 @@ public class VoyageOperationsOperationImportExportModel extends EchoBaseImportEx model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_START_TIME, EchoBaseCsvUtil.IMPORT_DAY_TIME_ECHOBASE); model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_END_TIME, EchoBaseCsvUtil.IMPORT_DAY_TIME_ECHOBASE); model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_START_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); - model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_END_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); + model.newMandatoryColumn(Operation.PROPERTY_GEAR_HAULING_END_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_START_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); - model.newMandatoryColumn(Operation.PROPERTY_GEAR_SHOOTING_END_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); + model.newMandatoryColumn(Operation.PROPERTY_GEAR_HAULING_END_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); return model; } @@ -70,9 +70,9 @@ public class VoyageOperationsOperationImportExportModel extends EchoBaseImportEx model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_START_TIME, EchoBaseCsvUtil.IMPORT_DAY_TIME_ECHOBASE); model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_END_TIME, EchoBaseCsvUtil.IMPORT_DAY_TIME_ECHOBASE); model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_START_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); - model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_END_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); + model.newColumnForExport(Operation.PROPERTY_GEAR_HAULING_END_LATITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_START_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); - model.newColumnForExport(Operation.PROPERTY_GEAR_SHOOTING_END_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); + model.newColumnForExport(Operation.PROPERTY_GEAR_HAULING_END_LONGITUDE, EchoBaseCsvUtil.PRIMITIVE_FLOAT); return model; } diff --git a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportRow.java b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportRow.java index 78b9b29..6308fa3 100644 --- a/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportRow.java +++ b/echobase-services/src/main/java/fr/ifremer/echobase/services/service/importdata/csv/VoyageOperationsOperationImportRow.java @@ -101,12 +101,12 @@ public class VoyageOperationsOperationImportRow { operation.setGearShootingStartLatitude(gearShootingStartLatitude); } - public Float getGearShootingEndLatitude() { - return operation.getGearShootingEndLatitude(); + public Float getGearHaulingEndLatitude() { + return operation.getGearHaulingEndLatitude(); } - public void setGearShootingEndLatitude(Float gearShootingEndLatitude) { - operation.setGearShootingEndLatitude(gearShootingEndLatitude); + public void setGearHaulingEndLatitude(Float gearHaulingEndLatitude) { + operation.setGearHaulingEndLatitude(gearHaulingEndLatitude); } public Float getGearShootingStartLongitude() { @@ -117,12 +117,12 @@ public class VoyageOperationsOperationImportRow { operation.setGearShootingStartLongitude(gearShootingStartLongitude); } - public Float getGearShootingEndLongitude() { - return operation.getGearShootingEndLongitude(); + public Float getGearHaulingEndLongitude() { + return operation.getGearHaulingEndLongitude(); } - public void setGearShootingEndLongitude(Float gearShootingEndLongitude) { - operation.setGearShootingEndLongitude(gearShootingEndLongitude); + public void setGearHaulingEndLongitude(Float gearHaulingEndLongitude) { + operation.setGearHaulingEndLongitude(gearHaulingEndLongitude); } public float getMidHaulLatitude() { diff --git a/echobase-services/src/test/resources/import-data/operation/operation.csv.gz b/echobase-services/src/test/resources/import-data/operation/operation.csv.gz index e00bd79..c436a50 100644 Binary files a/echobase-services/src/test/resources/import-data/operation/operation.csv.gz and b/echobase-services/src/test/resources/import-data/operation/operation.csv.gz differ diff --git a/src/site/en/rst/importData.rst b/src/site/en/rst/importData.rst index 99de293..34d5aa0 100644 --- a/src/site/en/rst/importData.rst +++ b/src/site/en/rst/importData.rst @@ -244,7 +244,7 @@ Required columns :: - vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearShootingEndLatitude;gearShootingEndLongitude;gearCode + vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearHaulingEndLatitude;gearHaulingEndLongitude;gearCode Columns formats --------------- @@ -270,11 +270,11 @@ Columns formats +-----------------------------+------------------------+ | gearShootingStartLatitude |(float) | +-----------------------------+------------------------+ -| gearShootingEndLatitude |(float) | +| gearHaulingEndLatitude |(float) | +-----------------------------+------------------------+ | gearShootingStartLongitude |(float) | +-----------------------------+------------------------+ -| gearShootingEndLongitude |(float) | +| gearHaulingEndLongitude |(float) | +-----------------------------+------------------------+ Example @@ -282,7 +282,7 @@ Example :: - vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearShootingEndLatitude;gearShootingEndLongitude;gearCode + vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearHaulingEndLatitude;gearHaulingEndLongitude;gearCode THALASSA II;P0422;CLAS;2011-05-05 06:49:50.0000;45.4165605;-1.4492292;45.4029733;-1.4860902;2011-05-05 07:42:19.0000;45.4301477;-1.4123682;57x52 OperationMetadataValue diff --git a/src/site/rst/importData.rst b/src/site/rst/importData.rst index cfd1071..bae3861 100644 --- a/src/site/rst/importData.rst +++ b/src/site/rst/importData.rst @@ -247,7 +247,7 @@ Colonnes requises :: - vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearShootingEndLatitude;gearShootingEndLongitude;gearCode + vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearHaulingEndLatitude;gearHaulingEndLongitude;gearCode Format des colonnes ------------------- @@ -273,11 +273,11 @@ Format des colonnes +-----------------------------+------------------------+ | gearShootingStartLatitude |(float) | +-----------------------------+------------------------+ -| gearShootingEndLatitude |(float) | +| gearHaulingEndLatitude |(float) | +-----------------------------+------------------------+ | gearShootingStartLongitude |(float) | +-----------------------------+------------------------+ -| gearShootingEndLongitude |(float) | +| gearHaulingEndLongitude |(float) | +-----------------------------+------------------------+ Exemple @@ -285,7 +285,7 @@ Exemple :: - vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearShootingEndLatitude;gearShootingEndLongitude;gearCode + vesselName;operationId;depthStratumId;gearShootingStartTime;midHaulLatitude;midHaulLongitude;gearShootingStartLatitude;gearShootingStartLongitude;gearShootingEndTime;gearHaulingEndLatitude;gearHaulingEndLongitude;gearCode THALASSA II;P0422;CLAS;2011-05-05 06:49:50.0000;45.4165605;-1.4492292;45.4029733;-1.4860902;2011-05-05 07:42:19.0000;45.4301477;-1.4123682;57x52 OperationMetadataValue -- 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 echobase. See https://gitlab.nuiton.org/codelutin/echobase.git commit f14ecbf59900e34eb2f0e5c0ad08280bcb7011ae Merge: 2b9173a 67e7379 Author: Julien Ruchaud <julien.ruchaud@debux.org> Date: Wed Nov 2 17:09:21 2016 +0100 Merge branch 'develop' of gitlab.nuiton.org:codelutin/echobase into develop echobase-domain/pom.xml | 2 +- echobase-services/pom.xml | 2 +- echobase-ui/pom.xml | 2 +- pom.xml | 2 +- src/site/rst/importData.rst | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.
participants (1)
-
codelutin.com scm