Added logic to handle the “, step” prefix in Point Beach’s transition number 6 (index 5)

This commit is contained in:
John Jenko 2014-03-14 16:58:09 +00:00
parent 0bfa619d99
commit ac8a99dd84

View File

@ -470,6 +470,14 @@ namespace VEPROMS.CSLA.Library
_Results.Append(Prefix);
_Prefix = null;
}
else if (_TranType == 5 && Prefix != null)
{
if (!HasText && Prefix.StartsWith(", "))
_Results.Append(Prefix.TrimStart(", ".ToCharArray()));
else
_Results.Append(Prefix);
_Prefix = null;
}
// If the prefix contains an open paren, we want to add the open paren regardless
// of whether there already is text in the resulting string.
else if (!HasText && Prefix != null && Prefix.Contains("("))
@ -861,7 +869,8 @@ namespace VEPROMS.CSLA.Library
tb.Remove(tb.Length - 7, 7); // 7 is length of ", Step "
tb.AppendPrefix();
}
else if (tb._TranType == 4 && tb._ToItem.MoreThanOneStepSection())
//else if (tb._TranType == 4 && tb._ToItem.MoreThanOneStepSection())
else if (tb._TranType == 4 && tb._ToItem.MoreThanOneStepSection() || tb._TranType == 5)
{
tb.AppendPrefix();
}
@ -948,6 +957,11 @@ namespace VEPROMS.CSLA.Library
// and going to default section, do not add it.
if (tb._ToItem.MyProcedure.ItemID != tb._FromItem.MyProcedure.ItemID && sect != null &&
sect.IsDefaultSection) return false; // tb.TextAdded;
// if in same procedure and same section do not add it.
if (tb._ToItem.MyProcedure.ItemID == tb._FromItem.MyProcedure.ItemID &&
sect == TranGetSectionItem(tb._FromItem))
return false;
// If a 'thru' range, only put out the section if it's to a different section
// that is not the default section.