Small bugfix and version bump
This commit is contained in:
parent
121ccaf295
commit
a59daa7a78
@ -108,30 +108,40 @@ namespace ENI2
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool HasCriticalInfoMissing(out string messageText)
|
public bool HasCriticalInfoMissing(out string messageText, string locode)
|
||||||
{
|
{
|
||||||
messageText = "";
|
messageText = "";
|
||||||
// Hier haben wir Logik für Spezialfälle, z.B. dass für BRE und BRV bestimmte Meldeklassen gesendet werden *müssen*
|
// Hier haben wir Logik für Spezialfälle, z.B. dass für BRE und BRV bestimmte Meldeklassen gesendet werden *müssen*
|
||||||
|
|
||||||
if(this.Core.PoC.Equals("DEBRV") || this.Core.PoC.Equals("DEBRE") || this.Core.PoC.Equals("DEHAM"))
|
switch (locode)
|
||||||
|
{
|
||||||
|
case "DEBRV":
|
||||||
|
case "DEBRE":
|
||||||
{
|
{
|
||||||
foreach (Message aMessage in _messages)
|
foreach (Message aMessage in _messages)
|
||||||
{
|
{
|
||||||
if (!this.Core.PoC.Equals("DEHAM")) {
|
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.NOA_NOD) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "NOA_NOD"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.NOA_NOD) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "NOA_NOD"; return true; }
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.AGNT) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "AGNT"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.AGNT) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "AGNT"; return true; }
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.INFO) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "INFO"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.INFO) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "INFO"; return true; }
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SEC) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "SEC"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SEC) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "SEC"; return true; }
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.TIEFA) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "TIEFA"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.TIEFA) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "TIEFA"; return true; }
|
||||||
}
|
}
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SERV) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "SERV"; return true; }
|
}
|
||||||
|
break;
|
||||||
|
case "DEHAM":
|
||||||
|
foreach (Message aMessage in _messages)
|
||||||
|
{
|
||||||
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SERV) && (aMessage.Elements.Count == 0)) { messageText = "SERV"; return true; }
|
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SERV) && (aMessage.Elements.Count == 0)) { messageText = "SERV"; return true; }
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Construction
|
#region Construction
|
||||||
|
|||||||
@ -36,8 +36,8 @@
|
|||||||
<MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion>
|
<MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion>
|
||||||
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
||||||
<WebPage>publish.html</WebPage>
|
<WebPage>publish.html</WebPage>
|
||||||
<ApplicationRevision>9</ApplicationRevision>
|
<ApplicationRevision>2</ApplicationRevision>
|
||||||
<ApplicationVersion>7.2.3.1</ApplicationVersion>
|
<ApplicationVersion>7.2.3.2</ApplicationVersion>
|
||||||
<UseApplicationTrust>false</UseApplicationTrust>
|
<UseApplicationTrust>false</UseApplicationTrust>
|
||||||
<CreateDesktopShortcut>true</CreateDesktopShortcut>
|
<CreateDesktopShortcut>true</CreateDesktopShortcut>
|
||||||
<PublishWizardCompleted>true</PublishWizardCompleted>
|
<PublishWizardCompleted>true</PublishWizardCompleted>
|
||||||
|
|||||||
@ -216,17 +216,28 @@ namespace ENI2
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Dez.22: Special case for BRE/BRV: Warning if some messages are not "confirmed"
|
// Dez.22: Special case for BRE/BRV: Warning if some messages are not "confirmed"
|
||||||
if(drc.Core.PoC.Equals("DEBRE")||drc.Core.PoC.Equals("DEBRV")||drc.Core.PoC.Equals("DEHAM"))
|
if(drc.Core.PoC.Equals("DEBRE")||drc.Core.PoC.Equals("DEBRV"))
|
||||||
{
|
{
|
||||||
if(drc.HasCriticalInfoMissing(out string missingClass))
|
if(drc.HasCriticalInfoMissing(out string missingClass, drc.Core.PoC))
|
||||||
{
|
{
|
||||||
_log.WarnFormat("set close warning because at least {0} is missing from BRE/BRV/HAM arrival", missingClass);
|
// _log.WarnFormat("set close warning because at least {0} is missing from BRE/BRV/HAM arrival", missingClass);
|
||||||
if (MessageBox.Show(string.Format(Properties.Resources.textSpecialCaseBREBRV, missingClass), Properties.Resources.textConfirmation, MessageBoxButton.YesNo,
|
if (MessageBox.Show(string.Format(Properties.Resources.textSpecialCaseBREBRV, missingClass), Properties.Resources.textConfirmation, MessageBoxButton.YesNo,
|
||||||
MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.No)
|
MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.No)
|
||||||
e.Cancel = true;
|
e.Cancel = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Jul.24: Special case HAM extended (from above)
|
||||||
|
if (drc.Core.PoC.Equals("DEHAM"))
|
||||||
|
{
|
||||||
|
if (drc.HasCriticalInfoMissing(out string missingClass, drc.Core.PoC))
|
||||||
|
{
|
||||||
|
if (MessageBox.Show(string.Format(Properties.Resources.textSpecialCaseDEHAM, missingClass), Properties.Resources.textConfirmation, MessageBoxButton.YesNo,
|
||||||
|
MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.No)
|
||||||
|
e.Cancel = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!e.Cancel)
|
if (!e.Cancel)
|
||||||
{
|
{
|
||||||
if (lockedCores.ContainsKey(tabItem))
|
if (lockedCores.ContainsKey(tabItem))
|
||||||
|
|||||||
9
ENI2/Properties/Resources.Designer.cs
generated
9
ENI2/Properties/Resources.Designer.cs
generated
@ -4682,6 +4682,15 @@ namespace ENI2.Properties {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to No {0} info given for DEHAM. Close anyway?.
|
||||||
|
/// </summary>
|
||||||
|
public static string textSpecialCaseDEHAM {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("textSpecialCaseDEHAM", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized string similar to Special requirements.
|
/// Looks up a localized string similar to Special requirements.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@ -1900,4 +1900,7 @@
|
|||||||
<data name="textCopyToPASD" xml:space="preserve">
|
<data name="textCopyToPASD" xml:space="preserve">
|
||||||
<value>Copy to PASD</value>
|
<value>Copy to PASD</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="textSpecialCaseDEHAM" xml:space="preserve">
|
||||||
|
<value>No {0} info given for DEHAM. Close anyway?</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
Loading…
Reference in New Issue
Block a user