Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix moh reset button in fault tree editor #626

Merged
merged 3 commits into from
Oct 8, 2024

Conversation

kostobog
Copy link
Collaborator

@kostobog kostobog commented Oct 8, 2024

@blcham
Fix #593

Fixes behavior of MOH input field and its refresh button.

The screen shots below show how the MOH input field is rendered based on three variables,

  • value of field MOH (MOH),
  • fault tree MOH (ftMoh ) and
  • system MOH (sMOH).

The style of MOH field uses orange color for the value of the MOH filed to distinguish if MOH is different from sMOH and orange color to of the border of the field to distinguish if MOH different from ftMOH. The field also has localized hint(s) to show

1) MOH = ftMoh and MOH = sMOH
image

2) MOH != ftMoh and MOH != sMOH - e.g. user updated MOH the value in the field
image

3) MOH = ftMoh and MOH != sMOH - e.g. user evaluated tree with MOH != sMOH
image

4) MOH != ftMoh and MOH = sMOH - e.g. user updated MOH to be equal to sMOH
image

The reset button updates the MOH value. Note that the reset button does not persist MOH (i.e. does not set ftMOH by calling server api) and it does not evaluate fault tree with MOH. The reset button works as follows based on the current state MOH, ftMOH and sMOH:
1) MOH = ftMoh and MOH = sMOH

  • do nothing
    2) MOH != ftMoh and MOH != sMOH or 4) MOH != ftMoh and MOH = sMOH
  • MOH := ftMoh
    3) MOH = ftMoh and MOH != sMOH
  • MOH := sMOH - sets MOH to sMOH

User

@kostobog kostobog requested review from blcham and grotskat and removed request for grotskat October 8, 2024 11:25
@blcham blcham merged commit e434734 into main Oct 8, 2024
1 check passed
@blcham blcham deleted the fix/593-fix-moh-reset-button-in-fault-tree-editor branch October 8, 2024 11:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The refresh button behaves strangely in fault trees
2 participants