From 6307309baf64555601ed53527ce9f2fa6fbe09f6 Mon Sep 17 00:00:00 2001 From: Victoria Plitt Date: Mon, 23 Oct 2023 14:00:15 +0300 Subject: Reset dryers bug. Related Work Items: #9175 --- .../ViewModels/MaintenanceViewVM.cs | 36 +++++++++++----------- .../Views/EurekaMaintenanceView.xaml | 4 +-- 2 files changed, 20 insertions(+), 20 deletions(-) (limited to 'Software/Visual_Studio/PPC/Modules') diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs index a8af047fc..2279b8bb5 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/ViewModels/MaintenanceViewVM.cs @@ -34,36 +34,36 @@ namespace Tango.PPC.Maintenance.ViewModels { public enum Boards { - [Description("Main")] - Main = 1, + //[Description("Main")] + //Main = 1, [Description("Heads")] - Heads = 2, + Heads = 1, [Description("Dryer")] - Dryer = 3, + Dryer = 2, [Description("Mid tanks")] - Midtanks = 4, + Midtanks = 3, [Description("Lubricant")] - Lubricant = 5, + Lubricant = 4, [Description("Dispenser 1")] - Dispenser_1 = 6, + Dispenser_1 = 5, [Description("Dispenser 2")] - Dispenser_2 = 7, + Dispenser_2 = 6, [Description("Dispenser 3")] - Dispenser_3 = 8, + Dispenser_3 = 7, [Description("Dispenser 4")] - Dispenser_4 = 9, - [Description("Dispenser 5")] - Dispenser_5 = 10, - [Description("Dispenser 6")] - Dispenser_6 = 11, + Dispenser_4 = 8, + //[Description("Dispenser 5")] + //Dispenser_5 = 9, + //[Description("Dispenser 6")] + //Dispenser_6 = 10, [Description("Winder 1")] - Winder_1 = 12, + Winder_1 = 11, [Description("Winder 2")] - Winder_2 = 13, + Winder_2 = 12, [Description("Winder 3")] - Winder_3 = 14, + Winder_3 = 13, [Description("Winder 4")] - Winder_4 = 15, + Winder_4 = 14, } public class WasteStateModel : ExtendedObject diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/EurekaMaintenanceView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/EurekaMaintenanceView.xaml index faef8be1a..0b30d697e 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/EurekaMaintenanceView.xaml +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Views/EurekaMaintenanceView.xaml @@ -132,7 +132,7 @@ - + @@ -152,7 +152,7 @@ - + + + diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image-X4.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image-X4.png new file mode 100644 index 000000000..5a6095e4c Binary files /dev/null and b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Images/Guides/machine-image-X4.png differ diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj index bebdd63c7..6ede5f25b 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Maintenance/Tango.PPC.Maintenance.csproj @@ -323,10 +323,13 @@ + + + - + \ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.Power/Images/machine-X4.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Power/Images/machine-X4.png new file mode 100644 index 000000000..25e4697fd Binary files /dev/null and b/Software/Visual_Studio/PPC/Modules/Tango.PPC.Power/Images/machine-X4.png differ diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-X4.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-X4.png new file mode 100644 index 000000000..25e4697fd Binary files /dev/null and b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-X4.png differ diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-image-X4.png b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-image-X4.png new file mode 100644 index 000000000..5a6095e4c Binary files /dev/null and b/Software/Visual_Studio/PPC/Tango.PPC.UI/Images/machine-image-X4.png differ diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj b/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj index 8f65f225b..a63c0fca2 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Tango.PPC.UI.csproj @@ -648,6 +648,8 @@ + + @@ -993,7 +995,7 @@ if $(ConfigurationName) == Eureka copy /Y "$(ProjectDir)Intro.wmv" "$(TargetDir) - + diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/EmergencyView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/EmergencyView.xaml index f2b018bfa..e4f55915c 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/EmergencyView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/EmergencyView.xaml @@ -20,7 +20,18 @@ 2. Release the emergency button. 3. Press the power button to power up the system. - + + + + + diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/ExternalBridgeView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/ExternalBridgeView.xaml index fddd15fe7..7276d7d4c 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/ExternalBridgeView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/ExternalBridgeView.xaml @@ -18,7 +18,18 @@ - + + + + + + + diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/RestartingView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/RestartingView.xaml index 41017f629..9e7abdca2 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/RestartingView.xaml +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/RestartingView.xaml @@ -14,7 +14,18 @@ - + + + + + -- cgit v1.3.1 From bf7234e0757a53129bd4991d3db30b03ff5049b3 Mon Sep 17 00:00:00 2001 From: Victoria Plitt Date: Wed, 25 Oct 2023 18:11:26 +0300 Subject: Add input\output inks to TS1800 progress screen Related Work Items: #9165 --- .../Images/JobProgressView/input.png | Bin 0 -> 1011 bytes .../Images/JobProgressView/output.png | Bin 0 -> 995 bytes .../Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj | 6 +- .../ViewModels/JobProgressViewVM.cs | 147 ++++++++++- .../Tango.PPC.JobsV2/Views/JobProgressView.xaml | 271 ++++++++++++++++++++- .../Tango.PPC.JobsV2/Views/JobSummeryView.xaml | 96 +++++++- 6 files changed, 514 insertions(+), 6 deletions(-) create mode 100644 Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/input.png create mode 100644 Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/output.png (limited to 'Software/Visual_Studio/PPC/Modules') diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/input.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/input.png new file mode 100644 index 000000000..77dbab1c9 Binary files /dev/null and b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/input.png differ diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/output.png b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/output.png new file mode 100644 index 000000000..53b317042 Binary files /dev/null and b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Images/JobProgressView/output.png differ diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj index 33ccc5b53..405f87b28 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Tango.PPC.JobsV2.csproj @@ -755,10 +755,14 @@ + + + + - + \ No newline at end of file diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/ViewModels/JobProgressViewVM.cs b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/ViewModels/JobProgressViewVM.cs index 8756a6a57..b879831b9 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/ViewModels/JobProgressViewVM.cs +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/ViewModels/JobProgressViewVM.cs @@ -4,6 +4,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; using Tango.BL.Entities; +using Tango.BL.Enumerations; using Tango.Core.Commands; using Tango.Integration.Operation; using Tango.Logging; @@ -37,7 +38,12 @@ namespace Tango.PPC.Jobs.ViewModels public Job Job { get { return _job; } - set { _job = value; RaisePropertyChangedAuto(); } + set { _job = value; + if(_job == null) + { + IsDyeingProcess = false; + } + RaisePropertyChangedAuto(); } } private RunningJobStatus _runningJobStatus; @@ -47,7 +53,14 @@ namespace Tango.PPC.Jobs.ViewModels public RunningJobStatus RunningJobStatus { get { return _runningJobStatus; } - set { _runningJobStatus = value; RaisePropertyChangedAuto(); } + set { + _runningJobStatus = value; + if(_runningJobStatus == null) + { + IsDyeingProcess = false; + } + RaisePropertyChangedAuto(); + } } private bool _isDisplayJobOutline; @@ -70,6 +83,73 @@ namespace Tango.PPC.Jobs.ViewModels set { _jobOutlineTicket = value; RaisePropertyChangedAuto(); } } + private bool _isDyeingProcess; + + public bool IsDyeingProcess + { + get { return _isDyeingProcess; } + set + { + if (_isDyeingProcess != value) + { + _isDyeingProcess = value; + RaisePropertyChangedAuto(); + } + } + } + + private BrushStop _currentBrushStop; + public BrushStop CurrentBrushStop + { + get { return _currentBrushStop; } + set + { + // if (_currentBrushStop != value) + { + _currentBrushStop = value; + OnUpdateCurrentBrush(); + RaisePropertyChangedAuto(); + } + } + } + + public JobBrushStop JobBrushStop { get; set; } + + public double CyanOutput + { + get { return GetVolumeLiquidType(LiquidTypes.Cyan); } + } + + public double MagentaOutput + { + get { return GetVolumeLiquidType(LiquidTypes.Magenta); } + } + + public double YellowOutput + { + get { return GetVolumeLiquidType(LiquidTypes.Yellow); } + } + + public double BlackOutput + { + get { return GetVolumeLiquidType(LiquidTypes.Black); } + } + + public double LightCyanOutput + { + get { return GetVolumeLiquidType(LiquidTypes.LightCyan); } + } + + public double LightMagentaOutput + { + get { return GetVolumeLiquidType(LiquidTypes.LightMagenta); } + } + + public double LightYellowOutput + { + get { return GetVolumeLiquidType(LiquidTypes.LightYellow); } + } + #endregion #region Commands @@ -123,6 +203,31 @@ namespace Tango.PPC.Jobs.ViewModels NavigationManager.ClearHistoryExcept(); } + protected void OnUpdateCurrentBrush() + { + RaisePropertyChanged(nameof(CyanOutput)); + RaisePropertyChanged(nameof(LightCyanOutput)); + RaisePropertyChanged(nameof(MagentaOutput)); + RaisePropertyChanged(nameof(LightMagentaOutput)); + RaisePropertyChanged(nameof(YellowOutput)); + RaisePropertyChanged(nameof(LightYellowOutput)); + RaisePropertyChanged(nameof(BlackOutput)); + } + + private double GetVolumeLiquidType(LiquidTypes liquidType) + { + if (JobBrushStop != null && JobBrushStop.Dispensers != null && JobBrushStop.Dispensers.Count > 0) + { + var lt = JobBrushStop.Dispensers.FirstOrDefault(x => x.DispenserLiquidType == (DispenserLiquidType)liquidType); + + if (lt != null) + { + return Math.Round(lt.Volume, 2); + } + } + return 0; + } + #endregion #region Override Methods @@ -160,6 +265,7 @@ namespace Tango.PPC.Jobs.ViewModels if (_handler != null) { _handler.Cancel(); + IsDyeingProcess = false; } } @@ -228,6 +334,7 @@ namespace Tango.PPC.Jobs.ViewModels _handler.SpoolChangeRequired -= JobHandler_SpoolChangeRequired; _handler.Stopped -= JobHandler_Stopped; _handler.CanCancelChanged -= JobHandler_CanCancelChanged; + IsDyeingProcess = false; } } @@ -241,6 +348,42 @@ namespace Tango.PPC.Jobs.ViewModels InvokeUI(() => { RunningJobStatus = e; + IsDyeingProcess = (RunningJobStatus != null && RunningJobStatus.CurrentSegment != null); + if (RunningJobStatus != null && RunningJobStatus.CurrentSegment != null) + { + if (_runningJobStatus.CurrentSegment.IsInterSegment) + { + CurrentBrushStop = _runningJobStatus.CurrentSegment.BrushStops.FirstOrDefault(); + JobBrushStop = null; + } + else + { + var realsegmIndex = 1; + if (Job.EnableInterSegment && Job.InterSegmentLength > 0) + { + int segmentIndex = _runningJobStatus.CurrentSegment.SegmentIndex - (Job.EffectiveSegments.Count * RunningJobStatus.CurrentUnit); + if (RunningJobStatus.CurrentUnit > 0) + { + segmentIndex -= RunningJobStatus.CurrentUnit;// inter segment between units + } + realsegmIndex = (int)(segmentIndex / 2) + 1; + } + else + { + realsegmIndex = Math.Max(_runningJobStatus.CurrentSegment.SegmentIndex - (Job.Segments.Count * RunningJobStatus.CurrentUnit), 0); + } + + var segment = Job.Segments.FirstOrDefault(x => x.SegmentIndex == realsegmIndex); + if (segment != null) + { + if (_handler.JobTicket.Segments.Count > 0) + { + JobBrushStop = _handler.JobTicket.Segments[Job.OrderedSegments.IndexOf(segment)].BrushStops.First(); + } + } + CurrentBrushStop = RunningJobStatus.CurrentSegment.FirstBrushStop; + } + } }); } diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobProgressView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobProgressView.xaml index a91d5676b..89b69a316 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobProgressView.xaml +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobProgressView.xaml @@ -7,6 +7,7 @@ xmlns:controls="clr-namespace:Tango.PPC.Jobs.Controls" xmlns:touch="clr-namespace:Tango.Touch.Controls;assembly=Tango.Touch" xmlns:converters="clr-namespace:Tango.PPC.Jobs.Converters" + xmlns:entities="clr-namespace:Tango.BL.Entities;assembly=Tango.BL" xmlns:global="clr-namespace:Tango.PPC.Jobs" xmlns:local="clr-namespace:Tango.PPC.Jobs.Views" mc:Ignorable="d" @@ -14,6 +15,105 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -119,7 +219,7 @@ - + @@ -206,8 +306,175 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Output ( % ) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + C + + + + + + LC + + + + + + M + + + + + + + LM + + + + + + Y + + + + + + LY + + + + + + K + + + + + - + Go to job diff --git a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobSummeryView.xaml b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobSummeryView.xaml index a013cd7f9..6eb51d16f 100644 --- a/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobSummeryView.xaml +++ b/Software/Visual_Studio/PPC/Modules/Tango.PPC.JobsV2/Views/JobSummeryView.xaml @@ -11,6 +11,14 @@ xmlns:local="clr-namespace:Tango.PPC.Jobs.Views" mc:Ignorable="d" d:DesignHeight="1280" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=vm:JobSummeryViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.JobSummeryViewVM}"> + + + + @@ -51,7 +59,8 @@ - + + @@ -103,7 +112,92 @@ + + + + + + + + + Input + + + + + + + + + + + + + + + + + + + + + + + + + + Output ( % ) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.3.1