C2026-010 Add Audit History to Setting Change Bars
This commit is contained in:
@@ -56,7 +56,20 @@ namespace Volian.Controls.Library
|
||||
set
|
||||
{
|
||||
if (DesignMode) return; // B2019-043 need to check if we are just saving changes to the user interface
|
||||
if (value is ProcedureInfo && _MyProcedureInfo is ProcedureInfo && value.ItemID == _MyProcedureInfo.ItemID)
|
||||
|
||||
//CSM - C2026-010 - Set/Show Change Bar Audit History
|
||||
if (value != null)
|
||||
{
|
||||
lbChangeBarHistory.DataSource = ChangeBarAuditHistory.GetChangeBarAuditHistory(value.ItemID);
|
||||
lbChangeBarHistory.ValueMember = "AuditID";
|
||||
lbChangeBarHistory.DisplayMember = "Text";
|
||||
}
|
||||
else
|
||||
{
|
||||
lbChangeBarHistory.DataSource = null;
|
||||
}
|
||||
|
||||
if (value is ProcedureInfo && _MyProcedureInfo is ProcedureInfo && value.ItemID == _MyProcedureInfo.ItemID)
|
||||
return;
|
||||
_MyProcedureInfo = value;
|
||||
if (value == null) return;
|
||||
@@ -184,6 +197,15 @@ namespace Volian.Controls.Library
|
||||
InitializeComponent();
|
||||
myRTB.FormatFont = null;
|
||||
RefreshRequired = true;
|
||||
|
||||
if (MyProcedureInfo != null)
|
||||
{
|
||||
lbChangeBarHistory.DataSource = ChangeBarAuditHistory.GetChangeBarAuditHistory(MyProcedureInfo.ItemID);
|
||||
}
|
||||
else
|
||||
{
|
||||
lbChangeBarHistory.DataSource = null;
|
||||
}
|
||||
}
|
||||
|
||||
private void lbChanges_VisibleChanged(object sender, System.EventArgs e)
|
||||
@@ -1075,7 +1097,25 @@ namespace Volian.Controls.Library
|
||||
{
|
||||
tvAudits.Height = ((tcpDetail.Height - btnRestore.Height) / 4) * 3;
|
||||
}
|
||||
public void RefreshChangeList()
|
||||
|
||||
//CSM - C2026-010 - Set/Show Change Bar Audit History
|
||||
//Display a Tooltip for what was in the list
|
||||
private void LbChangeBarHistory_MouseMove(object sender, MouseEventArgs e)
|
||||
{
|
||||
// Just use the item's value for the tooltip.
|
||||
int index = lbChangeBarHistory.IndexFromPoint(e.Location);
|
||||
|
||||
if (index != ListBox.NoMatches)
|
||||
{
|
||||
DataRow rw = (lbChangeBarHistory.Items[index] as DataRowView)?.Row;
|
||||
|
||||
// Display the item's value as a tooltip.
|
||||
if (tipCBHistory.GetToolTip(lbChangeBarHistory) != rw["Text"].ToString())
|
||||
tipCBHistory.SetToolTip(lbChangeBarHistory, rw["Text"].ToString());
|
||||
}
|
||||
}
|
||||
|
||||
public void RefreshChangeList()
|
||||
{
|
||||
myTimer.Enabled = false;
|
||||
myTimer.Enabled = true;
|
||||
|
||||
BIN
PROMS/Volian.Controls.Library/DisplayHistory.designer.cs
generated
BIN
PROMS/Volian.Controls.Library/DisplayHistory.designer.cs
generated
Binary file not shown.
@@ -188,4 +188,7 @@
|
||||
<metadata name="myTimer.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="tipCBHistory.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>119, 17</value>
|
||||
</metadata>
|
||||
</root>
|
||||
Reference in New Issue
Block a user