Output.FileWriters and Output.Printers changes, ver. 2.27.1807
This commit is contained in:
parent
71517b6cdb
commit
1d152afd6c
@ -29,5 +29,5 @@ using System.Runtime.InteropServices;
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
[assembly: AssemblyVersion("2.27.1802.0")]
|
||||
[assembly: AssemblyFileVersion("2.27.1802.0")]
|
||||
[assembly: AssemblyVersion("2.27.1807.0")]
|
||||
[assembly: AssemblyFileVersion("2.27.1807.0")]
|
||||
|
||||
@ -192,7 +192,7 @@ namespace TBF.Rig.Output.FileWriters.Enhanced
|
||||
{
|
||||
if (string.IsNullOrEmpty(writerCfg.FileNameFormat))
|
||||
{
|
||||
return string.Format("{0}{1:yyMMdd-HHmm}.txt", directory, time);
|
||||
return Path.Combine(directory, string.Format("{0:yyMMdd-HHmm}.txt", time));
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -202,7 +202,7 @@ namespace TBF.Rig.Output.FileWriters.Enhanced
|
||||
}
|
||||
catch
|
||||
{
|
||||
return string.Format("{0}{1:yyMMdd-HHmm}.txt", directory, time);
|
||||
return Path.Combine(directory, string.Format("{0:yyMMdd-HHmm}.txt", time));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
///
|
||||
/// Copyright (c) 2017 Sensus Metering Systems
|
||||
/// Copyright (c) 2017-2021 Sensus Slovensko a.s.
|
||||
///
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@ -188,12 +188,18 @@ namespace TBF.Rig.Output.FileWriters.OneFilePerMeter
|
||||
|
||||
try
|
||||
{
|
||||
if (string.IsNullOrEmpty(writerCfg.FileNameFormat)) throw new Exception();
|
||||
return directory + string.Format(writerCfg.FileNameFormat, time);
|
||||
if (string.IsNullOrEmpty(writerCfg.FileNameFormat))
|
||||
{
|
||||
return Path.Combine(directory, string.Format("{0:yyMMdd-HHmm}.txt", time));
|
||||
}
|
||||
else
|
||||
{
|
||||
return Path.Combine(directory, string.Format(writerCfg.FileNameFormat, time));
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
return string.Format("{0}{1:yyMMdd-HHmm}.txt", directory, time);
|
||||
return Path.Combine(directory, string.Format("{0:yyMMdd-HHmm}.txt", time));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -169,7 +169,8 @@ namespace TBF.Rig.Output.Printers.OnePerMeter
|
||||
try
|
||||
{
|
||||
if (string.IsNullOrEmpty(printerCfg.DocName)) throw (new Exception());
|
||||
documentName = string.Format(printerCfg.DocName, wm.StartTime(), wm.EndTime(), wm.BatchNr(), wm.WMPosition, wm.SerialNr);
|
||||
documentName = string.Format(printerCfg.DocName, wm.StartTime(), wm.EndTime(), wm.BatchNr(), wm.WMPosition, wm.SerialNr, wm.SerialNrAux);
|
||||
/// {0} {1} {2} {3} {4} {5}
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user