Save ProcessDataStandardFormat to EC_Metrology_Si
Del alignment
This commit is contained in:
parent
1e0803199a
commit
c2b6d873f6
@ -171,19 +171,17 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
Append(x.GradeRadialGradient).Append(del).
|
Append(x.GradeRadialGradient).Append(del).
|
||||||
Append(x.RsMean).Append(del).
|
Append(x.RsMean).Append(del).
|
||||||
Append(x.RsStdDev).Append(del).
|
Append(x.RsStdDev).Append(del).
|
||||||
Append(x.RsRadialGradient).Append(del);
|
Append(x.RsRadialGradient);
|
||||||
foreach (pcl.Description description in descriptions)
|
foreach (pcl.Description description in descriptions)
|
||||||
{
|
_ = results.Append(del).Append(description.Index + 1).
|
||||||
_ = results.Append(description.Index + 1).Append(del).
|
Append(del).Append(description.NAvg).
|
||||||
Append(description.NAvg).Append(del).
|
Append(del).Append(description.Nsl).
|
||||||
Append(description.Nsl).Append(del).
|
Append(del).Append(description.Vd).
|
||||||
Append(description.Vd).Append(del).
|
Append(del).Append(description.FlatZ).
|
||||||
Append(description.FlatZ).Append(del).
|
Append(del).Append(description.RhoAvg).
|
||||||
Append(description.RhoAvg).Append(del).
|
Append(del).Append(description.Rhosl).
|
||||||
Append(description.Rhosl).Append(del).
|
Append(del).Append(description.Phase).
|
||||||
Append(description.Phase).Append(del).
|
Append(del).Append(description.Grade);
|
||||||
Append(description.Grade).Append(del);
|
|
||||||
};
|
|
||||||
return results.ToString();
|
return results.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,6 +6,7 @@ using Adaptation.Shared.Methods;
|
|||||||
using Adaptation.Shared.Metrology;
|
using Adaptation.Shared.Metrology;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Globalization;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
@ -16,6 +17,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
{
|
{
|
||||||
|
|
||||||
private readonly string _OpenInsightMetrologyViewerAPI;
|
private readonly string _OpenInsightMetrologyViewerAPI;
|
||||||
|
private readonly string _OpenInsightMetrologyViewerFileShare;
|
||||||
|
|
||||||
public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) :
|
public FileRead(ISMTP smtp, Dictionary<string, string> fileParameter, string cellInstanceName, int? connectionCount, string cellInstanceConnectionName, FileConnectorConfiguration fileConnectorConfiguration, string equipmentTypeName, string parameterizedModelObjectDefinitionType, IList<ModelObjectParameterDefinition> modelObjectParameters, string equipmentDictionaryName, Dictionary<string, List<long>> dummyRuns, Dictionary<long, List<string>> staticRuns, bool useCyclicalForDescription, bool isEAFHosted) :
|
||||||
base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null)
|
base(new Description(), false, smtp, fileParameter, cellInstanceName, connectionCount, cellInstanceConnectionName, fileConnectorConfiguration, equipmentTypeName, parameterizedModelObjectDefinitionType, modelObjectParameters, equipmentDictionaryName, dummyRuns, staticRuns, useCyclicalForDescription, isEAFHosted: connectionCount is null)
|
||||||
@ -29,6 +31,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
throw new Exception(cellInstanceConnectionName);
|
throw new Exception(cellInstanceConnectionName);
|
||||||
if (!_IsDuplicator)
|
if (!_IsDuplicator)
|
||||||
throw new Exception(cellInstanceConnectionName);
|
throw new Exception(cellInstanceConnectionName);
|
||||||
|
_OpenInsightMetrologyViewerFileShare = @"\\messv02ecc1.ec.local\EC_Metrology_Si\MetrologyAttachments\MercuryProbeRunHeader_";
|
||||||
_OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI");
|
_OpenInsightMetrologyViewerAPI = GetPropertyValue(cellInstanceConnectionName, modelObjectParameters, "OpenInsight.MetrologyViewerAPI");
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -107,11 +110,15 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma warning disable IDE0060
|
private void SendData(string reportFullPath, DateTime dateTime, List<pcl.Description> descriptions)
|
||||||
private void SendData(DateTime dateTime, List<pcl.Description> descriptions)
|
|
||||||
#pragma warning restore IDE0060
|
|
||||||
{
|
{
|
||||||
WSRequest wsRequest = new(this, _Logistics, descriptions);
|
int weekOfYear = _Calendar.GetWeekOfYear(dateTime, CalendarWeekRule.FirstDay, DayOfWeek.Sunday);
|
||||||
|
string directory = Path.Combine(_OpenInsightMetrologyViewerFileShare, dateTime.Year.ToString(), $"WW{weekOfYear:00}", _Logistics.Sequence.ToString());
|
||||||
|
if (!Directory.Exists(directory))
|
||||||
|
_ = Directory.CreateDirectory(directory);
|
||||||
|
string fullPath = Path.Combine(directory, Path.GetFileName(reportFullPath));
|
||||||
|
File.Copy(reportFullPath, fullPath);
|
||||||
|
WSRequest wsRequest = new(this, _Logistics, descriptions, fullPath);
|
||||||
(string json, WS.Results wsResults) = WS.SendData(_OpenInsightMetrologyViewerAPI, wsRequest);
|
(string json, WS.Results wsResults) = WS.SendData(_OpenInsightMetrologyViewerAPI, wsRequest);
|
||||||
if (!wsResults.Success)
|
if (!wsResults.Success)
|
||||||
throw new Exception(wsResults.ToString());
|
throw new Exception(wsResults.ToString());
|
||||||
@ -134,7 +141,7 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
List<pcl.Description> descriptions = pcl.ProcessData.GetDescriptions(jsonElements);
|
List<pcl.Description> descriptions = pcl.ProcessData.GetDescriptions(jsonElements);
|
||||||
Test[] tests = (from l in descriptions select (Test)l.Test).ToArray();
|
Test[] tests = (from l in descriptions select (Test)l.Test).ToArray();
|
||||||
if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0)
|
if (_IsEAFHosted && _FileConnectorConfiguration.FileScanningIntervalInSeconds > 0)
|
||||||
SendData(dateTime, descriptions);
|
SendData(reportFullPath, dateTime, descriptions);
|
||||||
results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>());
|
results = new Tuple<string, Test[], JsonElement[], List<FileInfo>>(pdsf.Item1, tests, jsonElements, new List<FileInfo>());
|
||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
@ -70,13 +70,15 @@ public class WSRequest
|
|||||||
public string WaferSize { get; set; }
|
public string WaferSize { get; set; }
|
||||||
public string Zone { get; set; }
|
public string Zone { get; set; }
|
||||||
public List<pcl.Detail> Details { get; protected set; }
|
public List<pcl.Detail> Details { get; protected set; }
|
||||||
|
public string ProcessDataStandardFormat { get; set; }
|
||||||
|
|
||||||
[Obsolete("For json")] public WSRequest() { }
|
[Obsolete("For json")] public WSRequest() { }
|
||||||
|
|
||||||
#pragma warning disable IDE0060
|
#pragma warning disable IDE0060
|
||||||
internal WSRequest(IFileRead fileRead, Logistics logistics, List<pcl.Description> descriptions)
|
internal WSRequest(IFileRead fileRead, Logistics logistics, List<pcl.Description> descriptions, string processDataStandardFormat = null)
|
||||||
#pragma warning restore IDE0060
|
#pragma warning restore IDE0060
|
||||||
{
|
{
|
||||||
|
ProcessDataStandardFormat = processDataStandardFormat;
|
||||||
Id = string.Empty;
|
Id = string.Empty;
|
||||||
Details = new List<pcl.Detail>();
|
Details = new List<pcl.Detail>();
|
||||||
CellName = logistics.MesEntity;
|
CellName = logistics.MesEntity;
|
||||||
@ -185,7 +187,7 @@ public class WSRequest
|
|||||||
{
|
{
|
||||||
if (string.IsNullOrEmpty(json))
|
if (string.IsNullOrEmpty(json))
|
||||||
{
|
{
|
||||||
WSRequest wsRequest = new(fileRead, logistics, descriptions);
|
WSRequest wsRequest = new(fileRead, logistics, descriptions, string.Empty);
|
||||||
(json, WS.Results wsResults) = WS.SendData(openInsightMetrologyViewerAPI, wsRequest);
|
(json, WS.Results wsResults) = WS.SendData(openInsightMetrologyViewerAPI, wsRequest);
|
||||||
if (!wsResults.Success)
|
if (!wsResults.Success)
|
||||||
throw new Exception(wsResults.ToString());
|
throw new Exception(wsResults.ToString());
|
||||||
|
@ -43,7 +43,6 @@
|
|||||||
<PackageReference Include="IKVM.OpenJDK.XML.API" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference>
|
<PackageReference Include="IKVM.OpenJDK.XML.API" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference>
|
||||||
<PackageReference Include="IKVM.Runtime" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference>
|
<PackageReference Include="IKVM.Runtime" Version="7.2.4630.5"><NoWarn>NU1701</NoWarn></PackageReference>
|
||||||
<PackageReference Include="Instances" Version="3.0.0" />
|
<PackageReference Include="Instances" Version="3.0.0" />
|
||||||
<PackageReference Include="Microsoft.AspNetCore.SignalR.Client" Version="7.0.5" />
|
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="7.0.4" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="7.0.4" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.CommandLine" Version="7.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.CommandLine" Version="7.0.0" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="7.0.0" />
|
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="7.0.0" />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user