Save Copy - sql or json

CA1862 and GetWeekOfYear for WritePDSF
Removed Open Insight API IFX Directory from Save
v2_52_0-Tests
net8.0
This commit is contained in:
2024-02-01 14:34:59 -07:00
parent 839a08eda7
commit ee7be147e0
75 changed files with 1633 additions and 292 deletions

View File

@ -31,7 +31,7 @@ public class FileRead : Shared.FileRead, IFileRead
throw new Exception(cellInstanceConnectionName);
if (!_IsDuplicator)
throw new Exception(cellInstanceConnectionName);
_OpenInsightMetrologyViewerFileShare = @"\\messv02ecc1.ec.local\EC_Metrology_Si\MetrologyAttachments\TencorRunHeader_";
_OpenInsightMetrologyViewerFileShare = @"\\mesfs.infineon.com\EC_Metrology_Si\MetrologyAttachments\TencorRunHeader_";
_OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI");
}
@ -117,6 +117,8 @@ public class FileRead : Shared.FileRead, IFileRead
if (!Directory.Exists(directory))
_ = Directory.CreateDirectory(directory);
string fullPath = Path.Combine(directory, Path.GetFileName(reportFullPath));
if (File.Exists(fullPath))
File.Delete(fullPath);
File.Copy(reportFullPath, fullPath);
WSRequest wsRequest = new(this, _Logistics, descriptions, fullPath);
(string json, WS.Results wsResults) = WS.SendData(_OpenInsightMetrologyViewerAPI, wsRequest);

View File

@ -4,7 +4,6 @@ using Adaptation.Shared.Properties;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Text.Json;
@ -181,7 +180,7 @@ public class WSRequest
Details.Add(detail);
}
Date = logistics.DateTimeFromSequence.ToString();
if (UniqueId is null && Details.Any())
if (UniqueId is null && Details.Count != 0)
UniqueId = Details[0].HeaderUniqueId;
for (int i = 0; i < Details.Count; i++)
{
@ -273,7 +272,7 @@ public class WSRequest
cossArray.setString(a - 1, string.Concat(" {*", fullName, reactorLoadLock, "}]"));
}
}
if (updateValues.Any())
if (updateValues.Count != 0)
{
updatedStream = new org.apache.pdfbox.pdmodel.common.PDStream(pdDocument);
outputStream = updatedStream.createOutputStream();
@ -283,7 +282,7 @@ public class WSRequest
page.setContents(updatedStream);
}
}
if (updateValues.Any())
if (updateValues.Count != 0)
pdDocument.save(checkFileName);
pdDocument.close();
}