Sur un prébarrage complexe, il peut être fastidieux de comprendre quel paramètre de quel enfant est responsable de l'invalidation du bouton "Calculer". Mettre en rouge l'enfant responsable dans le schéma permettrait de guider l'utilisateur vers l'enfant à modifier pour valider le pré-barrage et permettre le calcul.
Designs
Child items
...
Show closed items
Linked items
0
Link issues together to show that they're related.
Learn more.
flowchart LR Start --> Stop style Stop fill:#f9f,stroke:#333,stroke-width:4px
flowchart LR Start --> Stop style Stop fill:#f9f,stroke:#333,stroke-width:4px
In this issue, the task consists in adding one line style for each PbBassin or PbCloison invalid for filling them in red. This can be done when the global style of each basin and cloison is defined:
The method Nub.isComputable is only checking the range of the parameters. Situation like "the field is empty" or "the field contains something else than numbers" are handled by the UI. So it is not usefull for checking the validity of a child nub of PreBarrage.
By Dorchies David on 2021-12-14T10:38:49 (imported from GitLab)
The solution provided in commit 17ca971a is not satisfactory. The compilation failed because this.form.currentNub is casted as Nub and not as a PreBarrage.
Anyway, finally I don't like the idea to put the code checking the parameter in jalhyd since it's only an UI issue. So I prefere to put this code into FormPreBarrage which is both available from CalculatorComponent which updates UI validity and PbSchemaComponent which need draws the scheme with the red nodes in error.
By Dorchies David on 2021-12-15T17:14:54 (imported from GitLab)