diff --git a/PROMS/Formats/fmtall/VEGPBckStpsall.xml b/PROMS/Formats/fmtall/VEGPBckStpsall.xml
index 6e965f6b..dd902de8 100644
Binary files a/PROMS/Formats/fmtall/VEGPBckStpsall.xml and b/PROMS/Formats/fmtall/VEGPBckStpsall.xml differ
diff --git a/PROMS/Formats/fmtall/VEGPBckall.xml b/PROMS/Formats/fmtall/VEGPBckall.xml
index 40d5726d..366e73df 100644
Binary files a/PROMS/Formats/fmtall/VEGPBckall.xml and b/PROMS/Formats/fmtall/VEGPBckall.xml differ
diff --git a/PROMS/Formats/genmacall/VEGPBck.svg b/PROMS/Formats/genmacall/VEGPBck.svg
index 5c1a41f7..e7cff7b4 100644
Binary files a/PROMS/Formats/genmacall/VEGPBck.svg and b/PROMS/Formats/genmacall/VEGPBck.svg differ
diff --git a/PROMS/Formats/genmacall/VEGPBckStps.svg b/PROMS/Formats/genmacall/VEGPBckStps.svg
index b5638d3b..e36a95fb 100644
Binary files a/PROMS/Formats/genmacall/VEGPBckStps.svg and b/PROMS/Formats/genmacall/VEGPBckStps.svg differ
diff --git a/PROMS/VEPROMS User Interface/PROMSFixes.Sql b/PROMS/VEPROMS User Interface/PROMSFixes.Sql
index 799f6769..93ef133c 100644
--- a/PROMS/VEPROMS User Interface/PROMSFixes.Sql
+++ b/PROMS/VEPROMS User Interface/PROMSFixes.Sql
@@ -1643,7 +1643,11 @@ Begin
Select Cast(i.LastChanged as varbinary(8)) as 'ILastChanged',
i.ItemID as 'ItemID',
zi.VersionID as 'VersionID',
- zi.PPath +
+ CASE WHEN c.[Type] % 20000 = 6 THEN REPLACE(zi.PPath,'Note','Caution')
+ WHEN c.[Type] % 20000 = 7 THEN REPLACE(zi.PPath,'Caution','Note')
+ ELSE zi.PPath
+ END
+ +
Case (c.[Type]/10000)
When 0 Then @Delim + @UnitPrefix + IsNull(c.Number,'') + @DelimNumber + IsNull(c.Text,'') -- Procedure
When 1 Then @Delim + IsNull(c.Number,'') + @DelimNumber + IsNull(c.Text,'') -- Section
@@ -24529,6 +24533,51 @@ GO
PRINT 'Added IX_tblROUsagesRODbIDDeleteStatusROID Index. Speeds up RO queries'
GO
+
+IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[GetCurrentApprovedRevisions]') AND OBJECTPROPERTY(id,N'IsProcedure') = 1)
+ DROP PROCEDURE [GetCurrentApprovedRevisions];
+
+GO
+
+/****** Object: StoredProcedure [dbo].[GetCurrentApprovedRevisions] Script Date: 02/05/2026 7:54:42 AM ******/
+
+-- =============================================
+-- Author: Matthew Schill
+-- Create date: 02/05/2026
+-- Description: Gets all current approved revisions
+-- =============================================
+CREATE PROCEDURE [dbo].[GetCurrentApprovedRevisions]
+(
+ @ItemID AS bigint
+)
+AS
+BEGIN
+
+ select max(rr.revisionid) revisionid, UnitId, UnitVal.name UnitName, max(rr.DTS) DTS
+ from items ii
+ inner join revisions rr on ii.itemid = rr.itemid
+ inner join versions vv on rr.revisionid = vv.revisionid
+ inner join stages ss on vv.stageid = ss.stageid
+ outer apply
+ (Select UnitId = r1.value('@Index','int') FROM rr.config.nodes('Config/Applicability') t1(r1)) App
+ left outer join
+ (select r1.value('@index','int') indx
+ ,r1.value('@Name','varchar') name
+ from (select *,cast(config as xml) xconfig from DocVersions
+ where ItemID in(select itemID from vefn_AllSiblingItems(@ItemID))) SDV
+ cross apply
+ xconfig.nodes('Config/Slaves/Slave') t1(r1)) UnitVal ON UnitVal.indx = UnitId
+ where ss.isapproved = 1
+ and ii.itemid = @ItemID
+ group by UnitId, UnitVal.name
+
+ RETURN
+END
+
+IF (@@Error = 0) PRINT 'Procedure Creation: [GetCurrentApprovedRevisions] Succeeded'
+ELSE PRINT 'Procedure Creation: [GetCurrentApprovedRevisions] Error on Creation'
+GO
+
/*
---------------------------------------------------------------------------
| ADD New Code Before this Block |
@@ -24562,8 +24611,8 @@ BEGIN TRY -- Try Block
DECLARE @RevDate varchar(255)
DECLARE @RevDescription varchar(255)
- set @RevDate = '01/19/2026 5:00 PM'
- set @RevDescription = 'Sync tree list Sort order between in RO Editor and PROMS'
+ set @RevDate = '02/09/2026 7:00 AM'
+ set @RevDescription = 'Added procedure for getting current revisions'
Select cast(@RevDate as datetime) RevDate, @RevDescription RevDescription
PRINT 'SQL Code Revision ' + @RevDate + ' - ' + @RevDescription
diff --git a/PROMS/VEPROMS User Interface/dlgManageSecurity.cs b/PROMS/VEPROMS User Interface/dlgManageSecurity.cs
index f3ab5011..83b0a1db 100644
--- a/PROMS/VEPROMS User Interface/dlgManageSecurity.cs
+++ b/PROMS/VEPROMS User Interface/dlgManageSecurity.cs
@@ -216,7 +216,7 @@ namespace VEPROMS
MembershipInfo mi = (MembershipInfo)lstMembers.SelectedItem;
string selectedUserID = mi.MyUserUserID;
string msg = "Are you sure you want to remove this Group Member?";
- if (MessageBox.Show(this, msg, "Confirm Group Member Removal", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question) == DialogResult.Yes)
+ if (MessageBox.Show(this, msg, "Confirm Group Member Removal", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
if (mi.MyGroup.GroupName == "Administrators" && mi.MyGroup.GroupMemberships.Count(mm => mm.EndDate == null || mm.EndDate == string.Empty) == 1)
{
@@ -255,7 +255,7 @@ namespace VEPROMS
MessageBox.Show("There are still users who are members of this group. You need to delete all members in order to delete this group.", "Group Has Members", MessageBoxButtons.OK, MessageBoxIcon.Warning);
return;
}
- if (MessageBox.Show("Are you sure you want to delete this group?", "Confirm Deleting Group", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question) == DialogResult.Yes)
+ if (MessageBox.Show("Are you sure you want to delete this group?", "Confirm Deleting Group", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
Group.Delete(gi.GID);
LoadRefreshGroupUsers();
@@ -397,7 +397,7 @@ namespace VEPROMS
}
int nummemberships = ui.UserMemberships.Count(mi => mi.EndDate == null || mi.EndDate == string.Empty);
string mem_text = nummemberships > 0 ? "\r\nNote that this will remove all memberships that this user has." : "";
- if (MessageBox.Show($"Are you sure you want to delete this user?{mem_text}", "Confirm Deleting User", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question) == DialogResult.Yes)
+ if (MessageBox.Show($"Are you sure you want to delete this user?{mem_text}", "Confirm Deleting User", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
foreach (MembershipInfo minfo in ui.UserMemberships.Where(mi => mi.EndDate == null || mi.EndDate == string.Empty))
{
@@ -477,7 +477,7 @@ namespace VEPROMS
{
MembershipInfo mi = (MembershipInfo)lstGroups.SelectedItem;
string msg = "Are you sure you want to remove this Group Member?";
- if (MessageBox.Show(this, msg, "Confirm Group Member Removal", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question) == DialogResult.Yes)
+ if (MessageBox.Show(this, msg, "Confirm Group Member Removal", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
{
if (mi.MyGroup.GroupName == "Administrators" && mi.MyGroup.GroupMemberships.Count(mm => mm.EndDate == null || mm.EndDate == string.Empty) == 1)
{
diff --git a/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.Designer.cs b/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.Designer.cs
index 9f87e261..a6ff65b0 100644
--- a/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.Designer.cs
+++ b/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.Designer.cs
@@ -28,142 +28,158 @@
///
private void InitializeComponent()
{
- this.btnOK = new DevComponents.DotNetBar.ButtonX();
- this.btnCancel = new DevComponents.DotNetBar.ButtonX();
- this.label1 = new System.Windows.Forms.Label();
- this.superTooltip1 = new DevComponents.DotNetBar.SuperTooltip();
- this.dateTimeInput1 = new DevComponents.Editors.DateTimeAdv.DateTimeInput();
- this.btnNow = new DevComponents.DotNetBar.ButtonX();
- ((System.ComponentModel.ISupportInitialize)(this.dateTimeInput1)).BeginInit();
- this.SuspendLayout();
- //
- // btnOK
- //
- this.btnOK.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
- this.btnOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
- this.btnOK.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
- this.btnOK.DialogResult = System.Windows.Forms.DialogResult.OK;
- this.btnOK.Location = new System.Drawing.Point(18, 111);
- this.btnOK.Name = "btnOK";
- this.btnOK.Size = new System.Drawing.Size(64, 23);
- this.btnOK.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
- this.btnOK.TabIndex = 1;
- this.btnOK.Text = "OK";
- this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
- //
- // btnCancel
- //
- this.btnCancel.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
- this.btnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
- this.btnCancel.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
- this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
- this.btnCancel.Location = new System.Drawing.Point(179, 111);
- this.btnCancel.Name = "btnCancel";
- this.btnCancel.Size = new System.Drawing.Size(64, 23);
- this.btnCancel.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
- this.btnCancel.TabIndex = 2;
- this.btnCancel.Text = "Cancel";
- //
- // label1
- //
- this.label1.AutoSize = true;
- this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.label1.Location = new System.Drawing.Point(3, 19);
- this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(229, 15);
- this.label1.TabIndex = 3;
- this.label1.Text = "Show Change Bars on Changes Starting:";
- //
- // superTooltip1
- //
- this.superTooltip1.DefaultTooltipSettings = new DevComponents.DotNetBar.SuperTooltipInfo("", "", "", null, null, DevComponents.DotNetBar.eTooltipColor.Gray);
- this.superTooltip1.LicenseKey = "F962CEC7-CD8F-4911-A9E9-CAB39962FC1F";
- //
- // dateTimeInput1
- //
- //
- //
- //
- this.dateTimeInput1.BackgroundStyle.Class = "DateTimeInputBackground";
- this.dateTimeInput1.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
- this.dateTimeInput1.ButtonDropDown.Shortcut = DevComponents.DotNetBar.eShortcut.AltDown;
- this.dateTimeInput1.ButtonDropDown.Visible = true;
- this.dateTimeInput1.CustomFormat = "MM/dd/yyyy HH:mm:ss";
- this.dateTimeInput1.DateTimeSelectorVisibility = DevComponents.Editors.DateTimeAdv.eDateTimeSelectorVisibility.DateSelector;
- this.dateTimeInput1.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
- this.dateTimeInput1.IsPopupCalendarOpen = false;
- this.dateTimeInput1.Location = new System.Drawing.Point(30, 51);
- //
- //
- //
- //
- //
- //
- this.dateTimeInput1.MonthCalendar.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
- this.dateTimeInput1.MonthCalendar.CalendarDimensions = new System.Drawing.Size(1, 1);
- this.dateTimeInput1.MonthCalendar.ClearButtonVisible = true;
- //
- //
- //
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColor2SchemePart = DevComponents.DotNetBar.eColorSchemePart.BarBackground2;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColorGradientAngle = 90;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.BarBackground;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTop = DevComponents.DotNetBar.eStyleBorderType.Solid;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTopColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.BarDockedBorder;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTopWidth = 1;
- this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
- this.dateTimeInput1.MonthCalendar.DisplayMonth = new System.DateTime(2016, 2, 1, 0, 0, 0, 0);
- //
- //
- //
- this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColor2SchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground2;
- this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColorGradientAngle = 90;
- this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground;
- this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
- this.dateTimeInput1.MonthCalendar.TodayButtonVisible = true;
- this.dateTimeInput1.Name = "dateTimeInput1";
- this.dateTimeInput1.Size = new System.Drawing.Size(146, 20);
- this.dateTimeInput1.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
- this.superTooltip1.SetSuperTooltip(this.dateTimeInput1, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar Start Date", "", "Only the changes made after this date will have change bars.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray, true, true, new System.Drawing.Size(138, 67)));
- this.dateTimeInput1.TabIndex = 4;
- this.dateTimeInput1.TimeSelectorTimeFormat = DevComponents.Editors.DateTimeAdv.eTimeSelectorFormat.Time24H;
- this.dateTimeInput1.TimeSelectorType = DevComponents.Editors.DateTimeAdv.eTimeSelectorType.TouchStyle;
- //
- // btnNow
- //
- this.btnNow.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
- this.btnNow.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
- this.btnNow.Location = new System.Drawing.Point(182, 51);
- this.btnNow.Name = "btnNow";
- this.btnNow.Size = new System.Drawing.Size(49, 23);
- this.btnNow.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
- this.superTooltip1.SetSuperTooltip(this.btnNow, new DevComponents.DotNetBar.SuperTooltipInfo("Now", "", "This will set the Change Bar Start date to today.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
- this.btnNow.TabIndex = 5;
- this.btnNow.Text = "Today";
- this.btnNow.Click += new System.EventHandler(this.btnNow_Click);
- //
- // dlgSetChangeBarStartDate
- //
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(268, 144);
- this.Controls.Add(this.btnNow);
- this.Controls.Add(this.dateTimeInput1);
- this.Controls.Add(this.label1);
- this.Controls.Add(this.btnCancel);
- this.Controls.Add(this.btnOK);
- this.DoubleBuffered = true;
- this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
- this.MaximizeBox = false;
- this.MinimizeBox = false;
- this.Name = "dlgSetChangeBarStartDate";
- this.ShowIcon = false;
- this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
- this.Text = "Change Bar Start Date";
- this.Load += new System.EventHandler(this.dlgSetChangeBarStartDate_Load);
- ((System.ComponentModel.ISupportInitialize)(this.dateTimeInput1)).EndInit();
- this.ResumeLayout(false);
- this.PerformLayout();
+ this.btnOK = new DevComponents.DotNetBar.ButtonX();
+ this.btnCancel = new DevComponents.DotNetBar.ButtonX();
+ this.label1 = new System.Windows.Forms.Label();
+ this.superTooltip1 = new DevComponents.DotNetBar.SuperTooltip();
+ this.dateTimeInput1 = new DevComponents.Editors.DateTimeAdv.DateTimeInput();
+ this.btnNow = new DevComponents.DotNetBar.ButtonX();
+ this.btnResetToApproved = new DevComponents.DotNetBar.ButtonX();
+ ((System.ComponentModel.ISupportInitialize)(this.dateTimeInput1)).BeginInit();
+ this.SuspendLayout();
+ //
+ // btnOK
+ //
+ this.btnOK.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
+ this.btnOK.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+ this.btnOK.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
+ this.btnOK.DialogResult = System.Windows.Forms.DialogResult.OK;
+ this.btnOK.Location = new System.Drawing.Point(18, 111);
+ this.btnOK.Name = "btnOK";
+ this.btnOK.Size = new System.Drawing.Size(64, 23);
+ this.btnOK.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
+ this.btnOK.TabIndex = 1;
+ this.btnOK.Text = "OK";
+ this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
+ //
+ // btnCancel
+ //
+ this.btnCancel.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
+ this.btnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+ this.btnCancel.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
+ this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
+ this.btnCancel.Location = new System.Drawing.Point(179, 111);
+ this.btnCancel.Name = "btnCancel";
+ this.btnCancel.Size = new System.Drawing.Size(64, 23);
+ this.btnCancel.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
+ this.btnCancel.TabIndex = 2;
+ this.btnCancel.Text = "Cancel";
+ //
+ // label1
+ //
+ this.label1.AutoSize = true;
+ this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.label1.Location = new System.Drawing.Point(3, 19);
+ this.label1.Name = "label1";
+ this.label1.Size = new System.Drawing.Size(229, 15);
+ this.label1.TabIndex = 3;
+ this.label1.Text = "Show Change Bars on Changes Starting:";
+ //
+ // superTooltip1
+ //
+ this.superTooltip1.DefaultTooltipSettings = new DevComponents.DotNetBar.SuperTooltipInfo("", "", "", null, null, DevComponents.DotNetBar.eTooltipColor.Gray);
+ this.superTooltip1.LicenseKey = "F962CEC7-CD8F-4911-A9E9-CAB39962FC1F";
+ //
+ // dateTimeInput1
+ //
+ //
+ //
+ //
+ this.dateTimeInput1.BackgroundStyle.Class = "DateTimeInputBackground";
+ this.dateTimeInput1.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
+ this.dateTimeInput1.ButtonDropDown.Shortcut = DevComponents.DotNetBar.eShortcut.AltDown;
+ this.dateTimeInput1.ButtonDropDown.Visible = true;
+ this.dateTimeInput1.CustomFormat = "MM/dd/yyyy HH:mm:ss";
+ this.dateTimeInput1.DateTimeSelectorVisibility = DevComponents.Editors.DateTimeAdv.eDateTimeSelectorVisibility.DateSelector;
+ this.dateTimeInput1.Format = DevComponents.Editors.eDateTimePickerFormat.Custom;
+ this.dateTimeInput1.IsPopupCalendarOpen = false;
+ this.dateTimeInput1.Location = new System.Drawing.Point(30, 51);
+ //
+ //
+ //
+ //
+ //
+ //
+ this.dateTimeInput1.MonthCalendar.BackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
+ this.dateTimeInput1.MonthCalendar.CalendarDimensions = new System.Drawing.Size(1, 1);
+ this.dateTimeInput1.MonthCalendar.ClearButtonVisible = true;
+ //
+ //
+ //
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColor2SchemePart = DevComponents.DotNetBar.eColorSchemePart.BarBackground2;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColorGradientAngle = 90;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BackColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.BarBackground;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTop = DevComponents.DotNetBar.eStyleBorderType.Solid;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTopColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.BarDockedBorder;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.BorderTopWidth = 1;
+ this.dateTimeInput1.MonthCalendar.CommandsBackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
+ this.dateTimeInput1.MonthCalendar.DisplayMonth = new System.DateTime(2016, 2, 1, 0, 0, 0, 0);
+ //
+ //
+ //
+ this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColor2SchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground2;
+ this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColorGradientAngle = 90;
+ this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.BackColorSchemePart = DevComponents.DotNetBar.eColorSchemePart.PanelBackground;
+ this.dateTimeInput1.MonthCalendar.NavigationBackgroundStyle.CornerType = DevComponents.DotNetBar.eCornerType.Square;
+ this.dateTimeInput1.MonthCalendar.TodayButtonVisible = true;
+ this.dateTimeInput1.Name = "dateTimeInput1";
+ this.dateTimeInput1.Size = new System.Drawing.Size(146, 20);
+ this.dateTimeInput1.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
+ this.superTooltip1.SetSuperTooltip(this.dateTimeInput1, new DevComponents.DotNetBar.SuperTooltipInfo("Change Bar Start Date", "", "Only the changes made after this date will have change bars.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray, true, true, new System.Drawing.Size(138, 67)));
+ this.dateTimeInput1.TabIndex = 4;
+ this.dateTimeInput1.TimeSelectorTimeFormat = DevComponents.Editors.DateTimeAdv.eTimeSelectorFormat.Time24H;
+ this.dateTimeInput1.TimeSelectorType = DevComponents.Editors.DateTimeAdv.eTimeSelectorType.TouchStyle;
+ //
+ // btnNow
+ //
+ this.btnNow.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
+ this.btnNow.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
+ this.btnNow.Location = new System.Drawing.Point(182, 51);
+ this.btnNow.Name = "btnNow";
+ this.btnNow.Size = new System.Drawing.Size(49, 23);
+ this.btnNow.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
+ this.superTooltip1.SetSuperTooltip(this.btnNow, new DevComponents.DotNetBar.SuperTooltipInfo("Now", "", "This will set the Change Bar Start date to today.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
+ this.btnNow.TabIndex = 5;
+ this.btnNow.Text = "Today";
+ this.btnNow.Click += new System.EventHandler(this.btnNow_Click);
+ //
+ // btnResetToApproved
+ //
+ this.btnResetToApproved.AccessibleRole = System.Windows.Forms.AccessibleRole.PushButton;
+ this.btnResetToApproved.ColorTable = DevComponents.DotNetBar.eButtonColor.OrangeWithBackground;
+ this.btnResetToApproved.Location = new System.Drawing.Point(30, 77);
+ this.btnResetToApproved.Name = "btnResetToApproved";
+ this.btnResetToApproved.Size = new System.Drawing.Size(201, 23);
+ this.btnResetToApproved.Style = DevComponents.DotNetBar.eDotNetBarStyle.StyleManagerControlled;
+ this.btnResetToApproved.TabIndex = 6;
+ this.btnResetToApproved.Text = "Reset Change Bar To Approved Date";
+ this.btnResetToApproved.Tooltip = "Reset Change Bar to the last approved date. If no approvals, reset to as if no ch" +
+ "ange bar date. After selecting this, press OK to save.";
+ this.btnResetToApproved.Click += new System.EventHandler(this.btnResetToApproved_Click);
+ //
+ // dlgSetChangeBarStartDate
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(268, 144);
+ this.Controls.Add(this.btnResetToApproved);
+ this.Controls.Add(this.btnNow);
+ this.Controls.Add(this.dateTimeInput1);
+ this.Controls.Add(this.label1);
+ this.Controls.Add(this.btnCancel);
+ this.Controls.Add(this.btnOK);
+ this.DoubleBuffered = true;
+ this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
+ this.MaximizeBox = false;
+ this.MinimizeBox = false;
+ this.Name = "dlgSetChangeBarStartDate";
+ this.ShowIcon = false;
+ this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
+ this.Text = "Change Bar Start Date";
+ this.Load += new System.EventHandler(this.dlgSetChangeBarStartDate_Load);
+ ((System.ComponentModel.ISupportInitialize)(this.dateTimeInput1)).EndInit();
+ this.ResumeLayout(false);
+ this.PerformLayout();
}
@@ -175,5 +191,6 @@
private DevComponents.DotNetBar.SuperTooltip superTooltip1;
private DevComponents.Editors.DateTimeAdv.DateTimeInput dateTimeInput1;
private DevComponents.DotNetBar.ButtonX btnNow;
- }
+ private DevComponents.DotNetBar.ButtonX btnResetToApproved;
+ }
}
\ No newline at end of file
diff --git a/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.cs b/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.cs
index ba10dfbf..c574c293 100644
--- a/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.cs
+++ b/PROMS/VEPROMS User Interface/dlgSetChangeBarStartDate.cs
@@ -1,31 +1,23 @@
using System;
-using System.Collections.Generic;
-using System.ComponentModel;
using System.Data;
-using System.Drawing;
using System.Text;
using System.Windows.Forms;
-using DevComponents.DotNetBar;
-using DevComponents.DotNetBar.Controls;
using VEPROMS.CSLA.Library;
-
+using Volian.Controls.Library;
namespace VEPROMS
{
public partial class dlgSetChangeBarStartDate : DevComponents.DotNetBar.Office2007Form
{
- private ProcedureConfig _MyProcConfig = null;
+ public ProcedureConfig MyProcConfig { get; set; } = null;
- public ProcedureConfig MyProcConfig
- {
- get { return _MyProcConfig; }
- set { _MyProcConfig = value; }
- }
+ public ProcedureInfo MyProcInfo { get; set; } = null;
- public dlgSetChangeBarStartDate(ProcedureConfig pc)
+ public dlgSetChangeBarStartDate(ProcedureConfig pc, ProcedureInfo pi)
{
InitializeComponent();
- _MyProcConfig = pc;
+ MyProcConfig = pc;
+ MyProcInfo = pi;
}
private void dlgSetChangeBarStartDate_Load(object sender, EventArgs e)
@@ -80,5 +72,65 @@ namespace VEPROMS
dateTimeInput1.Value = DateTime.Now;
}
- }
+ //C2026-009 Add Option to Reset Change Bar to Last Approved Date/Time
+ private void btnResetToApproved_Click(object sender, EventArgs e)
+ {
+ System.Data.DataTable dt = RevisionData.GetRevisionDataByUnit(MyProcInfo.ItemID);
+
+ if (dt.Rows.Count == 0)
+ {
+ //no records, remove
+ if (MessageBox.Show("There are currently no approvals set. Selecting yes will set ChangeBars to show all changes since the creation of the procedure.\r\nAre you sure you wish to reset ChangeBars?", "Reset ChangeBar Date", MessageBoxButtons.YesNo) == DialogResult.Yes)
+ {
+ MyProcConfig.Print_ChangeBarDate = "";
+ DialogResult = DialogResult.OK;
+ Close();
+ }
+ }
+ else if (RevisionData.HasUnits(dt))
+ {
+ //any with units
+ string maxDTS = RevisionData.MaxDTS(dt).ToString("MM/dd/yyyy HH:mm:ss");
+
+ //create wording for ChangeBar changes
+ StringBuilder sb = new StringBuilder();
+ sb.Append($" The Procedure Viewer Change Bar Date will be set to ({maxDTS}).");
+ foreach (DataRow r in dt.Rows)
+ {
+ sb.Append($"\r\n The Change Bar Date for Unit ({r["UnitName"]}) will be set to ({Convert.ToDateTime(r["DTS"]):MM/dd/yyyy HH:mm:ss}).");
+ }
+
+ sb.Append("\r\n Any Change Bars for Units not listed above will use the Overall/Procedure Viewer Change Bar Date (as these Units have no approvals).");
+
+ if (CustomMessageBox.Show($"This will reset ChangeBars to show for changes newer than the last approval.\r\nThis includes the following changes:\r\n{sb.ToString()}\r\n\r\nAre you sure you wish to reset ChangeBars?", "Reset ChangeBar Date", "Yes", "No") == DialogResult.Yes)
+ {
+ //Change the overall ChangeBarDate
+ MyProcConfig.Print_ChangeBarDate = maxDTS;
+
+ //Change the ChangeBarDate for each unit
+ foreach (DataRow r in dt.Rows)
+ {
+ MyProcConfig.SelectedSlave = Convert.ToInt32(r["UnitID"]);
+ MyProcConfig.Print_ChangeBarDate = Convert.ToDateTime(r["DTS"]).ToString("MM / dd / yyyy HH: mm: ss");
+ }
+ MyProcConfig.SelectedSlave = 0;
+
+ DialogResult = DialogResult.OK;
+ Close();
+ }
+ }
+ else
+ {
+ //no units
+ string maxDTS = RevisionData.MaxDTS(dt).ToString("MM/dd/yyyy HH:mm:ss");
+ if (MessageBox.Show($"This will reset ChangeBars to show for changes newer than the last approval ({maxDTS}).\r\nAre you sure you wish to reset ChangeBars?", "Reset ChangeBar Date", MessageBoxButtons.YesNo) == DialogResult.Yes)
+ {
+ MyProcConfig.Print_ChangeBarDate = maxDTS;
+ DialogResult = DialogResult.OK;
+ Close();
+ }
+ }
+
+ }
+ }
}
diff --git a/PROMS/VEPROMS User Interface/frmBatchRefresh.resx b/PROMS/VEPROMS User Interface/frmBatchRefresh.resx
index e63d56a3..7e66d1f3 100644
--- a/PROMS/VEPROMS User Interface/frmBatchRefresh.resx
+++ b/PROMS/VEPROMS User Interface/frmBatchRefresh.resx
@@ -165,9 +165,9 @@ This function will cause no change to data or records in PROMS.
It should however be performed when other users are not in PROMS, as it could
cause slowdown or errors for other users while it is running.
-
+
17, 17
-
+
This allows the user to remove folders and sub folders as well as their contents.
@@ -304,22 +304,22 @@ Should an item become orphaned (disconnected) from the rest of the data, it will
- This allows the user to check referenced objects links in procedure step data for multiple working drafts in a batch mode.
+ This allows the user to check referenced object links in procedure step data for multiple working drafts in a batch mode.
-Bad referenced bject links will be identified with an Bad RO Link annotation. Use the PROMS Search tool to list all of the steps that have this annotation.
+Bad referenced object links will be identified with a Bad RO Link annotation. Use the PROMS Search tool to list all of the steps that have this annotation.
-Be sure a current backup of the database exists prior performing this function.
+Be sure a current backup of the database exists prior to performing this function.
It is recommended that this be done during off hours.
- This allows the user to check referenced objects links in procedure step data for multiple working drafts in a batch mode.
+ This allows the user to check referenced object links in procedure step data for multiple working drafts in a batch mode.
-Bad referenced bject links will be identified with an Bad RO Link annotation. Use the PROMS Search tool to list all of the steps that have this annotation.
+Bad referenced object links will be identified with a Bad RO Link annotation. Use the PROMS Search tool to list all of the steps that have this annotation.
-Be sure a current backup of the database exists prior performing this function.
+Be sure a current backup of the database exists prior to performing this function.
It is recommended that this be done during off hours.
@@ -388,7 +388,8 @@ If more than one procedure is selected, it is recommended that this be performed
ud8AKwnMnBpmYFAAAAAASUVORK5CYII=
-
+
+
25
-
+
\ No newline at end of file
diff --git a/PROMS/VEPROMS User Interface/frmSectionProperties.cs b/PROMS/VEPROMS User Interface/frmSectionProperties.cs
index 9d19bf66..06ee3ce2 100644
--- a/PROMS/VEPROMS User Interface/frmSectionProperties.cs
+++ b/PROMS/VEPROMS User Interface/frmSectionProperties.cs
@@ -678,7 +678,7 @@ namespace VEPROMS
// to check that there are enough docstyles to map the selected type of section.
PlantFormat pf = _SectionConfig.MyFormat != null ? _SectionConfig.MyFormat.PlantFormat : _SectionConfig.MyDefaultFormat.PlantFormat;
if (!_Initializing && ppCmbxFormat.SelectedIndex >= 0)
- pf = FormatInfoList.SortedFormatInfoList[ppCmbxFormat.SelectedIndex].PlantFormat;
+ pf = ((FormatInfo) ppCmbxFormat.SelectedItem).PlantFormat;
else if (!_Initializing) // if the format was changed, it may have been set to default.
pf = _SectionConfig.MyDefaultFormat.PlantFormat;
_Initializing = true;
diff --git a/PROMS/VEPROMS User Interface/frmVEPROMS.cs b/PROMS/VEPROMS User Interface/frmVEPROMS.cs
index 0d3e7556..5e071de9 100644
--- a/PROMS/VEPROMS User Interface/frmVEPROMS.cs
+++ b/PROMS/VEPROMS User Interface/frmVEPROMS.cs
@@ -617,7 +617,7 @@ namespace VEPROMS
ProcedureConfig pc = pi.MyConfig as ProcedureConfig;
if (pc == null) return;
- dlgSetChangeBarStartDate cbdDlg = new dlgSetChangeBarStartDate(pc);
+ dlgSetChangeBarStartDate cbdDlg = new dlgSetChangeBarStartDate(pc, pi);
if (cbdDlg.ShowDialog() == DialogResult.OK)
{
using (Item itm = Item.Get(pi.ItemID))
diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/RevisionInfoExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/RevisionInfoExt.cs
index e3cc9d67..50b3b2d7 100644
--- a/PROMS/VEPROMS.CSLA.Library/Extension/RevisionInfoExt.cs
+++ b/PROMS/VEPROMS.CSLA.Library/Extension/RevisionInfoExt.cs
@@ -597,13 +597,6 @@ namespace VEPROMS.CSLA.Library
//if (_RevisionInfoList != null)
// return _RevisionInfoList;
RevisionInfoList tmp = DataPortal.Fetch(new ItemUnitCriteria(itemID, unitID));
-
- foreach (var x in tmp)
- {
- x.LatestVersion.ApprovedXML = x.RevisionID.ToString();
- x.LatestVersion.PDF = Encoding.ASCII.GetBytes(x.RevisionID.ToString());
- x.LatestVersion.SummaryPDF = Encoding.ASCII.GetBytes(x.RevisionID.ToString());
- }
RevisionInfo.AddList(tmp);
tmp.AddEvents();
//_RevisionInfoList = tmp;
diff --git a/PROMS/VEPROMS.CSLA.Library/Minimal/RevisionData.cs b/PROMS/VEPROMS.CSLA.Library/Minimal/RevisionData.cs
new file mode 100644
index 00000000..df2fb5cc
--- /dev/null
+++ b/PROMS/VEPROMS.CSLA.Library/Minimal/RevisionData.cs
@@ -0,0 +1,53 @@
+using Csla.Data;
+using System;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+
+//CSM - C2026-009 - Minimal Class for Getting Revision Data
+namespace VEPROMS.CSLA.Library
+{
+ public static class RevisionData
+ {
+ #region Check Data
+ //Check if Data Has Units
+ public static bool HasUnits(DataTable dt) => dt.AsEnumerable().Any(x => x.Field("UnitID") > 0);
+
+ //Get Maximum Date Time Stamp
+ public static DateTime MaxDTS(DataTable dt) => dt.AsEnumerable().Max(x => x.Field("DTS"));
+
+ #endregion
+
+ #region Get Revision Data
+ //CSM - C2026-009 Get Current Revision Data by Unit
+ public static DataTable GetRevisionDataByUnit(int itemID)
+ {
+ try
+ {
+ using (SqlConnection cn = Database.VEPROMS_SqlConnection)
+ {
+ using (SqlCommand cm = cn.CreateCommand())
+ {
+ cm.CommandType = CommandType.StoredProcedure;
+ cm.CommandText = "GetCurrentApprovedRevisions";
+ cm.CommandTimeout = Database.DefaultTimeout;
+ cm.Parameters.AddWithValue("@ItemID", itemID);
+
+ using (SqlDataAdapter da = new SqlDataAdapter(cm))
+ {
+ DataTable dt = new DataTable();
+ da.Fill(dt);
+ return dt;
+ }
+ }
+ }
+ }
+ catch (Exception ex)
+ {
+ throw new DbCslaException("Error in GetRevisionDataByUnit: retrieving data failed", ex);
+ }
+ }
+ #endregion
+
+ }
+}
diff --git a/PROMS/VEPROMS.CSLA.Library/VEPROMS.CSLA.Library.csproj b/PROMS/VEPROMS.CSLA.Library/VEPROMS.CSLA.Library.csproj
index b25089b2..2234b8df 100644
--- a/PROMS/VEPROMS.CSLA.Library/VEPROMS.CSLA.Library.csproj
+++ b/PROMS/VEPROMS.CSLA.Library/VEPROMS.CSLA.Library.csproj
@@ -391,6 +391,7 @@
+
diff --git a/PROMS/Volian.Controls.Library/CustomMessageBox.Designer.cs b/PROMS/Volian.Controls.Library/CustomMessageBox.Designer.cs
index c804d557..0deb398b 100644
--- a/PROMS/Volian.Controls.Library/CustomMessageBox.Designer.cs
+++ b/PROMS/Volian.Controls.Library/CustomMessageBox.Designer.cs
@@ -31,25 +31,32 @@
this.btn1 = new System.Windows.Forms.Button();
this.btn2 = new System.Windows.Forms.Button();
this.lblMessage = new System.Windows.Forms.Label();
+ this.tableLP1 = new System.Windows.Forms.TableLayoutPanel();
+ this.tableLP1.SuspendLayout();
this.SuspendLayout();
//
// btn1
//
+ this.btn1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.btn1.AutoSize = true;
- this.btn1.Location = new System.Drawing.Point(12, 99);
+ this.btn1.Location = new System.Drawing.Point(18, 102);
+ this.btn1.Margin = new System.Windows.Forms.Padding(10);
+ this.btn1.MinimumSize = new System.Drawing.Size(60, 20);
this.btn1.Name = "btn1";
- this.btn1.Size = new System.Drawing.Size(75, 23);
+ this.btn1.Size = new System.Drawing.Size(60, 20);
this.btn1.TabIndex = 0;
this.btn1.UseVisualStyleBackColor = true;
this.btn1.Click += new System.EventHandler(this.Btn1_Click);
//
// btn2
//
- this.btn2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+ this.btn2.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.btn2.AutoSize = true;
- this.btn2.Location = new System.Drawing.Point(322, 99);
+ this.btn2.Location = new System.Drawing.Point(335, 102);
+ this.btn2.Margin = new System.Windows.Forms.Padding(10);
+ this.btn2.MinimumSize = new System.Drawing.Size(60, 20);
this.btn2.Name = "btn2";
- this.btn2.Size = new System.Drawing.Size(75, 23);
+ this.btn2.Size = new System.Drawing.Size(60, 20);
this.btn2.TabIndex = 1;
this.btn2.UseVisualStyleBackColor = true;
this.btn2.Click += new System.EventHandler(this.Btn2_Click);
@@ -57,24 +64,48 @@
// lblMessage
//
this.lblMessage.AutoSize = true;
- this.lblMessage.Location = new System.Drawing.Point(33, 41);
+ this.tableLP1.SetColumnSpan(this.lblMessage, 2);
+ this.lblMessage.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.lblMessage.Location = new System.Drawing.Point(11, 8);
+ this.lblMessage.MaximumSize = new System.Drawing.Size(413, 0);
this.lblMessage.Name = "lblMessage";
- this.lblMessage.Size = new System.Drawing.Size(0, 13);
+ this.lblMessage.Size = new System.Drawing.Size(391, 84);
this.lblMessage.TabIndex = 2;
this.lblMessage.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
+ // tableLP1
+ //
+ this.tableLP1.AutoSize = true;
+ this.tableLP1.ColumnCount = 2;
+ this.tableLP1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLP1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
+ this.tableLP1.Controls.Add(this.lblMessage, 0, 0);
+ this.tableLP1.Controls.Add(this.btn1);
+ this.tableLP1.Controls.Add(this.btn2);
+ this.tableLP1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.tableLP1.Location = new System.Drawing.Point(0, 0);
+ this.tableLP1.MaximumSize = new System.Drawing.Size(413, 0);
+ this.tableLP1.MinimumSize = new System.Drawing.Size(413, 130);
+ this.tableLP1.Name = "tableLP1";
+ this.tableLP1.Padding = new System.Windows.Forms.Padding(8);
+ this.tableLP1.RowCount = 2;
+ this.tableLP1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
+ this.tableLP1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 30F));
+ this.tableLP1.Size = new System.Drawing.Size(413, 130);
+ this.tableLP1.TabIndex = 0;
+ //
// CustomMessageBox
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoSize = true;
this.ClientSize = new System.Drawing.Size(419, 130);
- this.Controls.Add(this.lblMessage);
- this.Controls.Add(this.btn2);
- this.Controls.Add(this.btn1);
+ this.Controls.Add(this.tableLP1);
this.Name = "CustomMessageBox";
this.ShowIcon = false;
this.Text = "CustomMessageBox";
+ this.tableLP1.ResumeLayout(false);
+ this.tableLP1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
@@ -85,5 +116,6 @@
private System.Windows.Forms.Button btn1;
private System.Windows.Forms.Button btn2;
private System.Windows.Forms.Label lblMessage;
+ private System.Windows.Forms.TableLayoutPanel tableLP1;
}
}
\ No newline at end of file
diff --git a/PROMS/Volian.Controls.Library/CustomMessageBox.cs b/PROMS/Volian.Controls.Library/CustomMessageBox.cs
index 3a42d5e7..a16a59d1 100644
--- a/PROMS/Volian.Controls.Library/CustomMessageBox.cs
+++ b/PROMS/Volian.Controls.Library/CustomMessageBox.cs
@@ -27,6 +27,10 @@ namespace Volian.Controls.Library
{
btn2.Text = button2Text;
btn2.Visible = true;
+
+ //make buttons uniform
+ btn1.Height = btn2.Height = btn1.Height > btn2.Height ? btn1.Height : btn2.Height;
+ btn1.Width = btn2.Width = btn1.Width > btn2.Width ? btn1.Width : btn2.Width;
}
else
{
diff --git a/PROMS/Volian.Controls.Library/DisplayApplicability.Designer.cs b/PROMS/Volian.Controls.Library/DisplayApplicability.Designer.cs
index 9a7f4920..74a354b4 100644
--- a/PROMS/Volian.Controls.Library/DisplayApplicability.Designer.cs
+++ b/PROMS/Volian.Controls.Library/DisplayApplicability.Designer.cs
@@ -1,3 +1,6 @@
+using System.Security.Cryptography;
+using VEPROMS.CSLA.Library;
+
namespace Volian.Controls.Library
{
partial class DisplayApplicability
@@ -20,6 +23,7 @@ namespace Volian.Controls.Library
base.Dispose(disposing);
}
+
#region Component Designer generated code
///
@@ -30,19 +34,41 @@ namespace Volian.Controls.Library
{
this.gpMode = new DevComponents.DotNetBar.Controls.GroupPanel();
this.gpItem = new DevComponents.DotNetBar.Controls.GroupPanel();
+ this.btnApplicabilitychg2 = new DevComponents.DotNetBar.ButtonItem();
+ this.btnApplicabilitychg = new DevComponents.DotNetBar.ButtonX();
+ this.superTooltip1 = new DevComponents.DotNetBar.SuperTooltip();
+ this.gpItem.SuspendLayout();
this.SuspendLayout();
//
+ // btnApplicabilitychg
+ //
+ this.btnApplicabilitychg.Location = new System.Drawing.Point(60, 8);
+ this.btnApplicabilitychg.Margin = new System.Windows.Forms.Padding(4);
+ this.btnApplicabilitychg.BackColor = System.Drawing.SystemColors.Control;
+ this.btnApplicabilitychg.Name = "btnApplicabilitychg";
+ this.btnApplicabilitychg.Size = new System.Drawing.Size(80, 22);
+ this.btnApplicabilitychg.Margin = new System.Windows.Forms.Padding(2);
+ this.btnApplicabilitychg.RightToLeft = System.Windows.Forms.RightToLeft.No;
+ this.superTooltip1.SetSuperTooltip(this.btnApplicabilitychg, new DevComponents.DotNetBar.SuperTooltipInfo("Change applicability settings - All At Level", "", "When clicked, all steps at the level of the current step will have their applicability settings changed.", null, null, DevComponents.DotNetBar.eTooltipColor.Gray));
+ this.btnApplicabilitychg.TabIndex = 0;
+ this.btnApplicabilitychg.Text = "Set All at Level";
+ this.btnApplicabilitychg.ColorTable = DevComponents.DotNetBar.eButtonColor.BlueOrb;
+ this.btnApplicabilitychg.Font = new System.Drawing.Font("Microsoft Sans Serif", 8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.btnApplicabilitychg.Click += new System.EventHandler(this.BtnApplicabilitychg_Click);
+ //
// gpMode
//
this.gpMode.AutoSize = true;
this.gpMode.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.gpMode.CanvasColor = System.Drawing.SystemColors.Control;
this.gpMode.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
+ this.gpMode.DisabledBackColor = System.Drawing.Color.Empty;
this.gpMode.Dock = System.Windows.Forms.DockStyle.Top;
this.gpMode.Location = new System.Drawing.Point(0, 0);
+ this.gpMode.Margin = new System.Windows.Forms.Padding(4);
this.gpMode.Name = "gpMode";
- this.gpMode.Padding = new System.Windows.Forms.Padding(10, 10, 10, 30);
- this.gpMode.Size = new System.Drawing.Size(324, 40);
+ this.gpMode.Padding = new System.Windows.Forms.Padding(13, 12, 13, 37);
+ this.gpMode.Size = new System.Drawing.Size(432, 49);
//
//
//
@@ -58,7 +84,6 @@ namespace Volian.Controls.Library
this.gpMode.Style.BorderRightWidth = 1;
this.gpMode.Style.BorderTop = DevComponents.DotNetBar.eStyleBorderType.Solid;
this.gpMode.Style.BorderTopWidth = 1;
- this.gpMode.Style.Class = "";
this.gpMode.Style.CornerDiameter = 4;
this.gpMode.Style.CornerType = DevComponents.DotNetBar.eCornerType.Rounded;
this.gpMode.Style.TextAlignment = DevComponents.DotNetBar.eStyleTextAlignment.Center;
@@ -67,12 +92,10 @@ namespace Volian.Controls.Library
//
//
//
- this.gpMode.StyleMouseDown.Class = "";
this.gpMode.StyleMouseDown.CornerType = DevComponents.DotNetBar.eCornerType.Square;
//
//
//
- this.gpMode.StyleMouseOver.Class = "";
this.gpMode.StyleMouseOver.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.gpMode.TabIndex = 0;
this.gpMode.Text = "Viewing Mode";
@@ -83,11 +106,14 @@ namespace Volian.Controls.Library
this.gpItem.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.gpItem.CanvasColor = System.Drawing.SystemColors.Control;
this.gpItem.ColorSchemeStyle = DevComponents.DotNetBar.eDotNetBarStyle.Office2007;
+ //this.gpItem.Controls.Add(this.btnApplicabilitychg);
+ this.gpItem.DisabledBackColor = System.Drawing.Color.Empty;
this.gpItem.Dock = System.Windows.Forms.DockStyle.Top;
- this.gpItem.Location = new System.Drawing.Point(0, 40);
+ this.gpItem.Location = new System.Drawing.Point(0, 49);
+ this.gpItem.Margin = new System.Windows.Forms.Padding(4);
this.gpItem.Name = "gpItem";
- this.gpItem.Padding = new System.Windows.Forms.Padding(10, 10, 10, 30);
- this.gpItem.Size = new System.Drawing.Size(324, 40);
+ this.gpItem.Padding = new System.Windows.Forms.Padding(13, 12, 13, 37);
+ this.gpItem.Size = new System.Drawing.Size(432, 85);
//
//
//
@@ -103,7 +129,6 @@ namespace Volian.Controls.Library
this.gpItem.Style.BorderRightWidth = 1;
this.gpItem.Style.BorderTop = DevComponents.DotNetBar.eStyleBorderType.Solid;
this.gpItem.Style.BorderTopWidth = 1;
- this.gpItem.Style.Class = "";
this.gpItem.Style.CornerDiameter = 4;
this.gpItem.Style.CornerType = DevComponents.DotNetBar.eCornerType.Rounded;
this.gpItem.Style.TextAlignment = DevComponents.DotNetBar.eStyleTextAlignment.Center;
@@ -112,26 +137,31 @@ namespace Volian.Controls.Library
//
//
//
- this.gpItem.StyleMouseDown.Class = "";
this.gpItem.StyleMouseDown.CornerType = DevComponents.DotNetBar.eCornerType.Square;
//
//
//
- this.gpItem.StyleMouseOver.Class = "";
this.gpItem.StyleMouseOver.CornerType = DevComponents.DotNetBar.eCornerType.Square;
this.gpItem.TabIndex = 1;
this.gpItem.Text = "Item Mode";
//
// DisplayApplicability
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.gpItem);
this.Controls.Add(this.gpMode);
+ this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "DisplayApplicability";
- this.Size = new System.Drawing.Size(324, 656);
+ this.Size = new System.Drawing.Size(432, 807);
+ this.gpItem.ResumeLayout(false);
this.ResumeLayout(false);
- this.PerformLayout();
+ this.PerformLayout();
+ //
+ // superTooltip1
+ //
+ this.superTooltip1.DefaultTooltipSettings = new DevComponents.DotNetBar.SuperTooltipInfo("", "", "", null, null, DevComponents.DotNetBar.eTooltipColor.Gray);
+ this.superTooltip1.LicenseKey = "F962CEC7-CD8F-4911-A9E9-CAB39962FC1F";
}
@@ -139,6 +169,9 @@ namespace Volian.Controls.Library
private DevComponents.DotNetBar.Controls.GroupPanel gpMode;
private DevComponents.DotNetBar.Controls.GroupPanel gpItem;
+ private DevComponents.DotNetBar.ButtonItem btnApplicabilitychg2;
+ private DevComponents.DotNetBar.ButtonX btnApplicabilitychg;
+ private DevComponents.DotNetBar.SuperTooltip superTooltip1;
}
}
diff --git a/PROMS/Volian.Controls.Library/DisplayApplicability.cs b/PROMS/Volian.Controls.Library/DisplayApplicability.cs
index a5869b64..8b9d460b 100644
--- a/PROMS/Volian.Controls.Library/DisplayApplicability.cs
+++ b/PROMS/Volian.Controls.Library/DisplayApplicability.cs
@@ -1,12 +1,13 @@
+using JR.Utils.GUI.Forms;
+using log4net.Util;
using System;
using System.Collections.Generic;
using System.ComponentModel;
-using System.Drawing;
using System.Data;
+using System.Drawing;
using System.Text;
using System.Windows.Forms;
using VEPROMS.CSLA.Library;
-using JR.Utils.GUI.Forms;
namespace Volian.Controls.Library
{
@@ -51,15 +52,22 @@ namespace Volian.Controls.Library
i++;
AddViewMode(name.Trim(), i.ToString(), apple == i);
}
+
AddItemMode("All", "-1");
i = 0;
foreach (string name in names)
AddItemMode(name.Trim(), (++i).ToString());
AddItemMode("None", "0");
+ gpItem.Controls.Add(btnApplicabilitychg);
+ btnApplicabilitychg.BringToFront();
if (_MyDisplayTabItem.MyStepTabPanel != null)
+ {
MyItemInfo = _MyDisplayTabItem.MyStepTabPanel.MyStepPanel.SelectedItemInfo;
+ }
else
+ {
MyItemInfo = _MyDisplayTabItem.MyItemInfo;
+ }
}
}
}
@@ -175,7 +183,8 @@ namespace Volian.Controls.Library
}
break;
}
- WireCheckboxes();
+
+ WireCheckboxes();
MyApplicability = string.Empty;
string sep = string.Empty;
foreach (int i in MyCheckBoxes.Keys)
@@ -270,6 +279,29 @@ namespace Volian.Controls.Library
// s.Save();
//}
}
+ private void BtnApplicabilitychg_Click(object sender, System.EventArgs e)
+ {
+ Volian.Base.Library.BigNum MasterSlave_ApplicabilityTmp;
+ StepConfig sc = MyItemInfo.MyConfig as StepConfig;
+ MasterSlave_ApplicabilityTmp = sc.MasterSlave_Applicability;
+
+ ItemInfo startitm = MyItemInfo.FirstSibling;
+ while (startitm != null)
+ {
+ StepConfig sc2 = startitm.MyConfig as StepConfig;
+ using (Content cnt = Content.Get(startitm.MyContent.ContentID))
+ {
+ sc2.MasterSlave_Applicability = (MasterSlave_ApplicabilityTmp);
+ cnt.Config = sc2.ToString();
+ cnt.Save();
+ }
+ startitm = startitm.GetNext();
+ }
+
+ _MyDisplayTabItem.MyStepTabPanel.MyStepTabRibbon.RefreshProcedure();
+
+ }
+
// B2021-149: for procedure, only consider external transitions as invalid
private bool IsProcWithNoExternalTrans(ItemInfo ii, List invalidTrans)
{
diff --git a/PROMS/Volian.Controls.Library/Volian.Controls.Library.csproj b/PROMS/Volian.Controls.Library/Volian.Controls.Library.csproj
index bb704d34..c840ed21 100644
--- a/PROMS/Volian.Controls.Library/Volian.Controls.Library.csproj
+++ b/PROMS/Volian.Controls.Library/Volian.Controls.Library.csproj
@@ -462,6 +462,7 @@
CustomMessageBox.cs
+ Designer
DisplayBookMarks.cs
diff --git a/PROMS/Volian.Controls.Library/vlnTreeView.cs b/PROMS/Volian.Controls.Library/vlnTreeView.cs
index 73889378..12fabd03 100644
--- a/PROMS/Volian.Controls.Library/vlnTreeView.cs
+++ b/PROMS/Volian.Controls.Library/vlnTreeView.cs
@@ -1601,12 +1601,11 @@ namespace Volian.Controls.Library
//B2024-024 create import file for parent/child procedure set
void MultiUnitImportProcedure_Click(object sender, EventArgs e)
{
- //RevisionInfo ri = (sender as MenuItem).Tag as RevisionInfo;
RevisionInfo ri = RevisionInfo.Get(int.Parse((sender as MenuItem).Tag.ToString()));
RevisionConfig rc = ri.MyConfig as RevisionConfig;
// bug fix: B2016-183 - add the child's name (ex Unit 1) to the export file name for Parent/Child procedures.
int applIdx = rc.Applicability_Index;
- string str = (applIdx > 0) ? _currentPri.MyDocVersion.UnitNames[applIdx - 1] + "_" : ""; // if parent/child get the defined child name to inlcude the export filename
+ string str = (applIdx > 0) ? _currentPri.MyDocVersion.UnitNames[applIdx - 1] + "_" : ""; // if parent/child get the defined child name to include the export filename
System.Xml.XmlDocument xd = new System.Xml.XmlDocument();
xd.LoadXml(ri.LatestVersion.ApprovedXML);
string PEIPath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments) + @"\VEPROMS\PEI_" + Database.VEPROMS_SqlConnection.Database;
@@ -1615,8 +1614,13 @@ namespace Volian.Controls.Library
// B2022-048: Crash when creating Procedure to Import from versions. Couldn't handle '/' in proc number.
string fNametmp = xd.SelectSingleNode("procedure/content/@number").InnerText.Replace(" ", "_").Replace(@"\u8209?", "-").Replace(@"\u9586?", "_").Replace("/", "-") + ".pxml";
// B2022-112: If applicability, need to resolve the '<' and '>' characters. Just use the UnitNames, i.e. str, from above.
- if (applIdx > 0) fNametmp = Regex.Replace(fNametmp, @"\", str, RegexOptions.IgnoreCase);
- string fileName = PEIPath + "\\" + str + "Approved_Rev_" + ri.RevisionNumber.Replace(" ", "_").Replace("\\", "-").Replace("/", "-") + "_" + fNametmp;
+ if (applIdx > 0)
+ {
+ fNametmp = Regex.Replace(fNametmp, @"\", str, RegexOptions.IgnoreCase);
+ fNametmp = Regex.Replace(fNametmp, @"\", str, RegexOptions.IgnoreCase);
+ }
+
+ string fileName = PEIPath + "\\" + str + "Approved_Rev_" + ri.RevisionNumber.Replace(" ", "_").Replace("\\", "-").Replace("/", "-") + "_" + fNametmp;
xd.Save(fileName);
FlexibleMessageBox.Show("Approved procedure saved to import file " + fileName, "Creating Export of Approved Procedure", MessageBoxButtons.OK, MessageBoxIcon.Information);
}