From 441917b6709fcf8dd1bd2758a27fddc50ece6952 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Thu, 6 Nov 2025 15:13:50 -0500 Subject: [PATCH 01/18] F2025-034 Updated Transition format to turn off putting parenthesis around section title and turn off the attempt of title-casing the procedure title. --- PROMS/Formats/fmtall/VEGP1all.xml | Bin 184418 -> 184426 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 236926 -> 236934 bytes PROMS/Formats/fmtall/VEGPAlrall.xml | Bin 211260 -> 211268 bytes PROMS/Formats/fmtall/VEGPBckStpsall.xml | Bin 59160 -> 59168 bytes PROMS/Formats/fmtall/VEGPBckall.xml | Bin 88838 -> 88846 bytes 5 files changed, 0 insertions(+), 0 deletions(-) diff --git a/PROMS/Formats/fmtall/VEGP1all.xml b/PROMS/Formats/fmtall/VEGP1all.xml index 275fd0b6df786d8e8bf241676836054a2821442e..a3f49af9957c776641d8bcccd5bd6f697f3f23c1 100644 GIT binary patch delta 65 zcmaE~fcw<~?uIRlB~PZSEn^gz9`b}yX8OD*j6$efzUgO{GYL#KGvb@h@|4kJvJVU2 Kc9*A&a<2h<5gB;^ delta 59 zcmaF0fcwz`?uIRlB~K>18SqVSdBUg%V`xo(^Mp}g@)I+G>3(Y%*`|v;Wz?E}<2WPF KcAuw=a<2gbOBnM2 diff --git a/PROMS/Formats/fmtall/VEGP2all.xml b/PROMS/Formats/fmtall/VEGP2all.xml index 402c540a8d9130a6c56105d221b24d22c95504c1..cea4fc161d86f6364de9f6fc8abf74be2bf8ead9 100644 GIT binary patch delta 70 zcmeyji?3}rU&9v0j(gK1?lJ02e|L|OZ~B3Ij4adJE(2L<_Za0sVsa3!RW&2mbfx=@ UT9bFN@U=(WXWSlfpGj>W0A!XO-2eap delta 62 zcmZqM&G&B?U&9v0j(gKJS{Zq!PrJuxz#76(#85iD{~n|9wEK(#(^D2QicQzJ&!`2F PXpg+lxIOYdlkPqM2f!DU diff --git a/PROMS/Formats/fmtall/VEGPAlrall.xml b/PROMS/Formats/fmtall/VEGPAlrall.xml index dbcba104540e0f4704bff3e6522bf7115505a316..286b1781c5469c2932b19f62f1111479489aa515 100644 GIT binary patch delta 89 zcmdnTiFbbh^`6mBS=9w0+>_2ejJbh diff --git a/PROMS/Formats/fmtall/VEGPBckStpsall.xml b/PROMS/Formats/fmtall/VEGPBckStpsall.xml index 8fdafbe29d32a902b5922934c62809adcb61c5d6..49b0a79432028fb88721e3d101027977c9a195ba 100644 GIT binary patch delta 54 zcmbPnj(Nd3<_-7OO@3y?H+j!Gxyc;sg^<{MldW`kCbw-9nw+=ZWO7)f!sY|(Bg_H4 CEErG# delta 50 zcmZ2*j(Ns8<_-7OO|CHJnLL4$ZStpeT9aEig@Cl$WGfw>$-i8sCfBXknryX%XY;o8 GS>^ytxE726 diff --git a/PROMS/Formats/fmtall/VEGPBckall.xml b/PROMS/Formats/fmtall/VEGPBckall.xml index 69d71ae8a0bcad927158cdbf2e4323e7f0b92d54..286597449549f46bfd24f1d03d8a93e1d66baadd 100644 GIT binary patch delta 88 zcmZqM#@e@yb;E@Plf{_%Ca+r{H~H5BAtW~6bSoD|0kA;ALX*h`EPT_~g)p*B-ZO<~ ja@Jyz$?uknO`fn!Z*qV?$7H=l9Fr$3)!Xc`Xx|P1G{+=5 delta 58 zcmeC%#@e=xb;E@PtRW0V45gE=FEEF*j3;{;@=QKv!Z-N?Bg^EBg+`OxSQI9|TPU>o I+(L()0J1O`KmY&$ -- 2.49.1 From 6f089482e6b1b28678a1da26094af80bb5c17275 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Thu, 6 Nov 2025 15:58:30 -0500 Subject: [PATCH 02/18] F2025-035 Change the open/closed parenthesis on the 2nd and 3rd sub-step levelsl to just the close parenthesis --- PROMS/Formats/fmtall/VEGP1all.xml | Bin 184426 -> 184042 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 236934 -> 236530 bytes PROMS/Formats/fmtall/VEGPAlrall.xml | Bin 211268 -> 210864 bytes PROMS/Formats/fmtall/VEGPBckall.xml | Bin 88846 -> 88462 bytes 4 files changed, 0 insertions(+), 0 deletions(-) diff --git a/PROMS/Formats/fmtall/VEGP1all.xml b/PROMS/Formats/fmtall/VEGP1all.xml index a3f49af9957c776641d8bcccd5bd6f697f3f23c1..92a8e7abe5bd18c6708b840499417954c397364c 100644 GIT binary patch delta 62 zcmaF0fcw>4?hP9DlkeGbOnY3>+VFY5P?b}S4 HFJu4!BY6~z delta 88 zcmeygov&>---b9NMvcje#)d#L&{%u&2Sbg?4~(49#ilnzF|ka3Vk9wng@MUr9peCy a!s!hu%xulijM|?WF#<8u_Gd=SJedG-mmk^y diff --git a/PROMS/Formats/fmtall/VEGPAlrall.xml b/PROMS/Formats/fmtall/VEGPAlrall.xml index 286b1781c5469c2932b19f62f1111479489aa515..f2fc06cc56736b974f36b2a094138da7d76bc9ba 100644 GIT binary patch delta 62 zcmX@|iD$!mo(&W9Ch2lbo};G$p*SY%8A?q4pqGUz+N@{Tu4l*y#7x`u44K6^0QZ3u A;Q#;t delta 95 zcmdn+p6AFXo(&W97&Rsz)DxcUp`!q1O-17ePj{$iAP5x)6GWmla f$K*Uam&pkZ9Fwc;ohDDPWNWT-*k0$rC?E*{>P#I= -- 2.49.1 From 1c87585570e88f8495b4b0d9759c788955fbf524 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Fri, 7 Nov 2025 09:51:18 -0500 Subject: [PATCH 03/18] =?UTF-8?q?F2025-036=20Removed=20the=20Two=20Column?= =?UTF-8?q?=20Attachment=20section=20style=20that=20is=20no=20longer=20nee?= =?UTF-8?q?ded=20because=20it=E2=80=99s=20identical=20to=20the=20=E2=80=9C?= =?UTF-8?q?Attachment=20-=20Two=20Column=20Step=20Editor=E2=80=9D=20sectio?= =?UTF-8?q?n=20style?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Formats/fmtall/VEGP2all.xml | Bin 236530 -> 233130 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/PROMS/Formats/fmtall/VEGP2all.xml b/PROMS/Formats/fmtall/VEGP2all.xml index 4b2a2e2a818c741829d2aeb98b037610b28b20e6..eced26724521ddb1c9a1396f3aed646d3ce168ec 100644 GIT binary patch delta 85 zcmeygop04#zJ?aYEld(url09y*4iF+g~^C(d%+LJM{L`<-Y~^L+0%I@F-L57U|~*c j2CJKHFo}_E`m1(kx#`PRGm322>t(KE+FsSgTp)0V_ delta 114 zcmZ2Am+#YdzJ?aYEld(ure`TJYfTs8VHVl$bcM-?Yr8=Y(<$cZ4jN2y+iw{#mvC-3 vc*@j-DLfr0thRm1H>Q2f2qUH&Ok!l4ek_Msg3)06!A|CKrtL Date: Mon, 10 Nov 2025 09:25:26 -0500 Subject: [PATCH 04/18] B2025-060 Fixes the printing a sub-section top continue message when the section is forced to start on the next page, either by PROMS print logic or when that sub-section is set to separate pagination. --- PROMS/Formats/fmtall/VEGP1all.xml | Bin 184042 -> 184072 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 233130 -> 233142 bytes PROMS/Volian.Print.Library/vlnParagraph.cs | 5 ++++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/PROMS/Formats/fmtall/VEGP1all.xml b/PROMS/Formats/fmtall/VEGP1all.xml index 92a8e7abe5bd18c6708b840499417954c397364c..11cbc389376d5b67f36a913c1e98b8e18f3f3f79 100644 GIT binary patch delta 60 zcmaDgm%C#gcS8%~7N#SG(;KEU8L|5^xH5z=I8L{n#Uu^q#Li+;oNiXc;0Lo+QN7kQo4-O4SJX)w!iCR OikXjHRlXjxbpik%i5yY@ delta 69 zcmdlsmv7ZvzJ?aYElgeh+c$_aAK{w5D~Q=_c}EnJF^C_;xcy!qQ^|Y~yNPl7g=I`4 W)A?AKe{7eTz*NS$J<5tXCIkSuNg3?` diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 2f307726..d2fd1df4 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -1855,7 +1855,10 @@ namespace Volian.Print.Library if (doSectionContinue) DoTopContinueMsg(cb, ref yPageStart, yTopMargin, docstyle, null); // If "ContinueSectionHeader" (format flag) is true then print the section title with "(Continued)" appended to it // B2020-164 added check for SpecialCaseCalvert to bypass IsSeparateSubsection STP O-67B-2 step 6.5 - if ((!MyItemInfo.IsSection || MyItemInfo.IsSubsection) && + // B2025-060 no section continue message if previous was not in same section or sub-section + // fixes Vogtle units 3&4 3-AOP-116 Attachments 2 & 3 + if ((!MyItemInfo.IsSection || MyItemInfo.IsSubsection) && + (MyItemInfo.ActiveSection == MyItemInfo.MyPrevious.ActiveSection) && MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.ContinueSectionHeader && (!MyItemInfo.IsSection || (MyItemInfo.IsSeparateSubsection || MyItemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.SpecialCaseCalvert))) { -- 2.49.1 From 875a8f101a9dde94c87eca37126af95a4c2b369f Mon Sep 17 00:00:00 2001 From: John Jenko Date: Fri, 14 Nov 2025 11:36:23 -0500 Subject: [PATCH 05/18] B2025-062 Fixed a null reference bug in the printing of Vogtle Units 3 & 4 AOP-204 --- PROMS/Volian.Print.Library/vlnParagraph.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index d2fd1df4..591ed771 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -1858,7 +1858,7 @@ namespace Volian.Print.Library // B2025-060 no section continue message if previous was not in same section or sub-section // fixes Vogtle units 3&4 3-AOP-116 Attachments 2 & 3 if ((!MyItemInfo.IsSection || MyItemInfo.IsSubsection) && - (MyItemInfo.ActiveSection == MyItemInfo.MyPrevious.ActiveSection) && + (MyItemInfo.MyPrevious != null && MyItemInfo.ActiveSection == MyItemInfo.MyPrevious.ActiveSection) && MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.StepSectionData.ContinueSectionHeader && (!MyItemInfo.IsSection || (MyItemInfo.IsSeparateSubsection || MyItemInfo.ActiveFormat.PlantFormat.FormatData.PrintData.SpecialCaseCalvert))) { -- 2.49.1 From bd89af5e8c674a4aa88618e21fda76775f2584b9 Mon Sep 17 00:00:00 2001 From: mschill Date: Mon, 17 Nov 2025 07:05:52 -0500 Subject: [PATCH 06/18] C2019-036 View Only mode work with Checked Out Procedures --- PROMS/VEPROMS User Interface/frmVEPROMS.cs | 43 +++++-- .../VEPROMS.CSLA.Library/Extension/ItemExt.cs | 10 +- .../Extension/MultiUserExt.cs | 2 +- .../VEPROMS.CSLA.Library/Generated/Content.cs | 11 +- .../DisplayTabControl.cs | 15 ++- .../Volian.Controls.Library/DisplayTabItem.cs | 26 +++-- PROMS/Volian.Controls.Library/StepPanel.cs | 21 ++++ .../Volian.Controls.Library/StepTabRibbon.cs | 107 +++++++++++++++++- .../StepTabRibbon.designer.cs | Bin 577962 -> 583236 bytes 9 files changed, 208 insertions(+), 27 deletions(-) diff --git a/PROMS/VEPROMS User Interface/frmVEPROMS.cs b/PROMS/VEPROMS User Interface/frmVEPROMS.cs index 8f09424b..1fded9ad 100644 --- a/PROMS/VEPROMS User Interface/frmVEPROMS.cs +++ b/PROMS/VEPROMS User Interface/frmVEPROMS.cs @@ -98,6 +98,8 @@ namespace VEPROMS _SelectedStepTabPanel.MyStepTabRibbon.ContActionSummaryRequest += MyStepTabRibbon_ContActionSummaryRequest; _SelectedStepTabPanel.MyStepTabRibbon.AddProcToDVInTree -= new StepTabRibbonEvent(MyStepTabRibbon_AddProcToDocVersionInTree); _SelectedStepTabPanel.MyStepTabRibbon.AddProcToDVInTree += new StepTabRibbonEvent(MyStepTabRibbon_AddProcToDocVersionInTree); + _SelectedStepTabPanel.MyStepTabRibbon.EnableDisableStepProperties -= EnableDisableStepProperties; + _SelectedStepTabPanel.MyStepTabRibbon.EnableDisableStepProperties += new StepTabRibbonEvent(EnableDisableStepProperties); // F2022-024 Time Critical Action Summary _SelectedStepTabPanel.MyStepTabRibbon.TimeCriticalActionSummaryRequest -= MyStepTabRibbon_TimeCriticalActionSummaryRequest; _SelectedStepTabPanel.MyStepTabRibbon.TimeCriticalActionSummaryRequest += MyStepTabRibbon_TimeCriticalActionSummaryRequest; @@ -119,7 +121,7 @@ namespace VEPROMS //added by jcb 20130718 to support create pdf button when multi-unit and user selects a unit pi.MyDocVersion.DocVersionConfig.SelectedSlave = pi.ProcedureConfig.SelectedSlave; - + DlgPrintProcedure prnDlg = new DlgPrintProcedure(pi); //added by jcb 20130718 to support create pdf button when multi-unit and user selects a unit @@ -372,12 +374,12 @@ namespace VEPROMS cmbFont.SelectedIndex = -1; string[] parameters = System.Environment.CommandLine.Split(" ".ToCharArray()); string db = Volian.Base.Library.VlnSettings.GetDB(); - + if (db != null) Database.SelectedDatabase = db; //B2018-129 Most Recently Used list was being cleared. Needed to remove a (string) type case in the IF statement - if (!string.IsNullOrEmpty((string)Properties.Settings.Default["DefaultDB"])) + if (!string.IsNullOrEmpty((string)Properties.Settings.Default["DefaultDB"])) Database.LastDatabase = Properties.Settings.Default.DefaultDB; // Setup the Context menu for DisplaySearch including the symbols @@ -416,7 +418,7 @@ namespace VEPROMS // B2019-107 Error Log message for inconsistent PromsFixes _MyLog.InfoFormat("\r\nSession Beginning\r\n<===={0}[SQL:{1:yyMM.ddHH}]====== User: {2}/{3} Started {4} ===============>{5}" , Application.ProductVersion, Database.RevDate, Environment.UserDomainName, Environment.UserName, DateTime.Now.ToString("dddd MMMM d, yyyy h:mm:ss tt"), FormatInfo.Failed ?? ""); - + // C2022-030 Notify the user if the stored procedure in the database are not update to date // with those in the PROMSFixes.sql delivered with the PROMS executable string pfVersion = ExeInfo.GetAssocicatedPROMSFixesVersion(); @@ -546,7 +548,7 @@ namespace VEPROMS tv.ProcedureCheckedOutTo += new vlnTreeViewEvent(tv_ProcedureCheckedOutTo); tv.ViewPDF += new vlnTreeViewPdfEvent(tv_ViewPDF); displayApplicability.ApplicabilityViewModeChanged += new DisplayApplicability.DisplayApplicabilityEvent(displayApplicability_ApplicabilityViewModeChanged); - + tv.ExportImportProcedureSets += new vlnTreeViewEvent(tv_ExportImportProcedureSets); tv.PrintTransitionReport += new vlnTreeViewEvent(tv_PrintTransitionReport); tv.ProcessingComplete += tv_ProcessingComplete; @@ -587,7 +589,7 @@ namespace VEPROMS } } - void tv_SelectDateToStartChangeBars(object sender, vlnTreeEventArgs args) + void tv_SelectDateToStartChangeBars(object sender, vlnTreeEventArgs args) { ProcedureInfo pi = (args.Node as VETreeNode).VEObject as ProcedureInfo; if (pi == null) return; @@ -1196,6 +1198,7 @@ namespace VEPROMS if (!MySessionInfo.CanCheckOutItem(pi.ItemID, CheckOutType.Procedure, ref message)) { + message = message.Replace("\r\nWould You like to open the procedure in View Only Mode?", ""); MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } @@ -2085,7 +2088,10 @@ namespace VEPROMS { foreach (DisplayTabItem dti in tc.MyBar.Items) { - if (!myList.Contains(dti.OwnerID)) + //C2019-036 View Only mode work with Checked Out Procedures + // View Only Mode is no longer checked out, so no longer has an OwnerID + // This will keep those tabs from auto-closing based on the timer + if (!myList.Contains(dti.OwnerID) && dti.MyStepTabPanel.MyStepPanel.VwMode != E_ViewMode.View) { MyCloseTabList.PushDTI(dti); } @@ -3926,6 +3932,7 @@ namespace VEPROMS string message = string.Empty; if (!MySessionInfo.CanCheckOutItem(args.ProcedureConfig.MyProcedure.ItemID, CheckOutType.Procedure, ref message)) { + message = message.Replace("\r\nWould You like to open the procedure in View Only Mode?", ""); MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning); this.Cursor = Cursors.Default; return DialogResult.None; @@ -3949,6 +3956,7 @@ namespace VEPROMS string message = string.Empty; if (!MySessionInfo.CanCheckOutItem(args.SectionConfig.MySection.MySectionInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message)) { + message = message.Replace("\r\nWould You like to open the procedure in View Only Mode?", ""); MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning); this.Cursor = Cursors.Default; return DialogResult.None; @@ -4749,6 +4757,11 @@ namespace VEPROMS // B2022-026 RO Memory reduction coding (Jakes Merge) displayRO.SetFindDocROButton(false); displayRO.LoadTree(); + + //C2019-036 View Only mode work with Checked Out Procedures + //In View Only Mode - Step Properties should be disabled + EnableDisableStepProperties(sender, new StepTabRibbonEventArgs(args.MyEditItem.MyItemInfo, 0, args.MyEditItem.MyStepPanel.VwMode)); + } else { @@ -4780,6 +4793,22 @@ namespace VEPROMS } + //C2019-036 View Only mode work with Checked Out Procedures + //In View Only Mode - Step Properties should be disabled + public void EnableDisableStepProperties(object sender, StepTabRibbonEventArgs args) + { + if (args.ViewMode == E_ViewMode.View && (infoTabs.Enabled || infoTabs.SelectedTab != infotabTags)) + { + infoTabs.Enabled = true; + infoTabs.SelectedTab = infotabTags; + infoTabs.Enabled = false; + } + else if (args.ViewMode != E_ViewMode.View && !infoTabs.Enabled) + { + infoTabs.Enabled = true; + } + } + void _LastStepRTB_EditModeChanged(object sender, EventArgs args) { if (_LastStepRTB.EditMode) // going into edit mode in a cell of the grid. diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs index 62e5ca4a..532d3585 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs @@ -7984,12 +7984,20 @@ namespace VEPROMS.CSLA.Library public ProcedureInfo(SafeDataReader dr) : base(dr) { } #endif private ProcedureInfo() : base() { ;} - public new static ProcedureInfo Get(int itemID) + public new static ProcedureInfo Get(int itemID, bool forcerefresh = false) { //if (!CanGetObject()) // throw new System.Security.SecurityException("User not authorized to view a Item"); try { + //C2019-036 View Only mode work with Checked Out Procedures + // fixes caching issue + // so this forces a refresh of the cache + if (forcerefresh) + { + _CacheByPrimaryKey.Remove(itemID.ToString()); + } + ProcedureInfo tmp = GetCachedByPrimaryKey(itemID); if (tmp == null) { diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/MultiUserExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/MultiUserExt.cs index ae52c60e..7c8f36c5 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/MultiUserExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/MultiUserExt.cs @@ -186,7 +186,7 @@ namespace VEPROMS.CSLA.Library if (string.IsNullOrEmpty(name)) { name = tmpproc.DisplayText; } - message = string.Format("The procedure {0} is already checked out to {1}", name, si.UserID); + message = string.Format("The procedure {0} is already checked out to {1}.\r\nWould You like to open the procedure in View Only Mode?", name, si.UserID); rv = rv && false; } else if (si.ProcessID != this.ProcessID && objectType == CheckOutType.Document) diff --git a/PROMS/VEPROMS.CSLA.Library/Generated/Content.cs b/PROMS/VEPROMS.CSLA.Library/Generated/Content.cs index 743a7fdd..a2bc7db8 100644 --- a/PROMS/VEPROMS.CSLA.Library/Generated/Content.cs +++ b/PROMS/VEPROMS.CSLA.Library/Generated/Content.cs @@ -990,12 +990,21 @@ namespace VEPROMS.CSLA.Library } return tmp; } - public static Content Get(int contentID) + public static Content Get(int contentID, bool forcerefresh = false) { if (!CanGetObject()) throw new System.Security.SecurityException("User not authorized to view a Content"); try { + //C2019-036 View Only mode work with Checked Out Procedures + // fixes caching issue + // this forces a refresh of the cache for a case when need to do a hard refresh + if (forcerefresh) + { + ConvertListToDictionary(); + _CacheByPrimaryKey.Remove(contentID.ToString()); + } + Content tmp = GetCachedByPrimaryKey(contentID); if (tmp == null) { diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index bda8b089..f58db41c 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -603,6 +603,8 @@ namespace Volian.Controls.Library { ItemInfo myItemInfo = myItemInfo2; + bool viewonlymode = false; + //B2025-046 Remember Tabs failing when swapping versions of PROMS if (myItemInfo?.MyDocVersion == null) // bug fix: B2016-108 disconnected data will not have a MyDocVersion { @@ -620,8 +622,11 @@ namespace Volian.Controls.Library { if (!MySessionInfo.CanCheckOutItem(myItemInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message)) { - FlexibleMessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning); - return null; + //C2019-036 View Only mode work with Checked Out Procedures + if (MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) + viewonlymode = true; + else + return null; } } else @@ -682,7 +687,7 @@ namespace Volian.Controls.Library // C2023-016 if a Word section and doing Find/Replace don't open Word section, position to section title in step editor instead if (myItemInfo.MyContent.MyEntry == null || doingFindReplace) // If it is not a Word document open in step editor { - return OpenStepTabPage(myItemInfo, setFocus); + return OpenStepTabPage(myItemInfo, setFocus, viewonlymode); } else // Otherwise open it in the Word editor { @@ -1178,7 +1183,7 @@ namespace Volian.Controls.Library //} //public Dictionary dicEnhancedDocuments = new Dictionary(); - private DisplayTabItem OpenStepTabPage(ItemInfo myItemInfo, bool setFocus) + private DisplayTabItem OpenStepTabPage(ItemInfo myItemInfo, bool setFocus, bool viewonlymode = false) { ItemInfo proc = myItemInfo.MyProcedure; // Find procedure Item string key = "Item - " + proc.ItemID.ToString(); @@ -1197,7 +1202,7 @@ namespace Volian.Controls.Library } else // If not already open, create a new Page { - pg = new DisplayTabItem(this.components, this, proc, key); // Open a new Procedure Tab + pg = new DisplayTabItem(this.components, this, proc, key, viewonlymode); // Open a new Procedure Tab _MyDisplayTabItems.Add(key, pg); if (setFocus) { diff --git a/PROMS/Volian.Controls.Library/DisplayTabItem.cs b/PROMS/Volian.Controls.Library/DisplayTabItem.cs index cf7db754..dbddc13d 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabItem.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabItem.cs @@ -98,13 +98,18 @@ namespace Volian.Controls.Library } #endregion #region Constructors - public DisplayTabItem(IContainer container, DisplayTabControl myDisplayTabControl, ItemInfo myItemInfo, string myKey) + public DisplayTabItem(IContainer container, DisplayTabControl myDisplayTabControl, ItemInfo myItemInfo, string myKey, bool viewonlymode = false) { _MyItemInfo = myItemInfo; - if (MyItemInfo.MyContent.MyEntry == null) - OwnerID = myDisplayTabControl.MySessionInfo.CheckOutItem(myItemInfo.MyProcedure.ItemID, CheckOutType.Procedure); - else - OwnerID = myDisplayTabControl.MySessionInfo.CheckOutItem(myItemInfo.MyContent.MyEntry.DocID, CheckOutType.Document); + //C2019-036 View Only mode work with Checked Out Procedures + //don't want to check out if opening in View Only Mode Due to someone else having it checked out + if (!viewonlymode) + { + if (MyItemInfo.MyContent.MyEntry == null) + OwnerID = myDisplayTabControl.MySessionInfo.CheckOutItem(myItemInfo.MyProcedure.ItemID, CheckOutType.Procedure); + else + OwnerID = myDisplayTabControl.MySessionInfo.CheckOutItem(myItemInfo.MyContent.MyEntry.DocID, CheckOutType.Document); + } //Console.WriteLine("DisplayTabItem"); _MyKey = myKey; _MyDisplayTabControl = myDisplayTabControl; @@ -112,7 +117,7 @@ namespace Volian.Controls.Library InitializeComponent(); this.Click += new EventHandler(DisplayTabItem_Click); if (myItemInfo.MyContent.MyEntry == null) - SetupStepTabPanel(); + SetupStepTabPanel(viewonlymode); else SetupDSOTabPanel(); SetupSecurity(myItemInfo); @@ -128,6 +133,11 @@ namespace Volian.Controls.Library private bool MesssageShown = false; public void SetupSecurity(ItemInfo myItem) { + //C2019-036 View Only mode work with Checked Out Procedures + //is in View Only Mode, so do not set up the Security + if (OwnerID == 0) + return; + UserInfo ui = UserInfo.GetByUserID(OwnerInfo.Get(OwnerID).SessionUserID); if (ui == null) @@ -246,7 +256,7 @@ namespace Volian.Controls.Library /// /// Creates and sets-up a StepTabPanel /// - private void SetupStepTabPanel() + private void SetupStepTabPanel(bool viewonlymode = false) { ((System.ComponentModel.ISupportInitialize)(_MyDisplayTabControl.MyBar)).BeginInit(); _MyDisplayTabControl.MyBar.SuspendLayout(); @@ -276,7 +286,7 @@ namespace Volian.Controls.Library _MyDisplayTabControl.MyBar.ResumeLayout(false); DocVersionInfo dvi = _MyItemInfo.MyProcedure.ActiveParent as DocVersionInfo; //MyRTBItem.MyItemInfo.MyProcedure.ActiveParent as DocVersionInfo; if (dvi == null) return; - if (dvi.VersionType > 127) + if (dvi.VersionType > 127 || viewonlymode) MyStepTabPanel.MyStepPanel.VwMode = E_ViewMode.View; // C2021 - 027: Procedure level PC/PC - add _MyIteminfo to argument list if (dvi.MultiUnitCount > 1) diff --git a/PROMS/Volian.Controls.Library/StepPanel.cs b/PROMS/Volian.Controls.Library/StepPanel.cs index 8f509a33..9b47a403 100644 --- a/PROMS/Volian.Controls.Library/StepPanel.cs +++ b/PROMS/Volian.Controls.Library/StepPanel.cs @@ -9,6 +9,7 @@ using System.Drawing; using System.Text.RegularExpressions; using Volian.Base.Library; using JR.Utils.GUI.Forms; +using System.Linq; namespace Volian.Controls.Library { @@ -386,6 +387,26 @@ namespace Volian.Controls.Library // The following line expands the items needed to display SelectedItemInfo ExpandAsNeeded(myItemInfo); } + + //C2019-036 View Only mode work with Checked Out Procedures + public void ResetAll() + { + List itemIDs = Controls.OfType().Where(t => t?.MyItemInfo?.ActiveParent != null && t.MyItemInfo.ActiveParent.GetType() == typeof(ItemInfo)).Select(x => (x.MyItemInfo.ActiveParent as ItemInfo).ItemID).Distinct().ToList(); + + foreach (int itemID in itemIDs) + { + ItemInfo.ResetParts(itemID); + } + + // The following line actually reloads the procedure item + MyProcedureItemInfo = ItemInfo.Get(MyProcedureItemInfo.ItemID, true); + MyProcedureItemInfo.RefreshConfig(); + ContentInfo.Refresh(Content.Get(MyProcedureItemInfo.MyContent.ContentID, true)); + + // The following line expands the items needed to display SelectedItemInfo + ExpandAsNeeded(SelectedItemInfo); + } + /// /// Currently selected StepRTB /// diff --git a/PROMS/Volian.Controls.Library/StepTabRibbon.cs b/PROMS/Volian.Controls.Library/StepTabRibbon.cs index 6e31dae5..87ce1980 100644 --- a/PROMS/Volian.Controls.Library/StepTabRibbon.cs +++ b/PROMS/Volian.Controls.Library/StepTabRibbon.cs @@ -16,6 +16,8 @@ using DevComponents.DotNetBar; using Microsoft.Win32; using System.Diagnostics; using JR.Utils.GUI.Forms; +using System.Collections.Concurrent; +using System.Threading.Tasks; namespace Volian.Controls.Library { @@ -906,6 +908,11 @@ namespace Volian.Controls.Library // //SetButtonAndMenuEnabling(false); //} private Bitmap createTextBitmap(char ch) + { + return createTextBitmap(ch, new Font("FreeMono", 18, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel)); + } + + private Bitmap createTextBitmap(char ch, Font objFont) { string txt = string.Format("{0}", ch); Bitmap objBmpImage = new Bitmap(1, 1); @@ -916,8 +923,6 @@ namespace Volian.Controls.Library // Create the Font object for the image text drawing. // later on, we could add logic to use either FreeMono or Arial Unicode MS based on the format being used // but for now, we are going to use FreeMono to create the symbol list - Font objFont = new Font("FreeMono", 18, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel); - //Font objFont = new Font("Arial Unicode MS", 18, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel); // Create a graphics object to measure the text's width and height. Graphics objGraphics = Graphics.FromImage(objBmpImage); @@ -937,7 +942,6 @@ namespace Volian.Controls.Library objGraphics.SmoothingMode = SmoothingMode.AntiAlias; objGraphics.TextContrast = 0; objGraphics.TextRenderingHint = TextRenderingHint.AntiAlias; - //objGraphics.DrawString(txt, objFont, new SolidBrush(Color.FromArgb(102, 102, 102)), 0, 0); objGraphics.DrawString(txt, objFont, new SolidBrush(Color.Black),0,0); objGraphics.Flush(); return (objBmpImage); @@ -2067,6 +2071,9 @@ namespace Volian.Controls.Library rtabHome.Select(); rtabTableGridTools.Visible = false; SetButtonMenuEnabledDisabledOnStepType(false); + //C2019-036 View Only mode work with Checked Out Procedures + //Is in View Only Mode so show button as selected + btnEditMode.Checked = btnCMEditMode1.Checked = true; this.Refresh(); return; } @@ -3338,10 +3345,43 @@ namespace Volian.Controls.Library public void SetupAdminMode() { } + + //C2019-036 View Only mode work with Checked Out Procedures + public event StepTabRibbonEvent EnableDisableStepProperties; + private void OnEnableDisableStepProperties(StepTabRibbonEventArgs args) + { + if (EnableDisableStepProperties != null) + EnableDisableStepProperties(this, args); + } private void btnToggleEditView_Click(object sender, EventArgs e) { if (MyEditItem == null) return; + + //C2019-036 View Only mode work with Checked Out Procedures + string message = string.Empty; + if (MyEditItem.MyStepPanel.VwMode == E_ViewMode.View && !MySessionInfo.CanCheckOutItem(MyEditItem.MyItemInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message)) + { + //someone else has the procedure checked out so cannot swap out of view only mode + message = message.Replace("\r\nWould You like to open the procedure in View Only Mode?", "\r\n\r\nYou will be unable to turn off View Only Mode for this procedure until it is checked in by the user specified above."); + MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning); + return; + } + else if (MyEditItem.MyStepPanel.VwMode == E_ViewMode.View) + { + //swapping into edit mode, so check out procedure and Setup Security + (this.Parent as StepTabPanel).MyDisplayTabItem.OwnerID = MySessionInfo.CheckOutItem(MyEditItem.MyItemInfo.MyProcedure.ItemID, 0); + (this.Parent as StepTabPanel).MyDisplayTabItem.SetupSecurity(MyItemInfo); + } + else + { + //swapping into View Only mode, so check in procedure + OwnerInfo oi = OwnerInfo.GetByItemID(MyEditItem.MyItemInfo.MyProcedure.ItemID, CheckOutType.Procedure); + MySessionInfo.CheckInItem(oi.OwnerID); + } + MyEditItem.MyStepPanel.VwMode = MyEditItem.MyStepPanel.VwMode == E_ViewMode.Edit ? E_ViewMode.View : E_ViewMode.Edit; + //enable / disable the Step Properties Panel based on the ViewMode + OnEnableDisableStepProperties(new StepTabRibbonEventArgs(MyEditItem.MyItemInfo, 0, MyEditItem.MyStepPanel.VwMode)); MyEditItem.ToggleEditView(MyEditItem.MyStepPanel.VwMode); SetButtonAndMenuEnabling(true); SetStepButtonAndMenuEnabling(true); @@ -3355,7 +3395,62 @@ namespace Volian.Controls.Library // btnEnhancedDocSync.Checked = !btnEnhancedDocSync.Checked; //} + //C2019-036 View Only mode work with Checked Out Procedures + // using a blocking collection to make it thread safe in case someone + // spams hitting the refresh button + private BlockingCollection blockingRefreshProcedure = new BlockingCollection(); + //C2019-036 View Only mode work with Checked Out Procedures + private void btnRefreshProcedure_Click(object sender, EventArgs e) + { + //Consumer + Task.Run(() => + { + //Blocks until a newRefresh Procedure Run is available + while (!blockingRefreshProcedure.IsCompleted) + { + _ = blockingRefreshProcedure.Take(); + RefreshProcedure(); + } + }); + + //Producer + Task.Run(() => { blockingRefreshProcedure.Add(true); }); + } + + public void RefreshProcedure() + { + StepTabPanel stab_Panel = Parent as StepTabPanel; + + if (MyEditItem != null) + { + if (!MyEditItem.MyStepPanel.ContainsFocus) + this.Invoke((Action)(() => { MyEditItem.MyStepPanel.Focus(); })); + + E_ViewMode mode = MyEditItem.MyStepPanel.VwMode; + Application.DoEvents(); + this.Invoke((Action)(() => {MyEditItem.MyStepPanel.ResetAll();})); + Application.DoEvents(); + this.Invoke((Action)(() => {MyEditItem.MyStepPanel.Refresh();})); + Application.DoEvents(); + MyEditItem.MyStepPanel.VwMode = mode; + Application.DoEvents(); + } + else if (stab_Panel != null) + { + if (!stab_Panel.MyStepPanel.ContainsFocus) + this.Invoke((Action)(() => {stab_Panel.MyStepPanel.Focus();})); + + E_ViewMode mode = stab_Panel.MyStepPanel.VwMode; + Application.DoEvents(); + this.Invoke((Action)(() => {stab_Panel.MyStepPanel.ResetAll();})); + Application.DoEvents(); + this.Invoke((Action)(() => {stab_Panel.MyStepPanel.Refresh();})); + Application.DoEvents(); + stab_Panel.MyStepPanel.VwMode = mode; + Application.DoEvents(); + } + } private void btnROEdit_Click(object sender, EventArgs e) { if (VlnSettings.ReleaseMode.Equals("DEMO")) @@ -4865,10 +4960,11 @@ namespace Volian.Controls.Library public class StepTabRibbonEventArgs : EventArgs { public StepTabRibbonEventArgs() { ; } - public StepTabRibbonEventArgs(ItemInfo proc, int oringFlg = 0) + public StepTabRibbonEventArgs(ItemInfo proc, int oringFlg = 0, E_ViewMode viewMode = E_ViewMode.Edit) { _Proc = proc; OringFlg = oringFlg; + ViewMode = viewMode; } private ItemInfo _Proc; @@ -4884,6 +4980,9 @@ namespace Volian.Controls.Library get { return _OringFlg; } set { _OringFlg = value; } } + + //C2019-036 View Only mode work with Checked Out Procedures + public E_ViewMode ViewMode { get; set; } } public delegate void StepTabRibbonEvent(object sender, StepTabRibbonEventArgs args); diff --git a/PROMS/Volian.Controls.Library/StepTabRibbon.designer.cs b/PROMS/Volian.Controls.Library/StepTabRibbon.designer.cs index f374745296d67545dc0e0e3210589c9c65294b12..a7dc72adfbba1bbe8e7d7e701a8cb3030c1cf760 100644 GIT binary patch delta 1054 zcmZuwT}YE*6h3F)&pyMfY}wz)Z$A!OVmiSjqD%w-s9abgRyyZwvT4iTG9f|8i-^?O z&P5Sg;)OTbjcd8^#=9geZ-OAaiMr_`i1Mx9UszVxEQ`;5 zG;$T?;NrgOU|^Rc^a^Et4|t##ymWR*+8eyz=pUW-jZOQIMaLq9r+wn^7S+3@d@8z* zVnzpOC&EA6lFv@-O{mbo0v3jvQQ3}?vluIBvkJ3Pj?tcGyh}?99QbIFzQv=OX_e+Q zGs@A>vaTcbtV`70iu?3h8#G~)>XJO+?=~qH6Ze$9DMnEzfl6 zMpG-AGO&*9E0Qh41Al8e?NSq|B+0b6A{9_(1dq_j5Q=mvg0|S5l=GSk&$WrCNqL|V zm+*z!aD1Djp!4@ZdN&{#6YUm6(MXP2UXq!niBG!V|F{g#Jd`$M8uxR_z6C5z8z@cL z#i!|B^E_skxZ{I#K_5SW2A12bRX``NUEqQMSMh+KOuI2}n}+z?BkKlE zrnhQ6!*rBKurPUgt6t$*dUB{nY^Abg%rYe!F>4K(;S!hq_i|b9B~y{^Fs*+@LyHQR z`45Q2`?*^c1{t)6!Kq9{%+tpZ1H60K(;v_5;Zo`711^erykWJ++vP>7EJiOWnT9W||e32W{0nS#UgIeF9JT^QfvB=@!Dg9cM vHf_oQ`ruFuv{j{ess53q&^d$Bu`>yGf@j+`rFL?E4vpt2JHnrx%G$j@Ri7lI delta 103 zcmX?dMtRj@XaNZ^&T;VkRJF-o7D+rRvA_u2fbBt?3sYF|tiRF`HFj`iy2) zmB|g;ryTS_gGkc~xIC7{=Z%E|`nj|i^Jui*p GT0H Date: Wed, 19 Nov 2025 06:34:52 -0500 Subject: [PATCH 07/18] C2019-036 View Only Mode --- shouldn't prompt for View Only Mode if already open in another tab in View Only Mode --- PROMS/Volian.Controls.Library/DisplayTabControl.cs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index f58db41c..4f43164c 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -622,8 +622,15 @@ namespace Volian.Controls.Library { if (!MySessionInfo.CanCheckOutItem(myItemInfo.MyProcedure.ItemID, CheckOutType.Procedure, ref message)) { + DisplayTabItem dti = MyBar?.Items?.OfType().FirstOrDefault(x => x.MyItemInfo?.ItemID == myItemInfo.MyProcedure.ItemID); + //C2019-036 View Only mode work with Checked Out Procedures - if (MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) + //shouldn't prompt - should just auto put in view only if already in open tab + //in view only + if ( + (dti != null && dti.MyStepTabPanel.MyStepPanel.VwMode == E_ViewMode.View) + || + MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) viewonlymode = true; else return null; -- 2.49.1 From 261f5a526cfa0aa3e2ec376579b1c1ad2c6f36fc Mon Sep 17 00:00:00 2001 From: mschill Date: Wed, 19 Nov 2025 08:42:09 -0500 Subject: [PATCH 08/18] C2019-036 View Only Mode - Handle special case where item is opened in a separate window and tabs are remembered --- PROMS/Volian.Controls.Library/DisplayTabControl.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index 4f43164c..d919f1be 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -630,6 +630,8 @@ namespace Volian.Controls.Library if ( (dti != null && dti.MyStepTabPanel.MyStepPanel.VwMode == E_ViewMode.View) || + (SeparateWindows && (VersionID == 0 || VersionID != myItemInfo.MyDocVersion.VersionID)) + || //to handle special case where item will be opened in a separate window MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) viewonlymode = true; else -- 2.49.1 From 9002fb3828af33b56c69727f6b41e07e8f196fce Mon Sep 17 00:00:00 2001 From: mschill Date: Wed, 19 Nov 2025 08:54:00 -0500 Subject: [PATCH 09/18] C2019-036 View Mode - Avoid double prompt when Remembering Tabs & Open in Separate Window --- PROMS/Volian.Controls.Library/DisplayTabControl.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index d919f1be..720fa1a8 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -630,7 +630,7 @@ namespace Volian.Controls.Library if ( (dti != null && dti.MyStepTabPanel.MyStepPanel.VwMode == E_ViewMode.View) || - (SeparateWindows && (VersionID == 0 || VersionID != myItemInfo.MyDocVersion.VersionID)) + (SeparateWindows && (VersionID == 0 || VersionID == myItemInfo.MyDocVersion.VersionID)) || //to handle special case where item will be opened in a separate window MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) viewonlymode = true; -- 2.49.1 From 7d87477d6839dd9695c94c9f5acdf9ab8837d4bd Mon Sep 17 00:00:00 2001 From: mschill Date: Wed, 19 Nov 2025 09:01:16 -0500 Subject: [PATCH 10/18] C2019-036 View Only - handle case when Separate Windows and Remember Tabs --- PROMS/Volian.Controls.Library/DisplayTabControl.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/Volian.Controls.Library/DisplayTabControl.cs b/PROMS/Volian.Controls.Library/DisplayTabControl.cs index 720fa1a8..f54f0ea4 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabControl.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabControl.cs @@ -630,7 +630,7 @@ namespace Volian.Controls.Library if ( (dti != null && dti.MyStepTabPanel.MyStepPanel.VwMode == E_ViewMode.View) || - (SeparateWindows && (VersionID == 0 || VersionID == myItemInfo.MyDocVersion.VersionID)) + (SeparateWindows && VersionID == myItemInfo.MyDocVersion.VersionID) || //to handle special case where item will be opened in a separate window MessageBox.Show(this, message, "Procedure Already Checked Out", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.Yes) viewonlymode = true; -- 2.49.1 From fa8b0bd6a174bd20d90f6dca34611ffe0e1e0be1 Mon Sep 17 00:00:00 2001 From: mschill Date: Thu, 20 Nov 2025 07:06:43 -0500 Subject: [PATCH 11/18] B2025-063 Show User in View Mode --- .../Volian.Controls.Library/DisplayTabItem.cs | 29 +++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/PROMS/Volian.Controls.Library/DisplayTabItem.cs b/PROMS/Volian.Controls.Library/DisplayTabItem.cs index dbddc13d..8206bf3c 100644 --- a/PROMS/Volian.Controls.Library/DisplayTabItem.cs +++ b/PROMS/Volian.Controls.Library/DisplayTabItem.cs @@ -136,9 +136,34 @@ namespace Volian.Controls.Library //C2019-036 View Only mode work with Checked Out Procedures //is in View Only Mode, so do not set up the Security if (OwnerID == 0) - return; + { - UserInfo ui = UserInfo.GetByUserID(OwnerInfo.Get(OwnerID).SessionUserID); + UserInfo uiViewOnly = UserInfo.GetByUserID(Base.Library.VlnSettings.UserID); + if (uiViewOnly.IsAdministrator()) + { + MyUserRole = $"{Base.Library.VlnSettings.UserID} - Administrator"; + } + else if (uiViewOnly.IsSetAdministrator(myItem.MyDocVersion)) + { + MyUserRole = $"{Base.Library.VlnSettings.UserID} - Set Administrator"; + } + else if (uiViewOnly.IsWriter(myItem.MyDocVersion)) + { + MyUserRole = $"{Base.Library.VlnSettings.UserID} - Writer"; + } + else if (uiViewOnly.IsROEditor(myItem.MyDocVersion)) + { + MyUserRole = $"{Base.Library.VlnSettings.UserID} - RO Editor"; + } + else + { + MyUserRole = $"{Base.Library.VlnSettings.UserID} - Reviewer"; + } + + return; + } + + UserInfo ui = UserInfo.GetByUserID(OwnerInfo.Get(OwnerID).SessionUserID); if (ui == null) { -- 2.49.1 From 7eb94d75750f0c11db4189a8a67c7cea8c63d0bc Mon Sep 17 00:00:00 2001 From: mschill Date: Thu, 20 Nov 2025 07:23:23 -0500 Subject: [PATCH 12/18] C2025-063 If Separate Windows is set, should not open Remember Tabs. --- PROMS/VEPROMS User Interface/frmVEPROMS.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/VEPROMS User Interface/frmVEPROMS.cs b/PROMS/VEPROMS User Interface/frmVEPROMS.cs index 1fded9ad..288f5d18 100644 --- a/PROMS/VEPROMS User Interface/frmVEPROMS.cs +++ b/PROMS/VEPROMS User Interface/frmVEPROMS.cs @@ -2497,7 +2497,7 @@ namespace VEPROMS //and set checkboxes based on what they are set to UserSettings usersettings = new UserSettings(VlnSettings.UserID); - if (DisPlayTabState.Rows.Count > 0 && (usersettings.UserSetting_OpenTabs_AutoOpen || !usersettings.UserSetting_OpenTabs_Remember)) + if (!Settings.Default.SeparateWindows && DisPlayTabState.Rows.Count > 0 && (usersettings.UserSetting_OpenTabs_AutoOpen || !usersettings.UserSetting_OpenTabs_Remember)) { //will open tabs by default / ask by default DialogResult result = DialogResult.Yes; -- 2.49.1 From 23f4b672b29b2b5bef38f36396c66221438871f6 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Fri, 21 Nov 2025 09:46:09 -0500 Subject: [PATCH 13/18] =?UTF-8?q?F2025-037=20Added=20=E2=80=9C/open?= =?UTF-8?q?=E2=80=9D=20and=20=E2=80=9C/reset=E2=80=9D=20to=20the=20replace?= =?UTF-8?q?words=20list=20and=20replace=20them=20as=20is=20so=20that=20the?= =?UTF-8?q?=20=E2=80=9Copen=E2=80=9D=20and=20=E2=80=9Creset=E2=80=9D=20are?= =?UTF-8?q?=20not=20bolded=20when=20preceded=20by=20a=20forward=20slash.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Formats/fmtall/VEGP1all.xml | Bin 184072 -> 185040 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 233142 -> 234110 bytes PROMS/Formats/fmtall/VEGPAlrall.xml | Bin 210864 -> 211832 bytes 3 files changed, 0 insertions(+), 0 deletions(-) diff --git a/PROMS/Formats/fmtall/VEGP1all.xml b/PROMS/Formats/fmtall/VEGP1all.xml index 11cbc389376d5b67f36a913c1e98b8e18f3f3f79..0c7bf1cdfd44093489b02c6e86b471676768c563 100644 GIT binary patch delta 120 zcmeB}$9-Wbcf%IOb*hZ|)7Ppps&ncy_%jqRq%!19Zj9Q`tj~}?eZ4B9Do{8dA-o-^ yya=R2-kVXATc05asJ?e3KY&q2yX`} wFH!~S_;1aq$*s>21XN!P#3fKYMbjB=7}bFiMKFnWM{7nPX4>v(&0HD`053fu8UO$Q delta 36 rcmeyjgm2qizJ@J~ePY}5Bp8cSr(dvSWNANR&j`d!+t1iDZwdkc6nqX< diff --git a/PROMS/Formats/fmtall/VEGPAlrall.xml b/PROMS/Formats/fmtall/VEGPAlrall.xml index f2fc06cc56736b974f36b2a094138da7d76bc9ba..12c460fbb4a3d201b4e4165e1581bbbbbd3b594a 100644 GIT binary patch delta 140 zcmdn+p6ACmo`x-q*Z7(B8T_YT6kt^41Tq*37*ZMXCNo;^XVjm5UVu>@D435BoPLgv zkz@Nke#R`2>L8%nVusYog4-0i;XH;CkZz!C5sEC72a#>}Fl7W{rtKc4%o$7oDaj@? delta 36 rcmezIjc3Dqo`x-q*Z8NO<74F5zE6-bOSN6Vk`aiRwhLG?XD|T(8(Iuv -- 2.49.1 From 37e727202cc50c4946f909b49932e6a7c5adc6b1 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Mon, 1 Dec 2025 14:24:31 -0500 Subject: [PATCH 14/18] =?UTF-8?q?F2025-039=20Added=20=E2=80=9CDeselect?= =?UTF-8?q?=E2=80=9D,=20=E2=80=9Cdeselect=E2=80=9D,=20=E2=80=9CRefill?= =?UTF-8?q?=E2=80=9D,=20=E2=80=9Crefill=E2=80=9D=20to=20the=20replace=20wo?= =?UTF-8?q?rds=20list=20to=20the=20Vogtle=20Units=203&4=20formats?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Formats/fmtall/VEGP1all.xml | Bin 185040 -> 186088 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 234110 -> 235158 bytes PROMS/Formats/fmtall/VEGPAlrall.xml | Bin 211832 -> 212880 bytes 3 files changed, 0 insertions(+), 0 deletions(-) diff --git a/PROMS/Formats/fmtall/VEGP1all.xml b/PROMS/Formats/fmtall/VEGP1all.xml index 0c7bf1cdfd44093489b02c6e86b471676768c563..09565922260b6aadb7c8ff92536d65e897168d71 100644 GIT binary patch delta 120 zcmcbxl>5b6?hSSGSc@4_8FD5!Hfm4aFpmYwySVu5WQW->-onMY?5PY8br%<(-&`}V zWX0qM=X9nkcrvoErZHp!^(%ItWG-SzoqYeCE+>#?fQwH5;K9h!{=toL`v*6s2i*WS Cb1yak delta 24 gcmaE{mixj|?hSSGHcwhmw4$BEn{hjbH`9Y|0GhoEJ^%m! diff --git a/PROMS/Formats/fmtall/VEGP2all.xml b/PROMS/Formats/fmtall/VEGP2all.xml index 37dcb82cb062f9577c6584e8812b8fec8882ba14..1a9b1c3fecc3d589ac63bbcc93648d39e8ef3836 100644 GIT binary patch delta 123 zcmeyjgm2nfz728xti=qe3^|h%i?kFFQz7+F9<3i^yJ%xMe|K>wRuBV&5CvdQ$`?W+HPRVoWKPDCVLL7 -- 2.49.1 From 62a296f9093456267eda601d9538fbaaaa93fff5 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Tue, 2 Dec 2025 10:53:26 -0500 Subject: [PATCH 15/18] =?UTF-8?q?F2025-038=20Added=20a=20format=20flag=20t?= =?UTF-8?q?o=20not=20include=20the=20word=20=E2=80=9CSECTION=E2=80=9D=20in?= =?UTF-8?q?=20front=20the=20section=20number=20and=20title=20on=20the=20Co?= =?UTF-8?q?ntinuous=20Action=20Summary=20that=20is=20generated=20by=20PROM?= =?UTF-8?q?S.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- PROMS/Formats/fmtall/BASEall.xml | Bin 91078 -> 91132 bytes PROMS/Formats/fmtall/VEGP2all.xml | Bin 235158 -> 235556 bytes .../Format/PlantFormat.cs | 10 ++++++++++ PROMS/Volian.Print.Library/ContActionSum.cs | 9 ++++++--- 4 files changed, 16 insertions(+), 3 deletions(-) diff --git a/PROMS/Formats/fmtall/BASEall.xml b/PROMS/Formats/fmtall/BASEall.xml index bfdff426c9a08e9a9ebddb19dab2154aaa7b6dc2..56657cc2a26697f470b093e7a194ae888682551d 100644 GIT binary patch delta 32 ocmX?hob}If)(uuMlYd0Zar!VMG9)piGUPOC$86V*VVunl0NalXc>n+a delta 18 Zcmex!ob}jo)(uuM%>^;r3t||1*a27%2nPTF diff --git a/PROMS/Formats/fmtall/VEGP2all.xml b/PROMS/Formats/fmtall/VEGP2all.xml index 1a9b1c3fecc3d589ac63bbcc93648d39e8ef3836..86043269b01fb8926ac35ca7a14d584254c39498 100644 GIT binary patch delta 300 zcmbQXmT$=hz71t&^_&b4Xv5&lkk63EkjYR2BujzpQifs%M}}k|KNBny3>3))!bFB5 zhDrt(AYB5)3Jjh=^~nr5K-mv06CNMQ&8o1Fucw`EWQ@``|RsUbin zej|K3p{td2~tg)bxp$80DMW S%-Y+`7=f5+dz%@vKmq`{OgxYP delta 31 lcmZ3ofp6Mcz71t&(;rM>6lfN)Xcw_y1Y)M`A{NX72>`*S3K{?a diff --git a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs index 4f02807b..87719a04 100644 --- a/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs +++ b/PROMS/VEPROMS.CSLA.Library/Format/PlantFormat.cs @@ -4341,6 +4341,16 @@ public LeftJustifyList(XmlNodeList xmlNodeList) : base(xmlNodeList) { } return LazyLoad(ref _IncludeSectionNumAndTitle, "@IncludeSectionNumAndTitle"); } } + + //F2025-038 default (in base format) is True. The lable "SECTION" will precede the section number an title + private LazyLoad _IncludeSectionLabel; + public bool IncludeSectionLabel + { + get + { + return LazyLoad(ref _IncludeSectionLabel, "@IncludeSectionLabel"); + } + } // the font and font styles to use for the continuous action summary private VE_Font _Font; public VE_Font Font diff --git a/PROMS/Volian.Print.Library/ContActionSum.cs b/PROMS/Volian.Print.Library/ContActionSum.cs index ec199b56..d7853e03 100644 --- a/PROMS/Volian.Print.Library/ContActionSum.cs +++ b/PROMS/Volian.Print.Library/ContActionSum.cs @@ -49,7 +49,7 @@ namespace Volian.Print.Library { if (myContAct.MyChildren.Count > 0) if (myContAct.MyParagraph.MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.AccSectionData.ContinuousActionSummaryData.IncludeSectionNumAndTitle) // only print the section title if it has Continuous Action Steps - AddSectionHeader(myContAct.MyParagraph.MyItemInfo.DisplayNumber, myContAct.MyParagraph.MyItemInfo.FormattedDisplayText); + AddSectionHeader(myContAct.MyParagraph.MyItemInfo.DisplayNumber, myContAct.MyParagraph.MyItemInfo.FormattedDisplayText, myContAct.MyParagraph.MyItemInfo.ActiveFormat.PlantFormat.FormatData.SectData.AccSectionData.ContinuousActionSummaryData.IncludeSectionLabel); foreach (pkParagraph pgh in myContAct.MyChildren) // within each section... { ItemInfo hlsii = GetHLSii(pgh.MyParagraph.MyItemInfo); @@ -175,7 +175,7 @@ namespace Volian.Print.Library WriteCell("DONE", true, true); WriteCell("PAGE", true, false); } - private void AddSectionHeader(string number, string title) + private void AddSectionHeader(string number, string title, bool IncludeSectionLabel) { if (!_FirstSection) { @@ -187,7 +187,10 @@ namespace Volian.Print.Library _FirstSection = false; Advance(2); SetIndent(0, 0); - WriteCell("SECTION " + number, true, false); + if (IncludeSectionLabel) + WriteCell("SECTION " + number, true, false); + else + WriteCell(number, true, false); // F2025-038 don't include the word SECTION before number and title WriteCell(" " + title, false, true); Advance(); } -- 2.49.1 From 2783d2cc77e5765d3210d6531e74d0d8926b76ac Mon Sep 17 00:00:00 2001 From: mschill Date: Wed, 3 Dec 2025 15:53:29 -0500 Subject: [PATCH 16/18] B2019-140/B2022-099 After doing an Approval (final stage) of a procedure, the change bars do not reset on the screen. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Also, when change the “Showing Change bars” option, the screen does not refresh. --- .../dlgApproveProcedure.cs | 22 +++++++++ PROMS/VEPROMS User Interface/frmVEPROMS.cs | 36 +++++++++++++++ .../VEPROMS.CSLA.Library/Extension/ItemExt.cs | 45 +++++++++++++++++++ 3 files changed, 103 insertions(+) diff --git a/PROMS/VEPROMS User Interface/dlgApproveProcedure.cs b/PROMS/VEPROMS User Interface/dlgApproveProcedure.cs index b914dad9..0dd507e5 100644 --- a/PROMS/VEPROMS User Interface/dlgApproveProcedure.cs +++ b/PROMS/VEPROMS User Interface/dlgApproveProcedure.cs @@ -13,6 +13,8 @@ using System.Text.RegularExpressions; using System.Globalization; using DevComponents.DotNetBar; using JR.Utils.GUI.Forms; +using Volian.Controls.Library; +using System.Linq; namespace VEPROMS { @@ -1321,6 +1323,26 @@ namespace VEPROMS // Clear the change bar override for this procedure: pi.ClearChangeBarOverrides(); + + //B2019-140 Change bars do not get refreshed when approval is run. + ProcedureInfo newproc = ItemInfo.ResetProcedure(pi.ItemID); + + //// Refresh the StepPanel for the current Procedure + //// so change bars update + //// on any open StepPanel + DisplayTabItem dti = MyFrmVEPROMS.GetTabContainingProcedure(pi.ItemID); + if (dti != null) + { + if (!dti.MyStepTabPanel.MyStepPanel.ContainsFocus) + dti.MyStepTabPanel.MyStepPanel.Focus(); + + foreach (EditItem eitm in dti.MyStepTabPanel.MyStepPanel.Controls.OfType()) + eitm.ChangeBar = eitm.MyItemInfo.HasChangeBar; + } + + //since in a separate form, need to update the tree view + //so "Showing Change Bars" Content Menu Item is correct + MyFrmVEPROMS.RefreshProcedureNode(newproc); } else UpdateProcedureConfig(pi, ap.RevNumber, ap.RevDate, myDTS, selectedSlave); diff --git a/PROMS/VEPROMS User Interface/frmVEPROMS.cs b/PROMS/VEPROMS User Interface/frmVEPROMS.cs index 288f5d18..b4308c66 100644 --- a/PROMS/VEPROMS User Interface/frmVEPROMS.cs +++ b/PROMS/VEPROMS User Interface/frmVEPROMS.cs @@ -589,6 +589,25 @@ namespace VEPROMS } } + //B2019-140 Change bars do not get refreshed when approval is run. + // Get the displaytab containing the procedure + // if none exists, return null + public DisplayTabItem GetTabContainingProcedure(int procid) => tc?.MyBar?.Items?.OfType().FirstOrDefault(x => x.MyItemInfo?.ItemID == procid); + // Refresh Node in Tree + // Used for when Change Bar Updates as part of approval. + public void RefreshProcedureNode(ProcedureInfo itm) + { + VETreeNode tn = tv.FindNode(itm, tv.Nodes); + var tmp = (ProcedureInfo)tn?.VEObject; + if (tmp != null) + { + tmp.ChangeBarDate = itm.ChangeBarDate; + tmp.MyConfig = itm.MyConfig; + } + + tn?.RefreshNode(); + } + void tv_SelectDateToStartChangeBars(object sender, vlnTreeEventArgs args) { ProcedureInfo pi = (args.Node as VETreeNode).VEObject as ProcedureInfo; @@ -606,6 +625,23 @@ namespace VEPROMS itm.MyContent.Config = pc.ToString(); itm.UserID = Volian.Base.Library.VlnSettings.UserID; itm.Save(); + + //B2019-140 Change bars do not get refreshed when approval is run. + // Reset a Procedure and sub items in the cache + ProcedureInfo newproc = ItemInfo.ResetProcedure(pi.ItemID); + + //// Refresh the StepPanel for the current Procedure + //// so change bars update + //// on any open StepPanel + DisplayTabItem dti = GetTabContainingProcedure(pi.ItemID); + if (dti != null) + { + if (!dti.MyStepTabPanel.MyStepPanel.ContainsFocus) + dti.MyStepTabPanel.MyStepPanel.Focus(); + + foreach (EditItem eitm in dti.MyStepTabPanel.MyStepPanel.Controls.OfType()) + eitm.ChangeBar = eitm.MyItemInfo.HasChangeBar; + } } } } diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs index 532d3585..8cd4a26b 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs @@ -3819,6 +3819,51 @@ namespace VEPROMS.CSLA.Library _Tables = null; _SupInfos = null; } + + //B2019-140 Change bars do not get refreshed when approval is run. + // Reset a Procedure and sub items in the cache + public static ProcedureInfo ResetProcedure(int procID) + { + // The following lines reload the procedure info cache + ProcedureInfo newproc = ProcedureInfo.Get(procID, true); + newproc.RefreshConfig(); + + //the following is needed to force the ProcedureConfig to reload + #pragma warning disable S1656 // Variables should not be self-assigned + newproc.MyConfig = newproc.MyConfig; + #pragma warning restore S1656 // Variables should not be self-assigned + + //reload the Content Cache for the procedure + ContentInfo.Refresh(Content.Get(newproc.MyContent.ContentID, true)); + + // The following line actually reloads the item info cache + ItemInfo newprocitem = Get(procID, true); + newprocitem.RefreshConfig(); + + //Reload all the child/sub items +#pragma warning disable S2971 // LINQ expressions should be simplified - need initial ToList to force enumeration + //otherwise will get a "Collection was modified; enumeration operation may not execute" error + List itemIDs = _CacheByPrimaryKey.Values.ToList().SelectMany(y => y).Where(t => t?.ActiveParent != null && (t.ActiveParent is ItemInfo) && t.MyProcedure.ItemID == procID).Select(x => (x.ActiveParent as ItemInfo).ItemID).Distinct().ToList(); +#pragma warning restore S2971 // LINQ expressions should be simplified + for (int index = 0; index < itemIDs.Count; index++) + { + ResetParts(itemIDs[index]); + } + + //reset the procedure config for all items attached to current procedure +#pragma warning disable S2971 // LINQ expressions should be simplified - need initial ToList to force enumeration + //otherwise will get a "Collection was modified; enumeration operation may not execute" error + List pconfigrefresh_items = _CacheByPrimaryKey.Values.ToList().SelectMany(y => y).Where(t => t?.MyProcedure?.ItemID == procID).Distinct().ToList(); +#pragma warning restore S2971 // LINQ expressions should be simplified + for (int index = 0; index < pconfigrefresh_items.Count; index++) + { + pconfigrefresh_items[index].MyProcedure = newproc; + } + + //return the changed procedure info + return newproc; + } + private ItemInfoList _Procedures; public ItemInfoList Procedures { get { return Lookup(E_FromType.Procedure, ref _Procedures); } } -- 2.49.1 From 47cdedefd45bec2b99a684f8c7f71692c2c86c52 Mon Sep 17 00:00:00 2001 From: mschill Date: Thu, 4 Dec 2025 10:41:37 -0500 Subject: [PATCH 17/18] B2025-064 PROMS clears the windows clipboard when closing PROMS with tabs open. --- PROMS/Volian.Controls.Library/StepTabRibbon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PROMS/Volian.Controls.Library/StepTabRibbon.cs b/PROMS/Volian.Controls.Library/StepTabRibbon.cs index 87ce1980..08618d12 100644 --- a/PROMS/Volian.Controls.Library/StepTabRibbon.cs +++ b/PROMS/Volian.Controls.Library/StepTabRibbon.cs @@ -1667,7 +1667,7 @@ namespace Volian.Controls.Library } } Clipboard.Clear(); - Clipboard.SetDataObject(myDO); // this saves the cleaned up information to the Windows clipboard + Clipboard.SetDataObject(myDO, true); // this saves the cleaned up information to the Windows clipboard } iData = Clipboard.GetDataObject(); bool noEquationData = true; -- 2.49.1 From b4f2b891393f1ac92f1a955c79b29a52f0193d27 Mon Sep 17 00:00:00 2001 From: John Jenko Date: Thu, 4 Dec 2025 16:42:40 -0500 Subject: [PATCH 18/18] F2025-040 Added code to adjust the position of the CAS box around the high level step number in single column attachment sections --- PROMS/Volian.Print.Library/vlnParagraph.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/PROMS/Volian.Print.Library/vlnParagraph.cs b/PROMS/Volian.Print.Library/vlnParagraph.cs index 591ed771..4a52b20f 100644 --- a/PROMS/Volian.Print.Library/vlnParagraph.cs +++ b/PROMS/Volian.Print.Library/vlnParagraph.cs @@ -6456,8 +6456,11 @@ namespace Volian.Print.Library { if (itemInfo.MyDocStyle.AlignHLSTabWithSect || itemInfo.FormatStepData.AlignHLSTabWithSectOvride) { + float orgXOffset = MyTab.XOffset; myTab.XOffset = (float)itemInfo.MyDocStyle.Layout.LeftMargin + (float)formatInfo.PlantFormat.FormatData.SectData.SectionHeader.Pos; XOffset = myTab.XOffset + myTab.Width; + // F2025-040 Adjust the Cont Act box position around HLS number + if (myTab.MyMacro != null) myTab.MyMacro.XOffset += (MyTab.XOffset - orgXOffset); } else { -- 2.49.1