Bug fix - GetHeaderId
This commit is contained in:
parent
255ccf4280
commit
6b5a187fe7
@ -78,20 +78,32 @@ public partial class WS
|
|||||||
{
|
{
|
||||||
foreach (Attachment attachment in headerAttachments)
|
foreach (Attachment attachment in headerAttachments)
|
||||||
{
|
{
|
||||||
directory = Path.GetDirectoryName(attachment.HeaderIdDirectory) ?? throw new Exception();
|
directory = Path.Combine(Path.GetDirectoryName(attachment.HeaderIdDirectory), attachment.AttachmentId) ?? throw new Exception();
|
||||||
File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.AttachmentId, attachment.DestinationFileName), overwrite: true);
|
if (!Directory.Exists(directory))
|
||||||
AttachFile(url, attachment);
|
_ = Directory.CreateDirectory(directory);
|
||||||
|
File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.DestinationFileName), overwrite: true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (dataAttachments is not null)
|
if (dataAttachments is not null)
|
||||||
{
|
{
|
||||||
foreach (Attachment attachment in dataAttachments)
|
foreach (Attachment attachment in dataAttachments)
|
||||||
{
|
{
|
||||||
directory = Path.GetDirectoryName(attachment.HeaderIdDirectory) ?? throw new Exception();
|
directory = Path.Combine(Path.GetDirectoryName(attachment.HeaderIdDirectory.Replace("Header", "Data")), attachment.AttachmentId) ?? throw new Exception();
|
||||||
File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.AttachmentId, attachment.DestinationFileName), overwrite: true);
|
if (!Directory.Exists(directory))
|
||||||
AttachFile(url, attachment);
|
_ = Directory.CreateDirectory(directory);
|
||||||
|
File.Copy(attachment.SourceFileName, Path.Combine(directory, attachment.DestinationFileName), overwrite: true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (headerAttachments is not null)
|
||||||
|
{
|
||||||
|
foreach (Attachment attachment in headerAttachments)
|
||||||
|
AttachFile(url, attachment);
|
||||||
|
}
|
||||||
|
if (dataAttachments is not null)
|
||||||
|
{
|
||||||
|
foreach (Attachment attachment in dataAttachments)
|
||||||
|
AttachFile(url, attachment);
|
||||||
|
}
|
||||||
//MessageBox.Show(r.ToString());
|
//MessageBox.Show(r.ToString());
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
|
@ -19,6 +19,8 @@ public class R34 : EAFLoggingUnitTesting
|
|||||||
internal static string DummyRoot { get; private set; }
|
internal static string DummyRoot { get; private set; }
|
||||||
internal static R34 EAFLoggingUnitTesting { get; private set; }
|
internal static R34 EAFLoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
static R34() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy";
|
||||||
|
|
||||||
public R34() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
public R34() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
||||||
{
|
{
|
||||||
if (EAFLoggingUnitTesting is null)
|
if (EAFLoggingUnitTesting is null)
|
||||||
|
@ -19,6 +19,8 @@ public class R36 : EAFLoggingUnitTesting
|
|||||||
internal static string DummyRoot { get; private set; }
|
internal static string DummyRoot { get; private set; }
|
||||||
internal static R36 EAFLoggingUnitTesting { get; private set; }
|
internal static R36 EAFLoggingUnitTesting { get; private set; }
|
||||||
|
|
||||||
|
static R36() => DummyRoot = @"\\mesfs.infineon.com\EC_Characterization_Si\Dummy";
|
||||||
|
|
||||||
public R36() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
public R36() : base(DummyRoot, testContext: null, declaringType: null, skipEquipmentDictionary: false)
|
||||||
{
|
{
|
||||||
if (EAFLoggingUnitTesting is null)
|
if (EAFLoggingUnitTesting is null)
|
||||||
|
@ -19,15 +19,11 @@ public class R34_EQPT
|
|||||||
_R34_EQPT = CreateSelfDescription.Staging.v2_56_0.R34_EQPT.EAFLoggingUnitTesting;
|
_R34_EQPT = CreateSelfDescription.Staging.v2_56_0.R34_EQPT.EAFLoggingUnitTesting;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if DEBUG
|
|
||||||
[Ignore]
|
[Ignore]
|
||||||
#endif
|
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
public void Staging__v2_56_0__R34_EQPT__DownloadJpegFile() => _R34_EQPT.Staging__v2_56_0__R34_EQPT__DownloadJpegFile();
|
public void Staging__v2_56_0__R34_EQPT__DownloadJpegFile() => _R34_EQPT.Staging__v2_56_0__R34_EQPT__DownloadJpegFile();
|
||||||
|
|
||||||
#if DEBUG
|
|
||||||
[Ignore]
|
[Ignore]
|
||||||
#endif
|
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
public void Staging__v2_56_0__R34_EQPT__DownloadJpegFile637812143477007703__Normal() => _R34_EQPT.Staging__v2_56_0__R34_EQPT__DownloadJpegFile();
|
public void Staging__v2_56_0__R34_EQPT__DownloadJpegFile637812143477007703__Normal() => _R34_EQPT.Staging__v2_56_0__R34_EQPT__DownloadJpegFile();
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ public class R34
|
|||||||
[TestMethod]
|
[TestMethod]
|
||||||
public void Staging__v2_56_0__R34__jpeg() => _R34.Staging__v2_56_0__R34__jpeg();
|
public void Staging__v2_56_0__R34__jpeg() => _R34.Staging__v2_56_0__R34__jpeg();
|
||||||
|
|
||||||
#if DEBUG
|
#if (!DEBUG)
|
||||||
[Ignore]
|
[Ignore]
|
||||||
#endif
|
#endif
|
||||||
[TestMethod]
|
[TestMethod]
|
||||||
|
@ -1,29 +0,0 @@
|
|||||||
#if true
|
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
|
||||||
|
|
||||||
namespace Adaptation._Tests.Extract.Staging.v2_56_0;
|
|
||||||
|
|
||||||
[TestClass]
|
|
||||||
public class R36_EQPT
|
|
||||||
{
|
|
||||||
|
|
||||||
#pragma warning disable CA2254
|
|
||||||
#pragma warning disable IDE0060
|
|
||||||
|
|
||||||
private static CreateSelfDescription.Staging.v2_56_0.R36_EQPT _R36_EQPT;
|
|
||||||
|
|
||||||
[ClassInitialize]
|
|
||||||
public static void ClassInitialize(TestContext testContext)
|
|
||||||
{
|
|
||||||
CreateSelfDescription.Staging.v2_56_0.R36_EQPT.ClassInitialize(testContext);
|
|
||||||
_R36_EQPT = CreateSelfDescription.Staging.v2_56_0.R36_EQPT.EAFLoggingUnitTesting;
|
|
||||||
}
|
|
||||||
|
|
||||||
#if DEBUG
|
|
||||||
[Ignore]
|
|
||||||
#endif
|
|
||||||
[TestMethod]
|
|
||||||
public void Staging__v2_56_0__R36_EQPT__DownloadJpegFile() => _R36_EQPT.Staging__v2_56_0__R36_EQPT__DownloadJpegFile();
|
|
||||||
|
|
||||||
}
|
|
||||||
#endif
|
|
@ -1,29 +0,0 @@
|
|||||||
#if true
|
|
||||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
|
||||||
|
|
||||||
namespace Adaptation._Tests.Extract.Staging.v2_56_0;
|
|
||||||
|
|
||||||
[TestClass]
|
|
||||||
public class R36
|
|
||||||
{
|
|
||||||
|
|
||||||
#pragma warning disable CA2254
|
|
||||||
#pragma warning disable IDE0060
|
|
||||||
|
|
||||||
private static CreateSelfDescription.Staging.v2_56_0.R36 _R36;
|
|
||||||
|
|
||||||
[ClassInitialize]
|
|
||||||
public static void ClassInitialize(TestContext testContext)
|
|
||||||
{
|
|
||||||
CreateSelfDescription.Staging.v2_56_0.R36.ClassInitialize(testContext);
|
|
||||||
_R36 = CreateSelfDescription.Staging.v2_56_0.R36.EAFLoggingUnitTesting;
|
|
||||||
}
|
|
||||||
|
|
||||||
#if DEBUG
|
|
||||||
[Ignore]
|
|
||||||
#endif
|
|
||||||
[TestMethod]
|
|
||||||
public void Staging__v2_56_0__R36__jpeg() => _R36.Staging__v2_56_0__R36__jpeg();
|
|
||||||
|
|
||||||
}
|
|
||||||
#endif
|
|
@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
[assembly: AssemblyVersion("2.52.0.0")]
|
[assembly: AssemblyVersion("2.56.0.0")]
|
||||||
[assembly: AssemblyFileVersion("2.52.0.0")]
|
[assembly: AssemblyFileVersion("2.56.0.0")]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user