From 8ede560ac66a8056a9bbb8d5c2b87e8ac25ac230 Mon Sep 17 00:00:00 2001 From: Kathy Date: Wed, 30 Sep 2020 13:22:51 +0000 Subject: [PATCH] =?UTF-8?q?F2020-023:=20Include=20substep=20levels=20in=20?= =?UTF-8?q?top=20&=20bottom=20continue=20message=20F2020-023:=20Include=20?= =?UTF-8?q?substep=20levels=20in=20top=20&=20bottom=20continue=20message?= =?UTF-8?q?=20(don=E2=80=99t=20duplicate=20parent=20tab)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Formats/fmtall/WCN1all.xml | Bin 97246 -> 97240 bytes .../VEPROMS.CSLA.Library/Extension/ItemExt.cs | 10 +++++++++ PROMS/Volian.Print.Library/vlnParagraph.cs | 21 +++++++++++++++++- 3 files changed, 30 insertions(+), 1 deletion(-) diff --git a/PROMS/Formats/fmtall/WCN1all.xml b/PROMS/Formats/fmtall/WCN1all.xml index 0150459914cdda87a2be5c5506c59bc763046ce1..4949db19f44d1b76c4affb71f5e718e44853f766 100644 GIT binary patch delta 90 zcmccjo%P0d)`l&NO>T_E(=U26t_4z!K8*9H1u;fUf8figG+iN@(Qmp!9;4Xy4IYdN d%y4Dffy!8=;arfe&(r&&7$0rt$zr@D2mmksA(H?A delta 67 zcmccdo%P;#)`l&NO>T@S)6aV|u4Oi2NZD@a&N!C^NnpBR2IJ@L1-^_zQb?lPfuhTW E0b?W=WB>pF diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs index b6be265e..760ff8ec 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs @@ -1017,6 +1017,7 @@ namespace VEPROMS.CSLA.Library if (ms && mn) pTab = pTab.TrimEnd() + "."; // remove ending '.' (if this is a hls, don't remove the '.') if (!itemInfo.IsHigh && thisTab.EndsWith(".")) thisTab = thisTab.Substring(0, thisTab.Length - 1); + if (itemInfo.HasParentTab) return thisTab.Trim(); // F2020-023: if tab includes parent tab already, don't concatenate it return pTab + thisTab.Trim(); } internal static void SetParentSectionAndDocVersion(ItemInfo itemInfo, IVEDrillDownReadOnly itemParent, SectionInfo sectionInfo, DocVersionInfo docVersionInfo, TransitionLookup tranLookup) @@ -1106,6 +1107,13 @@ namespace VEPROMS.CSLA.Library get { return _OffsetTab; } set { _OffsetTab = value; } } + // F2020-023: tab includes parent tab + private bool _HasParentTab = false; + public bool HasParentTab + { + get { return _HasParentTab; } + set { _HasParentTab = value; } + } private int _PrintLevel = 0; public int PrintLevel { @@ -4165,6 +4173,7 @@ namespace VEPROMS.CSLA.Library (myparent.IsStepPart && myparent.FormatStepData.AppendDotZero)) // F2018-022 Added step type flag to append a ".0" to the end of the high level step - put in for Westinghouse single column format (wst1), B2018-119 only do this for steps parentTab = parentTab.Replace(".0", ""); // this was added in, remove for substeps. tbformat = parentTab + (parentTab.EndsWith(".") ? "" : parentTab == "" ? "" : ".") + tbformat.TrimStart(); + HasParentTab = true; // F2020-023: tab includes parent tab } else if (IsSequential && ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.SkipNonSeqTabWithPar) { @@ -4182,6 +4191,7 @@ namespace VEPROMS.CSLA.Library { parentTab = mpar.MyTab.CleanText.Trim(); tbformat = parentTab + (parentTab.EndsWith(".") ? "" : ".") + tbformat.TrimStart(); + HasParentTab = true; // F2020-023: tab includes parent tab //if (_MyLog.IsInfoEnabled) _MyLog.InfoFormat("==>PARTAB: [{0}]", ShortPath + ", " + ItemID.ToString()); } } diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index ea6f1294..73dd1766 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -2701,7 +2701,13 @@ namespace Volian.Print.Library if (MyItemInfo.MyParent.IsSection && (docstyle.StructureStyle.Style & E_DocStructStyle.BottomSectionContinue) == E_DocStructStyle.BottomSectionContinue) myMsg = myMsg.Replace(@"%s", MyItemInfo.MyParent.MyTab.CleanText.Trim()); else - myMsg = myMsg.Replace(@"%s", MyItemInfo.MyParent.CombinedTab); + { + // F2020-023: tab includes parent tab and if caution/note don't use its parent, go up another level + if (MyItemInfo.IsCautionOrNotePart) + myMsg = myMsg.Replace(@"%s", MyItemInfo.MyParent.MyParent.CombinedTab); + else + myMsg = myMsg.Replace(@"%s", MyItemInfo.MyParent.CombinedTab); + } } if (myMsg.IndexOf(@"%3d") > -1) myMsg = myMsg.Replace(@"%3d", MyItemInfo.MyHLS.Ordinal.ToString()); @@ -2998,6 +3004,19 @@ namespace Volian.Print.Library myMsg = myMsg.Replace(@"%2d", tb.Trim(" .".ToCharArray()).PadLeft(2)); if (myMsg.IndexOf(@"%3d") > -1) myMsg = myMsg.Replace(@"%3d", MyItemInfo.MyHLS.Ordinal.ToString()); + // F2020-023: tab includes parent tab and if caution/note don't use its parent, go up another level + if (myMsg.IndexOf(@"%s") > -1) // %s was added for F2020-023 + { + string tmp = tb.Trim(); + if (!MyItemInfo.MyParent.IsHigh) + { + if (MyItemInfo.IsCautionOrNotePart) + tmp = MyItemInfo.MyParent.MyParent.CombinedTab.Trim(); + else + tmp = MyItemInfo.MyParent.CombinedTab.Trim(); + } + myMsg = myMsg.Replace(@"%s", tmp); + } return myMsg; } private vlnParagraph TopMostChild