aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs
diff options
context:
space:
mode:
authorRoy <Roy.mail.net@gmail.com>2022-11-24 10:55:24 +0200
committerRoy <Roy.mail.net@gmail.com>2022-11-24 10:55:24 +0200
commitfbd89edca2790b5c6a17927be8efa1c796f51dc0 (patch)
treeb1ba512b252fb3e117f42af766b943bd8698ba72 /Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs
parent02a189cb0e6feb3e70921726f2004b33f19c962e (diff)
downloadTango-fbd89edca2790b5c6a17927be8efa1c796f51dc0.tar.gz
Tango-fbd89edca2790b5c6a17927be8efa1c796f51dc0.zip
Working on final RSM bug fixes.
Diffstat (limited to 'Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs')
-rw-r--r--Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs17
1 files changed, 9 insertions, 8 deletions
diff --git a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs
index 891e40b94..0807e285a 100644
--- a/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs
+++ b/Software/Visual_Studio/FSE/Modules/Tango.FSE.Statistics/ViewModels/MainViewVM.cs
@@ -861,16 +861,17 @@ namespace Tango.FSE.Statistics.ViewModels
{
try
{
- if (Directory.Exists(Settings.StatisticsStreamingConfig.CsvReportsFolder))
+ if (!Directory.Exists(Settings.StatisticsStreamingConfig.CsvReportsFolder))
{
- stops.Reverse();
- String fileName = $"{MachineProvider.Machine.SerialNumber}_{stops[0].JobRun.JobName}_Run_{DateTime.Now.ToFileName()}.csv";
- ExportToCSV(stops, Path.Combine(Settings.StatisticsStreamingConfig.CsvReportsFolder, fileName));
- }
- else
- {
- LogManager.Log($"Statistics streaming csv directory does not exist..", Logging.LogCategory.Error);
+ Directory.CreateDirectory(Settings.StatisticsStreamingConfig.CsvReportsFolder);
}
+
+ stops.Reverse();
+
+ String suffix = stops[0].JobRun.JobDesignation == (int)JobDesignations.FineTuning ? "VFT" : "Run";
+
+ String fileName = $"{MachineProvider.Machine.SerialNumber}_{stops[0].JobRun.JobName}_{suffix}_{DateTime.Now.ToFileName()}.csv";
+ ExportToCSV(stops, Path.Combine(Settings.StatisticsStreamingConfig.CsvReportsFolder, fileName));
}
catch (Exception ex)
{