From 8a2d919c5aec5a4540e1ae2b000a4371793e10bd Mon Sep 17 00:00:00 2001
From: Mathias Chouet <mathias.chouet@irstea.fr>
Date: Mon, 11 May 2020 15:36:38 +0200
Subject: [PATCH] Translations for Verificateur : PVMax

---
 src/app/calculators/espece/config.json | 10 ++++++++++
 src/app/calculators/espece/en.json     |  5 ++++-
 src/app/calculators/espece/fr.json     |  5 ++++-
 src/locale/messages.en.json            |  3 +++
 src/locale/messages.fr.json            | 11 +++++++----
 5 files changed, 28 insertions(+), 6 deletions(-)

diff --git a/src/app/calculators/espece/config.json b/src/app/calculators/espece/config.json
index 096e616f0..e3718104c 100644
--- a/src/app/calculators/espece/config.json
+++ b/src/app/calculators/espece/config.json
@@ -1,4 +1,14 @@
 [
+    {
+        "id": "fs_param_common",
+        "type": "fieldset",
+        "fields": [
+            {
+                "id": "PVMax",
+                "allowEmpty": true
+            }
+        ]
+    },
     {
         "id": "fs_param_pab_s",
         "type": "fieldset",
diff --git a/src/app/calculators/espece/en.json b/src/app/calculators/espece/en.json
index 11f45ce1a..cedf49fdf 100644
--- a/src/app/calculators/espece/en.json
+++ b/src/app/calculators/espece/en.json
@@ -1,4 +1,5 @@
 {
+    "fs_param_common": "Common parameters",
     "fs_param_pab_s": "Fish ladders, surface jets or orifices",
     "fs_param_pab_p": "Fish ladders, diving jets",
     "fs_param_pam": "Rock-ramp fishpasses",
@@ -16,6 +17,7 @@
     "VMax": "Maximal flow velocity",
     "YMinSB": "Minimal water level on superactive baffles",
     "YMinPB": "Minimal water level on plane baffles",
+    "PVMax": "Maximal dissipated power",
 
     "UNIT_DHMaxS": "m",
     "UNIT_DHMaxP": "m",
@@ -28,5 +30,6 @@
     "UNIT_YMin": "m",
     "UNIT_VMax": "m/s",
     "UNIT_YMinSB": "m",
-    "UNIT_YMinPB": "m"
+    "UNIT_YMinPB": "m",
+    "UNIT_PVMax": "W/m³"
 }
diff --git a/src/app/calculators/espece/fr.json b/src/app/calculators/espece/fr.json
index 2c2ae4107..7654d4ce9 100644
--- a/src/app/calculators/espece/fr.json
+++ b/src/app/calculators/espece/fr.json
@@ -1,4 +1,5 @@
 {
+    "fs_param_common": "Paramètres communs",
     "fs_param_pab_s": "Passes à bassins, jets de surface et orifices",
     "fs_param_pab_p": "Passes à bassins, jets plongeants",
     "fs_param_pam": "Passes à macrorugosités",
@@ -16,6 +17,7 @@
     "VMax": "Vitesse d'écoulement maximale",
     "YMinSB": "Tirant d'eau minimal sur les ralentisseurs suractifs de fond",
     "YMinPB": "Tirant d'eau minimal sur les ralentisseurs plans",
+    "PVMax": "Puissance volumique dissipée maximale",
 
     "UNIT_DHMaxS": "m",
     "UNIT_DHMaxP": "m",
@@ -28,5 +30,6 @@
     "UNIT_YMin": "m",
     "UNIT_VMax": "m/s",
     "UNIT_YMinSB": "m",
-    "UNIT_YMinPB": "m"
+    "UNIT_YMinPB": "m",
+    "UNIT_PVMax": "W/m³"
 }
diff --git a/src/locale/messages.en.json b/src/locale/messages.en.json
index cb3e4c301..cf6f8349c 100644
--- a/src/locale/messages.en.json
+++ b/src/locale/messages.en.json
@@ -608,10 +608,12 @@
     "INFO_PARENT_PREFIX_DOWNWALL": "downwall: ",
     "ERROR_VERIF_ERRORS_IN_PASS": "Pass to verify contains errors",
     "ERROR_VERIF_MR_VMAX": "Maximum speed %V% too high (maximum: %maxV%)",
+    "ERROR_VERIF_MR_PVMAX": "Dissipated power %PV% too high (maximum: %maxPV%)",
     "ERROR_VERIF_MR_YMIN": "Water level %Y% too low (minimum: %minY%)",
     "ERROR_VERIF_MRC_AT_LEAST_ONE_APRON": "None of the aprons is crossable",
     "ERROR_VERIF_MRC_CROSSABLE_WIDTH": "Crossable width %width% m is lower than the width of a block pattern %patternWidth% m",
     "WARNING_VERIF_MRC_VMAX_APRON_N": "Apron #%N%: maximum speed %V% too high (maximum: %maxV%)",
+    "WARNING_VERIF_MRC_PVMAX_APRON_N": "Apron #%N%: dissipated power %PV% too high (maximum: %maxPV%)",
     "WARNING_VERIF_MRC_YMIN_APRON_N": "Apron #%N%: water level %Y% too low (minimum: %minY%)",
     "INFO_VERIF_MRC_CROSSABLE_WIDTH": "Maximum crossable width is %width% m",
     "ERROR_VERIF_NO_PRESET": "This species group is not compatible with this pass type",
@@ -641,6 +643,7 @@
     "WARNING_VERIF_PAB_YMOY_JET": "Wall #%N%: basin depth %PB% too low for jet type ENUM_STRUCTUREJETTYPE_%jetType% (minimum: %minPB%)",
     "ERROR_VERIF_PAB_YMOY_2_DH": "Wall #%N%: basin depth %PB% lower than 2x fall %DH%",
     "WARNING_VERIF_PAB_YMOY_2_DH": "Wall #%N%: basin depth %PB% lower than 2x fall %DH%",
+    "ERROR_VERIF_PAB_PVMAX": "Wall #%N%: dissipated power %PV% too high (maximum: %maxPV%)",
     "ERROR_VERIF_PAR_DH": "Downstream pass fall prevents crossability",
     "ERROR_VERIF_PAR_YMIN": "Water level %h% too low (minimum: %minY%)",
     "ERROR_VERIF_KO": "Crossability criteria are not met for at least one species group",
diff --git a/src/locale/messages.fr.json b/src/locale/messages.fr.json
index bf68ad175..9883598a3 100644
--- a/src/locale/messages.fr.json
+++ b/src/locale/messages.fr.json
@@ -611,10 +611,12 @@
     "ERROR_VERIF_ERRORS_IN_PASS": "La passe à vérifier contient des erreurs",
     "ERROR_VERIF_VARYING_ERRORS_IN_PASS": "La passe à vérifier contient des erreurs à l'itération %i%",
     "ERROR_VERIF_MR_VMAX": "Vitesse maximale %V% trop élevée (maximum&nbsp;: %maxV%)",
+    "ERROR_VERIF_MR_PVMAX": "Puissance dissipée %PV% trop élevée (maximum&nbsp;: %maxPV%)",
     "ERROR_VERIF_MR_YMIN": "Tirant d'eau %Y% insuffisant (minimum&nbsp;: %minY%)",
     "ERROR_VERIF_MRC_AT_LEAST_ONE_APRON": "Aucun des radiers n'est franchissable",
     "ERROR_VERIF_MRC_CROSSABLE_WIDTH": "La largeur franchissable %width% m est inférieure à la largeur d'un motif de blocs %patternWidth% m",
     "WARNING_VERIF_MRC_VMAX_APRON_N": "Radier n°%N%&nbsp;: vitesse maximale %V% trop élevée (maximum&nbsp;: %maxV%)",
+    "WARNING_VERIF_MRC_PVMAX_APRON_N": "Puissance dissipée %PV% trop élevée (maximum&nbsp;: %maxPV%) dans le radier %N%",
     "WARNING_VERIF_MRC_YMIN_APRON_N": "Radier n°%N%&nbsp;: tirant d'eau %Y% insuffisant (minimum&nbsp;: %minY%)",
     "INFO_VERIF_MRC_CROSSABLE_WIDTH": "La largeur franchissable maximale est %width% m",
     "ERROR_VERIF_NO_PRESET": "Ce groupe d'espèces n'est pas compatible avec ce type de passe",
@@ -635,15 +637,16 @@
     "ERROR_VERIF_PAB_HMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: charge sur l'échancrure %h1% insuffisante (minimum&nbsp;: %minH%)",
     "WARNING_VERIF_PAB_HMIN": "Cloison n°%NC%, ouvrage %NS%&nbsp;: charge sur l'échancrure %h1% insuffisante (minimum&nbsp;: %minH%)",
     "WARNING_VERIF_PAB_HMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: charge sur l'échancrure %h1% insuffisante (minimum&nbsp;: %minH%)",
-    "ERROR_VERIF_PAB_SMIN": "Cloison n°%NC%, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum: %minS%)",
-    "ERROR_VERIF_PAB_SMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum: %minS%)",
-    "WARNING_VERIF_PAB_SMIN": "Cloison n°%NC%, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum: %minS%)",
-    "WARNING_VERIF_PAB_SMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum: %minS%)",
+    "ERROR_VERIF_PAB_SMIN": "Cloison n°%NC%, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum&nbsp;: %minS%)",
+    "ERROR_VERIF_PAB_SMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum&nbsp;: %minS%)",
+    "WARNING_VERIF_PAB_SMIN": "Cloison n°%NC%, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum&nbsp;: %minS%)",
+    "WARNING_VERIF_PAB_SMIN_DW": "Cloison aval, ouvrage %NS%&nbsp;: surface de l'orifice %S% insuffisante (minimum&nbsp;: %minS%)",
     "ERROR_VERIF_PAB_YMOY": "Cloison n°%N%&nbsp;: profondeur de bassin %PB% insuffisante (minimum pour jet de surface&nbsp;: %minPBS%, minimum pour jet plongeant&nbsp;: %minPBP%)",
     "ERROR_VERIF_PAB_YMOY_JET": "Cloison n°%N%&nbsp;: profondeur de bassin %PB% insuffisante pour le jet ENUM_STRUCTUREJETTYPE_%jetType% (minimum&nbsp;: %minPB%)",
     "WARNING_VERIF_PAB_YMOY_JET": "Cloison n°%N%&nbsp;: profondeur de bassin %PB% insuffisante pour le jet ENUM_STRUCTUREJETTYPE_%jetType% (minimum&nbsp;: %minPB%)",
     "ERROR_VERIF_PAB_YMOY_2_DH": "Cloison n°%N%&nbsp;: profondeur de bassin %PB% inférieure à 2x la chute %DH%",
     "WARNING_VERIF_PAB_YMOY_2_DH": "Cloison n°%N%&nbsp;: profondeur de bassin %PB% inférieure à 2x la chute %DH%",
+    "ERROR_VERIF_PAB_PVMAX": "Cloison n°%N%&nbsp;: puissance dissipée %PV% trop élevée (maximum&nbsp;: %maxPV%)",
     "ERROR_VERIF_PAR_DH": "La chute en pied de passe empêche le franchissement",
     "ERROR_VERIF_PAR_YMIN": "Tirant d'eau %h% insuffisant (minimum&nbsp;: %minY%)",
     "ERROR_VERIF_KO": "Le franchissement est impossible pour au moins un groupe d'espèces",
-- 
GitLab