diff --git a/src/app/components/modules-diagram/modules-diagram.component.ts b/src/app/components/modules-diagram/modules-diagram.component.ts index b701aeac988e740c29a50945eff8cc63718fb7bb..c7566355fa91be90802460d28e29f93f3a347fbe 100644 --- a/src/app/components/modules-diagram/modules-diagram.component.ts +++ b/src/app/components/modules-diagram/modules-diagram.component.ts @@ -17,7 +17,10 @@ import { Nub, MacrorugoCompound, Pab, - Solveur + Solveur, + Verificateur, + Espece, + FishSpecies } from "jalhyd"; import { I18nService } from "../../services/internationalisation.service"; @@ -219,6 +222,21 @@ export class ModulesDiagramComponent implements AfterContentInit, AfterViewCheck def.push(nub.uid + "-->|" + finds + ":" + sp.symbol + "|" + sp.parentNub.uid); } } + // add Verificateur links + if (nub instanceof Verificateur) { + const ntv = nub.nubToVerify; + const sp = nub.species.filter((sp) => { + return sp.species === FishSpecies.SPECIES_CUSTOM; + }); + const verifiesPass = this.intlService.localizeText("INFO_DIAGRAM_VERIFICATEUR_VERIFIES_PASS"); + const verifiesSpecies = this.intlService.localizeText("INFO_DIAGRAM_VERIFICATEUR_VERIFIES_SPECIES"); + if (ntv !== undefined) { + def.push(nub.uid + "-->|" + verifiesPass + "|" + ntv.uid); + } + for (const s of sp) { + def.push(nub.uid + "-->|" + verifiesSpecies + "|" + s.uid); + } + } } return def.join("\n"); diff --git a/src/locale/messages.en.json b/src/locale/messages.en.json index ee67ebd305ac283d9105fc2cfc5d768af16fd237..138b4a8d61bcdc9540556ab891ae9165339226a3 100644 --- a/src/locale/messages.en.json +++ b/src/locale/messages.en.json @@ -97,6 +97,8 @@ "INFO_DEVER_TITRE": "Free flow weir stage-discharge laws", "INFO_DIAGRAM_SOLVEUR_FINDS": "finds", "INFO_DIAGRAM_SOLVEUR_READS": "reads", + "INFO_DIAGRAM_VERIFICATEUR_VERIFIES_PASS": "verifies pass", + "INFO_DIAGRAM_VERIFICATEUR_VERIFIES_SPECIES": "verifies species", "INFO_DIAGRAM_TITLE": "Calculation modules diagram", "INFO_DIAGRAM_DRAWING_ERROR": "Error while drawing diagram", "INFO_DIAGRAM_CALCULATED_PARAM": "calculated parameter", diff --git a/src/locale/messages.fr.json b/src/locale/messages.fr.json index 9fa99e7110b70cfce6a46968bf888ce325db9a60..503ac359bc346ddc676bcdaf41a6251865dcb0a7 100644 --- a/src/locale/messages.fr.json +++ b/src/locale/messages.fr.json @@ -97,6 +97,8 @@ "INFO_DEVER_TITRE": "Lois de déversoirs dénoyés", "INFO_DIAGRAM_SOLVEUR_FINDS": "trouve", "INFO_DIAGRAM_SOLVEUR_READS": "lit", + "INFO_DIAGRAM_VERIFICATEUR_VERIFIES_PASS": "vérifie la passe", + "INFO_DIAGRAM_VERIFICATEUR_VERIFIES_SPECIES": "vérifie les espèces", "INFO_DIAGRAM_TITLE": "Diagramme des modules de calcul", "INFO_DIAGRAM_DRAWING_ERROR": "Erreur lors du dessin du diagramme", "INFO_DIAGRAM_CALCULATED_PARAM": "paramètre calculé",