diff options
Diffstat (limited to 'Software/Visual_Studio/Utilities')
4 files changed, 51 insertions, 3 deletions
diff --git a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml index a330b4425..3eabf21b4 100644 --- a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml +++ b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml @@ -11,7 +11,7 @@ xmlns:local="clr-namespace:Tango.DispenserAnalyzer.UI" xmlns:vm ="clr-namespace:Tango.DispenserAnalyzer.UI.ViewModels" mc:Ignorable="d" - Title="Dispenser Analyser" Height="1000" Width="860" WindowStartupLocation="CenterScreen" WindowStyle="SingleBorderWindow" ResizeMode="CanResize" Foreground="#202020" + Title="{Binding WindowTitle, RelativeSource={RelativeSource Mode=Self}}" Height="1000" Width="860" WindowStartupLocation="CenterScreen" WindowStyle="SingleBorderWindow" ResizeMode="CanResize" Foreground="#202020" d:DataContext="{d:DesignInstance Type=vm:MainWindowVM, IsDesignTimeCreatable=False}"> <Window.Resources> <converters:EnumToDescriptionConverter x:Key="EnumToDescriptionConverter" /> diff --git a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml.cs b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml.cs index 26d64c995..a7bcf796e 100644 --- a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml.cs +++ b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/MainWindow.xaml.cs @@ -25,7 +25,17 @@ namespace Tango.DispenserAnalyzer.UI public partial class MainWindow : Window { private MainWindowVM _vm; - + + public string WindowTitle + { + get + { + Version version = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version; + return "Dispenser Analyzer - Version" + version; + } + } + + public MainWindow() { InitializeComponent(); diff --git a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/Properties/AssemblyInfo.cs b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/Properties/AssemblyInfo.cs index 4b15c6e1f..363f31ea5 100644 --- a/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/Properties/AssemblyInfo.cs +++ b/Software/Visual_Studio/Utilities/Tango.DispenserAnalyzer.UI/Properties/AssemblyInfo.cs @@ -51,5 +51,5 @@ using System.Windows; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyVersion("1.1.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/Software/Visual_Studio/Utilities/Tango.JobRunsGenerator/Program.cs b/Software/Visual_Studio/Utilities/Tango.JobRunsGenerator/Program.cs index b105b8254..b8031fdaf 100644 --- a/Software/Visual_Studio/Utilities/Tango.JobRunsGenerator/Program.cs +++ b/Software/Visual_Studio/Utilities/Tango.JobRunsGenerator/Program.cs @@ -78,6 +78,44 @@ namespace Tango.JobRunsGenerator if (run.ActualStartDate == null) run.ActualStartDate = run.StartDate; run.IsGradient = job.Segments.Any(x => x.BrushStops.Count > 1); + //Set new liquid quantities. + if (run.CyanQuantity == 0 && + run.MagentaQuantity == 0 && + run.YellowQuantity == 0 && + run.BlackQuantity == 0 && + run.TransparentQuantity == 0 && + run.LubricantQuantity == 0 && + run.CleanerQuantity == 0) + { + //Cyan + var cyan = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Cyan); + run.CyanQuantity = cyan != null ? cyan.Quantity : 0; + + //Magenta + var magenta = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Magenta); + run.MagentaQuantity = magenta != null ? magenta.Quantity : 0; + + //Yellow + var yellow = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Yellow); + run.YellowQuantity = yellow != null ? yellow.Quantity : 0; + + //Black + var black = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Black); + run.BlackQuantity = black != null ? black.Quantity : 0; + + //TI + var ti = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.TransparentInk); + run.TransparentQuantity = ti != null ? ti.Quantity : 0; + + //Lubricant + var lubricant = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Lubricant); + run.LubricantQuantity = lubricant != null ? lubricant.Quantity : 0; + + //Lubricant + var cleaner = run.LiquidQuantities.FirstOrDefault(x => x.LiquidType == BL.Enumerations.LiquidTypes.Cleaner); + run.CleanerQuantity = cleaner != null ? cleaner.Quantity : 0; + } + saveIndex++; if (saveIndex > 100) |
