eregister ebeling & fuhzoe

This commit is contained in:
Stoyan Zlatev
2024-12-18 15:13:15 +01:00
parent aaa71b61fc
commit b513f8d6ab
5 changed files with 124 additions and 77 deletions
@@ -764,7 +764,19 @@
return;
}
if (eolProgress.StandardRequirementId != requirements.StandardId)
if (requirements.IsStandardActive == false)
{
this.ThrowSentinelException($"Standard requirement is not active");
}
else if (requirements.IsStandardActive == true && requirements.IsStandardApproved == false)
{
this.ThrowSentinelException($"Standard requirement is active but not approved");
}
else if (requirements.IsSpecialActive == true && requirements.IsSpecialApproved == false)
{
this.ThrowSentinelException($"Special requirement is active but not approved");
}
else if (eolProgress.StandardRequirementId != requirements.StandardId)
{
this.ThrowSentinelException(
nameof(EOLProgressModel)
@@ -804,18 +816,6 @@
, nameof(requirements.SpecialVersion)
, requirements.SpecialVersion);
}
else if (requirements.IsStandardActive == false)
{
this.ThrowSentinelException($"Standard requirement is not active");
}
else if (requirements.IsStandardActive == true && requirements.IsStandardApproved == false)
{
this.ThrowSentinelException($"Standard requirement is active but not approved");
}
else if (requirements.IsSpecialActive == true && requirements.IsSpecialApproved == false)
{
this.ThrowSentinelException($"Special requirement is active but not approved");
}
}
internal void TryGetCordonelAppsAndRegisterValues(int pcbId, out CordonelAppsDictionary apps)
@@ -1042,6 +1042,7 @@
var sentinelVersion = $"{nameof(Sentinel)} - V{assemblyVersion.Major}.{assemblyVersion.MajorRevision}.{assemblyVersion.Minor}";
var exported = this.meterProcessState.MakeSAPExport(pcbId, state, nameof(Sentinel));
//TODO
//if (!exported)
//{
// this.ThrowSentinelException($"SAP export für PcbId: {pcbId} wurde nicht durchgeführt");
@@ -1052,9 +1053,9 @@
=> throw new SentinelException(method, message);
private SentinelException ThrowSentinelException(object class1, object property1, object value1, object class2, object property2, object value2, [CallerMemberName] string method = "")
=> throw new SentinelException(method, string.Format("{0}.{1}({2}) != {3}.{4}({5})", class1, property1, value1, class2, property2, value2));
=> throw new SentinelException(method, string.Format("{0}.{1}({2}) != {3}.{4}({5})", class1, property1, value1 ?? "NULL", class2, property2, value2 ?? "NULL"));
private SentinelException ThrowSentinelException(string class1, string property1, object value1, string sign, string class2, string property2, object value2, [CallerMemberName] string method = "")
=> throw new SentinelException(method, string.Format("{0}.{1}({2}) {3} {4}.{5}({6})", class1, property1, value1, sign, class2, property2, value2));
=> throw new SentinelException(method, string.Format("{0}.{1}({2}) {3} {4}.{5}({6})", class1, property1, value1 ?? "NULL", sign, class2, property2, value2 ?? "NULL"));
}
}