diff options
| author | Victoria Plitt <Victoria.Plitt@twine-s.com> | 2023-06-08 09:37:17 +0300 |
|---|---|---|
| committer | Victoria Plitt <Victoria.Plitt@twine-s.com> | 2023-06-08 09:37:17 +0300 |
| commit | 2b1c20945dc03d5136fba48ee9d165b412620e66 (patch) | |
| tree | fb2b4c9af81076740548706411e893e3764fdcb8 /Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs | |
| parent | 54624e4a90a240ad702995e1ed551901768e131f (diff) | |
| download | Tango-2b1c20945dc03d5136fba48ee9d165b412620e66.tar.gz Tango-2b1c20945dc03d5136fba48ee9d165b412620e66.zip | |
PPC. Resize the font and change color for Sensors display values.
Related Work Items: #8551
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs')
| -rw-r--r-- | Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs index faddc5c54..beba47246 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs @@ -110,15 +110,17 @@ namespace Tango.PPC.UI.Models { item.Status = "Heating Up"; item.Color = Colors.Orange; - item.DisplayValue = $"{state.CurrentValue.ToString("N1")} / {state.SetPoint}"; + item.DisplayValue = $"{state.CurrentValue.ToString("N1")}"; + item.DisplayMaxValue = $"/{state.SetPoint}"; item.MaxValue = state.SetPoint; item.Value = state.CurrentValue; } - else if (state.SetPoint == 0 || (state.CurrentValue >= (state.SetPoint - 10) || state.CurrentValue <= (state.SetPoint + 10))) + else if (state.SetPoint == 0 || (state.CurrentValue >= (state.SetPoint - 10) && state.CurrentValue <= (state.SetPoint + 10))) { item.Status = "Operational"; item.Color = Colors.Green; item.DisplayValue = $" {state.SetPoint}"; + item.DisplayMaxValue = ""; if(state.SetPoint == 0 && state.CurrentValue == 0) { item.MaxValue = 10; @@ -133,7 +135,8 @@ namespace Tango.PPC.UI.Models { item.Status = "Over-temperature"; item.Color = Colors.Red; - item.DisplayValue = $"{state.CurrentValue.ToString("N1")} / {state.SetPoint}"; + item.DisplayValue = $"{state.CurrentValue.ToString("N1")}"; + item.DisplayMaxValue = $"/{state.SetPoint}"; item.MaxValue = state.SetPoint; item.Value = state.CurrentValue > state.SetPoint? state.SetPoint : state.CurrentValue; } @@ -142,6 +145,7 @@ namespace Tango.PPC.UI.Models item.Color = Colors.Gray; item.MaxValue = 100; item.Value = 0; + item.DisplayMaxValue = ""; } } } @@ -205,8 +209,6 @@ namespace Tango.PPC.UI.Models Lubricant.DisplayValue = "None"; Lubricant.Color = Colors.Gray; } - - } } } |
