Tutti-commits
Threads by month
- ----- 2026 -----
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- 4058 discussions
Author: tchemit
Date: 2014-01-23 12:39:57 +0100 (Thu, 23 Jan 2014)
New Revision: 1524
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1524
Log:
mise ?\195?\160 jour doc sur les updates
Modified:
trunk/src/site/rst/update.rst.vm
Modified: trunk/src/site/rst/update.rst.vm
===================================================================
--- trunk/src/site/rst/update.rst.vm 2014-01-23 11:35:27 UTC (rev 1523)
+++ trunk/src/site/rst/update.rst.vm 2014-01-23 11:39:57 UTC (rev 1524)
@@ -44,6 +44,7 @@
- les compoasants de données :
1. Mise à jour des référentiels de la base de données.
+ 2. Mise à jour des rapports Birt.
Principe des mises à jour
-------------------------
@@ -93,19 +94,8 @@
Pour les composants de données, on utilise le fichier de propriétés disponible
sur le réseau à l'adresse suivante:
-http://appup.forge.codelutin.com/tutti/tutti-db.properties
+https://www.ifremer.fr/sih-resource-private/tutti/tutti-data.properties
-
-::
-
- ################################################################################
- ### DB Updates #################################################################
- ################################################################################
-
- db.version=${dbVersion}
- db.url=zip:http://appup.nuiton.org/tutti/auth/tutti-db-${dbVersion}.zip
- db.auth=true
-
Utilisation dans Tutti
----------------------
@@ -137,14 +127,3 @@
la base requière un mot de passe.
Le fichier de mise à jour quand à lui sera toujours disponible publiquement.
-
-Pré-requis à la création d'une nouvelle version de Tutti
---------------------------------------------------------
-
-Pour pouvoir créer une nouvelle version de Tutti, il nous faut connaitre la
-dernière mise à jour de la base.
-
-Ainsi nous pourrons monter les versions du fichier de mise à jour automatiquement.
-
-Les autres composants (jre, tutti, i18n, help) sont automatiquement gérés lors de
-la création de la nouvelle version.
\ No newline at end of file
1
0
r1523 - in trunk: src/site/rst tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service tutti-persistence/src/main/resources
by tchemit@users.forge.codelutin.com 23 Jan '14
by tchemit@users.forge.codelutin.com 23 Jan '14
23 Jan '14
Author: tchemit
Date: 2014-01-23 12:35:27 +0100 (Thu, 23 Jan 2014)
New Revision: 1523
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1523
Log:
fixes #4196: [TECH] Requ?\195?\170te d'acc?\195?\168s au r?\195?\169f?\195?\169rentiel Personne
Modified:
trunk/src/site/rst/referential.rst
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/ReferentialPersistenceServiceImpl.java
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java
trunk/tutti-persistence/src/main/resources/queries-override.hbm.xml
trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties
Modified: trunk/src/site/rst/referential.rst
===================================================================
--- trunk/src/site/rst/referential.rst 2014-01-23 11:01:50 UTC (rev 1522)
+++ trunk/src/site/rst/referential.rst 2014-01-23 11:35:27 UTC (rev 1523)
@@ -161,7 +161,6 @@
-------------------------------
::
-
SELECT DISTINCT
p.id,
p.lastname,
@@ -178,7 +177,7 @@
:projectMemberProfilId,
:userProfilId
)
- AND p.department.code LIKE 'PDG-%'
+ AND p.department.code LIKE concat(:departementPrefixCode , '%')
Paramètres :
@@ -187,6 +186,7 @@
- :userProfilId = *UserProfilId.USER*
- :statusValidCode = *StatusCode.ENABLE*
- :statusTemporaryCode = *StatusCode.TEMPORARY*
+- :departementPrefixCode = *UserProfilId.DEPARTEMENT_PREFIX*
*État:* Valide.
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/ReferentialPersistenceServiceImpl.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/ReferentialPersistenceServiceImpl.java 2014-01-23 11:01:50 UTC (rev 1522)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/ReferentialPersistenceServiceImpl.java 2014-01-23 11:35:27 UTC (rev 1523)
@@ -351,7 +351,9 @@
"allPersons",
"observerProfilId", IntegerType.INSTANCE, enumeration.USER_PROFIL_ID_OBSERVER,
"projectMemberProfilId", IntegerType.INSTANCE, enumeration.USER_PROFIL_ID_PROJECT_MEMBER,
- "userProfilId", IntegerType.INSTANCE, enumeration.USER_PROFIL_ID_USER);
+ "userProfilId", IntegerType.INSTANCE, enumeration.USER_PROFIL_ID_USER,
+ "departementPrefixCode", StringType.INSTANCE, enumeration.USER_PROFIL_ID_DEPARTEMENT_PREFIX
+ );
List<Person> result = Lists.newArrayList();
while (list.hasNext()) {
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java 2014-01-23 11:01:50 UTC (rev 1522)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java 2014-01-23 11:35:27 UTC (rev 1523)
@@ -119,6 +119,9 @@
@Value("${UserProfilId.USER}")
public final Integer USER_PROFIL_ID_USER = null;
+ @Value("${UserProfilId.DEPARTEMENT_PREFIX}")
+ public final String USER_PROFIL_ID_DEPARTEMENT_PREFIX = null;
+
@Value("${VesselTypeId.SCIENTIFIC_RESEARCH_VESSEL}")
public final Integer VESSEL_TYPE_ID_SCIENTIFIC = null;
Modified: trunk/tutti-persistence/src/main/resources/queries-override.hbm.xml
===================================================================
--- trunk/tutti-persistence/src/main/resources/queries-override.hbm.xml 2014-01-23 11:01:50 UTC (rev 1522)
+++ trunk/tutti-persistence/src/main/resources/queries-override.hbm.xml 2014-01-23 11:35:27 UTC (rev 1523)
@@ -851,13 +851,14 @@
:projectMemberProfilId,
:userProfilId
)
- AND p.department.code LIKE 'PDG-%'
+ AND p.department.code LIKE concat(:departementPrefixCode , '%')
]]>
<query-param name="observerProfilId" type="java.lang.Integer"/>
<query-param name="projectMemberProfilId" type="java.lang.Integer"/>
<query-param name="userProfilId" type="java.lang.Integer"/>
<query-param name="statusValidCode" type="java.lang.String"/>
<query-param name="statusTemporaryCode" type="java.lang.String"/>
+ <query-param name="departementPrefixCode" type="java.lang.String"/>
</query>
<!-- [REF-04-1] Get one person -->
Modified: trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties
===================================================================
--- trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties 2014-01-23 11:01:50 UTC (rev 1522)
+++ trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties 2014-01-23 11:35:27 UTC (rev 1523)
@@ -402,6 +402,8 @@
# (20=observateur volant, 95=Administrateur SIH) -> L'avantage du 20 est qu'il est inactif (=20), donc plus facilement detectable
PersonId.UNKNOWN_RECORDER_PERSON=20
+UserProfilId.DEPARTEMENT_PREFIX=PDG-
+
# 181=PDG-RBE (à confirmer par Vincent)
DepartmentId.UNKNOWN_RECORDER_DEPARTMENT=181
1
0
r1522 - in trunk: tutti-persistence/src/main/java/fr/ifremer/tutti tutti-persistence/src/main/java/fr/ifremer/tutti/persistence tutti-persistence/src/main/resources/i18n tutti-service/src/main/java/fr/ifremer/tutti/service tutti-ui-swing/src/main/assembly tutti-ui-swing/src/main/assembly/full tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing
by tchemit@users.forge.codelutin.com 23 Jan '14
by tchemit@users.forge.codelutin.com 23 Jan '14
23 Jan '14
Author: tchemit
Date: 2014-01-23 12:01:50 +0100 (Thu, 23 Jan 2014)
New Revision: 1522
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1522
Log:
fixes #4149: [TECH] Mise ?\195?\160 jour de r?\195?\169f?\195?\169rentiel - Erreur sur les donn?\195?\169es suite ?\195?\160 la mise ?\195?\160 jour
Added:
trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.bat
trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.sh
Modified:
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfiguration.java
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfigurationOption.java
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistence.java
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceImpl.java
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceNoDbImpl.java
trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_en_GB.properties
trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_fr_FR.properties
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/PersistenceService.java
trunk/tutti-ui-swing/src/main/assembly/full/README.txt
trunk/tutti-ui-swing/src/main/assembly/tutti-full-component.xml
trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/RunTutti.java
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfiguration.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfiguration.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfiguration.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -331,7 +331,6 @@
applicationConfig.setOption(TuttiConfigurationOption.PROTOCOL_ID.getKey(), protocolId);
}
-
//------------------------------------------------------------------------//
//--- Option getter ------------------------------------------------------//
//------------------------------------------------------------------------//
@@ -393,6 +392,11 @@
return applicationConfig.getOptionAsClass(TuttiConfigurationOption.HIBERNATE_DIALECT.getKey());
}
+ public boolean isSanityDb() {
+ boolean result = applicationConfig.getOptionAsBoolean(TuttiConfigurationOption.DB_SANITY.getKey());
+ return result;
+ }
+
public boolean isHibernateShowSql() {
boolean result = applicationConfig.getOptionAsBoolean(TuttiConfigurationOption.HIBERNATE_SHOW_SQL.getKey());
return result;
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfigurationOption.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfigurationOption.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/TuttiConfigurationOption.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -141,6 +141,12 @@
"allegro",
String.class),
+ DB_SANITY(
+ "tutti.persistence.db.sanity",
+ n_("tutti.persistence.db.sanity.description"),
+ "false",
+ Boolean.class),
+
JDBC_USERNAME(
"tutti.persistence.jdbc.username",
n_("tutti.config.option.persistence.jdbc.username.description"),
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistence.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistence.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistence.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -108,6 +108,8 @@
void updateSchema();
+ void sanityDb();
+
//------------------------------------------------------------------------//
//-- Referential methods --//
//------------------------------------------------------------------------//
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceImpl.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceImpl.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceImpl.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -99,8 +99,6 @@
private static final Log log =
LogFactory.getLog(TuttiPersistenceImpl.class);
- public static Boolean CHECK = false;
-
@Autowired
protected ReferentialPersistenceService referentialService;
@@ -211,6 +209,11 @@
}
@Override
+ public void sanityDb() {
+ databaseSanityService.sanity();
+ }
+
+ @Override
public void init() {
if (log.isInfoEnabled()) {
log.info("Open persistence driver " + getImplementationName());
@@ -231,12 +234,6 @@
TuttiEnumerationFile enumerationFile = getEnumerationFile();
batchVracPredicate = TuttiEntities.newSpeciesAbleBatchCategoryPredicate(enumerationFile.PMFM_ID_SORTED_UNSORTED, enumerationFile.QUALITATIVE_VRAC_ID);
-
- if (CHECK) {
-
- // sanity database
- databaseSanityService.sanity();
- }
}
protected boolean close;
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceNoDbImpl.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceNoDbImpl.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/TuttiPersistenceNoDbImpl.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -99,6 +99,11 @@
}
@Override
+ public void sanityDb() {
+ throw notImplemented();
+ }
+
+ @Override
public void clearAllCaches() {
throw notImplemented();
}
Modified: trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_en_GB.properties
===================================================================
--- trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_en_GB.properties 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_en_GB.properties 2014-01-23 11:01:50 UTC (rev 1522)
@@ -92,6 +92,7 @@
tutti.persistence.config.generateEnumFile.error=
tutti.persistence.config.generateFile.error=
tutti.persistence.cruise.gearUsedInOperations.error=
+tutti.persistence.db.sanity.description=
tutti.persistence.dbMetadata.instanciation.error=
tutti.persistence.error.caracteristic.notFound=
tutti.persistence.error.no.convertor=
Modified: trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_fr_FR.properties
===================================================================
--- trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_fr_FR.properties 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-persistence/src/main/resources/i18n/tutti-persistence_fr_FR.properties 2014-01-23 11:01:50 UTC (rev 1522)
@@ -92,6 +92,7 @@
tutti.persistence.config.generateEnumFile.error=Erreur lors de la génération du fichier d'énumération de la configuration de la base de données
tutti.persistence.config.generateFile.error=Erreur lors de la génération du fichier de configuration de la base de données
tutti.persistence.cruise.gearUsedInOperations.error=Vous essayez d'enlever un ou plusieurs engins qui sont utilisés sur des traits.<hr/>Veuillez changer l'engin des traits en question pour pouvoir les enlever de la campagne.
+tutti.persistence.db.sanity.description=Mettre à vrai pour nettoyer les bases au chargement
tutti.persistence.dbMetadata.instanciation.error=Erreur lors de l'initialisation des metadata de la base de données par la connexion %s
tutti.persistence.error.caracteristic.notFound=Caractéristique inconnue
tutti.persistence.error.no.convertor=Impossible de convertir en modèle de catégorie le type %s avec la valeur %s
Modified: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/PersistenceService.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/PersistenceService.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/PersistenceService.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -212,6 +212,11 @@
driver.updateSchema();
}
+ @Override
+ public void sanityDb() {
+ driver.sanityDb();
+ }
+
public static final DateFormat EXPORT_DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd");
public static final String EXPORT_DIRECTORY_FORMAT = "tutti-%s-%s";
@@ -622,6 +627,11 @@
// can use adagio driver
driver = TuttiPersistenceServiceLocator.getPersistenceService();
+ if (config.isSanityDb()) {
+
+ driver.sanityDb();
+ }
+
} else {
driver = new TuttiPersistenceNoDbImpl();
Modified: trunk/tutti-ui-swing/src/main/assembly/full/README.txt
===================================================================
--- trunk/tutti-ui-swing/src/main/assembly/full/README.txt 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-ui-swing/src/main/assembly/full/README.txt 2014-01-23 11:01:50 UTC (rev 1522)
@@ -1,17 +1,30 @@
Pour démarrer Allegro Campagne Saisie
-------------------------------------
+# Sous windows
+
+tutti.bat
+
# Sous Linux
./tutti.sh
+Pour nettoyer la base de donnée
+-------------------------------
+
+Si vous rencontrez des problèmes avec la base de données, vous pouvez tenter de lancer cette commande
+
# Sous windows
-tutti.bat
+tutti-sanity.bat
+# Sous Linux
+
+./tutti-sanity.sh
+
Consulter l'aide
----------------
-En attendant que l'aide soit finalisée, vous pouvez consulter ce document :
+L'aide en ligne est consultable dans l'application ou bien sur le site
-help/Aide_Allegro_Campagne.odt
\ No newline at end of file
+http://maven-site.forge.codelutin.com/tutti/help/fr/index.html
\ No newline at end of file
Copied: trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.bat (from rev 1520, trunk/tutti-ui-swing/src/main/assembly/full/tutti.bat)
===================================================================
--- trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.bat (rev 0)
+++ trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.bat 2014-01-23 11:01:50 UTC (rev 1522)
@@ -0,0 +1,44 @@
+@echo off
+
+set OLDDIR=%CD%
+cd /d %~dp0%
+
+set TUTTI_BASEDIR="%CD%"
+set JAVA_HOME=%TUTTI_BASEDIR%\jre
+set JAVA_COMMAND=%JAVA_HOME%\bin\java
+set TUTTI_LOG_FILE=%TUTTI_BASEDIR%\data\tutti-${project.version}.log
+
+echo Allegro Campaign basedir: %TUTTI_BASEDIR%
+echo Allegro Campaign app home: %TUTTI_HOME%
+echo Allegro Campaign jre home: %JAVA_HOME%
+echo Allegro Campaign log file: %TUTTI_LOG_FILE%
+
+:start
+
+copy tutti\update.bat .
+echo Searching for updates...
+call update.bat
+del update.bat
+if exist "tutti.config" copy tutti.config tutti
+echo Allegro Campaign ${project.version} is starting...
+call tutti\launch.bat --option tutti.launch.mode full --option tutti.basedir %TUTTI_BASEDIR% --option tutti.persistence.db.sanity true
+if errorlevel 89 goto deletedb
+if errorlevel 88 goto start
+
+goto quit
+
+:deletedb
+
+echo "Clean database and restart"
+
+del /S/Q data\db
+del /S/Q data\dbcache
+del /S/Q data\dbconf
+rmdir data\db
+rmdir data\dbcache
+rmdir data\dbconf
+
+goto start
+
+:quit
+cd %OLDDIR%
Copied: trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.sh (from rev 1520, trunk/tutti-ui-swing/src/main/assembly/full/tutti.sh)
===================================================================
--- trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.sh (rev 0)
+++ trunk/tutti-ui-swing/src/main/assembly/full/tutti-sanity.sh 2014-01-23 11:01:50 UTC (rev 1522)
@@ -0,0 +1,41 @@
+#!/bin/bash
+
+export TUTTI_BASEDIR=$(pwd)
+export TUTTI_HOME=$TUTTI_BASEDIR/tutti
+export JAVA_HOME=$TUTTI_BASEDIR/jre
+export JAVA_COMMAND=$JAVA_HOME/bin/java
+export TUTTI_LOG_FILE=$TUTTI_BASEDIR/data/tutti-${project.version}.log
+
+cd $TUTTI_BASEDIR
+
+echo "Allegro Campaign basedir: $TUTTI_BASEDIR"
+echo "Allegro Campaign app home: $TUTTI_HOME"
+echo "Allegro Campaign jre home: $JAVA_HOME"
+echo "Allegro Campaign log file: $TUTTI_LOG_FILE"
+
+while true; do
+
+ cp $TUTTI_HOME/update.sh .
+ echo "Searching for updates..."
+ ./update.sh
+ rm -f update.sh
+ if [ -f $TUTTI_BASEDIR/tutti.config ]; then
+ cp -rfv $TUTTI_BASEDIR/tutti.config $TUTTI_HOME
+ fi
+ echo "Allegro Campaign ${project.version} is starting..."
+ ./tutti/launch.sh --option tutti.launch.mode full --option tutti.basedir $TUTTI_BASEDIR --option tutti.persistence.db.sanity true
+ exitcode=$?
+
+ if [ "$exitcode" -eq "89" ]; then
+ # delete db directory and restart
+ rm -rfv data/db
+ rm -rfv data/dbcache
+ rm -rfv data/dbconf
+ exitcode=88
+ fi
+
+ if [ ! "$exitcode" -eq "88" ]; then
+ # quit now!
+ exit $exitcode
+ fi
+done
\ No newline at end of file
Modified: trunk/tutti-ui-swing/src/main/assembly/tutti-full-component.xml
===================================================================
--- trunk/tutti-ui-swing/src/main/assembly/tutti-full-component.xml 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-ui-swing/src/main/assembly/tutti-full-component.xml 2014-01-23 11:01:50 UTC (rev 1522)
@@ -36,8 +36,8 @@
<filtered>true</filtered>
<fileMode>0755</fileMode>
<includes>
- <include>tutti.sh</include>
- <include>tutti.bat</include>
+ <include>*.sh</include>
+ <include>*.bat</include>
<include>README*</include>
<include>report/**</include>
</includes>
Modified: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/RunTutti.java
===================================================================
--- trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/RunTutti.java 2014-01-23 08:25:49 UTC (rev 1521)
+++ trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/RunTutti.java 2014-01-23 11:01:50 UTC (rev 1522)
@@ -25,7 +25,6 @@
*/
import fr.ifremer.tutti.TuttiConfiguration;
-import fr.ifremer.tutti.persistence.TuttiPersistenceImpl;
import fr.ifremer.tutti.ui.swing.action.StartAction;
import fr.ifremer.tutti.ui.swing.action.UpdateApplicationAction;
import fr.ifremer.tutti.ui.swing.action.UpdateReportAction;
@@ -61,8 +60,6 @@
public static void main(String... args) {
- TuttiPersistenceImpl.CHECK = true;
-
if (log.isInfoEnabled()) {
log.info("Starting Tutti with arguments: " + Arrays.toString(args));
}
1
0
r1521 - in trunk: src/conception/specifications tutti-ui-swing/src/main/help/css tutti-ui-swing/src/main/help/en tutti-ui-swing/src/main/help/fr
by lkaufmann@users.forge.codelutin.com 23 Jan '14
by lkaufmann@users.forge.codelutin.com 23 Jan '14
23 Jan '14
Author: lkaufmann
Date: 2014-01-23 09:25:49 +0100 (Thu, 23 Jan 2014)
New Revision: 1521
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1521
Log:
Specifications update - v 0.4.2 & help update (spelling corrections)
Modified:
trunk/src/conception/specifications/AllegroCampagne-Specifications.odt
trunk/src/conception/specifications/AllegroCampagne-Specifications.pdf
trunk/tutti-ui-swing/src/main/help/css/style.css
trunk/tutti-ui-swing/src/main/help/en/editFishingOperation.html
trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html
Modified: trunk/src/conception/specifications/AllegroCampagne-Specifications.odt
===================================================================
(Binary files differ)
Modified: trunk/src/conception/specifications/AllegroCampagne-Specifications.pdf
===================================================================
(Binary files differ)
Modified: trunk/tutti-ui-swing/src/main/help/css/style.css
===================================================================
--- trunk/tutti-ui-swing/src/main/help/css/style.css 2014-01-21 16:44:14 UTC (rev 1520)
+++ trunk/tutti-ui-swing/src/main/help/css/style.css 2014-01-23 08:25:49 UTC (rev 1521)
@@ -54,4 +54,10 @@
.table > tbody > .danger > td,
.table > tfoot > .danger > td {
background-color: #F2DEDE !important;
+}
+
+.checked {
+ text-align: center;
+ font-weight: bold;
+}
}
\ No newline at end of file
Modified: trunk/tutti-ui-swing/src/main/help/en/editFishingOperation.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/en/editFishingOperation.html 2014-01-21 16:44:14 UTC (rev 1520)
+++ trunk/tutti-ui-swing/src/main/help/en/editFishingOperation.html 2014-01-23 08:25:49 UTC (rev 1521)
@@ -418,7 +418,7 @@
<dt>Poids inerte trié</dt>
<dd>
dans la fraction triée, correspond au poids de la vase, des cailloux,
- débris coquillers, etc.
+ débris coquilliers, etc.
</dd>
<dt>Poids vivant non détaillé trié</dt>
<dd>
@@ -525,7 +525,7 @@
<dd>
sur la ligne sélectionnée, pointer la catégorisation que vous voulez
modifier (exemple modifer Vrac en Hors Vrac), clic droit + Modifier la
- catégorie vous permet de choisir dans la lsite déroulante la nouvelle
+ catégorie vous permet de choisir dans la liste déroulante la nouvelle
valeur que vous souhaitez appliquer au lot.
</dd>
<dt>Clic droit sur un lot espèce + [Ajouter une catégorie]</dt>
Modified: trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-21 16:44:14 UTC (rev 1520)
+++ trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-23 08:25:49 UTC (rev 1521)
@@ -26,7 +26,7 @@
-->
<meta charset="utf-8">
- <title>Allegro Campagne - Gérer la base de données</title>
+ <title>Allegro Campagne - Mapping Écrans / Base de données</title>
<link href="../css/bootstrap.min.css" rel="stylesheet">
<link href="../css/style.css" rel="stylesheet">
<script type="text/javascript" src="../js/jquery-2.0.3.min.js"></script>
@@ -37,7 +37,7 @@
<div class="container">
<div class="page-header">
- <h1>Gérer la base de données</h1>
+ <h1>Mapping Écrans / Base de données</h1>
</div>
<p>Cette page décrit comment sont stockées les informations visibles dans les écrans de l'application.</p>
@@ -59,7 +59,7 @@
<p>Nom</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -73,7 +73,7 @@
<p>Zone</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -88,7 +88,7 @@
<p>Description</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -117,7 +117,7 @@
<p>Série</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -190,7 +190,7 @@
<p>Nombre de poches</p>
</td>
<td rowspan="2">
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td rowspan="2">
<p>Numérique</p>
@@ -215,7 +215,7 @@
<p>Port de départ</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -230,7 +230,7 @@
<p>Port d'arrivée</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -245,7 +245,7 @@
<p>Date de début</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
@@ -259,7 +259,7 @@
<p>Date de fin</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
@@ -273,7 +273,7 @@
<p>Navire</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -288,7 +288,7 @@
<p>Engin(s)</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -303,7 +303,7 @@
<p>Chef(s) de mission</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -318,7 +318,7 @@
<p>Responsable(s) de salle de tri</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -362,7 +362,7 @@
<p>Nom</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -760,7 +760,7 @@
<p>Code Station</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -774,7 +774,7 @@
<p>Numéro de Trait</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Numérique</p>
@@ -877,7 +877,7 @@
<p>Date de début de traîne</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
@@ -1473,10 +1473,10 @@
</tr>
<tr>
<td>
- <p>Tableau > Espèce</p>
+ <p>Tableau > Espèce du lot</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p> </p>
@@ -1490,7 +1490,7 @@
<p>Tableau > V/HV</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -1842,10 +1842,10 @@
</tr>
<tr>
<td>
- <p>Tableau > Benthos</p>
+ <p>Tableau > Espèce du lot</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p> </p>
@@ -1859,7 +1859,7 @@
<p>Tableau > V/HV</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -2143,10 +2143,10 @@
</tr>
<tr>
<td>
- <p>Tableau > Catégorie</p>
+ <p>Tableau > Catégorie de déchets</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p>Choix parmi les valeurs issues d'un référentiel</p>
@@ -2160,7 +2160,7 @@
<p>Tableau > Catégorie de taille</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p>Choix parmi les valeurs issues d'un référentiel</p>
@@ -2174,7 +2174,7 @@
<p>Tableau > Nombre</p>
</td>
<td>
- <p> </p>
+ <p class="checked">X</p>
</td>
<td>
<p>Numérique</p>
@@ -2259,7 +2259,7 @@
<p>Tableau > Espèce</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
@@ -2418,7 +2418,7 @@
<p>Tableau > Espèce</p>
</td>
<td>
- <p style="text-align:center;font-weight:bold;">X</p>
+ <p class="checked">X</p>
</td>
<td>
<p>Liste.</p>
Modified: trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html 2014-01-21 16:44:14 UTC (rev 1520)
+++ trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html 2014-01-23 08:25:49 UTC (rev 1521)
@@ -425,7 +425,7 @@
<dt>Poids inerte trié</dt>
<dd>
dans la fraction triée, correspond au poids de la vase, des cailloux,
- débris coquillers, etc.
+ débris coquilliers, etc.
</dd>
<dt>Poids vivant non détaillé trié</dt>
<dd>
@@ -532,7 +532,7 @@
<dd>
sur la ligne sélectionnée, pointer la catégorisation que vous voulez
modifier (exemple modifer Vrac en Hors Vrac), clic droit + Modifier la
- catégorie vous permet de choisir dans la lsite déroulante la nouvelle
+ catégorie vous permet de choisir dans la liste déroulante la nouvelle
valeur que vous souhaitez appliquer au lot.
</dd>
<dt>Clic droit sur un lot espèce + [Ajouter une catégorie]</dt>
1
0
r1520 - in trunk/tutti-ui-swing/src/main: filtered-resources help/fr
by tchemit@users.forge.codelutin.com 21 Jan '14
by tchemit@users.forge.codelutin.com 21 Jan '14
21 Jan '14
Author: tchemit
Date: 2014-01-21 17:44:14 +0100 (Tue, 21 Jan 2014)
New Revision: 1520
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1520
Log:
refs #3876: Import de donn?\195?\169es depuis un ictyom?\195?\168tre (par lot) (debut de doc)
Modified:
trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties
trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html
Modified: trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties
===================================================================
--- trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties 2014-01-21 16:29:59 UTC (rev 1519)
+++ trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties 2014-01-21 16:44:14 UTC (rev 1520)
@@ -121,7 +121,6 @@
tutti.editCatchBatch.action.computeWeights.help=editFishingOperation.html\#captureResumeActions
tutti.editCatchBatch.action.exportFishingOperationReport.help=editFishingOperation.html\#captureResumeActions
tutti.editCatchBatch.action.exportFishingOperationReportForSumatra.help=editFishingOperation.html\#captureResumeActions
-tutti.editCatchBatch.action.importPupitri.help=editFishingOperation.html\#captureResumeActions
tutti.editCatchBatch.action.saveCatchBatch.help=editFishingOperation.html\#captureResumeActions
tutti.editCatchBatch.field.benthosTotalSampleSortedWeight.help=editFishingOperation.html\#captureResumeFields
tutti.editCatchBatch.field.benthosTotalSortedWeight.help=editFishingOperation.html\#captureResumeFields
@@ -255,7 +254,7 @@
tutti.editSpeciesBatch.action.editFrequencies.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.exportMultiPost.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.importMultiPost.help=editFishingOperation.html\#captureEspecesActions
-tutti.editSpeciesBatch.action.importPsion.help=
+tutti.editSpeciesBatch.action.importPsion.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.importPupitri.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.removeBatch.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.removeSubBatch.help=editFishingOperation.html\#captureEspecesActions
Modified: trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html 2014-01-21 16:29:59 UTC (rev 1519)
+++ trunk/tutti-ui-swing/src/main/help/fr/editFishingOperation.html 2014-01-21 16:44:14 UTC (rev 1520)
@@ -589,6 +589,24 @@
(cf cas particulier du tri d'un mélange). Les deux fichiers importés
sont sauvegardés comme pièce jointe dans l'onglet « Résumé ».
</dd>
+ <dt>Import psion</dt>
+ <dd>
+ TODO A finir.
+ Il est possible d'importer le fichier généré par le Psion à l'issue du tri de la capture.
+ A l'invitation, sélectionner le fichier .IWA et valider. L'applicatif
+ importera dans l'onglet « Espèces » la liste des espèces
+ triées et les poids associés.
+ L'import ne sera effectif que si le code station et la date du début de trait des
+ fichiers correspondent au code station et date de début du trait et qu'aucune erreur n'est détectée.
+ Toute espèce déjà renseignée dans l'onglet « Résumé » ne peut pas être réimportée.
+ Les espèces non présentent dans le référentiel ne seront pas importées dans
+ l'onglet « Espèces »
+ (cf cas particulier du tri d'un mélange). Le fichier importé
+ est sauvegardé comme pièce jointe dans l'onglet « Résumé ».
+
+ A noter aussi que l'import nécessite l'utilisation d'un protocole (le code campagne des espèces est utilisé
+ pour retrouver celles-ci dans le référentiel).
+ </dd>
<dt>Importer des lots d'espèces</dt>
<dd>
En mode "saisie multi-postes", permet d'importer une saisie des espèces
1
0
21 Jan '14
Author: tchemit
Date: 2014-01-21 17:29:59 +0100 (Tue, 21 Jan 2014)
New Revision: 1519
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1519
Log:
refs #3876: Import de donn?\195?\169es depuis un ictyom?\195?\168tre (par lot)
Added:
trunk/tutti-service/src/test/resources/psion/protocol.tuttiProtocol
trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/action/ImportPsionAction.java
Modified:
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java
trunk/tutti-service/src/main/resources/i18n/tutti-service_en_GB.properties
trunk/tutti-service/src/main/resources/i18n/tutti-service_fr_FR.properties
trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java
trunk/tutti-service/src/test/resources/psion/CC053.IWA
trunk/tutti-service/src/test/resources/psion/FM001.IWA
trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties
trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/TuttiUIContext.java
trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.css
trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.jaxx
trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_en_GB.properties
trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_fr_FR.properties
Modified: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -24,11 +24,15 @@
* #L%
*/
+import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import fr.ifremer.tutti.persistence.entities.referential.Species;
+import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.mutable.MutableInt;
import java.io.Serializable;
+import java.util.Iterator;
+import java.util.List;
import java.util.Map;
/**
@@ -39,6 +43,26 @@
*/
public class PsionImportBatchModel {
+ public static class SampleCategory {
+
+ protected final Integer categoryId;
+
+ protected final Serializable categoryValue;
+
+ public SampleCategory(Integer categoryId, Serializable categoryValue) {
+ this.categoryId = categoryId;
+ this.categoryValue = categoryValue;
+ }
+
+ public Integer getCategoryId() {
+ return categoryId;
+ }
+
+ public Serializable getCategoryValue() {
+ return categoryValue;
+ }
+ }
+
protected final Species species;
protected final Integer lengthStepCaracteristicId;
@@ -47,18 +71,23 @@
protected Float sampleWeight;
- protected Integer categoryId;
+ protected final List<SampleCategory> categories;
- protected Serializable categoryValue;
-
protected final Map<Float, MutableInt> frequencies;
+ protected String categoryCode;
+
public PsionImportBatchModel(Species species, Integer lengthStepCaracteristicId) {
this.species = species;
this.lengthStepCaracteristicId = lengthStepCaracteristicId;
- frequencies = Maps.newTreeMap();
+ this.frequencies = Maps.newTreeMap();
+ this.categories = Lists.newArrayList();
}
+ public void setCategoryCode(String categoryCode) {
+ this.categoryCode = categoryCode;
+ }
+
public void setWeight(Float weight) {
this.weight = weight;
}
@@ -68,23 +97,27 @@
}
public void setCategory(Integer categoryId, Serializable categoryValue) {
- this.categoryId = categoryId;
- this.categoryValue = categoryValue;
+ SampleCategory category = new SampleCategory(categoryId, categoryValue);
+ categories.add(category);
}
- public void addFrequency(Float size) {
+ public void addFrequency(Float size, int number) {
MutableInt mutableFloat = frequencies.get(size);
if (mutableFloat == null) {
mutableFloat = new MutableInt(0);
frequencies.put(size, mutableFloat);
}
- mutableFloat.increment();
+ mutableFloat.add(number);
}
public Species getSpecies() {
return species;
}
+ public String getCategoryCode() {
+ return categoryCode;
+ }
+
public Integer getLengthStepCaracteristicId() {
return lengthStepCaracteristicId;
}
@@ -97,18 +130,18 @@
return sampleWeight;
}
- public Integer getCategoryId() {
- return categoryId;
+ public Iterator<SampleCategory> getCategoryIterator() {
+ return categories.iterator();
}
- public Serializable getCategoryValue() {
- return categoryValue;
- }
-
public boolean withFrequencies() {
return !frequencies.isEmpty();
}
+ public boolean withCategories() {
+ return !categories.isEmpty();
+ }
+
public Map<Float, MutableInt> getFrequencies() {
return frequencies;
}
@@ -116,4 +149,15 @@
public int getNbFrequencies() {
return frequencies.size();
}
+
+ @Override
+ public String toString() {
+ return new ToStringBuilder(this)
+ .append("species", species.getSurveyCode())
+ .append("categoryCode", categoryCode)
+ .append("weight", weight)
+ .append("sampleWeight", sampleWeight)
+ .append("frequencies", frequencies.size())
+ .toString();
+ }
}
Modified: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -25,10 +25,15 @@
*/
import com.google.common.collect.Lists;
+import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
import fr.ifremer.tutti.persistence.entities.referential.Species;
+import org.apache.commons.lang3.mutable.MutableInt;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import java.util.List;
+import java.util.Map;
import java.util.Set;
/**
@@ -39,34 +44,25 @@
*/
public class PsionImportModel {
- protected final List<PsionImportBatchModel> batchs;
+ /** Logger. */
+ private static final Log log = LogFactory.getLog(PsionImportModel.class);
- protected final Set<String> ignoredSpecies;
+ protected final Map<String, PsionImportBatchModel> batchsByCategory;
+ protected final List<String> errors;
+
public PsionImportModel() {
- batchs = Lists.newArrayList();
- ignoredSpecies = Sets.newHashSet();
+ batchsByCategory = Maps.newLinkedHashMap();
+ errors = Lists.newArrayList();
}
- public void addBatch(PsionImportBatchModel batchModel) {
- batchs.add(batchModel);
- }
-
- public void addIgnoredSpecies(String species) {
- ignoredSpecies.add(species);
- }
-
public boolean withBatchs() {
- return !batchs.isEmpty();
+ return !batchsByCategory.isEmpty();
}
- public Set<String> getIgnoredSpecies() {
- return ignoredSpecies;
- }
-
public Set<Species> getSpecies() {
Set<Species> result = Sets.newLinkedHashSet();
- for (PsionImportBatchModel batch : batchs) {
+ for (PsionImportBatchModel batch : batchsByCategory.values()) {
result.add(batch.getSpecies());
}
return result;
@@ -74,11 +70,55 @@
public List<PsionImportBatchModel> getBatchs(Species species) {
List<PsionImportBatchModel> result = Lists.newArrayList();
- for (PsionImportBatchModel batch : batchs) {
+ for (PsionImportBatchModel batch : batchsByCategory.values()) {
if (species.equals(batch.getSpecies())) {
result.add(batch);
}
}
return result;
}
+
+ public boolean withErrors() {
+ return !errors.isEmpty();
+ }
+
+ void addBatch(PsionImportBatchModel batchModel) {
+
+ String cacheCode = batchModel.getSpecies().getSurveyCode() + "_" + batchModel.getCategoryCode();
+
+ PsionImportBatchModel mergeBatch = batchsByCategory.get(cacheCode);
+
+ if (mergeBatch == null) {
+
+ // new batch
+ batchsByCategory.put(cacheCode, batchModel);
+
+ if (log.isInfoEnabled()) {
+ log.info("Added " + batchModel);
+ }
+ } else {
+
+ // merge data with this batch
+
+ mergeBatch.setWeight(mergeBatch.getWeight() + batchModel.getWeight());
+ mergeBatch.setSampleWeight(mergeBatch.getSampleWeight() + batchModel.getSampleWeight());
+
+ for (Map.Entry<Float, MutableInt> entry : batchModel.getFrequencies().entrySet()) {
+ Float stepClass = entry.getKey();
+ int number = entry.getValue().intValue();
+ mergeBatch.addFrequency(stepClass, number);
+ }
+ if (log.isInfoEnabled()) {
+ log.info("Merged " + batchModel + " to " + mergeBatch);
+ }
+ }
+ }
+
+ void addError(String error) {
+ errors.add(error);
+ }
+
+ public List<String> getErrors() {
+ return errors;
+ }
}
Modified: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -24,7 +24,10 @@
* #L%
*/
+import com.google.common.collect.Lists;
+
import java.io.File;
+import java.util.List;
/**
* Created on 1/20/14.
@@ -36,12 +39,13 @@
protected final File importFile;
+ protected final List<String> errors;
+
protected int nbImported;
- protected int nbNotImported;
-
- public PsionImportResult(File importFile) {
+ public PsionImportResult(File importFile, List<String> errors) {
this.importFile = importFile;
+ this.errors = Lists.newArrayList(errors);
}
public File getImportFile() {
@@ -52,15 +56,19 @@
return nbImported;
}
- public int getNbNotImported() {
- return nbNotImported;
+ public List<String> getErrors() {
+ return errors;
}
void incrementNbImported() {
this.nbImported++;
}
- void incrementNbNotImported() {
- this.nbNotImported++;
+ void addError(String error) {
+ errors.add(error);
}
+
+ public boolean isDone() {
+ return errors.isEmpty();
+ }
}
Modified: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -50,9 +50,9 @@
import fr.ifremer.tutti.persistence.service.TuttiEnumerationFile;
import fr.ifremer.tutti.service.AbstractTuttiService;
import fr.ifremer.tutti.service.PersistenceService;
-import fr.ifremer.tutti.service.TuttiDataContext;
import fr.ifremer.tutti.service.TuttiServiceContext;
import org.apache.commons.io.IOUtils;
+import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.mutable.MutableInt;
import org.apache.commons.logging.Log;
@@ -63,6 +63,10 @@
import java.io.IOException;
import java.io.Serializable;
import java.text.DateFormat;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -81,43 +85,59 @@
private static final Log log = LogFactory.getLog(PsionImportService.class);
- protected static final Set<String> SEX_VALUES = Sets.newHashSet(
- "N", "n", "I", "i", "F", "f", "M", "m"
- );
+ protected static final Set<String> SEX_VALUES = Sets.newHashSet("I", "i", "F", "f", "M", "m");
- protected static final Set<String> MATURITY_VALUES = Sets.newHashSet(
- "1", "2", "3", "4", "5"
- );
+ protected static final Set<String> MATURITY_VALUES = Sets.newHashSet("1", "2", "3", "4", "5");
+ /**
+ * All usables keywords in a psion import.
+ * <p/>
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+ public static enum PsionImportKeyword {
+
+ ESPE,
+ POID,
+ TAIL,
+ CATE,
+ LONG
+// // ignored
+// HEUR(true),
+// AGEN(true),
+// CAIS(true),
+// TAXO(true),
+// OUTI(true),
+// PORT(true),
+// DATE(true),
+// HERE(true),
+// NAVI(true),
+// ENGI(true);
+ }
+
protected PersistenceService persistenceService;
- protected char csvSeparator;
+ protected TuttiEnumerationFile enumerationFile;
- protected TuttiDataContext dataContext;
-
protected CaracteristicQualitativeValue sortedCaracteristic;
protected CaracteristicQualitativeValue unsortedCaracteristic;
- protected Map<String, Species> speciesBySurveyCode;
-
- protected Map<String, SpeciesProtocol> speciesProtocolBySurveyCode;
-
protected Map<String, CaracteristicQualitativeValue> sexCaracteristicValues;
protected Map<String, CaracteristicQualitativeValue> maturityCaracteristicValues;
+ protected final DateFormat df = new SimpleDateFormat("MM-dd-yyyy");
+
@Override
public void setServiceContext(TuttiServiceContext context) {
super.setServiceContext(context);
persistenceService = getService(PersistenceService.class);
- csvSeparator = ';';
- dataContext = context.getDataContext();
+ enumerationFile = persistenceService.getEnumerationFile();
-
- TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
-
{ // sorted/unsorted caracteristic
Caracteristic caracteristic =
persistenceService.getSortedUnsortedCaracteristic();
@@ -161,85 +181,117 @@
maturityCaracteristicValues.put("4", byIds.get(enumerationFile.QUALITATIVE_MATURITY_4_ID));
maturityCaracteristicValues.put("5", byIds.get(enumerationFile.QUALITATIVE_MATURITY_5_ID));
}
+ }
- List<Species> allReferentSpecies = persistenceService.getReferentSpeciesWithSurveyCode(
- persistenceService.getAllReferentSpecies());
+ public PsionImportResult importFile(File psionFile, FishingOperation operation, CatchBatch catchBatch) {
- speciesBySurveyCode = Maps.newTreeMap();
- for (Species species : allReferentSpecies) {
+ Preconditions.checkNotNull(psionFile);
+ Preconditions.checkArgument(psionFile.exists(), "Psion file " + psionFile + " does not exist.");
+
+ TuttiProtocol protocol = persistenceService.getProtocol();
+
+ if (protocol == null) {
+ throw new ApplicationBusinessException(_("tutti.service.psionimport.error.no.protocol"));
+ }
+
+ List<Species> allReferentSpecies = persistenceService.getAllReferentSpecies();
+ List<Species> allSpeciesWithSurveyCode = persistenceService.getReferentSpeciesWithSurveyCode(
+ allReferentSpecies);
+
+ Map<String, Species> speciesBySurveyCode = Maps.newTreeMap();
+ for (Species species : allSpeciesWithSurveyCode) {
if (species.getSurveyCode() != null) {
speciesBySurveyCode.put(species.getSurveyCode(), species);
}
}
+ Map<String, SpeciesProtocol> speciesProtocolBySurveyCode = Maps.newTreeMap();
- speciesProtocolBySurveyCode = Maps.newTreeMap();
-
- TuttiProtocol protocol = dataContext.getProtocol();
-
- if (protocol == null) {
- // not possible
- //FIXME Deal with error
- throw new IllegalStateException("Can't open psionImportService without a protocol");
- }
-
- List<SpeciesProtocol> speciesProtocols = protocol.getSpecies();
- for (SpeciesProtocol speciesProtocol : speciesProtocols) {
+ for (SpeciesProtocol speciesProtocol : protocol.getSpecies()) {
if (speciesProtocol.getSpeciesSurveyCode() == null) {
continue;
}
speciesProtocolBySurveyCode.put(speciesProtocol.getSpeciesSurveyCode(), speciesProtocol);
}
- }
- public PsionImportResult importFile(File psionFile, FishingOperation operation, CatchBatch catchBatch) {
+ BatchContainer<SpeciesBatch> rootSpeciesBatch =
+ persistenceService.getRootSpeciesBatch(operation.getId(), null);
- Preconditions.checkNotNull(psionFile);
- Preconditions.checkArgument(psionFile.exists(), "Psion file " + psionFile + " does not exist.");
+ Set<Species> alreadyUsedSpecies = Sets.newHashSet();
+ for (SpeciesBatch speciesBatch : rootSpeciesBatch.getChildren()) {
+ alreadyUsedSpecies.add(speciesBatch.getSpecies());
+ }
// load model
- PsionImportModel importModel;
+ PsionImportModel importModel = new PsionImportModel();
try {
- importModel = readImportFile(psionFile);
+ readImportFile(importModel,
+ psionFile,
+ operation,
+ speciesBySurveyCode,
+ speciesProtocolBySurveyCode,
+ alreadyUsedSpecies);
} catch (IOException e) {
- throw new ApplicationBusinessException(e.getMessage(), e.getCause());
+ importModel.addError(e.getMessage());
}
- // import in database
- PsionImportResult result = persist(psionFile, importModel, operation, catchBatch);
+ PsionImportResult result = new PsionImportResult(psionFile, importModel.getErrors());
+ if (importModel.withErrors()) {
+ if (log.isWarnEnabled()) {
+ log.warn("Won't import psion file, errors detected.");
+ }
+ } else {
+ // persist in db
+ persist(result, importModel, operation, catchBatch);
+ }
+
return result;
}
- protected PsionImportModel readImportFile(File arpFile) throws IOException {
+ protected void readImportFile(PsionImportModel importModel,
+ File importFile,
+ FishingOperation operation,
+ Map<String, Species> speciesBySurveyCode,
+ Map<String, SpeciesProtocol> speciesProtocolBySurveyCode,
+ Set<Species> alreadyUsedSpecies) throws IOException {
- TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
+ BufferedReader reader = Files.newReader(importFile, Charsets.UTF_8);
- PsionImportModel importModel = new PsionImportModel();
+ try {
- BufferedReader reader = Files.newReader(arpFile, Charsets.UTF_8);
+ reader.readLine(); // initiales saisisseurs
+ String operationCode = reader.readLine(); // Id du trait
+ String operationDateStr = reader.readLine(); // Date du trait
- try {
- PsionImportBatchModel batch = null;
+ Date operationDate;
+ try {
+ operationDate = df.parse(operationDateStr);
+ } catch (ParseException e) {
- // first line, don't care
- String line;
+ throw new IOException(_("tutti.service.psionimport.error.invalid.date.format"));
+ }
- line = reader.readLine(); // initiales saisisseurs
- line = reader.readLine(); // Id du trait
- line = reader.readLine(); // Date du trait
- line = reader.readLine(); // Heure de création du fichier
- line = reader.readLine(); // Ligne blanche
+ boolean correctOperation = ObjectUtils.equals(operationCode, operation.getStationNumber()) &&
+ ObjectUtils.equals(operationDate, operation.getGearShootingStartDate());
- int lineNumber = 6;
+ if (!correctOperation) {
+ throw new IOException(_("tutti.service.psionimport.error.invalid.operation"));
+ }
+ reader.readLine(); // Heure de création du fichier
+ reader.readLine(); // Ligne blanche
+
+ int lineNumber = 5;
+
+ PsionImportBatchModel batch = null;
+
+ String line;
String badSpecies = null;
while ((line = reader.readLine()) != null) {
lineNumber++;
if (!line.contains(":")) {
- throw new IOException(
- "Format de la ligne (" +
- lineNumber + ") incorrecte : " + line);
+ throw new IOException(_("tutti.service.psionimport.error.invalid.line.syntax", lineNumber, line));
}
int endIndex = line.indexOf(':');
String commandStr = StringUtils.trim(line.substring(0, endIndex));
@@ -250,18 +302,9 @@
try {
command = PsionImportKeyword.valueOf(commandStr);
} catch (IllegalArgumentException e) {
- throw new IOException(
- "La commande " + commandStr + " n'est pas connue ligne (" +
- lineNumber + ") ");
+ throw new IOException(_("tutti.service.psionimport.error.invalid.command.syntax", commandStr, lineNumber));
}
- if (command.isIgnored()) {
- if (log.isWarnEnabled()) {
- log.warn("Ignoring command: " + command);
- }
- continue;
- }
-
String value = StringUtils.trim(line.substring(endIndex + 1));
if (PsionImportKeyword.ESPE.equals(command)) {
@@ -270,7 +313,7 @@
// register previous batch
if (batch != null) {
- addBatchToModel(importModel, batch);
+ importModel.addBatch(batch);
}
Species species = speciesBySurveyCode.get(value);
@@ -278,11 +321,26 @@
if (species == null) {
// could not load this species
+ badSpecies = value;
+ batch = null;
+ String error = _("tutti.service.psionimport.error.species.not.found", lineNumber, value);
if (log.isWarnEnabled()) {
- log.warn("Ligne " + lineNumber + " espèce " + value + " inconnue.");
+ log.warn(error);
}
+ importModel.addError(error);
+ continue;
+ }
+
+ if (alreadyUsedSpecies.contains(species)) {
+
+ // can't use an already used species
badSpecies = value;
- importModel.addIgnoredSpecies(badSpecies);
+ batch = null;
+ String error = _("tutti.service.psionimport.error.species.already.used", lineNumber, value);
+ if (log.isWarnEnabled()) {
+ log.warn(error);
+ }
+ importModel.addError(error);
continue;
}
@@ -293,11 +351,13 @@
String lengthStepCaracteristicId = speciesProtocol.getLengthStepPmfmId();
if (StringUtils.isBlank(lengthStepCaracteristicId)) {
+ badSpecies = value;
+ batch = null;
+ String error = _("tutti.service.psionimport.error.no.lengthClass.caracteristic", lineNumber, value);
if (log.isWarnEnabled()) {
- log.warn("Ligne " + lineNumber + " espèce " + value + " ignorée car pas de caractéristique de classe de taille renseignée dans le protocole.");
+ log.warn(error);
}
- badSpecies = value;
- importModel.addIgnoredSpecies(badSpecies);
+ importModel.addError(error);
continue;
}
batch = new PsionImportBatchModel(species, Integer.valueOf(lengthStepCaracteristicId));
@@ -315,8 +375,7 @@
// check batch exists
if (batch == null) {
throw new IOException(
- "La ligne " + line + " (" + lineNumber +
- ") n'est pas valide, elle doit être précédée par une ligne ESPE");
+ _("tutti.service.psionimport.error.invalid.firstLine", line, lineNumber));
}
switch (command) {
@@ -336,54 +395,63 @@
case CATE:
// add category
- Integer caracteristicId;
- CaracteristicQualitativeValue caracteristicQualitativeValue;
+ if (StringUtils.isBlank(value)) {
+ badSpecies = batch.getSpecies().getSurveyCode();
+ batch = null;
+ String error = _("tutti.service.psionimport.error.invalid.category.syntax", lineNumber, value, badSpecies);
- if (SEX_VALUES.contains(value)) {
+ if (log.isWarnEnabled()) {
+ log.warn(error);
+ }
+ importModel.addError(error);
+ continue;
+ }
- // sex caracteristic
- caracteristicId = enumerationFile.PMFM_ID_SEX;
+ if ("N".equals(value)) {
- caracteristicQualitativeValue = sexCaracteristicValues.get(value);
+ // special case, no category
- if (caracteristicQualitativeValue == null) {
+ } else {
- //means non sexé
- caracteristicId = null;
- }
+ // guess all categories
- } else if (MATURITY_VALUES.contains(value)) {
+ for (int i = 0, nbCategory = value.length(); i < nbCategory; i++) {
+ String categoryCode = value.substring(i, i + 1);
- // maturity caracteristic
- caracteristicId = enumerationFile.PMFM_ID_MATURITY;
- caracteristicQualitativeValue = maturityCaracteristicValues.get(value);
+ PsionImportBatchModel.SampleCategory category = guessCategory(categoryCode);
- } else {
+ if (category == null) {
+ badSpecies = batch.getSpecies().getSurveyCode();
+ batch = null;
+ String error = _("tutti.service.psionimport.error.invalid.category.syntax", lineNumber, categoryCode, badSpecies);
+ if (log.isWarnEnabled()) {
+ log.warn(error);
+ }
+ importModel.addError(
+ error
+ );
+ break;
+ }
- if (log.isWarnEnabled()) {
- log.warn("Ligne " + lineNumber + ", catégorisation '" + value + "' inconnue, espèce " + batch.getSpecies().getSurveyCode() + " ignorée");
+ batch.setCategory(category.getCategoryId(), category.getCategoryValue());
}
- badSpecies = batch.getSpecies().getSurveyCode();
- importModel.addIgnoredSpecies(badSpecies);
- batch = null;
- continue;
-// throw new IOException(
-// "Ligne " + lineNumber + ", catégorisation '" + value + "' inconnue");
+ if (batch == null) {
+
+ // at least one category was not ok
+ continue;
+ }
}
- batch.setCategory(caracteristicId, caracteristicQualitativeValue);
+ batch.setCategoryCode(value);
+
break;
case LONG:
// add frequency
Float size = toFloat(value, lineNumber);
- batch.addFrequency(size);
+ batch.addFrequency(size, 1);
break;
-
- case OUTI:
- // ignore it
- break;
}
}
}
@@ -391,32 +459,24 @@
if (batch != null) {
// save it
- addBatchToModel(importModel, batch);
+ importModel.addBatch(batch);
}
reader.close();
- return importModel;
} finally {
IOUtils.closeQuietly(reader);
}
}
- protected PsionImportResult persist(File arpFile,
- PsionImportModel importModel,
- FishingOperation operation,
- CatchBatch catchBatch) {
- PsionImportResult result = new PsionImportResult(arpFile);
+ protected void persist(PsionImportResult result,
+ PsionImportModel importModel,
+ FishingOperation operation,
+ CatchBatch catchBatch) {
if (catchBatch != null) {
- addFileAsAttachment(arpFile, catchBatch);
+ addFileAsAttachment(result.getImportFile(), catchBatch);
}
- // delete all species batches
- BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
- for (SpeciesBatch batch : rootSpeciesBatch.getChildren()) {
- persistenceService.deleteSpeciesBatch(batch.getId());
- }
-
// insert all imported species batches
TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
@@ -425,10 +485,9 @@
for (Species specy : species) {
- //FIXME Make sure this does work well with a none sex batch...
List<PsionImportBatchModel> batchs = importModel.getBatchs(specy);
- if (batchs.size() == 1 && batchs.get(0).getCategoryId() == null) {
+ if (batchs.size() == 1 && !batchs.get(0).withCategories()) {
PsionImportBatchModel batchModel = batchs.get(0);
@@ -436,10 +495,9 @@
SpeciesBatch batch = createSpeciesBatch(operation,
batchModel.getSpecies(),
batchModel.getWeight(),
+ batchModel.getSampleWeight(),
enumerationFile.PMFM_ID_SORTED_UNSORTED,
sortedCaracteristic);
- //FIXME Check this is ok.
- batch.setWeight(batchModel.getSampleWeight());
batch = persistenceService.createSpeciesBatch(batch, null);
@@ -449,37 +507,109 @@
// batch with categories
- SpeciesBatch batch = createSpeciesBatch(operation,
- specy,
- null,
- enumerationFile.PMFM_ID_SORTED_UNSORTED,
- sortedCaracteristic);
+ SpeciesBatch rootBatch = createSpeciesBatch(operation,
+ specy,
+ null,
+ null,
+ enumerationFile.PMFM_ID_SORTED_UNSORTED,
+ sortedCaracteristic);
- batch = persistenceService.createSpeciesBatch(batch, null);
+ rootBatch = persistenceService.createSpeciesBatch(rootBatch, null);
+
for (PsionImportBatchModel batchModel : batchs) {
- SpeciesBatch childBatch = createSpeciesBatch(operation,
- batchModel.getSpecies(),
- batchModel.getWeight(),
- batchModel.getCategoryId(),
- batchModel.getCategoryValue());
- //FIXME Check this is ok.
- childBatch.setWeight(batchModel.getSampleWeight());
+ SpeciesBatch parentBatch = rootBatch;
- childBatch = persistenceService.createSpeciesBatch(childBatch, batch.getId());
+ SpeciesBatch childBatch = null;
+ Iterator<PsionImportBatchModel.SampleCategory> categoryIterator = batchModel.getCategoryIterator();
+
+ while (categoryIterator.hasNext()) {
+ PsionImportBatchModel.SampleCategory sampleCategory = categoryIterator.next();
+
+ boolean lastCategory = !categoryIterator.hasNext();
+
+ Integer categoryId = sampleCategory.getCategoryId();
+ Serializable categoryValue = sampleCategory.getCategoryValue();
+
+ if (lastCategory) {
+
+ // always create the leaf
+ childBatch = createSpeciesBatch(operation,
+ specy,
+ batchModel.getWeight(),
+ batchModel.getSampleWeight(),
+ categoryId,
+ categoryValue);
+ } else {
+
+ // try to find child in parent children
+
+ childBatch = null;
+ for (SpeciesBatch speciesBatch : parentBatch.getChildBatchs()) {
+
+ if (speciesBatch.getSampleCategoryId().equals(categoryId) &&
+ speciesBatch.getSampleCategoryValue().equals(categoryValue)) {
+ childBatch = speciesBatch;
+ break;
+ }
+ }
+
+ if (childBatch == null) {
+
+ // must create it
+ childBatch = createSpeciesBatch(operation,
+ specy,
+ null,
+ null,
+ categoryId,
+ categoryValue);
+ }
+ }
+
+ if (TuttiEntities.isNew(childBatch)) {
+
+ // persist it
+ childBatch = persistenceService.createSpeciesBatch(childBatch, parentBatch.getId());
+ parentBatch.addChildBatchs(childBatch);
+ }
+
+ parentBatch = childBatch;
+ }
+
persistFrequencies(childBatch, batchModel);
}
}
result.incrementNbImported();
}
- for (String ignoredSpecies : importModel.getIgnoredSpecies()) {
- result.incrementNbNotImported();
- }
persistenceService.saveCatchBatch(catchBatch);
+ }
+ protected PsionImportBatchModel.SampleCategory guessCategory(String categoryCode) {
+
+ PsionImportBatchModel.SampleCategory result = null;
+
+ Integer caracteristicId;
+ CaracteristicQualitativeValue caracteristicQualitativeValue;
+
+ if (SEX_VALUES.contains(categoryCode)) {
+
+ // sex caracteristic
+ caracteristicId = enumerationFile.PMFM_ID_SEX;
+ caracteristicQualitativeValue = sexCaracteristicValues.get(categoryCode);
+
+ result = new PsionImportBatchModel.SampleCategory(caracteristicId, caracteristicQualitativeValue);
+
+ } else if (MATURITY_VALUES.contains(categoryCode)) {
+
+ // maturity caracteristic
+ caracteristicId = enumerationFile.PMFM_ID_MATURITY;
+ caracteristicQualitativeValue = maturityCaracteristicValues.get(categoryCode);
+
+ result = new PsionImportBatchModel.SampleCategory(caracteristicId, caracteristicQualitativeValue);
+ }
return result;
}
@@ -506,19 +636,10 @@
persistenceService.saveSpeciesBatchFrequency(batch.getId(), toSave);
}
- protected void addBatchToModel(PsionImportModel importModel,
- PsionImportBatchModel batch) throws IOException {
-
- if (log.isInfoEnabled()) {
- log.info("Adding for species " + batch.getSpecies().getSurveyCode() + ", " +
- batch.getNbFrequencies() + " batchs.");
- }
- importModel.addBatch(batch);
- }
-
protected SpeciesBatch createSpeciesBatch(FishingOperation operation,
Species species,
Float catchWeight,
+ Float sampleWeight,
Integer categoryId,
Serializable cqv) {
SpeciesBatch batch = SpeciesBatchs.newSpeciesBatch();
@@ -526,8 +647,11 @@
batch.setSampleCategoryId(categoryId);
batch.setSampleCategoryValue(cqv);
batch.setSpecies(species);
- batch.setSampleCategoryWeight(
- catchWeight == null ? null : TuttiEntities.roundKiloGram(catchWeight));
+ batch.setSampleCategoryWeight(catchWeight == null ? null : TuttiEntities.roundKiloGram(catchWeight));
+ //FIXME Check this is ok.
+ batch.setWeight(sampleWeight == null ? null : TuttiEntities.roundKiloGram(sampleWeight));
+
+ batch.setChildBatchs(Lists.<SpeciesBatch>newArrayList());
return batch;
}
@@ -537,7 +661,7 @@
attachment.setObjectId(Integer.valueOf(catchBatch.getId()));
attachment.setName(f.getName());
String date = DateFormat.getDateTimeInstance().format(context.currentDate());
- String comment = _("tutti.service.arp.import.attachment.comment", date);
+ String comment = _("tutti.service.psion.import.attachment.comment", date);
attachment.setComment(comment);
persistenceService.createAttachment(attachment, f);
}
@@ -557,43 +681,4 @@
}
return result;
}
-
- /**
- * All usables keywords in a psion import.
- * <p/>
- * Created on 1/20/14.
- *
- * @author Tony Chemit <chemit(a)codelutin.com>
- * @since 3.0.1
- */
- public static enum PsionImportKeyword {
-
- ESPE(false),
- POID(false),
- TAIL(false),
- CATE(false),
- LONG(false),
-
- // ignored
- HEUR(true),
- AGEN(true),
- CAIS(true),
- TAXO(true),
- OUTI(true),
- PORT(true),
- DATE(true),
- HERE(true),
- NAVI(true),
- ENGI(true);
-
- private final boolean ignored;
-
- PsionImportKeyword(boolean ignored) {
- this.ignored = ignored;
- }
-
- public boolean isIgnored() {
- return ignored;
- }
- }
}
Modified: trunk/tutti-service/src/main/resources/i18n/tutti-service_en_GB.properties
===================================================================
--- trunk/tutti-service/src/main/resources/i18n/tutti-service_en_GB.properties 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/resources/i18n/tutti-service_en_GB.properties 2014-01-21 16:29:59 UTC (rev 1519)
@@ -43,6 +43,7 @@
tutti.report.step.export.fishingOperation=
tutti.report.step.generateReport=
tutti.report.step.load.fishingOperation=
+tutti.service.arp.import.attachment.comment=
tutti.service.compressZipFile.error=
tutti.service.context.serviceInstanciation.error=
tutti.service.csv.parse.entityNotFound=
@@ -144,6 +145,17 @@
tutti.service.protocol.import.benthos.error=
tutti.service.protocol.import.species.error=
tutti.service.protocol.import.taxonUsed.error=
+tutti.service.psion.import.attachment.comment=
+tutti.service.psionimport.error.invalid.category.syntax=
+tutti.service.psionimport.error.invalid.command.syntax=
+tutti.service.psionimport.error.invalid.date.format=
+tutti.service.psionimport.error.invalid.firstLine=
+tutti.service.psionimport.error.invalid.line.syntax=
+tutti.service.psionimport.error.invalid.operation=
+tutti.service.psionimport.error.no.lengthClass.caracteristic=
+tutti.service.psionimport.error.no.protocol=
+tutti.service.psionimport.error.species.already.used=
+tutti.service.psionimport.error.species.not.found=
tutti.service.pupitri.export.species.error=
tutti.service.pupitri.import.attachment.comment=
tutti.service.pupitri.import.carrousel.error=
Modified: trunk/tutti-service/src/main/resources/i18n/tutti-service_fr_FR.properties
===================================================================
--- trunk/tutti-service/src/main/resources/i18n/tutti-service_fr_FR.properties 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/main/resources/i18n/tutti-service_fr_FR.properties 2014-01-21 16:29:59 UTC (rev 1519)
@@ -144,6 +144,17 @@
tutti.service.protocol.import.benthos.error=Erreur lors de l'import du benthos du protocole %1s du fichier %2s
tutti.service.protocol.import.species.error=Erreur lors de l'import des espèces du protocole %1s du fichier %2s
tutti.service.protocol.import.taxonUsed.error=Le taxon référent d'id %s est déjà utilisé
+tutti.service.psion.import.attachment.comment=Import Psion du %s
+tutti.service.psionimport.error.invalid.category.syntax=Ligne %s, catégorisation '%s' inconnue, l'espèce %s sera ignorée
+tutti.service.psionimport.error.invalid.command.syntax=Ligne %s, la commande '%s' n'est pas reconnue
+tutti.service.psionimport.error.invalid.date.format=Format de la date du trait incorrecte (mm-dd-aaaa)
+tutti.service.psionimport.error.invalid.firstLine=La ligne %s (%s) n'est pas valide, elle doit être précédée par une ligne ESPE
+tutti.service.psionimport.error.invalid.line.syntax=Ligne %s, format incorrecte (%s)
+tutti.service.psionimport.error.invalid.operation=Code station ou date du trait incorrect
+tutti.service.psionimport.error.no.lengthClass.caracteristic=Ligne %s espèce '%s' ignorée car pas de caractéristique de classe de taille renseignée dans le protocole.
+tutti.service.psionimport.error.no.protocol=Impossible de faire un import Psion sans protocol.
+tutti.service.psionimport.error.species.already.used="Ligne %s, espèce '%s' déjà utilisée
+tutti.service.psionimport.error.species.not.found=Ligne %s, espèce '%s' inconnue
tutti.service.pupitri.export.species.error=Erreur lors de l'export des espèces pour Pupitri dans le fichier %s
tutti.service.pupitri.import.attachment.comment=Import Pupitri du %s
tutti.service.pupitri.import.carrousel.error=Erreur lors de l'import du fichier de carrousel %2s pour le trait %1s
Modified: trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java
===================================================================
--- trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -42,6 +42,7 @@
import java.io.File;
import java.io.IOException;
+import java.util.List;
/**
* Created on 1/19/14.
@@ -85,9 +86,9 @@
TuttiServiceContext serviceContext = dbResource.getServiceContext();
- File protocol = dbResource.copyClassPathResource("pupitri/ano-3898.tuttiProtocol", "ano-3898.tuttiProtocol");
+ File protocol = dbResource.copyClassPathResource("psion/protocol.tuttiProtocol", "protocol.tuttiProtocol");
dbResource.getConfig().getApplicationConfig().setOption(TuttiConfigurationOption.DB_PROTOCOL_DIRECTORY.getKey(), protocol.getParentFile().getAbsolutePath());
- serviceContext.getDataContext().setProtocolId("ano-3898");
+ serviceContext.getDataContext().setProtocolId("protocol");
dbResource.openDataContext();
@@ -103,86 +104,88 @@
@Test
public void importCC053() throws IOException {
- File trunk = dbResource.copyClassPathResource("psion/CC053.IWA", "CC053.IWA");
+ File importFile = dbResource.copyClassPathResource("psion/CC053.IWA", "CC053.IWA");
FishingOperation operation = dataContext.operations.get(1);
CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
catchBatch.setFishingOperation(operation);
BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
-// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
- PsionImportResult arpImportResult = service.importFile(trunk, operation, catchBatch);
+ int oldNbBatchs = rootSpeciesBatch.sizeChildren();
- PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+ PsionImportResult importResult = service.importFile(importFile, operation, catchBatch);
int nbAdded = importResult.getNbImported();
- int nbNotAdded = importResult.getNbNotImported();
+ List<String> errors = importResult.getErrors();
if (log.isInfoEnabled()) {
log.info("Imported: " + nbAdded);
- log.info("Ignored: " + nbNotAdded);
+ log.info("Errors: " + errors.size());
}
- Assert.assertEquals(9, nbAdded);
- Assert.assertEquals(9, nbNotAdded);
+ Assert.assertEquals(17, nbAdded);
+ Assert.assertEquals(0, errors.size());
+ // no batch imported
BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
- Assert.assertEquals(9, rootSpeciesBatchAfter.sizeChildren());
+ Assert.assertEquals(oldNbBatchs + 17, rootSpeciesBatchAfter.sizeChildren());
}
@Test
public void importFM001() throws IOException {
- File trunk = dbResource.copyClassPathResource("psion/FM001.IWA", "FM001.IWA");
+ File importFile = dbResource.copyClassPathResource("psion/FM001.IWA", "FM001.IWA");
FishingOperation operation = dataContext.operations.get(1);
CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
catchBatch.setFishingOperation(operation);
BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
-// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
- PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+ int oldNbBatchs = rootSpeciesBatch.sizeChildren();
+ PsionImportResult importResult = service.importFile(importFile, operation, catchBatch);
+
int nbAdded = importResult.getNbImported();
- int nbNotAdded = importResult.getNbNotImported();
+ List<String> errors = importResult.getErrors();
if (log.isInfoEnabled()) {
log.info("Imported: " + nbAdded);
- log.info("Ignored: " + nbNotAdded);
+ log.info("Errors: " + errors.size());
}
- Assert.assertEquals(2, nbAdded);
- Assert.assertEquals(8, nbNotAdded);
+ Assert.assertEquals(10, nbAdded);
+ Assert.assertEquals(0, errors.size());
BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
- Assert.assertEquals(2, rootSpeciesBatchAfter.sizeChildren());
+ Assert.assertEquals(oldNbBatchs + 10, rootSpeciesBatchAfter.sizeChildren());
}
@Test
public void importCFchephren() throws IOException {
- File trunk = dbResource.copyClassPathResource("psion/CFchephren 110612.IWA", "CFchephren 110612.IWA");
+ File importFile = dbResource.copyClassPathResource("psion/CFchephren 110612.IWA", "CFchephren 110612.IWA");
FishingOperation operation = dataContext.operations.get(1);
CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
catchBatch.setFishingOperation(operation);
BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
-// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
- PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+ int oldNbBatchs = rootSpeciesBatch.sizeChildren();
+ PsionImportResult importResult = service.importFile(importFile, operation, catchBatch);
int nbAdded = importResult.getNbImported();
- int nbNotAdded = importResult.getNbNotImported();
+ List<String> errors = importResult.getErrors();
if (log.isInfoEnabled()) {
log.info("Imported: " + nbAdded);
- log.info("Ignored: " + nbNotAdded);
+ log.info("Errors: " + errors.size());
}
Assert.assertEquals(0, nbAdded);
- Assert.assertEquals(1, nbNotAdded);
+ Assert.assertEquals(1, errors.size());
+ // no batch imported
BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
- Assert.assertEquals(0, rootSpeciesBatchAfter.sizeChildren());
+ Assert.assertEquals(oldNbBatchs, rootSpeciesBatchAfter.sizeChildren());
}
}
Modified: trunk/tutti-service/src/test/resources/psion/CC053.IWA
===================================================================
--- trunk/tutti-service/src/test/resources/psion/CC053.IWA 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/test/resources/psion/CC053.IWA 2014-01-21 16:29:59 UTC (rev 1519)
@@ -1,6 +1,6 @@
cc
-053
-06-13-2013
+A
+07-01-2013
07:19:11
ESPE : MERLMER
@@ -346,11 +346,6 @@
LONG : 15
LONG : 14
LONG : 11.5
-ESPE : SQUIMAN
-POID : 37
-TAIL : 37
-CATE : N
-LONG : 27
ESPE : OCTOVUL
POID : 11600
TAIL : 11600
Modified: trunk/tutti-service/src/test/resources/psion/FM001.IWA
===================================================================
--- trunk/tutti-service/src/test/resources/psion/FM001.IWA 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-service/src/test/resources/psion/FM001.IWA 2014-01-21 16:29:59 UTC (rev 1519)
@@ -1,6 +1,6 @@
fm
-001
-05-24-2013
+A
+07-01-2013
18:28:13
ESPE : HELIDAC
@@ -20,8 +20,18 @@
ESPE : RAJAOXY
POID : 115
TAIL : 115
+CATE : M
+LONG : 34
+ESPE : RAJAOXY
+POID : 115
+TAIL : 115
CATE : F1
LONG : 35
+ESPE : RAJAOXY
+POID : 115
+TAIL : 115
+CATE : F2
+LONG : 36
ESPE : PHYIBLE
POID : 235
TAIL : 235
Added: trunk/tutti-service/src/test/resources/psion/protocol.tuttiProtocol
===================================================================
--- trunk/tutti-service/src/test/resources/psion/protocol.tuttiProtocol (rev 0)
+++ trunk/tutti-service/src/test/resources/psion/protocol.tuttiProtocol 2014-01-21 16:29:59 UTC (rev 1519)
@@ -0,0 +1,2427 @@
+id: 7a959cb1-2bf0-4876-8e20-ba0021c27835
+name: Protocole MEDITS
+benthos:
+- !SpeciesProtocol
+ id: e48d74a1-3ed9-4063-b970-fa95601ce813
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 907
+ speciesSurveyCode: ALPHGLA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: bedf43f2-1ba4-404e-ada2-cdd5c66e67b3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 886
+ speciesSurveyCode: CHLOGRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 99d3c435-ce9e-48f2-a2e5-de1e30af1c05
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 931
+ speciesSurveyCode: CRANSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6b2491d8-d237-489c-b98a-460594276fec
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 990
+ speciesSurveyCode: DARDSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cab84c60-0637-49b8-880e-74bf53fe8de8
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1140
+ speciesSurveyCode: DORILAN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ce1dc3a2-912b-439b-8930-83c6bb5a9112
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1012
+ speciesSurveyCode: GALADIS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ddfe6e29-03e4-4387-b052-a698f5087bf2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1013
+ speciesSurveyCode: GALAINT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fe7f5f8d-bfac-4ae9-8e9e-3abed1c6aa1e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1014
+ speciesSurveyCode: GALANEX
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 03fd6fe9-9e9b-409e-96bf-57caa9e9419a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1103
+ speciesSurveyCode: GONERHO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fb000dfa-157d-42d8-affe-3585b21addb0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 951
+ speciesSurveyCode: HOMAVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6e3a1545-86ff-41f7-ab1a-892c60e12a55
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1029
+ speciesSurveyCode: HOMOBAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6c61c141-d7de-4201-8291-53bfd17f856f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1129
+ speciesSurveyCode: INACSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6f594c41-c44a-4d26-a76a-a54ec9368862
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1136
+ speciesSurveyCode: MACRSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 50e66761-7754-4c68-bd89-b2a4a8749421
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1111
+ speciesSurveyCode: MAJASQU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c4fc0b86-0848-49b1-b150-8f2bf4ca2034
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1067
+ speciesSurveyCode: MCPIDEP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 242174d3-8ca9-4cf9-b8b9-21316ffa5a93
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1066
+ speciesSurveyCode: MCPITUB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a3915c98-71ec-4561-8673-95933e8edf70
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1075
+ speciesSurveyCode: MCPIVER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ac3f2c25-fc67-4820-95a2-1de26faf840c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1015
+ speciesSurveyCode: MUNISPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 83bf86a4-810d-4c9b-8dcb-37c66735b33c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 999
+ speciesSurveyCode: PAGUEXC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2c53f5e8-688b-4766-8b22-d62d92109f8a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 994
+ speciesSurveyCode: PAGUPRI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: baafb7ef-164c-4b98-975c-28c518a7315a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 997
+ speciesSurveyCode: PAGUSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e26e4708-50e8-4947-b395-18dbd51e25fb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 885
+ speciesSurveyCode: PAPANAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c4b0705b-5657-480e-ad6b-4d6327de8073
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1028
+ speciesSurveyCode: PAROCUV
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 33b8eb55-932c-488a-8de9-d4696a485c21
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 868
+ speciesSurveyCode: PASISIV
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2e4c871c-d943-4dff-8d8d-a23bf39f8482
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 866
+ speciesSurveyCode: PASISPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 423733e0-43c8-48ef-b6b9-b0077b8a03ae
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 880
+ speciesSurveyCode: PLESACA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2cc65b6e-4f4d-4757-aa89-40dd52f13f3c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 881
+ speciesSurveyCode: PLESANT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 99805344-1325-4139-b3dd-f6e4690b5316
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 7185
+ speciesSurveyCode: PLESEDW
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6aa66a07-fcd1-4fdf-aec9-29ce15c595f9
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 882
+ speciesSurveyCode: PLESGIG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fe2af1be-2d65-4658-b587-49f22d4b939f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 883
+ speciesSurveyCode: PLESHET
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5fde324e-f7a1-4516-9190-7eaf2239c69b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 884
+ speciesSurveyCode: PLESMAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8a8129f5-f66a-4057-8282-6c6287e80629
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 879
+ speciesSurveyCode: PLESSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ff17d20e-bfa6-4752-8c52-5614a4d0ae3e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 953
+ speciesSurveyCode: POLCTYP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5b3ccbb3-2f1a-4b55-b5b3-69a0559edbb9
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 935
+ speciesSurveyCode: PONPNOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ebc7e293-3dd4-4d9a-b314-fdc7b0a23d89
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 934
+ speciesSurveyCode: PONPSPI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 95fa55c4-f2f3-451f-ae27-3f520e43af38
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 928
+ speciesSurveyCode: PONTCAT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fa1a37a0-3623-47be-aaa4-4b6c725b8b1d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 929
+ speciesSurveyCode: PONTLAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d9a9967d-f191-4e6e-9a5c-a5dea4b8b774
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 10607
+ speciesSurveyCode: PROCEDU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: bbf63159-be69-444d-a004-66a13a63088b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 915
+ speciesSurveyCode: PROCSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 489084e7-7442-4ade-b356-cacb09e0ed3f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 858
+ speciesSurveyCode: SOLOMEM
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c0ed971f-8a60-4ddc-888a-866483167241
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 715
+ speciesSurveyCode: SCALSCA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1e9007ee-a31d-451f-9ad2-f6de5048f4cb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 837
+ speciesSurveyCode: EUPHSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1a27e40d-2660-4e47-badd-0df6cb48efc1
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 831
+ speciesSurveyCode: SQUIMAN
+ lengthStepPmfmId: 1417
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 04601e60-e556-428c-8aec-2beb1d8a5784
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 353
+ speciesSurveyCode: ATRIFRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 4a296117-cfea-41fa-ba1d-9ddee2480957
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 379
+ speciesSurveyCode: CARDACU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e16a2e50-fc6f-4255-897f-337286659f38
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 378
+ speciesSurveyCode: CARDECH
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a70dcb6b-6dc1-48f3-b95c-d47b933ff50a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 382
+ speciesSurveyCode: CARDSPI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a2c6201f-12f1-432a-b4a5-d5fa8b44e860
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 362
+ speciesSurveyCode: PECTSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fcba0a99-625d-4854-9305-da4a346dbcc9
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 261
+ speciesSurveyCode: APORPES
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 90fca18f-1277-4de4-8ee2-50711a0fed72
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 262
+ speciesSurveyCode: APORSER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 84b81e6a-3b65-485d-9bca-f37ef670709f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 305
+ speciesSurveyCode: BUCCSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e8c86081-2b02-4e6b-a82b-c28b2d3422fd
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 280
+ speciesSurveyCode: CASSECH
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c43a3c68-95e0-405b-87c4-9c8313ef68a4
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 281
+ speciesSurveyCode: CASSTYR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b7aedc06-1d73-4a11-8369-c71f5d244f37
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2451
+ speciesSurveyCode: GIBBSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: dd2dfe21-db6d-4a42-a480-610051e55f4a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3928
+ speciesSurveyCode: MUREBRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 37db060c-6c26-46f2-bce3-44cfb88f4c2c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 292
+ speciesSurveyCode: MURETRU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d15aee86-46a1-4b67-9228-75ca54cbd4e2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 318
+ speciesSurveyCode: SCAPNIG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3fe5fc8e-0cc7-43cb-a9a6-16c7875a1011
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1189
+ speciesSurveyCode: MICOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ca52cdab-2b66-4d37-8af8-b81529aa8d52
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1191
+ speciesSurveyCode: MICOVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6ac82f3b-a242-4923-92ad-5eee494c0861
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 224
+ speciesSurveyCode: MBBRYOZ
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 13b65cd0-a23c-47e0-a92c-30b68f2edde5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3671
+ speciesSurveyCode: GRYPVIT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 547f9754-999d-46c6-853e-83bb687604be
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 4626
+ speciesSurveyCode: ADAMCAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a353ed3f-76e8-4c26-a270-17f06b539e14
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 133
+ speciesSurveyCode: ALCYPAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c1023085-ad82-46a7-aef8-7bb04c5ef860
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3037
+ speciesSurveyCode: ALCYSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 50328180-2c0b-410b-bd0f-875957542e42
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 6758
+ speciesSurveyCode: FMVERET
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3b787133-a724-411e-a625-8baf34542b7a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 6804
+ speciesSurveyCode: FUNIQUA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d0cc902e-ad69-46e8-9448-c70b3f343d6f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2224
+ speciesSurveyCode: ORACTIN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f66c8ecd-afdf-4227-b10a-9ec3a34cb87c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 7390
+ speciesSurveyCode: ANTESPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 10d40446-c9e5-4822-9de5-4b746c24977c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 11181
+ speciesSurveyCode: ASTRIRR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3754b3ad-1723-4f42-a746-7a320da08171
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 11943
+ speciesSurveyCode: ASTRSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 78d430ba-4d36-42e5-bb53-0a03a3f4ac6a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 6812
+ speciesSurveyCode: CIDACID
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a28fbcad-63b7-4f7f-8d22-b26a3aafbd49
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1151
+ speciesSurveyCode: CLOPHIU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9d5fc95c-52cc-4e29-a901-a832db1ad7f3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 4235
+ speciesSurveyCode: ECHNACU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 14271e01-b001-427d-b14a-d65667dd47b5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3397
+ speciesSurveyCode: HOLOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b3b6e938-7f0d-46eb-9cfb-3b7d48dc6919
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 4240
+ speciesSurveyCode: LEPRSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 24b681d8-981c-4257-b8e2-680e66bce967
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1155
+ speciesSurveyCode: OPHUOPH
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ec4f46f8-6c1d-42a7-85bf-953694f97218
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1177
+ speciesSurveyCode: STICREG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c9e18e97-92fa-4c87-b032-dd2efc434ab3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 395
+ speciesSurveyCode: SPISSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a88de136-eac9-4cca-b22c-5f7ca1d14da9
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 246
+ speciesSurveyCode: CANIGRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 55b686b8-6249-408d-b303-77c58e1cff48
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 245
+ speciesSurveyCode: CANIZIZ
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 667f6b5c-f295-4c00-b03e-c097b5cd3aed
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 226
+ speciesSurveyCode: CLGASTE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 11c25935-9e93-49b5-b4ef-22de3aac3d0e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 12060
+ speciesSurveyCode: FMAPLYS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6fe77fe1-fafe-4846-ac80-1ec79b15ee34
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 250
+ speciesSurveyCode: TURRSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 199934f5-b6a6-46cd-bfc6-db1e81c48e40
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 4413
+ speciesSurveyCode: APLYSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 338fa494-885b-4392-8d89-bc19ee5cbfbf
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 155
+ speciesSurveyCode: APHRACU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 751705d4-25f2-4bb4-9a53-96aed1fc3d84
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 196
+ speciesSurveyCode: FMMALDA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 443aa667-4773-443a-ae48-76f80d016310
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3032
+ speciesSurveyCode: FMSABED
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 42af4c8f-fe49-4e33-a539-d4a966726530
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 209
+ speciesSurveyCode: FMSERPU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 94bec064-27cf-40c2-b746-ee1ddb0ef089
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 150
+ speciesSurveyCode: MBANNEL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: dbe23df9-1ef9-44f3-a272-7dec649b4e87
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 211
+ speciesSurveyCode: STERSCU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3c55f53b-2998-46e6-b1bf-f2761df75b29
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3668
+ speciesSurveyCode: DENTSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1f798975-e4ca-4df6-9adb-184e1ca167a4
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 147
+ speciesSurveyCode: SIPSNUD
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b0f41012-8aa8-4633-b632-8b415f721606
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 7
+ speciesSurveyCode: MBPORIF
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3df8daac-bf56-4041-8ff0-02899d7f6dca
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1182
+ speciesSurveyCode: CLASCID
+ weightEnabled: true
+gearUseFeaturePmfmId: !com.google.common.collect.Lists$TransformingRandomAccessList
+- 833
+- 828
+- 905
+- 826
+individualObservationPmfmId: !com.google.common.collect.Lists$TransformingRandomAccessList
+- 196
+- 174
+- 1435
+lengthClassesPmfmId:
+- 1417
+- 299
+- 307
+species:
+- !SpeciesProtocol
+ id: 4c712b41-ab72-4ab2-88ef-75eabbcd3f94
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 848
+ speciesSurveyCode: ARISFOL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3d9610bd-cd71-4f8c-8bd9-e0ab89e3023c
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 849
+ speciesSurveyCode: ARITANT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cdc14002-96d8-42e5-abe0-07cab51e8bc0
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 855
+ speciesSurveyCode: PAPELON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 972082e1-b1bf-4228-b8f6-19c5f040792e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 949
+ speciesSurveyCode: NEPRNOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f3149d94-a711-45b3-b9b3-1f734454a06e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 507
+ speciesSurveyCode: ILLECOI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b1da88e2-55ae-49f6-9174-4c189cc98e54
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 489
+ speciesSurveyCode: LOLIVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 0dc70454-fccc-46cf-9176-2e38cb5c5c3a
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1277
+ speciesSurveyCode: CENTGRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 4f70310c-2dd3-452f-8f44-d90feb39248e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1282
+ speciesSurveyCode: SCYMLIC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 0d57db02-07d7-4b24-85d7-b2ffffd6b255
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1275
+ speciesSurveyCode: ETMOSPI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: bd461ac9-f897-4fcd-ab23-abbf981279f1
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1254
+ speciesSurveyCode: GALEGAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1c264e2f-96f9-423b-a54b-cb5aa762b0cc
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1245
+ speciesSurveyCode: GALUMEL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6efe4eb1-e2a7-4fdb-89ad-3b2d6b47e2ec
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1222
+ speciesSurveyCode: HEPTPER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 48412543-cf57-452d-979a-4e908cdd3f4c
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1220
+ speciesSurveyCode: HEXAGRI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: baeca8b7-a1d7-4224-b3d6-022f15c6be5a
+ calcifySampleEnabled: true
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 2050
+ speciesSurveyCode: LOPHBUD
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ec5d8fb6-e26b-4e61-89d8-7c169fbe6096
+ calcifySampleEnabled: true
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 2049
+ speciesSurveyCode: LOPHPIS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 73b81c79-5117-4475-a393-ede51babfebe
+ calcifySampleEnabled: true
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1540
+ speciesSurveyCode: MERLMER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 944b5f40-f4d0-4fce-8b5d-5df2eb7ef30d
+ calcifySampleEnabled: true
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1689
+ speciesSurveyCode: MULLBAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c5174b9b-061d-46e5-9a36-259d8dbe7ebf
+ calcifySampleEnabled: true
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1690
+ speciesSurveyCode: MULLSUR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b6f62ed7-34ea-48f3-a91c-196e5be13d45
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1257
+ speciesSurveyCode: MUSTAST
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 543a37c5-1b1a-49b4-9a1e-2c0022b17b5c
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1258
+ speciesSurveyCode: MUSTMED
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1cc14725-4f35-4669-9048-0613a698a356
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1256
+ speciesSurveyCode: MUSTMUS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 310f665a-7c07-48fd-a6fd-65f5b43bd098
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1329
+ speciesSurveyCode: MYLIAQU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b83d4fd8-391a-42d5-8003-c71ecb8a9937
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1263
+ speciesSurveyCode: OXYNCEN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2ec145c1-0184-4c26-ae12-34fcd006c48b
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1312
+ speciesSurveyCode: RAJAALB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5fca8811-4586-43f8-8908-2f83ee9fa90d
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1313
+ speciesSurveyCode: RAJAAST
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d7b06817-a0d9-4b7e-aa7f-77acf6916ce1
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1306
+ speciesSurveyCode: RAJABAT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7d20d463-8c8e-4b1e-95b9-21076ab708ca
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1310
+ speciesSurveyCode: RAJACIR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 933d3b3a-b4cb-4239-896b-1f13f7ea6938
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1302
+ speciesSurveyCode: RAJACLA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 02521403-26cc-4338-98fa-c437de064538
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1314
+ speciesSurveyCode: RAJAMEL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b8cb7a32-93c9-4203-9e52-a13691528e21
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1315
+ speciesSurveyCode: RAJAMIR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: dca10109-c771-4290-adac-3220d72a15d9
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1308
+ speciesSurveyCode: RAJAOXY
+ weightEnabled: true
+- !SpeciesProtocol
+ id: eaec42f0-ca79-481c-9062-5b2787c552c4
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1316
+ speciesSurveyCode: RAJAPOL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 498f415a-bd36-4076-9dce-86015c89f678
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1318
+ speciesSurveyCode: RAJAUND
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e8269d24-6773-4b7f-88a0-de3ecafa83d6
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1292
+ speciesSurveyCode: RHINCEM
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 401bd28f-f102-4529-a535-c02cfe561424
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1293
+ speciesSurveyCode: RHINRHI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c1f9efff-260f-4855-9f5f-25cbddd76dd8
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1242
+ speciesSurveyCode: SCYOCAN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f4b01ee8-9dbc-4dfb-a597-668924690e98
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1243
+ speciesSurveyCode: SCYOSTE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3309c9a2-6e23-47a5-bf3c-83719215f6bf
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1266
+ speciesSurveyCode: SQUAACA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2c7cbd7d-d5a1-4ab8-b27d-90d561074a2a
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1267
+ speciesSurveyCode: SQUABLA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f13d6105-09e6-4485-9b23-6fa034a4a707
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1288
+ speciesSurveyCode: SQUTACU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f1fba700-1436-42b2-8be0-86781893fb29
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1289
+ speciesSurveyCode: SQUTOCL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 519bcc67-852a-4cd6-8328-cad0931e6732
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1287
+ speciesSurveyCode: SQUTSQU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 87fb8821-e053-4f5c-8940-4f5540fb85c8
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 174
+ - 196
+ speciesReferenceTaxonId: 1297
+ speciesSurveyCode: TORPMAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a744eb4d-43a7-4e7c-b51b-6c9b0c5a56d9
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 957
+ speciesSurveyCode: PALIELE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3e854d0b-7592-43be-9bf0-00152ad19cf0
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 299
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 853
+ speciesSurveyCode: PENAKER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f684a970-b662-473e-aeff-b3b25881dc42
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 514
+ speciesSurveyCode: OCTOVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 04d6c377-d267-4897-bfeb-eda10b88b082
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 522
+ speciesSurveyCode: ELEDCIR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 767b25a5-b89e-4dc7-82c3-6d7046f21e34
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 521
+ speciesSurveyCode: ELEDMOS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 52d095a6-ad24-4d03-b318-95a6b6434f89
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 467
+ speciesSurveyCode: SEPIOFF
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2d5ae016-cb48-498d-949c-bc99f84b1c9b
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 1417
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 509
+ speciesSurveyCode: TODASAG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 033ae020-e315-4b51-9f62-6408f436ec7e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1912
+ speciesSurveyCode: ASPICUC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 0a405bc2-1330-4cbb-87d2-a925a9393991
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1698
+ speciesSurveyCode: BOOPBOO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f75aa101-3ba5-4577-a2fc-f40d907dc896
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1953
+ speciesSurveyCode: CITHMAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 0f84dfac-6bed-40b8-8df6-78d2fc6f8fa9
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1700
+ speciesSurveyCode: DIPLANN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c5b257e3-8d83-4d59-8d22-ceba000efdaa
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1702
+ speciesSurveyCode: DIPLPUN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6e72e9cb-285d-455d-b943-ca68288438a6
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1703
+ speciesSurveyCode: DIPLSAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 521f937a-f6ce-44cf-a32a-5567eaf45e6a
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1704
+ speciesSurveyCode: DIPLVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c1a0bb60-ff2c-4430-9ea6-fdd80bc350dd
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1362
+ speciesSurveyCode: ENGRENC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 46b2419d-80e8-45ce-8845-1deb7c744300
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1632
+ speciesSurveyCode: EPINSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 67bca5b0-b534-41fd-a81e-969168446289
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1920
+ speciesSurveyCode: EUTRGUR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d787ebfa-c8fe-4fac-b8f5-16c2b70e462c
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1905
+ speciesSurveyCode: HELIDAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3ef4b084-2080-4e17-a8f4-eb5eae314151
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1961
+ speciesSurveyCode: LEPMBOS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d565422d-5a09-4f63-8df7-3736726d012d
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1710
+ speciesSurveyCode: LITHMOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7ab19715-e91b-4ff0-bd3d-605be8a890e6
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1553
+ speciesSurveyCode: MICMPOU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ff7b2f1b-50ae-4d8d-82ce-916ac63c60bd
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1714
+ speciesSurveyCode: PAGEACA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 0415fc50-f9ac-4ad6-a4b2-a9d2875e2a26
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1715
+ speciesSurveyCode: PAGEBOG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e0d8f887-16ff-4d44-a35a-70a35146d44b
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1713
+ speciesSurveyCode: PAGEERY
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 17e577d9-9b23-430d-b6aa-b4600378ced7
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1695
+ speciesSurveyCode: SPARPAG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d84bc931-3c2a-4819-ad4f-e007a830accc
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1573
+ speciesSurveyCode: PHYIBLE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a334e7b1-73a8-410d-a348-ed6ad81846fb
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1641
+ speciesSurveyCode: POLYAME
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cc57956b-1fa1-40a0-a913-1550c0479052
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1957
+ speciesSurveyCode: PSETMAX
+ weightEnabled: true
+- !SpeciesProtocol
+ id: aa43606f-a395-453a-9e5c-8e75320f5559
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1351
+ speciesSurveyCode: SARDPIL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 56846282-2998-455e-a3c0-5b5adca223af
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 3789
+ speciesSurveyCode: SCOMPNE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7f637203-607f-4f24-9076-9ec6f05bcd7e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1772
+ speciesSurveyCode: SCOMSCO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3969d69f-a17d-47ff-87d4-af539ae8ed45
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1996
+ speciesSurveyCode: SOLEVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 466b5b93-b472-4c8a-aa08-5bf53d90bfa0
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1723
+ speciesSurveyCode: SPICMAE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1ee6372f-c2e8-4633-8db9-36b5f487a005
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1724
+ speciesSurveyCode: SPICSMA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 933968a6-1352-474f-a408-9939ad16e5b1
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1663
+ speciesSurveyCode: TRACMED
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 69f476b0-862e-47e1-b593-2bb096616f9e
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1662
+ speciesSurveyCode: TRACTRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3ca8616b-71db-40d3-9b50-caaf2ec20b41
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1921
+ speciesSurveyCode: TRIGLUC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f5adec71-9859-487d-b728-e2edf84dd1e7
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1922
+ speciesSurveyCode: TRIPLAS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9c337552-d9ce-43c8-baee-bb8a16990f06
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1558
+ speciesSurveyCode: TRISCAP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6a8c710e-561b-42fa-822b-38fae515f841
+ countIfNoFrequencyEnabled: true
+ lengthStepPmfmId: 307
+ mandatorySampleCategoryId:
+ - 198
+ speciesReferenceTaxonId: 1619
+ speciesSurveyCode: ZEUSFAB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d6b592f0-715e-469c-b5f9-a878a40d96f0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 495
+ speciesSurveyCode: ABRAVER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b7be5501-ab00-4d28-970d-0a6ea8c68f85
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 491
+ speciesSurveyCode: ALLOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3219f09e-3d2b-47ad-bf3d-3f47f5678989
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1358
+ speciesSurveyCode: ALOSALO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 056bdc4b-11da-42d1-9974-8c95d20a8ad1
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1359
+ speciesSurveyCode: ALOSFAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9382a0b5-cb31-41e7-a928-8bf9adf1232a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1637
+ speciesSurveyCode: ANTHANT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 14ebb140-3775-4e69-aa2e-edec2d2aca44
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1547
+ speciesSurveyCode: ANTOMEG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2455d46e-558b-4400-8578-e2dfee943d81
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1394
+ speciesSurveyCode: ARGESPY
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5b560316-efa2-47a6-a200-4f1d1c7f15d3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1970
+ speciesSurveyCode: ARNOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2dcb33c5-27f9-4b4f-9899-09a8fc8a79fa
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1972
+ speciesSurveyCode: ARNOIMP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8a757c0c-ba3e-4fb5-a909-cb064927de06
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1971
+ speciesSurveyCode: ARNOLAT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3d2ab930-a3ae-427e-a051-fd10a1082fd6
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1973
+ speciesSurveyCode: ARNORUP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cf728432-af31-4025-bb73-dfe8c5c59dd3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1974
+ speciesSurveyCode: ARNOTHO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8eaf92d2-cc37-496d-8163-ebf04822a274
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1913
+ speciesSurveyCode: ASPIOBS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f716bcb0-4378-4e06-b98e-3f60a16aaad8
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 523
+ speciesSurveyCode: BATISPO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cdc46f8e-8e52-4c79-a2f2-03e028df5f13
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1818
+ speciesSurveyCode: BLENOCE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d3ba3646-93fd-40ef-93fb-832a3cb660e6
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2004
+ speciesSurveyCode: BUGLLUT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cf2b786c-4982-4ff8-8e3d-79aadc7f538f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1810
+ speciesSurveyCode: CALMSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a08a8d64-6347-49b1-a04c-515a40721381
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1811
+ speciesSurveyCode: CALMLYR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c023762c-40ab-45cf-86e1-e706d9379a4e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1812
+ speciesSurveyCode: CALMMAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d5efefa8-395d-4432-b742-42705c605c2c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1814
+ speciesSurveyCode: CALMRIS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: bd1b7e19-f2ee-4604-894c-c47d66538ceb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1624
+ speciesSurveyCode: CAPOAPE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 62aeb758-506f-4d20-979c-57dcc774e9c0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1860
+ speciesSurveyCode: CARPACU
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 21b09e73-3869-47b4-92fd-ee4673b0e3c0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1720
+ speciesSurveyCode: CECACIR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 864923f3-cc7f-4abd-a624-868e1f1e6731
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1279
+ speciesSurveyCode: CENTUYA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1c48f803-e058-4c2c-a924-b29507422267
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1654
+ speciesSurveyCode: CEPOMAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 432de6bf-9f6e-4790-946b-75da0c9929d5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1383
+ speciesSurveyCode: CHAUSLO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e9f97268-2810-429d-9194-aac6768f25d3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1335
+ speciesSurveyCode: CHIMMON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 254fde77-2969-479f-b1d5-73addd18449b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1410
+ speciesSurveyCode: CLORAGA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 16e7adde-7c7a-4ff3-910b-e50f34ba777b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1532
+ speciesSurveyCode: COELCOE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: eec35479-9550-4bf5-aca6-b2f9388df19d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1533
+ speciesSurveyCode: COELOCC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3537d192-e998-4caa-b760-4cb6a8f4d0b7
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1467
+ speciesSurveyCode: CONGCON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 25dce34d-5ebe-488b-aad6-3734314a641c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1474
+ speciesSurveyCode: DALOIMB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d54f1cca-cb49-40e1-a8c0-10ab46df1d6c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1321
+ speciesSurveyCode: DASICEN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 4ad0e928-afe2-444b-aeb9-50a92b48622b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1322
+ speciesSurveyCode: DASIPAS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 339c15a6-1518-44cd-b23f-722f21370bf0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 3003
+ speciesSurveyCode: DASITOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ef87ff58-12f9-496e-9d87-05ab13fc6906
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1323
+ speciesSurveyCode: DASIVIO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7fe7b385-ce85-464d-8b87-ff88814d005b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1789
+ speciesSurveyCode: GOBIQUA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 56032d3e-93c6-4940-989c-c77e6830a821
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1706
+ speciesSurveyCode: DENTDEN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ed034eaf-6fe9-4404-bbae-72a1d1fef38e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1644
+ speciesSurveyCode: DICELAB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 15918297-cb98-49cb-905e-145e8d7231c9
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 10581
+ speciesSurveyCode: DIPLCER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f29352c8-5caf-4bbb-ab30-6c13b9c5cd6b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1475
+ speciesSurveyCode: ECHEMIR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fff748a1-94b9-4623-827d-c3d10a0e1af6
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1648
+ speciesSurveyCode: EPIGSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 51909bed-9e38-4db2-bfe6-bfcab3dfce70
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1649
+ speciesSurveyCode: EPIGCON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 720c4f61-6aaa-4462-ba80-bbfebff36c8e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1650
+ speciesSurveyCode: EPIGDEN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 48859723-699c-4662-b965-ef7020c2c526
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1586
+ speciesSurveyCode: GADAMAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d43881ee-1fc7-4e03-8fa7-540e321547c2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 7693
+ speciesSurveyCode: GADIARG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 56c555be-f691-4e6a-9d2e-925fd3afa638
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1579
+ speciesSurveyCode: GAIDMED
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ee845d00-009b-46fd-883d-ebdb547e0f20
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1580
+ speciesSurveyCode: GAIDVUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b4ea935c-957e-47ce-81ec-c471f15c135b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1396
+ speciesSurveyCode: GLOSLEI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 87b2f346-a827-4516-9d08-184ca2c87c7f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1783
+ speciesSurveyCode: GOBISPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9b165269-d44e-4ccf-a4be-a809a5eeadef
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1785
+ speciesSurveyCode: GOBINIG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 12476229-943a-4037-8b79-83f14da19921
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 501
+ speciesSurveyCode: HISTSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b3843058-f126-44f1-823e-cac25ba4b6f6
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 7700
+ speciesSurveyCode: HOPLMED
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c6b6e928-c8f2-4e3c-a8c1-4a6463f6980c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1428
+ speciesSurveyCode: LAMASPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6637d2d8-5ffb-4e2a-8277-d185a44c3061
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1429
+ speciesSurveyCode: LAMACRO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3ab57331-ec76-44ee-bab7-96c780e603f0
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1590
+ speciesSurveyCode: LEPOLEP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f1b914a1-37bf-42c8-9387-920a422b9963
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1960
+ speciesSurveyCode: LEPMWHS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7c41537e-af2a-49ba-9959-39fb85d56527
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1917
+ speciesSurveyCode: LEPTCAV
+ weightEnabled: true
+- !SpeciesProtocol
+ id: abaab523-9759-4ec4-b103-5df101d0b510
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1918
+ speciesSurveyCode: LEPTDIE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a2ce385c-0786-459b-aa26-02d936797165
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1791
+ speciesSurveyCode: GOBIFRI
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 91008a01-63e4-4e37-bdc1-dec8f0f0e9a5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1882
+ speciesSurveyCode: LIZAAUR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: eddfe767-343e-4cc6-97af-59dd8367ba8d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1881
+ speciesSurveyCode: LIZARAM
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1ec767ba-1430-4678-a88f-ab9cfca572c2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1883
+ speciesSurveyCode: LIZASAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: db272acd-412c-4fa3-8750-e9ba6c664331
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 488
+ speciesSurveyCode: LOLISPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 67fa6ded-3a71-4ee3-a68c-b9c66b915775
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 12582
+ speciesSurveyCode: LOLIFOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3c5f43b9-3c1b-4416-b4fb-ac9627e6f305
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1497
+ speciesSurveyCode: MACOSCO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5b6f52bb-9014-47d5-a642-67465903521f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1379
+ speciesSurveyCode: MAURMUE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b9928831-f097-434e-b023-ec19e673b328
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1551
+ speciesSurveyCode: GADUMER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5a0dbd0c-a97b-4b03-8fa3-65cac4dcafce
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2011
+ speciesSurveyCode: MICUVAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 590ad66e-8a57-4fb6-9160-64216646fa4e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1567
+ speciesSurveyCode: MOLVDYP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8c123060-9d02-4938-ad86-867b14c37f6c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1568
+ speciesSurveyCode: MOLVMAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 08628555-a63c-4def-a9f0-330fdb250092
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1566
+ speciesSurveyCode: MOLVMOL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7d640ad6-0104-4dde-9792-36d792e8be3b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1593
+ speciesSurveyCode: MORAMOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 27ac2050-f2f2-425b-a203-33171a22b0c4
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1877
+ speciesSurveyCode: MUGICEP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3ff92ada-84b8-4b8c-9be2-346a39e2aeaf
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1414
+ speciesSurveyCode: MYCOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: acbc1c5d-3125-4ce3-816f-b92135e53cf5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1464
+ speciesSurveyCode: NETTMEL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5c12bd71-e723-413d-9be9-2e062646070b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1527
+ speciesSurveyCode: NEZUAEQ
+ weightEnabled: true
+- !SpeciesProtocol
+ id: db8b2566-540d-4d22-aaea-cd2949136a31
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1528
+ speciesSurveyCode: NEZUSCL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7bd39d56-8571-4936-9247-2c3f7db3ca8c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1483
+ speciesSurveyCode: NOTABON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 35cdc743-e4bf-45a8-b80f-9ac6f50e6b3e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1711
+ speciesSurveyCode: OBLAMEL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7aa028ca-c686-4592-8482-10be13c54d77
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 513
+ speciesSurveyCode: OCTOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2acef86b-b195-4ff7-8164-874751de27e4
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 515
+ speciesSurveyCode: OCTODEP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 4d715d15-f9e1-4081-9d10-cf0f651b728d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 517
+ speciesSurveyCode: OCTOSAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ee9780a1-4ffc-43d1-bda0-8c180b59b18d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1476
+ speciesSurveyCode: OPHCRUF
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 99345448-fefe-468f-bd59-6a0ba827dc8c
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1857
+ speciesSurveyCode: OPDIBAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9b50141a-7e9f-45bb-8cb9-0609aec8952e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1858
+ speciesSurveyCode: OPDIROC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6282d580-dde1-4477-89dd-f6ab1e4e63f1
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1477
+ speciesSurveyCode: OPHISER
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 44dbd32c-d339-4666-941b-8be80326a7d5
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1572
+ speciesSurveyCode: PHYIPHY
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b333a01f-33af-4fae-a8ee-372cbf0afd08
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 519
+ speciesSurveyCode: OCTOTET
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 3951b007-79c2-40f9-9ce2-f56f2b66e480
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1300
+ speciesSurveyCode: RAJASPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: dd590225-43f1-4403-8acb-6894ca3a7ebb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1301
+ speciesSurveyCode: RAJABRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9ac0e7e4-563d-4f60-957e-22fe39c0860a
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1309
+ speciesSurveyCode: RAJAFUL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7efd6a9a-1e6a-47da-915c-b68d1fd00017
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1304
+ speciesSurveyCode: RAJAMON
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f4b357aa-1c5c-40d8-8acd-b1ecffa18025
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1311
+ speciesSurveyCode: RAJANAE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 003afb88-af45-457c-a84b-16975a529645
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1317
+ speciesSurveyCode: RAJARDA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 4ae3247b-a7d3-4d1d-bd78-9e866821c072
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 471
+ speciesSurveyCode: ROSSMAC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 88da67b0-2f77-4d0b-bed1-08f3102fcd98
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1775
+ speciesSurveyCode: SADASAR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 12079205-9148-41b1-9d64-a920793f70bb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1716
+ speciesSurveyCode: SARPSAL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 14bfc0d8-46cd-4f85-805e-8549a0ab90b8
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1894
+ speciesSurveyCode: SCORSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8d055995-0c6f-4f52-bc05-bc79cc35e867
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1895
+ speciesSurveyCode: SCORELO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 8eda25d1-73d8-4e79-80e4-0829fb8bd1c3
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1897
+ speciesSurveyCode: SCORLOP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 220da7a9-05cb-484b-b299-49658e585bff
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1898
+ speciesSurveyCode: SCORMAD
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f27a7a08-2fa9-402a-8601-f8c26bb8f29d
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1899
+ speciesSurveyCode: SCORNOT
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 19328f63-e90d-4be0-a332-9efe14c87038
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1896
+ speciesSurveyCode: SCORPOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 6c7342d2-f50f-4231-bc91-5851e778a916
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1900
+ speciesSurveyCode: SCORSCO
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 7b68433c-0e52-4369-9f13-9b300a0a31cb
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 466
+ speciesSurveyCode: SEPISPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ec368e8f-6152-4828-9d85-38d2cd6fe2ab
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 468
+ speciesSurveyCode: SEPIELE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 72688083-ed6d-418c-8195-b7290d2aeeba
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 469
+ speciesSurveyCode: SEPIORB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9bbb3bcb-f770-448e-8141-2a2a250dff45
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 476
+ speciesSurveyCode: SEPOSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: bb6f45c4-c085-4809-b63a-1b0750f58ac2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1628
+ speciesSurveyCode: SERACAB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 5976284b-a33e-4f31-aef3-cd5190f40b34
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1629
+ speciesSurveyCode: SERAHEP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1b37cc5c-5164-4fa6-8f48-08173ace1507
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1995
+ speciesSurveyCode: SOLESPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: be091828-e022-4725-a682-f0e9ea3af3ba
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1998
+ speciesSurveyCode: SOLEIMP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 1075356e-b3b8-4c38-aba4-73f359a6b98b
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1999
+ speciesSurveyCode: SOLEKLE
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 00d90ba4-c2af-408b-a497-30a4c35c34dc
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2000
+ speciesSurveyCode: SOLELAS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f49aadd1-65ea-4820-bed9-583a25761cf6
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1997
+ speciesSurveyCode: SOLESEN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 220088e3-a661-48a1-a837-ab6a8888f170
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1693
+ speciesSurveyCode: SPARAUR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: e3a09923-8414-4ad9-b131-825f41537ba7
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1874
+ speciesSurveyCode: SPHYSPY
+ weightEnabled: true
+- !SpeciesProtocol
+ id: ccf5602f-99b2-4976-a1b4-b27efedeaeb2
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1721
+ speciesSurveyCode: SPICSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2d623cc1-c373-4b00-844f-7933d5599b56
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1718
+ speciesSurveyCode: SPODCAN
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 01748fc9-794b-4951-9e0a-e38dfc479f30
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1356
+ speciesSurveyCode: SPRASPR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d49011fc-ec85-40de-afd0-e0ab033557ff
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1286
+ speciesSurveyCode: SQUTSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 23d7fd79-fa86-4f82-80f6-6a8d84c81171
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 6835
+ speciesSurveyCode: STOMBOA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 04dfc865-479b-4c52-b1fa-4c9ea6832eba
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 2018
+ speciesSurveyCode: SYMPNIG
+ weightEnabled: true
+- !SpeciesProtocol
+ id: c0331582-7102-4ce4-b3a0-07d49ae7c93e
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1815
+ speciesSurveyCode: CALMPHA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 9afd6c5b-773c-4d54-a378-5e194f8d5964
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 508
+ speciesSurveyCode: TODIEBL
+ weightEnabled: true
+- !SpeciesProtocol
+ id: d94abbd3-a93b-4ecb-ad20-26da4e3b8516
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1295
+ speciesSurveyCode: TORPSPP
+ weightEnabled: true
+- !SpeciesProtocol
+ id: cd2d62d0-edd9-4033-ad35-c376a5087fdf
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1298
+ speciesSurveyCode: TORPNOB
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 2a676665-dd81-4df7-945e-006ee86ba7b8
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1296
+ speciesSurveyCode: TORPTOR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: f57e191d-a6ec-49c5-a485-b437e5b290d1
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1760
+ speciesSurveyCode: TRAHARA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: b35892d0-732f-4490-a369-32c35ee580cc
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1759
+ speciesSurveyCode: TRAHDRA
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 500570c2-7875-4f17-a865-664c065631f4
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1761
+ speciesSurveyCode: TRAHRAD
+ weightEnabled: true
+- !SpeciesProtocol
+ id: a6c14a6b-f9a8-45be-ac57-0330bf385a05
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1664
+ speciesSurveyCode: TRACPIC
+ weightEnabled: true
+- !SpeciesProtocol
+ id: 729c0fba-b454-4bf8-a41d-6e513b63954f
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1910
+ speciesSurveyCode: TRIGLYR
+ weightEnabled: true
+- !SpeciesProtocol
+ id: dd584b99-1065-475f-8257-eaafc85dc0c8
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1560
+ speciesSurveyCode: TRISLUS
+ weightEnabled: true
+- !SpeciesProtocol
+ id: fb9842ce-13fa-48b8-b294-db418257f706
+ countIfNoFrequencyEnabled: true
+ mandatorySampleCategoryId: []
+ speciesReferenceTaxonId: 1764
+ speciesSurveyCode: URANSCA
+ weightEnabled: true
+vesselUseFeaturePmfmId: !com.google.common.collect.Lists$TransformingRandomAccessList
+- 863
+- 862
+- 173
Modified: trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties
===================================================================
--- trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/filtered-resources/tutti-help-fr.properties 2014-01-21 16:29:59 UTC (rev 1519)
@@ -1,5 +1,5 @@
#Generated by org.nuiton.jaxx.plugin.GenerateHelpIdsMojo
-#Sun Jan 12 14:36:06 CET 2014
+#Tue Jan 21 11:51:19 CET 2014
tutti.config.help=config.html
tutti.createAccidentalBatch.action.cancel.help=editFishingOperation.html\#captureCapturesAccidentellesActions
tutti.createAccidentalBatch.action.saveAndClose.help=editFishingOperation.html\#captureCapturesAccidentellesActions
@@ -255,6 +255,7 @@
tutti.editSpeciesBatch.action.editFrequencies.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.exportMultiPost.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.importMultiPost.help=editFishingOperation.html\#captureEspecesActions
+tutti.editSpeciesBatch.action.importPsion.help=
tutti.editSpeciesBatch.action.importPupitri.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.removeBatch.help=editFishingOperation.html\#captureEspecesActions
tutti.editSpeciesBatch.action.removeSubBatch.help=editFishingOperation.html\#captureEspecesActions
Modified: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/TuttiUIContext.java
===================================================================
--- trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/TuttiUIContext.java 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/TuttiUIContext.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -54,6 +54,7 @@
import fr.ifremer.tutti.service.export.pdf.CatchesPdfExportService;
import fr.ifremer.tutti.service.export.sumatra.CatchesSumatraExportService;
import fr.ifremer.tutti.service.protocol.ProtocolImportExportService;
+import fr.ifremer.tutti.service.psionimport.PsionImportService;
import fr.ifremer.tutti.service.pupitri.PupitriImportExportService;
import fr.ifremer.tutti.service.referential.ReferentialImportExportService;
import fr.ifremer.tutti.service.referential.TuttiReferentialSynchronizeService;
@@ -596,6 +597,10 @@
return serviceContext.getService(PupitriImportExportService.class);
}
+ public PsionImportService getTuttiPsionImportExportService() {
+ return serviceContext.getService(PsionImportService.class);
+ }
+
public ReferentialImportExportService getTuttiReferentialImportExportService() {
return serviceContext.getService(ReferentialImportExportService.class);
}
Added: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/action/ImportPsionAction.java
===================================================================
--- trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/action/ImportPsionAction.java (rev 0)
+++ trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/action/ImportPsionAction.java 2014-01-21 16:29:59 UTC (rev 1519)
@@ -0,0 +1,173 @@
+package fr.ifremer.tutti.ui.swing.action;
+
+import com.google.common.base.Joiner;
+import com.google.common.collect.Lists;
+import fr.ifremer.tutti.persistence.entities.data.CatchBatch;
+import fr.ifremer.tutti.persistence.entities.data.FishingOperation;
+import fr.ifremer.tutti.persistence.entities.data.SampleCategoryModel;
+import fr.ifremer.tutti.persistence.service.TuttiEnumerationFile;
+import fr.ifremer.tutti.service.PersistenceService;
+import fr.ifremer.tutti.service.psionimport.PsionImportResult;
+import fr.ifremer.tutti.service.psionimport.PsionImportService;
+import fr.ifremer.tutti.ui.swing.content.operation.FishingOperationsUI;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.EditCatchesUI;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.EditCatchesUIModel;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.species.ImportPupitriPopupUI;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.species.SpeciesBatchUI;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.species.SpeciesBatchUIHandler;
+import fr.ifremer.tutti.ui.swing.content.operation.catches.species.SpeciesBatchUIModel;
+
+import javax.swing.JOptionPane;
+import javax.swing.UIManager;
+import java.io.File;
+import java.util.List;
+
+import static org.nuiton.i18n.I18n._;
+
+/**
+ * Created on 1/21/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.1
+ */
+public class ImportPsionAction extends AbstractTuttiAction<SpeciesBatchUIModel, SpeciesBatchUI, SpeciesBatchUIHandler> {
+
+ protected File importedTrunkFile;
+
+ protected ImportPupitriPopupUI importPupitriDialog;
+
+ protected PersistenceService persistenceService;
+
+ protected EditFishingOperationAction editAction;
+
+ protected PsionImportResult importResult;
+
+ public ImportPsionAction(SpeciesBatchUIHandler handler) {
+ super(handler, false);
+ persistenceService = getContext().getPersistenceService();
+ importPupitriDialog = new ImportPupitriPopupUI(handler.getContext());
+ }
+
+ public EditFishingOperationAction getEditAction() {
+ if (editAction == null) {
+ FishingOperationsUI parentContainer = handler.getParentContainer(FishingOperationsUI.class);
+ editAction = getContext().getActionFactory().createLogicAction(parentContainer.getHandler(),
+ EditFishingOperationAction.class);
+ }
+ return editAction;
+ }
+
+ @Override
+ public boolean prepareAction() throws Exception {
+ boolean result = true;
+
+ // must check that sample category model is compatible for pupitri import
+ // means need some categories
+
+ TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
+ SampleCategoryModel sampleCategoryModel = getDataContext().getSampleCategoryModel();
+
+ List<String> missingCategories = Lists.newArrayList();
+// if (!sampleCategoryModel.containsCategoryId(enumerationFile.PMFM_ID_SIZE_CATEGORY)) {
+// missingCategories.add("<li>" + persistenceService.getSizeCategoryCaracteristic().getParameterName() + "</li>");
+// }
+ if (!sampleCategoryModel.containsCategoryId(enumerationFile.PMFM_ID_SEX)) {
+ missingCategories.add("<li>" + persistenceService.getSexCaracteristic().getParameterName() + "</li>");
+ }
+ if (!sampleCategoryModel.containsCategoryId(enumerationFile.PMFM_ID_MATURITY)) {
+ missingCategories.add("<li>" + persistenceService.getMaturityCaracteristic().getParameterName() + "</li>");
+ }
+ if (!missingCategories.isEmpty()) {
+ result = false;
+ JOptionPane.showMessageDialog(
+ getContext().getActionUI(),
+ _("tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.message", Joiner.on("").join(missingCategories)),
+ _("tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.title"),
+ JOptionPane.ERROR_MESSAGE,
+ UIManager.getIcon("error")
+ );
+ }
+// if (result) {
+//
+// SpeciesBatchUIModel speciesBatchUIModel = getUI().getModel();
+// if (speciesBatchUIModel.getRowCount() > 0) {
+// String htmlMessage = String.format(
+// AbstractTuttiUIHandler.CONFIRMATION_FORMAT,
+// _("tutti.editSpeciesBatch.action.importPsion.existingData.message"),
+// _("tutti.editSpeciesBatch.action.importPsion.existingData.help"));
+//
+// int answer = JOptionPane.showConfirmDialog(getContext().getActionUI(),
+// htmlMessage,
+// _("tutti.editSpeciesBatch.action.importPsion.existingData.title"),
+// JOptionPane.OK_CANCEL_OPTION,
+// JOptionPane.WARNING_MESSAGE);
+//
+// result = answer == JOptionPane.OK_OPTION;
+// }
+// }
+
+ if (result) {
+ // choose file to import
+ importedTrunkFile = chooseFile(
+ _("tutti.editSpeciesBatch.action.title.choose.importPsionFile"),
+ _("tutti.editSpeciesBatch.action.choosePsionFile.import"),
+ "^.*\\.IWA", _("tutti.common.file.iwa"));
+
+ result = importedTrunkFile != null;
+ }
+
+ return result;
+ }
+
+ @Override
+ public void doAction() throws Exception {
+ PsionImportService importService = getContext().getTuttiPsionImportExportService();
+
+ EditCatchesUI parentContainer = handler.getParentContainer(EditCatchesUI.class);
+ EditCatchesUIModel model = parentContainer.getModel();
+
+ FishingOperation operation = model.getFishingOperation();
+ CatchBatch catchBatch = model.toEntity();
+
+ // import
+ importResult = importService.importFile(importedTrunkFile,
+ operation,
+ catchBatch);
+
+ if (importResult.isDone()) {
+
+ // reload operation
+ getEditAction().loadCatchBatch(operation);
+ }
+ }
+
+ @Override
+ public void releaseAction() {
+ super.releaseAction();
+ importedTrunkFile = null;
+ }
+
+ @Override
+ public void postSuccessAction() {
+ super.postSuccessAction();
+
+ if (importResult.isDone()) {
+
+ sendMessage(_("tutti.editSpeciesBatch.action.importPsion.success",
+ getModel().getRootNumber(), importResult.getNbImported()));
+ } else {
+
+ StringBuilder sb = new StringBuilder();
+ for (String s : importResult.getErrors()) {
+ sb.append("<li>").append(s).append("</li>");
+ }
+ displayWarningMessage(
+ _("tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation.title"),
+ "<html><body>" +
+ _("tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation", sb.toString()) +
+ "</body></html>"
+ );
+ sendMessage(_("tutti.editSpeciesBatch.action.importPsion.no.matching.data"));
+ }
+ }
+}
Property changes on: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/action/ImportPsionAction.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Modified: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.css
===================================================================
--- trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.css 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.css 2014-01-21 16:29:59 UTC (rev 1519)
@@ -252,6 +252,15 @@
_help: {"tutti.editSpeciesBatch.action.importPupitri.help"};
}
+#importPsionButton {
+ actionIcon: pupitri-import;
+ text: "tutti.editSpeciesBatch.action.importPsion";
+ toolTipText: "tutti.editSpeciesBatch.action.importPsion.tip";
+ i18nMnemonic: "tutti.editSpeciesBatch.action.importPsion.mnemonic";
+ _applicationAction: {fr.ifremer.tutti.ui.swing.action.ImportPsionAction.class};
+ _help: {"tutti.editSpeciesBatch.action.importPsion.help"};
+}
+
#importMultiPostButton {
actionIcon: import;
text: "tutti.editSpeciesBatch.action.importMultiPost";
Modified: trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.jaxx
===================================================================
--- trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.jaxx 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/java/fr/ifremer/tutti/ui/swing/content/operation/catches/species/SpeciesBatchUI.jaxx 2014-01-21 16:29:59 UTC (rev 1519)
@@ -64,6 +64,7 @@
<JToolBar id='speciesBatchTabToolBar'>
<JButton id='importPupitriButton'/>
+ <JButton id='importPsionButton'/>
<JButton id='importMultiPostButton'/>
<JButton id='exportMultiPostButton'/>
</JToolBar>
Modified: trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_en_GB.properties
===================================================================
--- trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_en_GB.properties 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_en_GB.properties 2014-01-21 16:29:59 UTC (rev 1519)
@@ -77,6 +77,7 @@
tutti.common.cancel=
tutti.common.cancel.mnemonic=
tutti.common.file.csv=
+tutti.common.file.iwa=
tutti.common.file.pdf=
tutti.common.file.protocol=
tutti.common.file.tuttiAccidental=
@@ -948,6 +949,7 @@
tutti.editSpeciesBatch.action.changeSampleCategory=
tutti.editSpeciesBatch.action.changeSampleCategory.mnemonic=
tutti.editSpeciesBatch.action.changeSampleCategory.tip=
+tutti.editSpeciesBatch.action.choosePsionFile.import=
tutti.editSpeciesBatch.action.createBatch=
tutti.editSpeciesBatch.action.createBatch.mnemonic=
tutti.editSpeciesBatch.action.createBatch.tip=
@@ -969,6 +971,18 @@
tutti.editSpeciesBatch.action.importMultiPost.sourceFile.title=
tutti.editSpeciesBatch.action.importMultiPost.success=
tutti.editSpeciesBatch.action.importMultiPost.tip=
+tutti.editSpeciesBatch.action.importPsion=
+tutti.editSpeciesBatch.action.importPsion.existingData.help=
+tutti.editSpeciesBatch.action.importPsion.existingData.message=
+tutti.editSpeciesBatch.action.importPsion.existingData.title=
+tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.message=
+tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.title=
+tutti.editSpeciesBatch.action.importPsion.mnemonic=
+tutti.editSpeciesBatch.action.importPsion.no.matching.data=
+tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation=
+tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation.title=
+tutti.editSpeciesBatch.action.importPsion.success=
+tutti.editSpeciesBatch.action.importPsion.tip=
tutti.editSpeciesBatch.action.importPupitri=
tutti.editSpeciesBatch.action.importPupitri.existingData.help=
tutti.editSpeciesBatch.action.importPupitri.existingData.message=
@@ -997,6 +1011,7 @@
tutti.editSpeciesBatch.action.splitBatch=
tutti.editSpeciesBatch.action.splitBatch.mnemonic=
tutti.editSpeciesBatch.action.splitBatch.tip=
+tutti.editSpeciesBatch.action.title.choose.importPsionFile=
tutti.editSpeciesBatch.error.sampleCategoryValue.notAvailable=
tutti.editSpeciesBatch.field.speciesTotalInertWeight=
tutti.editSpeciesBatch.field.speciesTotalInertWeight.tip=
Modified: trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_fr_FR.properties
===================================================================
--- trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_fr_FR.properties 2014-01-21 10:01:54 UTC (rev 1518)
+++ trunk/tutti-ui-swing/src/main/resources/i18n/tutti-ui-swing_fr_FR.properties 2014-01-21 16:29:59 UTC (rev 1519)
@@ -70,6 +70,7 @@
tutti.common.cancel=Annuler
tutti.common.cancel.mnemonic=A
tutti.common.file.csv=Extension d'un fichier csv
+tutti.common.file.iwa=Fichier d'import Psion
tutti.common.file.pdf=Extension d'un fichier pdf
tutti.common.file.protocol=Extension d'un fichier de protocole Tutti
tutti.common.file.tuttiAccidental=Fichier d'import/export des lots de captures accidentelles
@@ -941,6 +942,7 @@
tutti.editSpeciesBatch.action.changeSampleCategory=Modifier la catégorie
tutti.editSpeciesBatch.action.changeSampleCategory.mnemonic=M
tutti.editSpeciesBatch.action.changeSampleCategory.tip=Modifier la catégorie de la cellule sélectionnée
+tutti.editSpeciesBatch.action.choosePsionFile.import=Importer
tutti.editSpeciesBatch.action.createBatch=Créer un lot pour une espèce
tutti.editSpeciesBatch.action.createBatch.mnemonic=C
tutti.editSpeciesBatch.action.createBatch.tip=Créer un nouveau lot pour une espèce
@@ -962,6 +964,18 @@
tutti.editSpeciesBatch.action.importMultiPost.sourceFile.title=Importer des lots d'espèces
tutti.editSpeciesBatch.action.importMultiPost.success=Des lots d'espèces ont été importés depuis le fichier %s
tutti.editSpeciesBatch.action.importMultiPost.tip=Importer des lots d'espèces créés sur un poste satellite
+tutti.editSpeciesBatch.action.importPsion=Import Psion
+tutti.editSpeciesBatch.action.importPsion.existingData.help=Que voulez-vous faire ?<ul><li><strong>Annuler</strong> pour ne pas importer les données Pupitri et conserver les espèces saisies</li><li><strong>OK</strong> pour supprimer les espèces existantes et les remplacer par les données de Pupitri</li></ul>
+tutti.editSpeciesBatch.action.importPsion.existingData.message=Des espèces ont déjà été saisies dans la capture. Si vous continuez, elles vont être écrasées.
+tutti.editSpeciesBatch.action.importPsion.existingData.title=Données existantes
+tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.message=<html><body>Le modèle de catégorisation n'est pas compatible pour un import psion.<br> Il manque les catégories suivantes \: <ul>%s</ul><hr/>Veuillez ajouter cette catégorie dans la configuration de catégorisation (menu administration).</body></html>
+tutti.editSpeciesBatch.action.importPsion.invalidSampleCategoryModel.title=Modèle de catégorisation non compatible
+tutti.editSpeciesBatch.action.importPsion.mnemonic=P
+tutti.editSpeciesBatch.action.importPsion.no.matching.data=Import psion non réalisé (des erreurs ont été détectées lors de la lecture du fichier)
+tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation=L'import Psion n'a pas été réalisé, des erreurs ont été détectées \:<ul>%s</ul><br/>Aucun lot n'a donc été importé.
+tutti.editSpeciesBatch.action.importPsion.no.matching.fishingOperation.title=Import Psion
+tutti.editSpeciesBatch.action.importPsion.success=Import Psion réussi \: %1s espèces importées, %2s espèces rejetées
+tutti.editSpeciesBatch.action.importPsion.tip=Import Psion
tutti.editSpeciesBatch.action.importPupitri=Import Pupitri
tutti.editSpeciesBatch.action.importPupitri.existingData.help=Que voulez-vous faire ?<ul><li><strong>Annuler</strong> pour ne pas importer les données Pupitri et conserver les espèces saisies</li><li><strong>OK</strong> pour supprimer les espèces existantes et les remplacer par les données de Pupitri</li></ul>
tutti.editSpeciesBatch.action.importPupitri.existingData.message=Des espèces ont déjà été saisies dans la capture. Si vous continuez, elles vont être écrasées.
@@ -990,6 +1004,7 @@
tutti.editSpeciesBatch.action.splitBatch=Catégoriser le lot
tutti.editSpeciesBatch.action.splitBatch.mnemonic=C
tutti.editSpeciesBatch.action.splitBatch.tip=Catégoriser le lot courant (celui de la ligne sélectionné)
+tutti.editSpeciesBatch.action.title.choose.importPsionFile=Importer un fichier Psion
tutti.editSpeciesBatch.error.sampleCategoryValue.notAvailable=La valeur %s de la catégorie %s est déjà utilisée
tutti.editSpeciesBatch.field.speciesTotalInertWeight=Poids inerte trié
tutti.editSpeciesBatch.field.speciesTotalInertWeight.tip=Poids de la fraction inerte restante après le tri des espèces (cailloux, vase, débris coquilliers, etc.)
1
0
21 Jan '14
Author: lkaufmann
Date: 2014-01-21 11:01:54 +0100 (Tue, 21 Jan 2014)
New Revision: 1518
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1518
Log:
Refs #4138. Update screen/db help page content
Modified:
trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
Modified: trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-20 20:42:25 UTC (rev 1517)
+++ trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-21 10:01:54 UTC (rev 1518)
@@ -138,7 +138,7 @@
<p> </p>
</td>
<td colspan="2">
- [LK] Cet élément ne fait plus partie de l'interface ?
+ <u>LK: Cet élément ne fait plus partie de l'interface ?</u>
</td>
</tr>
<tr>
@@ -1004,7 +1004,7 @@
<p>Lecture seule</p>
</td>
<td>
- <p>(depuis version 1.2) Identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) (Obsolète) : TODO supprimer le code qui fait cette gestion Si le navire est identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) Sinon : Operation.operationVesselAssociation (OPERATION_VESSEL_ASSOCIATION.VESSEL_FK avec IS_CATCH_ON_OPERATION_VESSEL=0). Operation.vessel est alors rempli avec le premier navire de la liste de la campagne, pour être compatible avec Allegro (on doit toujours avoir : SCIENTIFIC_CRUISE.VESSEL_FK = OPERATION_VESSEL_FK).</p>
+ <p><u>(depuis version 1.2) Identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) (Obsolète) : TODO supprimer le code qui fait cette gestion Si le navire est identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) Sinon : Operation.operationVesselAssociation (OPERATION_VESSEL_ASSOCIATION.VESSEL_FK avec IS_CATCH_ON_OPERATION_VESSEL=0). Operation.vessel est alors rempli avec le premier navire de la liste de la campagne, pour être compatible avec Allegro (on doit toujours avoir : SCIENTIFIC_CRUISE.VESSEL_FK = OPERATION_VESSEL_FK).</u></p>
</td>
</tr>
<tr>
@@ -1034,7 +1034,7 @@
<p>Choix parmi les navires existants en base</p>
</td>
<td>
- <p>Est-ce stocké en base ?</p>
+ <p><u>LK: Est-ce stocké en base ?</u></p>
</td>
</tr>
<tr>
@@ -1102,7 +1102,7 @@
<h3>Trait > Autres paramètres</h3>
- <p>Cet onglet permet la saisie de l'hydrologie et des paramètres environnementaux.</p>
+ <p>Cet onglet permet la saisie des paramètres d'hydrologie et des paramètres environnementaux.</p>
<table class='table table-bordered table-striped table-hover table-condensed'>
<thead>
@@ -1126,7 +1126,7 @@
</td>
<td>
<p>Operation.gearUseFeatures.vesselUseMeasurement (GEAR_USE_MEASUREMENT.xxx - en fonction du type de PSFM : NUMERICAL_VALUE, ALPHANUMERICAL_VALUE ou QUALITATIVE_VALUE_FK<br/>
- <strong>WARNING</strong> : En v2 (version à confirmer), informations dispatcher dans différent onglet, en fonction du PSFM trouvé dans le protocole</p>
+ <u><strong>WARNING</strong> : En v2 (version à confirmer), informations dispatcher dans différent onglet, en fonction du PSFM trouvé dans le protocole</u></p>
</td>
</tr>
</tbody>
@@ -1148,7 +1148,7 @@
<tbody>
<tr>
<td>
- <p>Poids TOTAL</p>
+ <p>Capture > Poids TOTAL</p>
</td>
<td>
<p> </p>
@@ -1162,13 +1162,13 @@
</tr>
<tr>
<td>
- <p>Poids total VRAC</p>
+ <p>Capture > Poids total VRAC</p>
</td>
<td>
<p> </p>
</td>
<td>
- <p>Numérique</p>
+ <p>Numérique (Lecture seule)</p>
</td>
<td>
<p>Lot "Capture > Vrac" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
@@ -1176,13 +1176,13 @@
</tr>
<tr>
<td>
- <p>Poids total HORS VRAC</p>
+ <p>Capture > Poids total HORS VRAC</p>
</td>
<td>
<p> </p>
</td>
<td>
- <p>Numérique</p>
+ <p>Numérique (Lecture seule)</p>
</td>
<td>
<p>Lot "Capture > Hors Vrac" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
@@ -1190,7 +1190,7 @@
</tr>
<tr>
<td>
- <p>Poids total NON TRIE</p>
+ <p>Capture > Poids total NON TRIE</p>
</td>
<td>
<p> </p>
@@ -1202,6 +1202,22 @@
<p>Lot "Capture > Non trié" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
</td>
</tr>
+ <tr class="danger">
+ <td>
+ <p>Capture > Carroussel observé (1)</p>
+ </td>
+ <td></td>
+ <td>Numérique (Lecture seule)</td>
+ <td><u>LK: Est-ce stocké en base ?</u></td>
+ </tr>
+ <tr class="danger">
+ <td>
+ <p>Capture > Trémie (1)</p>
+ </td>
+ <td></td>
+ <td>Numérique (Lecture seule)</td>
+ <td><u>LK: Est-ce stocké en base ?</u></td>
+ </tr>
<tr>
<td>
<p>Espèce > Poids TOTAL</p>
@@ -1230,7 +1246,7 @@
<p>Lot "Capture > Vrac > Espèce" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Espèce > Poids total VRAC trié</p>
</td>
@@ -1241,7 +1257,7 @@
<p>Numérique</p>
</td>
<td>
- <p> </p>
+ <p><u>Calculé par tutti ? utile seulement si Thalassa ?</u></p>
</td>
</tr>
<tr>
@@ -1255,7 +1271,7 @@
<p>Numérique</p>
</td>
<td>
- <p> </p>
+ <p>Lot "Capture > Hors Vrac > Espèce" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
</td>
</tr>
<tr>
@@ -1286,7 +1302,7 @@
<p>Lot "Capture > Vrac > Benthos" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Benthos > Poids total VRAC trié</p>
</td>
@@ -1297,12 +1313,12 @@
<p>Numérique</p>
</td>
<td>
- <p> </p>
+ <p><u>Calculé par tutti ? utile seulement si Thalassa ?</u></p>
</td>
</tr>
<tr>
<td>
- <p>Benthos > Poids total HORS VRAC TRIE</p>
+ <p>Benthos > Poids total HORS VRAC</p>
</td>
<td>
<p> </p>
@@ -1331,6 +1347,8 @@
</tbody>
</table>
+ <p><strong>(1)</strong> Uniquement si le navire possède un carrousel et un trémie.</p>
+
<h3>Captures > Espèces</h3>
<table class='table table-bordered table-striped table-hover table-condensed'>
@@ -1345,9 +1363,22 @@
<tbody>
<tr>
<td>
- <p>Espèce > Poids total VRAC</p>
+ <p>Poids total</p>
</td>
<td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
+ <tr>
+ <td>
+ <p>Poids total VRAC</p>
+ </td>
+ <td>
<p> </p>
</td>
<td>
@@ -1360,6 +1391,32 @@
</tr>
<tr>
<td>
+ <p>Poids VRAC trié</p>
+ </td>
+ <td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
+ <tr>
+ <td>
+ <p>Poids total HORS VRAC</p>
+ </td>
+ <td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
+ <tr>
+ <td>
<p>Poids inerte trié</p>
</td>
<td>
@@ -1569,23 +1626,32 @@
<p>Chaque pièce jointes est stockée dans MeasurementFile (MEASUREMENT_FILE avec PMFM_FK=null, OBJECT_TYPE_FK='SAMPLE' et OBJECT_ID=<ID du lot de la ligne du tableau>) MeasurementFile.path : chemin du fichier (copier dans un répertoire, puis stocké en relatif ?) MeasurementFile.name : nom MeasurementFile.comments : commentaire</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Tableau > A confirmer</p>
</td>
<td>
- <p> </p>
</td>
<td>
<p>Booléen (Case à cocher)</p>
</td>
<td colspan="2">
- <p>
-
- </p>
+ <u>LK: Est-ce stocké en base?</u>
</td>
</tr>
+ </tbody>
+ </table>
+ <table class='table table-bordered table-striped table-hover table-condensed'>
+ <thead>
<tr>
+ <th>Libellé de l'élément</th>
+ <th>Obligatoire</th>
+ <th>Type</th>
+ <th colspan="2">Correspondance en base de données</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
<td>
<p>Mensuration > Type de mesure</p>
</td>
@@ -1595,7 +1661,7 @@
<p>Dupliqué pour chaque lot de mensuration créé (un lot pour chaque taille saisie) Batch.sortingMeasurement.pmfm (SORTING_MEASUREMENT.PMFM_FK)</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Mensuration > Pas de la classe de taille</p>
</td>
@@ -1603,7 +1669,7 @@
<td></td>
<td colspan="2">
- <p> </p>
+ <p><u>WARNING : Non stocké, devrait dépendre de PSFM.precision ? Peut-etre peut-on le calculer par analyse des mensurations saisies ? (et si aucune mesure prendre la précision du PSFM)</u></p>
</td>
</tr>
<tr>
@@ -1664,10 +1730,22 @@
<th colspan="2">Correspondance en base de données</th>
</tr>
</thead>
- <tbody>
+ <tbody><tr>
+ <td>
+ <p>Poids total</p>
+ </td>
+ <td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
<tr>
<td>
- <p>Benthos > Poids total VRAC</p>
+ <p>Poids total VRAC</p>
</td>
<td>
<p> </p>
@@ -1682,6 +1760,32 @@
</tr>
<tr>
<td>
+ <p>Poids VRAC trié</p>
+ </td>
+ <td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
+ <tr>
+ <td>
+ <p>Poids total HORS VRAC</p>
+ </td>
+ <td>
+ </td>
+ <td>
+ <p>Numérique (Lecture seule)</p>
+ </td>
+ <td colspan="2">
+ Non stocké en base.
+ </td>
+ </tr>
+ <tr>
+ <td>
<p>Poids inerte trié</p>
</td>
<td>
@@ -1891,7 +1995,7 @@
<p>Chaque pièce jointes est stockée dans MeasurementFile (MEASUREMENT_FILE avec PMFM_FK=null, OBJECT_TYPE_FK='SAMPLE' et OBJECT_ID=<ID du lot de la ligne du tableau>) MeasurementFile.path : chemin du fichier (copier dans un répertoire, puis stocké en relatif) MeasurementFile.name : nom MeasurementFile.comments : commentaire</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Tableau > A confirmer</p>
</td>
@@ -1903,11 +2007,23 @@
</td>
<td colspan="2">
<p>
-
+ <u>LK : Est-ce stocké en base ?</u>
</p>
</td>
</tr>
+ </tbody>
+ </table>
+ <table class='table table-bordered table-striped table-hover table-condensed'>
+ <thead>
<tr>
+ <th>Libellé de l'élément</th>
+ <th>Obligatoire</th>
+ <th>Type</th>
+ <th>Correspondance en base de données</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
<td>
<p>Mensuration > Type de mesure</p>
</td>
@@ -1917,14 +2033,14 @@
<p>Dupliqué pour chaque lot de mensuration créé (un lot pour chaque taille saisie) Batch.sortingMeasurement.pmfm (SORTING_MEASUREMENT.PMFM_FK)</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Mensuration > Pas de la classe de taille</p>
</td>
<td></td>
<td></td>
<td colspan="2">
- <p> </p>
+ <u>WARNING : Non stocké, devrait dépendre de PSFM.precision ? Peut-etre peut-on le calculer par analyse des mensurations saisies ? (et si aucune mesure prendre la précision du PSFM)</u>
</td>
</tr>
<tr>
@@ -1997,9 +2113,9 @@
<p>Lot "Capture > Hors Vrac > Macro déchets" Batch.quantificationMeasurement.numericalValue (QUANTIFICATION_MEASUREMENT.NUMERICAL_VALUE avec IS_REFERENT=1 et PMFM_FK=<PmfmId.WEIGHT_OBSERVED>)</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
- <p>Pièces Jointes</p>
+ <p>Pièces Jointes<br/><u>LK: Y a-t-il une différence avec Tableau > Pièces jointes ?</u></p>
</td>
<td>
<p> </p>
1
0
r1517 - in trunk/tutti-persistence/src/main: java/fr/ifremer/tutti/persistence/service resources
by tchemit@users.forge.codelutin.com 20 Jan '14
by tchemit@users.forge.codelutin.com 20 Jan '14
20 Jan '14
Author: tchemit
Date: 2014-01-20 21:42:25 +0100 (Mon, 20 Jan 2014)
New Revision: 1517
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1517
Log:
refs #3876: Import de donn?\195?\169es depuis un ictyom?\195?\168tre (par lot)
Modified:
trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java
trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties
Modified: trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java
===================================================================
--- trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java 2014-01-20 20:41:49 UTC (rev 1516)
+++ trunk/tutti-persistence/src/main/java/fr/ifremer/tutti/persistence/service/TuttiEnumerationFile.java 2014-01-20 20:42:25 UTC (rev 1517)
@@ -149,6 +149,21 @@
@Value("${QualitativeValueId.SEX_UNDEFINED}")
public final Integer QUALITATIVE_SEX_UNDEFINED_ID = null;
+ @Value("${QualitativeValueId.MATURITY_1}")
+ public final Integer QUALITATIVE_MATURITY_1_ID = null;
+
+ @Value("${QualitativeValueId.MATURITY_2}")
+ public final Integer QUALITATIVE_MATURITY_2_ID = null;
+
+ @Value("${QualitativeValueId.MATURITY_3}")
+ public final Integer QUALITATIVE_MATURITY_3_ID = null;
+
+ @Value("${QualitativeValueId.MATURITY_4}")
+ public final Integer QUALITATIVE_MATURITY_4_ID = null;
+
+ @Value("${QualitativeValueId.MATURITY_5}")
+ public final Integer QUALITATIVE_MATURITY_5_ID = null;
+
@Value("${QualitativeValueId.SIZE_SMALL}")
public final Integer QUALITATIVE_SIZE_SMALL_ID = null;
Modified: trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties
===================================================================
--- trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties 2014-01-20 20:41:49 UTC (rev 1516)
+++ trunk/tutti-persistence/src/main/resources/tutti-db-enumerations.properties 2014-01-20 20:42:25 UTC (rev 1517)
@@ -331,6 +331,12 @@
PmfmId.AGE=1430
# Catégorie maturité
PmfmId.MATURITY=174
+QualitativeValueId.MATURITY_1=272
+QualitativeValueId.MATURITY_2=273
+QualitativeValueId.MATURITY_3=274
+QualitativeValueId.MATURITY_4=275
+QualitativeValueId.MATURITY_5=276
+
# Catégorie macro-déchet
PmfmId.MARINE_LITTER_TYPE=1421
# Classe de taille macro-déchet
1
0
r1516 - in trunk/tutti-service/src: main/java/fr/ifremer/tutti/service main/java/fr/ifremer/tutti/service/psionimport test/java/fr/ifremer/tutti/service test/java/fr/ifremer/tutti/service/psionimport test/resources test/resources/psion
by tchemit@users.forge.codelutin.com 20 Jan '14
by tchemit@users.forge.codelutin.com 20 Jan '14
20 Jan '14
Author: tchemit
Date: 2014-01-20 21:41:49 +0100 (Mon, 20 Jan 2014)
New Revision: 1516
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1516
Log:
refs #3876: Import de donn?\195?\169es depuis un ictyom?\195?\168tre (par lot)
Added:
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java
trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java
trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/
trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java
trunk/tutti-service/src/test/resources/psion/
trunk/tutti-service/src/test/resources/psion/CC053.IWA
trunk/tutti-service/src/test/resources/psion/CFchephren 110612.IWA
trunk/tutti-service/src/test/resources/psion/FM001.IWA
Added: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java (rev 0)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,119 @@
+package fr.ifremer.tutti.service.psionimport;
+
+/*
+ * #%L
+ * Tutti :: Service
+ * $Id$
+ * $HeadURL:$
+ * %%
+ * Copyright (C) 2012 - 2014 Ifremer
+ * %%
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU 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 General Public
+ * License along with this program. If not, see
+ * <http://www.gnu.org/licenses/gpl-3.0.html>.
+ * #L%
+ */
+
+import com.google.common.collect.Maps;
+import fr.ifremer.tutti.persistence.entities.referential.Species;
+import org.apache.commons.lang3.mutable.MutableInt;
+
+import java.io.Serializable;
+import java.util.Map;
+
+/**
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+public class PsionImportBatchModel {
+
+ protected final Species species;
+
+ protected final Integer lengthStepCaracteristicId;
+
+ protected Float weight;
+
+ protected Float sampleWeight;
+
+ protected Integer categoryId;
+
+ protected Serializable categoryValue;
+
+ protected final Map<Float, MutableInt> frequencies;
+
+ public PsionImportBatchModel(Species species, Integer lengthStepCaracteristicId) {
+ this.species = species;
+ this.lengthStepCaracteristicId = lengthStepCaracteristicId;
+ frequencies = Maps.newTreeMap();
+ }
+
+ public void setWeight(Float weight) {
+ this.weight = weight;
+ }
+
+ public void setSampleWeight(Float sampleWeight) {
+ this.sampleWeight = sampleWeight;
+ }
+
+ public void setCategory(Integer categoryId, Serializable categoryValue) {
+ this.categoryId = categoryId;
+ this.categoryValue = categoryValue;
+ }
+
+ public void addFrequency(Float size) {
+ MutableInt mutableFloat = frequencies.get(size);
+ if (mutableFloat == null) {
+ mutableFloat = new MutableInt(0);
+ frequencies.put(size, mutableFloat);
+ }
+ mutableFloat.increment();
+ }
+
+ public Species getSpecies() {
+ return species;
+ }
+
+ public Integer getLengthStepCaracteristicId() {
+ return lengthStepCaracteristicId;
+ }
+
+ public Float getWeight() {
+ return weight;
+ }
+
+ public Float getSampleWeight() {
+ return sampleWeight;
+ }
+
+ public Integer getCategoryId() {
+ return categoryId;
+ }
+
+ public Serializable getCategoryValue() {
+ return categoryValue;
+ }
+
+ public boolean withFrequencies() {
+ return !frequencies.isEmpty();
+ }
+
+ public Map<Float, MutableInt> getFrequencies() {
+ return frequencies;
+ }
+
+ public int getNbFrequencies() {
+ return frequencies.size();
+ }
+}
Property changes on: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportBatchModel.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Added: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java (rev 0)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,84 @@
+package fr.ifremer.tutti.service.psionimport;
+
+/*
+ * #%L
+ * Tutti :: Service
+ * $Id$
+ * $HeadURL:$
+ * %%
+ * Copyright (C) 2012 - 2014 Ifremer
+ * %%
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU 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 General Public
+ * License along with this program. If not, see
+ * <http://www.gnu.org/licenses/gpl-3.0.html>.
+ * #L%
+ */
+
+import com.google.common.collect.Lists;
+import com.google.common.collect.Sets;
+import fr.ifremer.tutti.persistence.entities.referential.Species;
+
+import java.util.List;
+import java.util.Set;
+
+/**
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+public class PsionImportModel {
+
+ protected final List<PsionImportBatchModel> batchs;
+
+ protected final Set<String> ignoredSpecies;
+
+ public PsionImportModel() {
+ batchs = Lists.newArrayList();
+ ignoredSpecies = Sets.newHashSet();
+ }
+
+ public void addBatch(PsionImportBatchModel batchModel) {
+ batchs.add(batchModel);
+ }
+
+ public void addIgnoredSpecies(String species) {
+ ignoredSpecies.add(species);
+ }
+
+ public boolean withBatchs() {
+ return !batchs.isEmpty();
+ }
+
+ public Set<String> getIgnoredSpecies() {
+ return ignoredSpecies;
+ }
+
+ public Set<Species> getSpecies() {
+ Set<Species> result = Sets.newLinkedHashSet();
+ for (PsionImportBatchModel batch : batchs) {
+ result.add(batch.getSpecies());
+ }
+ return result;
+ }
+
+ public List<PsionImportBatchModel> getBatchs(Species species) {
+ List<PsionImportBatchModel> result = Lists.newArrayList();
+ for (PsionImportBatchModel batch : batchs) {
+ if (species.equals(batch.getSpecies())) {
+ result.add(batch);
+ }
+ }
+ return result;
+ }
+}
Property changes on: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportModel.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Added: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java (rev 0)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,66 @@
+package fr.ifremer.tutti.service.psionimport;
+
+/*
+ * #%L
+ * Tutti :: Service
+ * $Id$
+ * $HeadURL:$
+ * %%
+ * Copyright (C) 2012 - 2014 Ifremer
+ * %%
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU 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 General Public
+ * License along with this program. If not, see
+ * <http://www.gnu.org/licenses/gpl-3.0.html>.
+ * #L%
+ */
+
+import java.io.File;
+
+/**
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+public class PsionImportResult {
+
+ protected final File importFile;
+
+ protected int nbImported;
+
+ protected int nbNotImported;
+
+ public PsionImportResult(File importFile) {
+ this.importFile = importFile;
+ }
+
+ public File getImportFile() {
+ return importFile;
+ }
+
+ public int getNbImported() {
+ return nbImported;
+ }
+
+ public int getNbNotImported() {
+ return nbNotImported;
+ }
+
+ void incrementNbImported() {
+ this.nbImported++;
+ }
+
+ void incrementNbNotImported() {
+ this.nbNotImported++;
+ }
+}
Property changes on: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportResult.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Added: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java
===================================================================
--- trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java (rev 0)
+++ trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,599 @@
+package fr.ifremer.tutti.service.psionimport;
+
+/*
+ * #%L
+ * Tutti :: Service
+ * $Id$
+ * $HeadURL:$
+ * %%
+ * Copyright (C) 2012 - 2014 Ifremer
+ * %%
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU 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 General Public
+ * License along with this program. If not, see
+ * <http://www.gnu.org/licenses/gpl-3.0.html>.
+ * #L%
+ */
+
+import com.google.common.base.Charsets;
+import com.google.common.base.Preconditions;
+import com.google.common.collect.Lists;
+import com.google.common.collect.Maps;
+import com.google.common.collect.Sets;
+import com.google.common.io.Files;
+import fr.ifremer.shared.application.ApplicationBusinessException;
+import fr.ifremer.tutti.persistence.entities.TuttiEntities;
+import fr.ifremer.tutti.persistence.entities.data.AttachementObjectTypeEnum;
+import fr.ifremer.tutti.persistence.entities.data.Attachment;
+import fr.ifremer.tutti.persistence.entities.data.Attachments;
+import fr.ifremer.tutti.persistence.entities.data.BatchContainer;
+import fr.ifremer.tutti.persistence.entities.data.CatchBatch;
+import fr.ifremer.tutti.persistence.entities.data.FishingOperation;
+import fr.ifremer.tutti.persistence.entities.data.SpeciesBatch;
+import fr.ifremer.tutti.persistence.entities.data.SpeciesBatchFrequency;
+import fr.ifremer.tutti.persistence.entities.data.SpeciesBatchFrequencys;
+import fr.ifremer.tutti.persistence.entities.data.SpeciesBatchs;
+import fr.ifremer.tutti.persistence.entities.protocol.SpeciesProtocol;
+import fr.ifremer.tutti.persistence.entities.protocol.TuttiProtocol;
+import fr.ifremer.tutti.persistence.entities.referential.Caracteristic;
+import fr.ifremer.tutti.persistence.entities.referential.CaracteristicQualitativeValue;
+import fr.ifremer.tutti.persistence.entities.referential.Species;
+import fr.ifremer.tutti.persistence.service.TuttiEnumerationFile;
+import fr.ifremer.tutti.service.AbstractTuttiService;
+import fr.ifremer.tutti.service.PersistenceService;
+import fr.ifremer.tutti.service.TuttiDataContext;
+import fr.ifremer.tutti.service.TuttiServiceContext;
+import org.apache.commons.io.IOUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.mutable.MutableInt;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.IOException;
+import java.io.Serializable;
+import java.text.DateFormat;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import static org.nuiton.i18n.I18n._;
+
+/**
+ * To import some psion files.
+ * <p/>
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+public class PsionImportService extends AbstractTuttiService {
+
+ private static final Log log = LogFactory.getLog(PsionImportService.class);
+
+ protected static final Set<String> SEX_VALUES = Sets.newHashSet(
+ "N", "n", "I", "i", "F", "f", "M", "m"
+ );
+
+ protected static final Set<String> MATURITY_VALUES = Sets.newHashSet(
+ "1", "2", "3", "4", "5"
+ );
+
+ protected PersistenceService persistenceService;
+
+ protected char csvSeparator;
+
+ protected TuttiDataContext dataContext;
+
+ protected CaracteristicQualitativeValue sortedCaracteristic;
+
+ protected CaracteristicQualitativeValue unsortedCaracteristic;
+
+ protected Map<String, Species> speciesBySurveyCode;
+
+ protected Map<String, SpeciesProtocol> speciesProtocolBySurveyCode;
+
+ protected Map<String, CaracteristicQualitativeValue> sexCaracteristicValues;
+
+ protected Map<String, CaracteristicQualitativeValue> maturityCaracteristicValues;
+
+ @Override
+ public void setServiceContext(TuttiServiceContext context) {
+ super.setServiceContext(context);
+ persistenceService = getService(PersistenceService.class);
+
+ csvSeparator = ';';
+ dataContext = context.getDataContext();
+
+
+ TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
+
+ { // sorted/unsorted caracteristic
+ Caracteristic caracteristic =
+ persistenceService.getSortedUnsortedCaracteristic();
+
+ sortedCaracteristic = TuttiEntities.getQualitativeValue(caracteristic, enumerationFile.QUALITATIVE_VRAC_ID);
+ unsortedCaracteristic = TuttiEntities.getQualitativeValue(caracteristic, enumerationFile.QUALITATIVE_HORS_VRAC_ID);
+ }
+
+ { // sex caracteristic
+
+ sexCaracteristicValues = Maps.newTreeMap();
+
+ Caracteristic caracteristic = persistenceService.getSexCaracteristic();
+
+ List<CaracteristicQualitativeValue> qualitativeValues = caracteristic.getQualitativeValue();
+
+ Map<Integer, CaracteristicQualitativeValue> sexById = TuttiEntities.splitByIdAsInt(qualitativeValues);
+ CaracteristicQualitativeValue femaleCaracteristic = sexById.get(enumerationFile.QUALITATIVE_SEX_FEMALE_ID);
+ sexCaracteristicValues.put("F", femaleCaracteristic);
+ sexCaracteristicValues.put("f", femaleCaracteristic);
+ CaracteristicQualitativeValue maleCaracteristic = sexById.get(enumerationFile.QUALITATIVE_SEX_MALE_ID);
+ sexCaracteristicValues.put("M", maleCaracteristic);
+ sexCaracteristicValues.put("m", maleCaracteristic);
+ CaracteristicQualitativeValue unkownCaracteristic = sexById.get(enumerationFile.QUALITATIVE_SEX_UNDEFINED_ID);
+ sexCaracteristicValues.put("I", unkownCaracteristic);
+ sexCaracteristicValues.put("i", unkownCaracteristic);
+ }
+
+ { // maturity caracteristic
+
+ maturityCaracteristicValues = Maps.newTreeMap();
+
+ Caracteristic caracteristic = persistenceService.getMaturityCaracteristic();
+
+ List<CaracteristicQualitativeValue> qualitativeValues = caracteristic.getQualitativeValue();
+
+ Map<Integer, CaracteristicQualitativeValue> byIds = TuttiEntities.splitByIdAsInt(qualitativeValues);
+ maturityCaracteristicValues.put("1", byIds.get(enumerationFile.QUALITATIVE_MATURITY_1_ID));
+ maturityCaracteristicValues.put("2", byIds.get(enumerationFile.QUALITATIVE_MATURITY_2_ID));
+ maturityCaracteristicValues.put("3", byIds.get(enumerationFile.QUALITATIVE_MATURITY_3_ID));
+ maturityCaracteristicValues.put("4", byIds.get(enumerationFile.QUALITATIVE_MATURITY_4_ID));
+ maturityCaracteristicValues.put("5", byIds.get(enumerationFile.QUALITATIVE_MATURITY_5_ID));
+ }
+
+ List<Species> allReferentSpecies = persistenceService.getReferentSpeciesWithSurveyCode(
+ persistenceService.getAllReferentSpecies());
+
+ speciesBySurveyCode = Maps.newTreeMap();
+ for (Species species : allReferentSpecies) {
+ if (species.getSurveyCode() != null) {
+ speciesBySurveyCode.put(species.getSurveyCode(), species);
+ }
+ }
+
+ speciesProtocolBySurveyCode = Maps.newTreeMap();
+
+ TuttiProtocol protocol = dataContext.getProtocol();
+
+ if (protocol == null) {
+ // not possible
+ //FIXME Deal with error
+ throw new IllegalStateException("Can't open psionImportService without a protocol");
+ }
+
+ List<SpeciesProtocol> speciesProtocols = protocol.getSpecies();
+ for (SpeciesProtocol speciesProtocol : speciesProtocols) {
+ if (speciesProtocol.getSpeciesSurveyCode() == null) {
+ continue;
+ }
+
+ speciesProtocolBySurveyCode.put(speciesProtocol.getSpeciesSurveyCode(), speciesProtocol);
+ }
+ }
+
+ public PsionImportResult importFile(File psionFile, FishingOperation operation, CatchBatch catchBatch) {
+
+ Preconditions.checkNotNull(psionFile);
+ Preconditions.checkArgument(psionFile.exists(), "Psion file " + psionFile + " does not exist.");
+
+ // load model
+ PsionImportModel importModel;
+ try {
+ importModel = readImportFile(psionFile);
+ } catch (IOException e) {
+ throw new ApplicationBusinessException(e.getMessage(), e.getCause());
+ }
+
+ // import in database
+ PsionImportResult result = persist(psionFile, importModel, operation, catchBatch);
+
+ return result;
+ }
+
+ protected PsionImportModel readImportFile(File arpFile) throws IOException {
+
+ TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
+
+ PsionImportModel importModel = new PsionImportModel();
+
+ BufferedReader reader = Files.newReader(arpFile, Charsets.UTF_8);
+
+ try {
+ PsionImportBatchModel batch = null;
+
+ // first line, don't care
+ String line;
+
+ line = reader.readLine(); // initiales saisisseurs
+ line = reader.readLine(); // Id du trait
+ line = reader.readLine(); // Date du trait
+ line = reader.readLine(); // Heure de création du fichier
+ line = reader.readLine(); // Ligne blanche
+
+ int lineNumber = 6;
+
+ String badSpecies = null;
+ while ((line = reader.readLine()) != null) {
+ lineNumber++;
+ if (!line.contains(":")) {
+ throw new IOException(
+ "Format de la ligne (" +
+ lineNumber + ") incorrecte : " + line);
+ }
+ int endIndex = line.indexOf(':');
+ String commandStr = StringUtils.trim(line.substring(0, endIndex));
+
+
+ PsionImportKeyword command;
+
+ try {
+ command = PsionImportKeyword.valueOf(commandStr);
+ } catch (IllegalArgumentException e) {
+ throw new IOException(
+ "La commande " + commandStr + " n'est pas connue ligne (" +
+ lineNumber + ") ");
+ }
+
+ if (command.isIgnored()) {
+ if (log.isWarnEnabled()) {
+ log.warn("Ignoring command: " + command);
+ }
+ continue;
+ }
+
+ String value = StringUtils.trim(line.substring(endIndex + 1));
+
+ if (PsionImportKeyword.ESPE.equals(command)) {
+
+ // start a new species
+
+ // register previous batch
+ if (batch != null) {
+ addBatchToModel(importModel, batch);
+ }
+
+ Species species = speciesBySurveyCode.get(value);
+
+ if (species == null) {
+
+ // could not load this species
+ if (log.isWarnEnabled()) {
+ log.warn("Ligne " + lineNumber + " espèce " + value + " inconnue.");
+ }
+ badSpecies = value;
+ importModel.addIgnoredSpecies(badSpecies);
+ continue;
+ }
+
+ badSpecies = null;
+
+ SpeciesProtocol speciesProtocol = speciesProtocolBySurveyCode.get(value);
+
+ String lengthStepCaracteristicId = speciesProtocol.getLengthStepPmfmId();
+
+ if (StringUtils.isBlank(lengthStepCaracteristicId)) {
+ if (log.isWarnEnabled()) {
+ log.warn("Ligne " + lineNumber + " espèce " + value + " ignorée car pas de caractéristique de classe de taille renseignée dans le protocole.");
+ }
+ badSpecies = value;
+ importModel.addIgnoredSpecies(badSpecies);
+ continue;
+ }
+ batch = new PsionImportBatchModel(species, Integer.valueOf(lengthStepCaracteristicId));
+ } else {
+
+ if (badSpecies != null) {
+ // ignore this line due to bad species
+ if (log.isDebugEnabled()) {
+ log.debug("Ligne " + lineNumber
+ + " ignorée car l'espèce " + badSpecies + " n'était pas reconnue");
+ }
+ continue;
+ }
+
+ // check batch exists
+ if (batch == null) {
+ throw new IOException(
+ "La ligne " + line + " (" + lineNumber +
+ ") n'est pas valide, elle doit être précédée par une ligne ESPE");
+ }
+
+ switch (command) {
+
+ case POID:
+ // add weight
+ Float weight = toFloat(value, lineNumber);
+ batch.setWeight(weight);
+ break;
+
+ case TAIL:
+ // add sample weight
+ Float sampleWeight = toFloat(value, lineNumber);
+ batch.setSampleWeight(sampleWeight);
+ break;
+
+ case CATE:
+ // add category
+
+ Integer caracteristicId;
+ CaracteristicQualitativeValue caracteristicQualitativeValue;
+
+ if (SEX_VALUES.contains(value)) {
+
+ // sex caracteristic
+ caracteristicId = enumerationFile.PMFM_ID_SEX;
+
+ caracteristicQualitativeValue = sexCaracteristicValues.get(value);
+
+ if (caracteristicQualitativeValue == null) {
+
+ //means non sexé
+ caracteristicId = null;
+ }
+
+ } else if (MATURITY_VALUES.contains(value)) {
+
+ // maturity caracteristic
+ caracteristicId = enumerationFile.PMFM_ID_MATURITY;
+ caracteristicQualitativeValue = maturityCaracteristicValues.get(value);
+
+ } else {
+
+ if (log.isWarnEnabled()) {
+ log.warn("Ligne " + lineNumber + ", catégorisation '" + value + "' inconnue, espèce " + batch.getSpecies().getSurveyCode() + " ignorée");
+ }
+
+ badSpecies = batch.getSpecies().getSurveyCode();
+ importModel.addIgnoredSpecies(badSpecies);
+ batch = null;
+ continue;
+// throw new IOException(
+// "Ligne " + lineNumber + ", catégorisation '" + value + "' inconnue");
+ }
+
+ batch.setCategory(caracteristicId, caracteristicQualitativeValue);
+ break;
+
+ case LONG:
+ // add frequency
+ Float size = toFloat(value, lineNumber);
+ batch.addFrequency(size);
+ break;
+
+ case OUTI:
+ // ignore it
+ break;
+ }
+ }
+ }
+
+ if (batch != null) {
+
+ // save it
+ addBatchToModel(importModel, batch);
+ }
+
+ reader.close();
+ return importModel;
+ } finally {
+ IOUtils.closeQuietly(reader);
+ }
+ }
+
+ protected PsionImportResult persist(File arpFile,
+ PsionImportModel importModel,
+ FishingOperation operation,
+ CatchBatch catchBatch) {
+ PsionImportResult result = new PsionImportResult(arpFile);
+
+ if (catchBatch != null) {
+ addFileAsAttachment(arpFile, catchBatch);
+ }
+
+ // delete all species batches
+ BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+ for (SpeciesBatch batch : rootSpeciesBatch.getChildren()) {
+ persistenceService.deleteSpeciesBatch(batch.getId());
+ }
+
+ // insert all imported species batches
+
+ TuttiEnumerationFile enumerationFile = persistenceService.getEnumerationFile();
+
+ Set<Species> species = importModel.getSpecies();
+
+ for (Species specy : species) {
+
+ //FIXME Make sure this does work well with a none sex batch...
+ List<PsionImportBatchModel> batchs = importModel.getBatchs(specy);
+
+ if (batchs.size() == 1 && batchs.get(0).getCategoryId() == null) {
+
+ PsionImportBatchModel batchModel = batchs.get(0);
+
+ // simple batch with no category
+ SpeciesBatch batch = createSpeciesBatch(operation,
+ batchModel.getSpecies(),
+ batchModel.getWeight(),
+ enumerationFile.PMFM_ID_SORTED_UNSORTED,
+ sortedCaracteristic);
+ //FIXME Check this is ok.
+ batch.setWeight(batchModel.getSampleWeight());
+
+ batch = persistenceService.createSpeciesBatch(batch, null);
+
+ persistFrequencies(batch, batchModel);
+
+ } else {
+
+ // batch with categories
+
+ SpeciesBatch batch = createSpeciesBatch(operation,
+ specy,
+ null,
+ enumerationFile.PMFM_ID_SORTED_UNSORTED,
+ sortedCaracteristic);
+
+ batch = persistenceService.createSpeciesBatch(batch, null);
+
+ for (PsionImportBatchModel batchModel : batchs) {
+
+ SpeciesBatch childBatch = createSpeciesBatch(operation,
+ batchModel.getSpecies(),
+ batchModel.getWeight(),
+ batchModel.getCategoryId(),
+ batchModel.getCategoryValue());
+ //FIXME Check this is ok.
+ childBatch.setWeight(batchModel.getSampleWeight());
+
+ childBatch = persistenceService.createSpeciesBatch(childBatch, batch.getId());
+
+ persistFrequencies(childBatch, batchModel);
+ }
+ }
+ result.incrementNbImported();
+ }
+
+ for (String ignoredSpecies : importModel.getIgnoredSpecies()) {
+ result.incrementNbNotImported();
+ }
+ persistenceService.saveCatchBatch(catchBatch);
+
+ return result;
+ }
+
+ protected void persistFrequencies(SpeciesBatch batch, PsionImportBatchModel batchModel) {
+
+ Integer lengthStepCaracteristicId = batchModel.getLengthStepCaracteristicId();
+ Map<Float, MutableInt> frequencies = batchModel.getFrequencies();
+ List<SpeciesBatchFrequency> toSave = Lists.newArrayList();
+
+ Caracteristic lengthStepCaracteristic = persistenceService.getCaracteristic(lengthStepCaracteristicId);
+
+ for (Map.Entry<Float, MutableInt> entry : frequencies.entrySet()) {
+ Float size = entry.getKey();
+ MutableInt number = entry.getValue();
+
+ SpeciesBatchFrequency batchFrequency = SpeciesBatchFrequencys.newSpeciesBatchFrequency();
+ batchFrequency.setBatch(batch);
+ batchFrequency.setLengthStepCaracteristic(lengthStepCaracteristic);
+ batchFrequency.setLengthStep(size);
+ batchFrequency.setNumber(number.getValue());
+ toSave.add(batchFrequency);
+ }
+
+ persistenceService.saveSpeciesBatchFrequency(batch.getId(), toSave);
+ }
+
+ protected void addBatchToModel(PsionImportModel importModel,
+ PsionImportBatchModel batch) throws IOException {
+
+ if (log.isInfoEnabled()) {
+ log.info("Adding for species " + batch.getSpecies().getSurveyCode() + ", " +
+ batch.getNbFrequencies() + " batchs.");
+ }
+ importModel.addBatch(batch);
+ }
+
+ protected SpeciesBatch createSpeciesBatch(FishingOperation operation,
+ Species species,
+ Float catchWeight,
+ Integer categoryId,
+ Serializable cqv) {
+ SpeciesBatch batch = SpeciesBatchs.newSpeciesBatch();
+ batch.setFishingOperation(operation);
+ batch.setSampleCategoryId(categoryId);
+ batch.setSampleCategoryValue(cqv);
+ batch.setSpecies(species);
+ batch.setSampleCategoryWeight(
+ catchWeight == null ? null : TuttiEntities.roundKiloGram(catchWeight));
+ return batch;
+ }
+
+ protected void addFileAsAttachment(File f, CatchBatch catchBatch) {
+ Attachment attachment = Attachments.newAttachment();
+ attachment.setObjectType(AttachementObjectTypeEnum.CATCH_BATCH);
+ attachment.setObjectId(Integer.valueOf(catchBatch.getId()));
+ attachment.setName(f.getName());
+ String date = DateFormat.getDateTimeInstance().format(context.currentDate());
+ String comment = _("tutti.service.arp.import.attachment.comment", date);
+ attachment.setComment(comment);
+ persistenceService.createAttachment(attachment, f);
+ }
+
+ protected Float toFloat(String cell, int lineNumber) throws IOException {
+ Float result = null;
+ if (!cell.isEmpty()) {
+ try {
+ result = Float.valueOf(cell);
+ } catch (NumberFormatException e) {
+ throw new IOException("Format de la valeur [" + lineNumber + "] : " + cell +
+ " incorrect, devrait être un entier décimal");
+ }
+ }
+ if (result == null) {
+ throw new IOException("La valeur [" + lineNumber + "] est obligatoire mais n'est pas renseignée");
+ }
+ return result;
+ }
+
+ /**
+ * All usables keywords in a psion import.
+ * <p/>
+ * Created on 1/20/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.0.1
+ */
+ public static enum PsionImportKeyword {
+
+ ESPE(false),
+ POID(false),
+ TAIL(false),
+ CATE(false),
+ LONG(false),
+
+ // ignored
+ HEUR(true),
+ AGEN(true),
+ CAIS(true),
+ TAXO(true),
+ OUTI(true),
+ PORT(true),
+ DATE(true),
+ HERE(true),
+ NAVI(true),
+ ENGI(true);
+
+ private final boolean ignored;
+
+ PsionImportKeyword(boolean ignored) {
+ this.ignored = ignored;
+ }
+
+ public boolean isIgnored() {
+ return ignored;
+ }
+ }
+}
Property changes on: trunk/tutti-service/src/main/java/fr/ifremer/tutti/service/psionimport/PsionImportService.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Added: trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java
===================================================================
--- trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java (rev 0)
+++ trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,188 @@
+package fr.ifremer.tutti.service.psionimport;
+
+/*
+ * #%L
+ * Tutti :: Service
+ * $Id$
+ * $HeadURL:$
+ * %%
+ * Copyright (C) 2012 - 2014 Ifremer
+ * %%
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU 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 General Public
+ * License along with this program. If not, see
+ * <http://www.gnu.org/licenses/gpl-3.0.html>.
+ * #L%
+ */
+
+import fr.ifremer.tutti.TuttiConfigurationOption;
+import fr.ifremer.tutti.persistence.ProgressionModel;
+import fr.ifremer.tutti.persistence.entities.data.BatchContainer;
+import fr.ifremer.tutti.persistence.entities.data.CatchBatch;
+import fr.ifremer.tutti.persistence.entities.data.FishingOperation;
+import fr.ifremer.tutti.persistence.entities.data.SpeciesBatch;
+import fr.ifremer.tutti.service.PersistenceService;
+import fr.ifremer.tutti.service.ServiceDbResource;
+import fr.ifremer.tutti.service.TuttiServiceContext;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.ClassRule;
+import org.junit.Test;
+
+import java.io.File;
+import java.io.IOException;
+
+/**
+ * Created on 1/19/14.
+ *
+ * @author Tony Chemit <chemit(a)codelutin.com>
+ * @since 3.1
+ */
+public class PsionImportServiceTest {
+
+ @ClassRule
+ public static final ServiceDbResource dbResource =
+ ServiceDbResource.writeDb("dbExport");
+
+ /** Logger. */
+ private static final Log log = LogFactory.getLog(PsionImportServiceTest.class);
+
+ public static final String PROGRAM_ID = "CAM-TEST_ELEVATION";
+
+ public static final String CRUISE_ID = "100003";
+
+ public static final String OPERATION_1_ID = "100112";
+
+ public static final String OPERATION_2_ID = "100113";
+
+ public static final String OPERATION_3_ID = "100115";
+
+ protected PsionImportService service;
+
+ protected PersistenceService persistenceService;
+
+ protected ServiceDbResource.DataContext dataContext;
+
+ protected ProgressionModel progressionModel;
+
+ protected File dataDirectory;
+
+ @Before
+ public void setUp() throws Exception {
+
+ dataDirectory = dbResource.getConfig().getDataDirectory();
+
+ TuttiServiceContext serviceContext = dbResource.getServiceContext();
+
+ File protocol = dbResource.copyClassPathResource("pupitri/ano-3898.tuttiProtocol", "ano-3898.tuttiProtocol");
+ dbResource.getConfig().getApplicationConfig().setOption(TuttiConfigurationOption.DB_PROTOCOL_DIRECTORY.getKey(), protocol.getParentFile().getAbsolutePath());
+ serviceContext.getDataContext().setProtocolId("ano-3898");
+
+ dbResource.openDataContext();
+
+ persistenceService = serviceContext.getService(PersistenceService.class);
+ service = serviceContext.getService(PsionImportService.class);
+
+ progressionModel = new ProgressionModel();
+ progressionModel.setTotal(9);
+
+ dataContext = dbResource.loadContext(PROGRAM_ID, CRUISE_ID, 3, OPERATION_2_ID, OPERATION_1_ID, OPERATION_3_ID);
+ }
+
+ @Test
+ public void importCC053() throws IOException {
+
+ File trunk = dbResource.copyClassPathResource("psion/CC053.IWA", "CC053.IWA");
+
+ FishingOperation operation = dataContext.operations.get(1);
+ CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
+ catchBatch.setFishingOperation(operation);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
+ PsionImportResult arpImportResult = service.importFile(trunk, operation, catchBatch);
+
+ PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+
+ int nbAdded = importResult.getNbImported();
+ int nbNotAdded = importResult.getNbNotImported();
+
+ if (log.isInfoEnabled()) {
+ log.info("Imported: " + nbAdded);
+ log.info("Ignored: " + nbNotAdded);
+ }
+
+ Assert.assertEquals(9, nbAdded);
+ Assert.assertEquals(9, nbNotAdded);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+ Assert.assertEquals(9, rootSpeciesBatchAfter.sizeChildren());
+ }
+
+ @Test
+ public void importFM001() throws IOException {
+
+ File trunk = dbResource.copyClassPathResource("psion/FM001.IWA", "FM001.IWA");
+
+ FishingOperation operation = dataContext.operations.get(1);
+ CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
+ catchBatch.setFishingOperation(operation);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
+ PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+
+ int nbAdded = importResult.getNbImported();
+ int nbNotAdded = importResult.getNbNotImported();
+
+ if (log.isInfoEnabled()) {
+ log.info("Imported: " + nbAdded);
+ log.info("Ignored: " + nbNotAdded);
+ }
+
+ Assert.assertEquals(2, nbAdded);
+ Assert.assertEquals(8, nbNotAdded);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+ Assert.assertEquals(2, rootSpeciesBatchAfter.sizeChildren());
+ }
+
+ @Test
+ public void importCFchephren() throws IOException {
+
+ File trunk = dbResource.copyClassPathResource("psion/CFchephren 110612.IWA", "CFchephren 110612.IWA");
+
+ FishingOperation operation = dataContext.operations.get(1);
+ CatchBatch catchBatch = persistenceService.getCatchBatchFromFishingOperation(operation.getId());
+ catchBatch.setFishingOperation(operation);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatch = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+// Assert.assertEquals(3, rootSpeciesBatch.sizeChildren());
+ PsionImportResult importResult = service.importFile(trunk, operation, catchBatch);
+
+ int nbAdded = importResult.getNbImported();
+ int nbNotAdded = importResult.getNbNotImported();
+
+ if (log.isInfoEnabled()) {
+ log.info("Imported: " + nbAdded);
+ log.info("Ignored: " + nbNotAdded);
+ }
+
+ Assert.assertEquals(0, nbAdded);
+ Assert.assertEquals(1, nbNotAdded);
+
+ BatchContainer<SpeciesBatch> rootSpeciesBatchAfter = persistenceService.getRootSpeciesBatch(operation.getId(), null);
+ Assert.assertEquals(0, rootSpeciesBatchAfter.sizeChildren());
+ }
+}
Property changes on: trunk/tutti-service/src/test/java/fr/ifremer/tutti/service/psionimport/PsionImportServiceTest.java
___________________________________________________________________
Added: svn:keywords
+ Author Date Id Revision
Added: svn:eol-style
+ native
Added: trunk/tutti-service/src/test/resources/psion/CC053.IWA
===================================================================
--- trunk/tutti-service/src/test/resources/psion/CC053.IWA (rev 0)
+++ trunk/tutti-service/src/test/resources/psion/CC053.IWA 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,590 @@
+cc
+053
+06-13-2013
+07:19:11
+
+ESPE : MERLMER
+POID : 50
+TAIL : 50
+CATE : I
+LONG : 12.5
+LONG : 15
+ESPE : SPICMAE
+POID : 20
+TAIL : 20
+CATE : N
+LONG : 12
+ESPE : TRIPLAS
+POID : 40
+TAIL : 40
+CATE : N
+LONG : 15
+ESPE : PAGEERY
+POID : 760
+TAIL : 760
+CATE : N
+LONG : 16.5
+LONG : 20
+LONG : 20
+LONG : 18.5
+LONG : 17.5
+LONG : 18.5
+LONG : 17.5
+LONG : 19
+LONG : 18.5
+ESPE : ELEDMOS
+POID : 230
+TAIL : 230
+CATE : N
+LONG : 5
+LONG : 6
+LONG : 5
+ESPE : SOLEVUL
+POID : 1350
+TAIL : 1350
+CATE : N
+LONG : 34.5
+LONG : 27.5
+LONG : 31
+LONG : 23
+LONG : 21.5
+LONG : 34.5
+ESPE : ELEDCIR
+POID : 4650
+TAIL : 1820
+CATE : N
+LONG : 6.5
+LONG : 5.5
+LONG : 5.5
+LONG : 5
+LONG : 5
+LONG : 5
+LONG : 5
+LONG : 5
+LONG : 5.5
+LONG : 5
+LONG : 5
+LONG : 5.5
+LONG : 5.5
+LONG : 5.5
+LONG : 5
+LONG : 5
+LONG : 5
+LONG : 4
+LONG : 4
+LONG : 4
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+LONG : 4.5
+ESPE : SPICMAE
+POID : 864
+TAIL : 300
+CATE : N
+LONG : 11.5
+LONG : 13.5
+LONG : 14
+LONG : 14.5
+LONG : 17
+LONG : 15.5
+LONG : 12.5
+LONG : 14
+LONG : 14
+LONG : 13.5
+ESPE : EUTRGUR
+POID : 3788
+TAIL : 1315
+CATE : N
+LONG : 20
+LONG : 16
+LONG : 15
+LONG : 17.5
+LONG : 15.5
+LONG : 18.5
+LONG : 15
+LONG : 16
+LONG : 14.5
+LONG : 13.5
+LONG : 17.5
+LONG : 16
+LONG : 16.5
+LONG : 19
+LONG : 15.5
+LONG : 16
+LONG : 16
+LONG : 16
+LONG : 17
+LONG : 17
+LONG : 19
+LONG : 13.5
+LONG : 19
+LONG : 18
+LONG : 23.5
+LONG : 16.5
+LONG : 16.5
+LONG : 16.5
+LONG : 15
+LONG : 15.5
+LONG : 14.5
+LONG : 16.5
+LONG : 19
+LONG : 18
+LONG : 13.5
+ESPE : TRISCAP
+POID : 7777
+TAIL : 1545
+CATE : N
+LONG : 16
+LONG : 20
+LONG : 17
+LONG : 20
+LONG : 18.5
+LONG : 18.5
+LONG : 19.5
+LONG : 18
+LONG : 16.5
+LONG : 18.5
+LONG : 17.5
+LONG : 20.5
+LONG : 16.5
+LONG : 16.5
+LONG : 17
+LONG : 18.5
+LONG : 16
+LONG : 17.5
+LONG : 17
+LONG : 18.5
+LONG : 15.5
+LONG : 16
+LONG : 16.5
+LONG : 16.5
+LONG : 16.5
+ESPE : TRACMED
+POID : 10700
+TAIL : 3715
+CATE : N
+LONG : 21
+LONG : 18.5
+LONG : 22
+LONG : 21.5
+LONG : 24.5
+LONG : 18.5
+LONG : 18
+LONG : 13
+LONG : 21
+LONG : 21
+LONG : 20
+LONG : 13.5
+LONG : 21.5
+LONG : 16
+LONG : 23
+LONG : 22
+LONG : 22
+LONG : 17
+LONG : 19.5
+LONG : 20
+LONG : 23.5
+LONG : 19.5
+LONG : 12.5
+LONG : 19.5
+LONG : 14
+LONG : 19
+LONG : 20
+LONG : 18
+LONG : 23
+LONG : 18.5
+LONG : 10.5
+LONG : 10
+LONG : 15.5
+LONG : 19
+LONG : 16
+LONG : 16
+LONG : 19.5
+LONG : 20.5
+LONG : 26
+LONG : 12
+LONG : 20.5
+LONG : 22.5
+LONG : 19.5
+LONG : 21
+LONG : 24
+LONG : 25.5
+LONG : 17.5
+LONG : 19
+LONG : 17
+LONG : 20
+LONG : 17.5
+LONG : 16
+LONG : 20
+LONG : 15.5
+LONG : 14
+LONG : 12
+LONG : 17
+LONG : 13
+LONG : 9
+LONG : 10.5
+LONG : 9
+LONG : 9.5
+LONG : 14
+LONG : 12
+ESPE : PAGEACA
+POID : 6600
+TAIL : 3220
+CATE : N
+LONG : 17.5
+LONG : 17.5
+LONG : 17.5
+LONG : 16.5
+LONG : 17.5
+LONG : 16
+LONG : 17.5
+LONG : 16.5
+LONG : 18
+LONG : 18
+LONG : 21.5
+LONG : 17
+LONG : 18
+LONG : 17.5
+LONG : 17.5
+LONG : 18
+LONG : 17
+LONG : 18
+LONG : 18
+LONG : 17.5
+LONG : 17
+LONG : 17
+LONG : 17
+LONG : 19
+LONG : 17.5
+LONG : 22
+LONG : 17
+LONG : 17
+LONG : 18.5
+LONG : 17.5
+LONG : 18
+LONG : 16.5
+LONG : 17.5
+LONG : 17
+LONG : 17.5
+LONG : 17.5
+LONG : 17.5
+LONG : 16
+LONG : 16
+LONG : 17.5
+LONG : 16
+LONG : 17.5
+LONG : 17.5
+ESPE : BOOPBOO
+POID : 45943
+TAIL : 2230
+CATE : N
+LONG : 21
+LONG : 17
+LONG : 17
+LONG : 16
+LONG : 16.5
+LONG : 17
+LONG : 20
+LONG : 17.5
+LONG : 17
+LONG : 16
+LONG : 16.5
+LONG : 16.5
+LONG : 18.5
+LONG : 15.5
+LONG : 16.5
+LONG : 16.5
+LONG : 17
+LONG : 16.5
+LONG : 16.5
+LONG : 16.5
+LONG : 17.5
+LONG : 18
+LONG : 20
+LONG : 16.5
+LONG : 17
+LONG : 16.5
+LONG : 16.5
+LONG : 17
+LONG : 16
+LONG : 21.5
+LONG : 19
+LONG : 17
+LONG : 16
+LONG : 18
+LONG : 15
+LONG : 16.5
+LONG : 17
+LONG : 13.5
+LONG : 15
+ESPE : MERLMER
+POID : 395
+TAIL : 395
+CATE : F
+LONG : 34.5
+ESPE : LOPHPIS
+POID : 1175
+TAIL : 1175
+CATE : F
+LONG : 32
+LONG : 28.5
+LONG : 27.5
+ESPE : MERLMER
+POID : 317
+TAIL : 110
+CATE : I
+LONG : 15.5
+LONG : 15
+LONG : 15
+LONG : 14
+LONG : 11.5
+ESPE : SQUIMAN
+POID : 37
+TAIL : 37
+CATE : N
+LONG : 27
+ESPE : OCTOVUL
+POID : 11600
+TAIL : 11600
+CATE : N
+LONG : 11
+LONG : 14
+LONG : 13
+LONG : 13
+LONG : 6.5
+LONG : 10
+LONG : 7.5
+LONG : 6.5
+ESPE : DIPLVUL
+POID : 2250
+TAIL : 2250
+CATE : N
+LONG : 20.5
+LONG : 20.5
+LONG : 18.5
+LONG : 15.5
+LONG : 19.5
+LONG : 20.5
+LONG : 21
+LONG : 22
+LONG : 18
+LONG : 18
+LONG : 18.5
+LONG : 19.5
+LONG : 24
+LONG : 20
+LONG : 20
+LONG : 19.5
+LONG : 18
+LONG : 19.5
+ESPE : TRISCAP
+POID : 3341
+TAIL : 210
+CATE : N
+LONG : 9.5
+LONG : 10.5
+LONG : 8.5
+LONG : 8
+LONG : 9
+LONG : 8
+LONG : 8
+LONG : 8
+LONG : 8
+LONG : 8
+LONG : 11
+LONG : 10.5
+LONG : 10
+LONG : 10
+LONG : 8.5
+LONG : 8.5
+LONG : 8.5
+LONG : 9
+LONG : 9
+LONG : 8
+LONG : 9.5
+LONG : 9
+LONG : 7.5
+LONG : 8
+LONG : 8
+LONG : 8.5
+LONG : 8.5
+LONG : 8.5
+LONG : 8.5
+LONG : 8.5
+ESPE : TRACTRA
+POID : 1267
+TAIL : 440
+CATE : N
+LONG : 20
+LONG : 8
+LONG : 8
+LONG : 8.5
+LONG : 7.5
+LONG : 6.5
+LONG : 9
+LONG : 9
+LONG : 8.5
+LONG : 16
+LONG : 9
+LONG : 14
+LONG : 17.5
+LONG : 18
+LONG : 15.5
+LONG : 9
+LONG : 10.5
+LONG : 8
+LONG : 11
+LONG : 8
+LONG : 8
+LONG : 8.5
+LONG : 8.5
+LONG : 9
+LONG : 9
+LONG : 8
+LONG : 7
+LONG : 8
+LONG : 8.5
+LONG : 8
+LONG : 8.5
+LONG : 7.5
+LONG : 7.5
+LONG : 8
+LONG : 7.5
+ESPE : MULLBAR
+POID : 3629
+TAIL : 1260
+CATE : M
+LONG : 12
+LONG : 11.5
+LONG : 11
+LONG : 11.5
+LONG : 11.5
+LONG : 10.5
+LONG : 10.5
+LONG : 11.5
+LONG : 11.5
+LONG : 11
+LONG : 9
+LONG : 11.5
+LONG : 10.5
+LONG : 12.5
+LONG : 11.5
+LONG : 11
+LONG : 11
+LONG : 11.5
+LONG : 10.5
+LONG : 10.5
+LONG : 12
+LONG : 11.5
+LONG : 13
+LONG : 11
+LONG : 12
+LONG : 11
+LONG : 11.5
+LONG : 12
+LONG : 10.5
+LONG : 11.5
+LONG : 11
+LONG : 10.5
+LONG : 9.5
+LONG : 10.5
+LONG : 11
+LONG : 10.5
+LONG : 11
+LONG : 11
+LONG : 12
+LONG : 16
+LONG : 13.5
+LONG : 13
+LONG : 12
+LONG : 13
+LONG : 16.5
+LONG : 12
+LONG : 11.5
+LONG : 12
+LONG : 11
+LONG : 11
+LONG : 11.5
+LONG : 13
+LONG : 12
+LONG : 11
+LONG : 14
+LONG : 12.5
+LONG : 11.5
+LONG : 12
+LONG : 12.5
+LONG : 12
+LONG : 12.5
+LONG : 16
+LONG : 16
+LONG : 11.5
+LONG : 11.5
+LONG : 10.5
+LONG : 11.5
+LONG : 11.5
+ESPE : MULLBAR
+POID : 4853
+TAIL : 1685
+CATE : F
+LONG : 9.5
+LONG : 10.5
+LONG : 11.5
+LONG : 11.5
+LONG : 13
+LONG : 12
+LONG : 10.5
+LONG : 12
+LONG : 12
+LONG : 13.5
+LONG : 16.5
+LONG : 12.5
+LONG : 15.5
+LONG : 12.5
+LONG : 12
+LONG : 14
+LONG : 14.5
+LONG : 14.5
+LONG : 14.5
+LONG : 14.5
+LONG : 12.5
+LONG : 13
+LONG : 13.5
+LONG : 12
+LONG : 12
+LONG : 11.5
+LONG : 12
+LONG : 13
+LONG : 15.5
+LONG : 14.5
+LONG : 13.5
+LONG : 13
+LONG : 13
+LONG : 13
+LONG : 14
+LONG : 15.5
+LONG : 14.5
+LONG : 14
+LONG : 12.5
+LONG : 17
+LONG : 15
+LONG : 15
+LONG : 15
+LONG : 16
+LONG : 15
+LONG : 14.5
+LONG : 14.5
+LONG : 14.5
+LONG : 15.5
+LONG : 14
+LONG : 13.5
+LONG : 16
+LONG : 13.5
+LONG : 15
Added: trunk/tutti-service/src/test/resources/psion/CFchephren 110612.IWA
===================================================================
--- trunk/tutti-service/src/test/resources/psion/CFchephren 110612.IWA (rev 0)
+++ trunk/tutti-service/src/test/resources/psion/CFchephren 110612.IWA 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,330 @@
+
+INIT : CF
+PORT : LOC
+DATE : 06-11-2012
+HEUR : 04:37:33
+OUTI : Pied � coulisse
+NAVI : CHEPHREN
+ENGI : B
+ESPE : 4401
+TAXO : 1
+LONG : 10.77
+LONG : 10.25
+LONG : 11.59
+LONG : 10.55
+LONG : 12.88
+LONG : 11.06
+LONG : 9.64
+LONG : 10.16
+LONG : 12.70
+LONG : 14.29
+LONG : 14.24
+LONG : 10.48
+LONG : 11.52
+LONG : 10.60
+LONG : 10.47
+LONG : 10.77
+LONG : 8.61
+LONG : 12.94
+LONG : 12.10
+LONG : 13.31
+LONG : 10.86
+LONG : 10.71
+LONG : 13.07
+LONG : 12.02
+LONG : 11.08
+LONG : 12.31
+LONG : 11.78
+LONG : 11.94
+LONG : 10.35
+LONG : 12.07
+LONG : 9.86
+LONG : 12.28
+LONG : 10.35
+LONG : 11.28
+LONG : 12.50
+LONG : 12.09
+LONG : 11.07
+LONG : 9.63
+LONG : 10.31
+LONG : 8.85
+LONG : 10.14
+LONG : 12.15
+LONG : 10.69
+LONG : 11.50
+LONG : 10.45
+LONG : 10.10
+LONG : 10.70
+TAXO : 2
+LONG : 12.33
+LONG : 11.89
+LONG : 10.21
+LONG : 10.55
+LONG : 9.95
+LONG : 10.83
+LONG : 9.92
+LONG : 12.32
+LONG : 11.90
+LONG : 10.43
+LONG : 10.46
+LONG : 10.33
+LONG : 10.82
+LONG : 9.87
+LONG : 9.89
+LONG : 10.91
+LONG : 10.28
+LONG : 10.29
+LONG : 11.18
+LONG : 9.86
+LONG : 11.00
+LONG : 11.52
+LONG : 11.22
+LONG : 12.02
+LONG : 11.11
+LONG : 9.59
+LONG : 11.26
+LONG : 10.02
+LONG : 10.61
+LONG : 9.31
+LONG : 10.85
+LONG : 11.24
+LONG : 10.25
+LONG : 11.20
+LONG : 11.11
+LONG : 11.77
+LONG : 9.89
+LONG : 10.53
+LONG : 10.46
+LONG : 11.77
+LONG : 12.44
+LONG : 9.96
+LONG : 10.32
+LONG : 10.23
+LONG : 10.96
+LONG : 10.65
+LONG : 10.06
+LONG : 8.15
+LONG : 10.53
+LONG : 12.65
+LONG : 10.49
+LONG : 12.22
+LONG : 11.49
+LONG : 11.01
+LONG : 10.46
+LONG : 10.02
+LONG : 11.39
+LONG : 9.98
+LONG : 10.72
+LONG : 10.64
+LONG : 11.28
+LONG : 11.59
+LONG : 11.89
+LONG : 11.47
+LONG : 11.18
+LONG : 10.62
+LONG : 12.19
+LONG : 10.16
+LONG : 10.40
+LONG : 11.98
+LONG : 11.87
+LONG : 11.92
+LONG : 10.86
+LONG : 10.07
+LONG : 11.23
+LONG : 9.93
+LONG : 10.24
+LONG : 10.95
+LONG : 9.69
+LONG : 9.82
+LONG : 11.61
+LONG : 9.57
+LONG : 11.40
+LONG : 10.22
+LONG : 9.27
+LONG : 10.80
+LONG : 11.40
+LONG : 9.68
+LONG : 10.68
+LONG : 7.09
+LONG : 10.61
+LONG : 10.33
+LONG : 10.73
+TAXO : 1
+LONG : 11.79
+LONG : 11.35
+LONG : 10.58
+LONG : 11.32
+LONG : 15.86
+TAXO : 2
+LONG : 10.49
+LONG : 10.60
+LONG : 10.73
+LONG : 10.31
+LONG : 9.52
+TAXO : 1
+LONG : 1.16
+CAIS : 05:13:38
+AGEN : CF
+PORT : LOC
+DATE : 06-11-2012
+HEUR : 05:14:3
+OUTI : Ichtyometre
+OUTI : Pied a coulisse
+NAVI : CHEPHREN
+ENGI : B
+ESPE : 4401
+CATE : N
+TAXO : 2
+LONG : 46
+TAXO : 1
+LONG : 56
+LONG : 53
+LONG : 54
+LONG : 57
+LONG : 50
+LONG : 53
+LONG : 54
+LONG : 56
+LONG : 55
+LONG : 55
+LONG : 51
+LONG : 48
+LONG : 51
+LONG : 58
+LONG : 49
+LONG : 51
+LONG : 50
+LONG : 49
+LONG : 54
+LONG : 47
+LONG : 49
+LONG : 51
+LONG : 49
+LONG : 51
+LONG : 49
+LONG : 56
+LONG : 52
+LONG : 56
+LONG : 56
+LONG : 51
+LONG : 50
+LONG : 53
+LONG : 52
+LONG : 51
+LONG : 51
+LONG : 48
+LONG : 51
+LONG : 48
+LONG : 55
+LONG : 49
+LONG : 51
+LONG : 57
+LONG : 53
+LONG : 53
+LONG : 57
+LONG : 54
+LONG : 48
+LONG : 51
+LONG : 52
+LONG : 58
+LONG : 52
+LONG : 54
+LONG : 54
+LONG : 51
+LONG : 54
+LONG : 53
+LONG : 53
+LONG : 58
+LONG : 53
+LONG : 48
+LONG : 50
+LONG : 50
+LONG : 54
+LONG : 56
+LONG : 58
+LONG : 53
+LONG : 50
+LONG : 50
+LONG : 54
+LONG : 56
+LONG : 49
+LONG : 54
+LONG : 55
+LONG : 54
+LONG : 50
+LONG : 50
+LONG : 53
+LONG : 59
+LONG : 51
+LONG : 49
+LONG : 52
+LONG : 45
+LONG : 49
+LONG : 56
+LONG : 55
+LONG : 55
+LONG : 54
+LONG : 53
+LONG : 53
+LONG : 52
+LONG : 61
+LONG : 55
+LONG : 51
+LONG : 53
+LONG : 53
+LONG : 55
+LONG : 55
+LONG : 55
+LONG : 52
+LONG : 53
+LONG : 54
+LONG : 50
+LONG : 54
+LONG : 47
+LONG : 54
+LONG : 57
+LONG : 51
+LONG : 51
+LONG : 51
+LONG : 56
+LONG : 50
+LONG : 53
+LONG : 47
+LONG : 56
+LONG : 57
+LONG : 54
+LONG : 56
+LONG : 55
+LONG : 48
+LONG : 58
+LONG : 55
+LONG : 59
+LONG : 51
+LONG : 49
+LONG : 51
+LONG : 52
+LONG : 54
+LONG : 41
+LONG : 53
+LONG : 54
+LONG : 51
+LONG : 56
+LONG : 54
+LONG : 47
+LONG : 49
+LONG : 48
+LONG : 54
+LONG : 49
+LONG : 49
+LONG : 54
+LONG : 53
+LONG : 51
+LONG : 55
+LONG : 51
+LONG : 52
+LONG : 53
+LONG : 50
+LONG : 53
+LONG : 52
+LONG : 49
+CAIS : 05:35:7
Added: trunk/tutti-service/src/test/resources/psion/FM001.IWA
===================================================================
--- trunk/tutti-service/src/test/resources/psion/FM001.IWA (rev 0)
+++ trunk/tutti-service/src/test/resources/psion/FM001.IWA 2014-01-20 20:41:49 UTC (rev 1516)
@@ -0,0 +1,210 @@
+fm
+001
+05-24-2013
+18:28:13
+
+ESPE : HELIDAC
+POID : 1040
+TAIL : 1040
+CATE : N
+LONG : 21.5
+LONG : 26
+LONG : 22
+LONG : 24
+LONG : 25.5
+ESPE : TODASAG
+POID : 265
+TAIL : 265
+CATE : N
+LONG : 21
+ESPE : RAJAOXY
+POID : 115
+TAIL : 115
+CATE : F1
+LONG : 35
+ESPE : PHYIBLE
+POID : 235
+TAIL : 235
+CATE : N
+LONG : 6.5
+LONG : 6.5
+LONG : 7.5
+LONG : 7.5
+LONG : 6
+LONG : 6.5
+LONG : 7.5
+LONG : 7.5
+LONG : 8
+LONG : 8
+LONG : 6.5
+LONG : 8.5
+LONG : 7.5
+LONG : 7
+LONG : 5.5
+LONG : 7.5
+LONG : 7
+LONG : 6.5
+LONG : 7.5
+LONG : 7.5
+LONG : 6
+LONG : 6
+LONG : 6
+LONG : 6.5
+LONG : 5.5
+LONG : 6.5
+LONG : 7
+LONG : 7.5
+LONG : 6.5
+LONG : 18
+LONG : 16
+LONG : 22.5
+LONG : 15.5
+LONG : 16
+LONG : 7.5
+LONG : 7.5
+ESPE : GALUMEL
+POID : 1460
+TAIL : 1460
+CATE : M
+LONG : 35
+LONG : 32.5
+LONG : 34
+LONG : 33.5
+LONG : 40
+LONG : 40
+LONG : 40
+LONG : 42
+LONG : 45
+ESPE : LEPMBOS
+POID : 275
+TAIL : 275
+CATE : N
+LONG : 21
+LONG : 15.5
+LONG : 16.5
+LONG : 20
+LONG : 20
+LONG : 14
+ESPE : GALUMEL
+POID : 4890
+TAIL : 4890
+CATE : F
+LONG : 42
+LONG : 43.5
+LONG : 34
+LONG : 40
+LONG : 44
+LONG : 36.5
+LONG : 30.5
+LONG : 37.5
+LONG : 40
+LONG : 38
+LONG : 37
+LONG : 38
+LONG : 37
+LONG : 40
+LONG : 43
+LONG : 38
+LONG : 35
+LONG : 46
+LONG : 49
+LONG : 48.5
+LONG : 48.5
+LONG : 46.5
+LONG : 48.5
+ESPE : NEPRNOR
+POID : 110
+TAIL : 110
+CATE : F
+LONG : 28
+LONG : 31
+LONG : 29
+LONG : 36
+LONG : 25
+LONG : 32
+LONG : 32
+LONG : 34
+ESPE : NEPRNOR
+POID : 365
+TAIL : 365
+CATE : M
+LONG : 54
+LONG : 44
+LONG : 47
+LONG : 39
+LONG : 27
+LONG : 37
+LONG : 30
+LONG : 32
+LONG : 34
+LONG : 32
+ESPE : ARISFOL
+POID : 775
+TAIL : 775
+CATE : F
+LONG : 46
+LONG : 47
+LONG : 43
+LONG : 43
+LONG : 45
+LONG : 43
+LONG : 45
+LONG : 47
+LONG : 46
+LONG : 33
+LONG : 43
+LONG : 33
+LONG : 29
+LONG : 43
+LONG : 46
+LONG : 45
+LONG : 46
+LONG : 45
+LONG : 46
+LONG : 43
+LONG : 42
+LONG : 42
+LONG : 43
+LONG : 45
+LONG : 46
+LONG : 45
+LONG : 47
+LONG : 45
+LONG : 40
+ESPE : ARISFOL
+POID : 75
+TAIL : 75
+CATE : M
+LONG : 34
+LONG : 32
+LONG : 38
+LONG : 32
+LONG : 33
+ESPE : PAPELON
+POID : 40
+TAIL : 40
+CATE : M
+LONG : 30
+LONG : 32
+LONG : 33
+ESPE : PAPELON
+POID : 40
+TAIL : 40
+CATE : F
+LONG : 36
+LONG : 36
+ESPE : ETMOSPI
+POID : 90
+TAIL : 90
+CATE : F
+LONG : 20
+LONG : 19.5
+LONG : 12.5
+ESPE : ETMOSPI
+POID : 295
+TAIL : 295
+CATE : M
+LONG : 18.5
+LONG : 13
+LONG : 30.5
+LONG : 30.5
1
0
r1515 - in trunk/tutti-ui-swing/src/main/help: css fr
by lkaufmann@users.forge.codelutin.com 20 Jan '14
by lkaufmann@users.forge.codelutin.com 20 Jan '14
20 Jan '14
Author: lkaufmann
Date: 2014-01-20 18:08:33 +0100 (Mon, 20 Jan 2014)
New Revision: 1515
Url: http://forge.codelutin.com/projects/tutti/repository/revisions/1515
Log:
Refs #4138. Update screen/db help page content
Modified:
trunk/tutti-ui-swing/src/main/help/css/style.css
trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
Modified: trunk/tutti-ui-swing/src/main/help/css/style.css
===================================================================
--- trunk/tutti-ui-swing/src/main/help/css/style.css 2014-01-20 16:51:25 UTC (rev 1514)
+++ trunk/tutti-ui-swing/src/main/help/css/style.css 2014-01-20 17:08:33 UTC (rev 1515)
@@ -44,4 +44,14 @@
.dropdown-submenu:hover>.dropdown-menu{display:block;}
.dropdown-submenu>a:after{display:block;content:" ";float:right;width:0;height:0;border-color:transparent;border-style:solid;border-width:5px 0 5px 5px;border-left-color:#cccccc;margin-top:5px;margin-right:-10px;}
.dropdown-submenu:hover>a:after{border-left-color:#ffffff;}
-.dropdown-submenu.pull-left{float:none;}.dropdown-submenu.pull-left>.dropdown-menu{left:-100%;margin-left:10px;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px;}
\ No newline at end of file
+.dropdown-submenu.pull-left{float:none;}.dropdown-submenu.pull-left>.dropdown-menu{left:-100%;margin-left:10px;-webkit-border-radius:6px 0 6px 6px;-moz-border-radius:6px 0 6px 6px;border-radius:6px 0 6px 6px;}
+
+
+.table > thead > tr > .danger,
+.table > tbody > tr > .danger,
+.table > tfoot > tr > .danger,
+.table > thead > .danger > td,
+.table > tbody > .danger > td,
+.table > tfoot > .danger > td {
+ background-color: #F2DEDE !important;
+}
\ No newline at end of file
Modified: trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html
===================================================================
--- trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-20 16:51:25 UTC (rev 1514)
+++ trunk/tutti-ui-swing/src/main/help/fr/dbMapping.html 2014-01-20 17:08:33 UTC (rev 1515)
@@ -59,7 +59,7 @@
<p>Nom</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -73,7 +73,7 @@
<p>Zone</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -88,7 +88,7 @@
<p>Description</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -117,7 +117,7 @@
<p>Série</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -127,16 +127,21 @@
<p>ScientificCruise.program (SCIENTIFIC_CRUISE.PROGRAM_FK)</p>
</td>
</tr>
- <tr>
- <td rowspan="2">
+ <tr class="danger">
+ <td rowspan="3">
<p>Année</p>
</td>
- <td rowspan="2">
+ <td rowspan="3">
<p> </p>
</td>
- <td rowspan="2">
+ <td rowspan="3">
<p> </p>
</td>
+ <td colspan="2">
+ [LK] Cet élément ne fait plus partie de l'interface ?
+ </td>
+ </tr>
+ <tr>
<td>
<p>En lecture</p>
</td>
@@ -185,7 +190,7 @@
<p>Nombre de poches</p>
</td>
<td rowspan="2">
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td rowspan="2">
<p>Numérique</p>
@@ -210,7 +215,7 @@
<p>Port de départ</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -225,7 +230,7 @@
<p>Port d'arrivée</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -240,7 +245,7 @@
<p>Date de début</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
@@ -254,7 +259,7 @@
<p>Date de fin</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
@@ -268,7 +273,7 @@
<p>Navire</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -283,7 +288,7 @@
<p>Engin(s)</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -298,7 +303,7 @@
<p>Chef(s) de mission</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -313,7 +318,7 @@
<p>Responsable(s) de salle de tri</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -357,7 +362,7 @@
<p>Nom</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -755,7 +760,7 @@
<p>Code Station</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Texte libre</p>
@@ -769,7 +774,7 @@
<p>Numéro de Trait</p>
</td>
<td>
- <p> </p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Numérique</p>
@@ -869,34 +874,56 @@
</tr>
<tr>
<td>
- <p>Date et Heure de début de traîne</p>
+ <p>Date de début de traîne</p>
</td>
<td>
- <p> </p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Date (JJ/MM/AAAA)</p>
</td>
- <td>
+ <td rowspan="2">
<p>Operation.startDateTime et Operation.fishingStartDateTime (OPERATION.START_DATE_TIME et OPERATION.FISHING_START_DATE_TIME)</p>
</td>
</tr>
<tr>
<td>
- <p>Date et Heure de fin de traîne</p>
+ <p>Heure de début de traîne</p>
</td>
<td>
<p> </p>
</td>
<td>
+ <p>Heure (HH:MM)</p>
+ </td>
+ </tr>
+ <tr>
+ <td>
+ <p>Date de fin de traîne</p>
+ </td>
+ <td>
+ <p> </p>
+ </td>
+ <td>
<p>Date (JJ/MM/AAAA)</p>
</td>
- <td>
+ <td rowspan="2">
<p>Operation.endDateTime et Operation.fishingEndDateTime (OPERATION.END_DATE_TIME et OPERATION.FISHING_END_DATE_TIME)</p>
</td>
</tr>
<tr>
<td>
+ <p>Heure de fin de traîne</p>
+ </td>
+ <td>
+ <p> </p>
+ </td>
+ <td>
+ <p>Heure (HH:MM)</p>
+ </td>
+ </tr>
+ <tr>
+ <td>
<p>Trait rectiligne</p>
</td>
<td>
@@ -931,10 +958,10 @@
<p> </p>
</td>
<td>
- <p>Numérique</p>
+ <p>Numérique (Lecture seule)</p>
</td>
<td>
- <p> </p>
+ <p>Non stockée en base</p>
</td>
</tr>
<tr>
@@ -966,7 +993,7 @@
<p>Operation.vesselPersonFeatures avec un VesselPersonRole.id=<responsable_de_campagne></p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Autres caractéristiques du Navire</p>
</td>
@@ -977,7 +1004,7 @@
<p>Lecture seule</p>
</td>
<td>
- <p>Operation.vessel (OPERATION.VESSEL_FK)</p>
+ <p>(depuis version 1.2) Identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) (Obsolète) : TODO supprimer le code qui fait cette gestion Si le navire est identique à celui de la campagne : Operation.vessel (OPERATION.VESSEL_FK) Sinon : Operation.operationVesselAssociation (OPERATION_VESSEL_ASSOCIATION.VESSEL_FK avec IS_CATCH_ON_OPERATION_VESSEL=0). Operation.vessel est alors rempli avec le premier navire de la liste de la campagne, pour être compatible avec Allegro (on doit toujours avoir : SCIENTIFIC_CRUISE.VESSEL_FK = OPERATION_VESSEL_FK).</p>
</td>
</tr>
<tr>
@@ -995,7 +1022,7 @@
<p>Operation.gearPhysicialFeatures (OPERATION.GEAR_PHYSCIAL_FEATURES_FK) : lien vers un engin déjà déclaré au niveau de la campagne. Le code de l'engin est également dupliqué au début de Operation.name (OPERATION.NAME), devant le numéro du trait, pour rester compatible avec le format des données historiques.</p>
</td>
</tr>
- <tr>
+ <tr class="danger">
<td>
<p>Navire(s) associé(s)</p>
</td>
@@ -1007,7 +1034,7 @@
<p>Choix parmi les navires existants en base</p>
</td>
<td>
- <p> </p>
+ <p>Est-ce stocké en base ?</p>
</td>
</tr>
<tr>
@@ -1060,7 +1087,7 @@
<p>Valeur</p>
</td>
<td>
- <p>X</p>
+ <p></p>
</td>
<td>
<p>Type de la caractéristique issu d'un référentiel</p>
@@ -1073,8 +1100,10 @@
</table>
- <h3>Hydrologie et paramètres environnementaux</h3>
+ <h3>Trait > Autres paramètres</h3>
+ <p>Cet onglet permet la saisie de l'hydrologie et des paramètres environnementaux.</p>
+
<table class='table table-bordered table-striped table-hover table-condensed'>
<thead>
<tr>
@@ -1085,18 +1114,19 @@
</tr>
</thead>
<tbody>
- <tr>
+ <tr class="danger">
<td>
<p>Valeur</p>
</td>
<td>
- <p>X</p>
+ <p></p>
</td>
<td>
<p>Type de la caractéristique issu d'un référentiel</p>
</td>
<td>
- <p>Operation.gearUseFeatures.vesselUseMeasurement (GEAR_USE_MEASUREMENT.xxx - en fonction du type de PSFM : NUMERICAL_VALUE, ALPHANUMERICAL_VALUE ou QUALITATIVE_VALUE_FK</p>
+ <p>Operation.gearUseFeatures.vesselUseMeasurement (GEAR_USE_MEASUREMENT.xxx - en fonction du type de PSFM : NUMERICAL_VALUE, ALPHANUMERICAL_VALUE ou QUALITATIVE_VALUE_FK<br/>
+ <strong>WARNING</strong> : En v2 (version à confirmer), informations dispatcher dans différent onglet, en fonction du PSFM trouvé dans le protocole</p>
</td>
</tr>
</tbody>
@@ -2113,7 +2143,7 @@
<p>Tableau > Espèce</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
@@ -2272,7 +2302,7 @@
<p>Tableau > Espèce</p>
</td>
<td>
- <p>X</p>
+ <p style="text-align:center;font-weight:bold;">X</p>
</td>
<td>
<p>Liste.</p>
1
0