Compare commits

...

11 Commits

Author SHA1 Message Date
3ee9e0f4eb F2025-002 Per customer, remove the newly added Action Verbs from the PROMS ReplaceWords list. 2025-02-17 15:12:06 -05:00
d6c924a51f Merge pull request 'B2025-016 – Quick Print Shortcut Key' (#518) from B2025-016 into Development
good for testing phase
2025-02-17 08:41:17 -05:00
3a739c5b64 B2025-016 – Quick Print Shortcut Key
Found during Functional Testing:
Using "ALT R" shortcut key shows that Quick Print PDF & Create PDF both then have "P" as their shortcut. Kept Create PDF/Print as Ctrl-P. Changed Quick Print to be shortcut of Ctrl-Q.
2025-02-17 08:21:16 -05:00
3564f4ba8e Merge pull request 'C2024-038 PROMS – Summary of Changes report generation enhancements' (#517) from C2024-038 into Development
Good for testing phase
2025-02-14 15:21:08 -05:00
5ad9d81cc1 C2024-038 PROMS – Summary of Changes report generation enhancements
This is an upgrade item to add a method to exclude annotations and a way run the summary of changes report from a specific date.
2025-02-14 15:10:40 -05:00
0292634374 Merge pull request 'We are reverting back to the last DotNetBar install. We found issues on the developer side of maintaining the dialogs and forms in PROMS.' (#515) from OrgDotNetBar into Development
Software Development Environment update.  No source control document  needed.
2025-02-11 15:06:39 -05:00
d4418b8d8a We are reverting back to the last DotNetBar install. We found issues on the developer side of maintaining the dialogs and forms in PROMS. 2025-02-11 15:02:58 -05:00
a33f136e77 Merge pull request 'B2025-011-Global-search-is-not-finding-question-marks' (#514) from B2025-011-Global-search-is-not-finding-question-marks into Development
good for testing phase
2025-02-11 09:07:12 -05:00
f85f8e9e2c Merge pull request 'B2025-013 PROMS –Admin Tool Tree Behavior' (#513) from B2025-013 into Development
good for testing phase
2025-02-10 11:04:07 -05:00
4bfffc945a Merge remote-tracking branch 'origin/Development' into B2025-011-Global-search-is-not-finding-question-marks 2025-02-10 10:23:24 -05:00
16509c2eab B2025-011-Global-search-is-not-finding-question-marks 2025-02-09 22:44:01 -05:00
20 changed files with 152 additions and 21 deletions

View File

@@ -48,7 +48,7 @@
<ItemGroup>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -43,7 +43,7 @@
<ItemGroup>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>

View File

@@ -109,7 +109,7 @@
</Reference>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="Ionic.Zip, Version=1.9.1.8, Culture=neutral, PublicKeyToken=edbe51ad942a3f5c, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>

View File

@@ -194,6 +194,23 @@ namespace VEPROMS.CSLA.Library
public partial class AnnotationAuditInfoList
{
/// <summary>
/// C2024- 038 - Summary of Changes report generation enhancements
/// Constructor - takes a Generic list of AnnotationAuditInfo
/// and creates a AnnotationAuditInfoList
/// </summary>
public AnnotationAuditInfoList(List<AnnotationAuditInfo> lst)
{
IsReadOnly = false;
if (lst != null)
{
foreach (AnnotationAuditInfo itm in lst)
this.Add(itm);
}
IsReadOnly = true;
}
/// <summary>
/// Return a list of all AnnotationAuditInfo by ItemID.
/// </summary>
@@ -487,6 +504,23 @@ namespace VEPROMS.CSLA.Library
public partial class ContentAuditInfoList
{
/// <summary>
/// C2024- 038 - Summary of Changes report generation enhancements
/// Constructor - takes a Generic list of ContentAuditInfo
/// and creates a ContentAuditInfoList
/// </summary>
public ContentAuditInfoList(List<ContentAuditInfo> lst)
{
IsReadOnly = false;
if (lst != null)
{
foreach (ContentAuditInfo itm in lst)
this.Add(itm);
}
IsReadOnly = true;
}
/// <summary>
/// Return a list of all ContentAuditInfo by ContentID.
/// </summary>

View File

@@ -89,7 +89,7 @@
</Reference>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>

View File

@@ -66,7 +66,7 @@
<ItemGroup>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<Reference Include="EnvDTE80, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />

View File

@@ -10,6 +10,7 @@ using System.IO;
using System.Text.RegularExpressions;
using JR.Utils.GUI.Forms;
using Volian.Base.Library;
using System.Linq;
namespace Volian.Controls.Library
{
@@ -163,7 +164,7 @@ namespace Volian.Controls.Library
else
{
DateTime revDate;
if (!DateTime.TryParse(cfg.Print_RevDate, out revDate)) revDate = MyProcedureInfo.ChangeBarDate; // DateTime.Now;
if (!DateTime.TryParse(cfg.Print_RevDate, out revDate)) revDate = MyProcedureInfo.ChangeBarDate; // DateTime.Now;
SetRevDate(revDate);
//SetRevDate(DateTime.Parse(cfg.Print_RevDate));
}
@@ -263,7 +264,7 @@ namespace Volian.Controls.Library
{
AnnotationTypeInfo ati = AnnotationTypeInfo.Get(aai.TypeID);
// B2023-066: Crash when trying to access a deleted annotation type (added the ati==null check)
tn = annotationDeleted.Nodes.Add(ati==null?"Deleted Annotation Type":ati.Name);
tn = annotationDeleted.Nodes.Add(ati == null ? "Deleted Annotation Type" : ati.Name);
}
TreeNode cn = tn.Nodes.Add(aai.ListString());
cn.Tag = aai;
@@ -517,7 +518,7 @@ namespace Volian.Controls.Library
if (delC.Type >= 0 && delC.Type < 1000)
{
int indx = delC.Config.IndexOf("DelProcReason");
if (indx >= 0 && delC.Config.Length > indx+15) // 15 accounts for 'DelProcReason = "'
if (indx >= 0 && delC.Config.Length > indx + 15) // 15 accounts for 'DelProcReason = "'
{
string reason = delC.Config.Substring(indx + 15);
if (reason != null && reason.Length > 0)
@@ -529,7 +530,7 @@ namespace Volian.Controls.Library
}
}
}
TreeNode tnn = deletedItems.Nodes.Add(iai.ToString()+"; Reason: " + strR);
TreeNode tnn = deletedItems.Nodes.Add(iai.ToString() + "; Reason: " + strR);
tnn.Tag = iai;
#endregion
}
@@ -558,7 +559,7 @@ namespace Volian.Controls.Library
if (MyProcedureInfo == null)
{
this.ParentForm.Cursor = Cursors.Default;
btnViewSummaryReport.Enabled = btnViewChronologyReport.Enabled = lbChanges.Items.Count > 0;
btnViewSummaryReport.Enabled = btnViewChronologyReport.Enabled = cbSumExcludeAnn.Enabled = DT_SumAsOf.Enabled = lbChanges.Items.Count > 0;
return;
}
ContentAuditInfoList cail2;
@@ -586,7 +587,7 @@ namespace Volian.Controls.Library
// B2020-156: When procedure title is changed, it does not print in Summary/Chronolgy of changes.
// Need to only check the date (not the date/time) for some procedures, the original item was listed
// in the list box and should not be because some MyRevDate's did not have time included.
if (CompareDateOrDateTime(cai.DTS,MyRevDate) || cai.ActionWhen > MyRevDate)
if (CompareDateOrDateTime(cai.DTS, MyRevDate) || cai.ActionWhen > MyRevDate)
{
string itemTitle = FixPath(cai.Path);
lbChanges.Items.Add(cai);
@@ -614,7 +615,7 @@ namespace Volian.Controls.Library
}
//Console.WriteLine("WalkProcedure fini: {0} seconds", TimeSpan.FromTicks(DateTime.Now.Ticks - start.Ticks).TotalSeconds);
this.ParentForm.Cursor = Cursors.Default;
btnViewSummaryReport.Enabled = btnViewChronologyReport.Enabled = lbChanges.Items.Count > 0;
btnViewSummaryReport.Enabled = btnViewChronologyReport.Enabled = cbSumExcludeAnn.Enabled = DT_SumAsOf.Enabled = lbChanges.Items.Count > 0;
RefreshRequired = false;
return;
}
@@ -648,9 +649,73 @@ namespace Volian.Controls.Library
//_AnnotationList = AnnotationAuditInfoList.GetChronology(0, 0, MyProcedureInfo.ChangeBarDate);
//added setting selected slave in order for reports to replace unit number,etc jcb 20101010
MyItemInfo.MyProcedure.MyDocVersion.DocVersionConfig.SelectedSlave = ApplDisplayMode;
// OnSummaryPrintRequest(new DisplayHistoryReportEventArgs(Volian.Base.Library.VlnSettings.TemporaryFolder + @"\MySummary.pdf", MyItemInfo.MyProcedure, _SummaryAuditList, _AnnotationList));
OnSummaryPrintRequest(new DisplayHistoryReportEventArgs(string.Format(@"{0}\{1} Summary of Changes.pdf", Volian.Base.Library.VlnSettings.TemporaryFolder, MyItemInfo.MyProcedure.PDFNumber), MyItemInfo.MyProcedure, _SummaryAuditList, _AnnotationList));
//}
var dhr = new DisplayHistoryReportEventArgs(string.Format(@"{0}\{1} Summary of Changes.pdf", Volian.Base.Library.VlnSettings.TemporaryFolder, MyItemInfo.MyProcedure.PDFNumber), MyItemInfo.MyProcedure, null, null);
//C2024- 038 - Summary of Changes report generation enhancements
//check if need to modify
// _SummaryAuditList
if (DT_SumAsOf.Checked)
dhr.AuditList = FilterSummaryByDate(_SummaryAuditList, DT_SumAsOf.Value);
else
dhr.AuditList = _SummaryAuditList;
//C2024- 038 - Summary of Changes report generation enhancements
// if Exclude Annotations Checked
// send an empty list instead of
//_AnnotationList
if (cbSumExcludeAnn.Checked)
dhr.AnnotationList = new AnnotationAuditInfoList(null);
else if (DT_SumAsOf.Checked)
dhr.AnnotationList = FilterSummaryByDate_Annotations(_AnnotationList, DT_SumAsOf.Value);
else
{ dhr.AnnotationList = _AnnotationList; }
OnSummaryPrintRequest(dhr);
}
//C2024- 038 - Summary of Changes report generation enhancements
//modify _SummaryAuditList
//to limit to a specific date
private ContentAuditInfoList FilterSummaryByDate(ContentAuditInfoList summaryAuditList, DateTime value)
{
List<ContentAuditInfo> slst = summaryAuditList.Clone().ToList();
//Grab the first change to each item before the date and set that to the AsOf date
foreach (ContentAuditInfo firstbeforedate in slst.GroupBy(x => x.ItemID).Select(x => x.OrderByDescending(y => y.DTS).FirstOrDefault(d => d.DTS < value)))
{
if (firstbeforedate != null && firstbeforedate.ActionWhat != "Deleted")
{
firstbeforedate.ActionWhat = $"As Of: {value.ToShortDateString()}";
}
}
//remove all items before the date we are checking against
//note that for deleted - sometimes the DTS is not correct and
//need to use the ActionWhen
slst.RemoveAll(x => x.DTS < value && !x.ActionWhat.StartsWith("As Of:") && (x.ActionWhat != "Deleted" || (x.ActionWhen < x.DTS ? x.DTS : x.ActionWhen) < value));
//remove all items where first text matches the last text
//unless it was added after the date we are checking against
//or the last item is a deletion that occurred after
//the date we are checking against
var itms = slst.Select(x => x.ItemID).Distinct().ToList();
foreach (int itmID in itms)
{
ContentAuditInfo first = slst.Where(i => i.ItemID == itmID).OrderBy(y => y.DTS).FirstOrDefault();
ContentAuditInfo last = slst.Where(i => i.ItemID == itmID).OrderByDescending(y => y.DTS).FirstOrDefault();
if (first != null && last != null && first.DTS < value && (last.ActionWhat != "Deleted" || (last.ActionWhen < last.DTS ? last.DTS : last.ActionWhen) < value) && ItemInfo.ConvertToDisplayText(first.Text) == ItemInfo.ConvertToDisplayText(last.Text))
slst.RemoveAll(x => x.ItemID == itmID);
}
return new ContentAuditInfoList(slst);
}
//C2024- 038 - Summary of Changes report generation enhancements
//modify _SummaryAuditList
//to limit to a specific date
private AnnotationAuditInfoList FilterSummaryByDate_Annotations(AnnotationAuditInfoList annotationAuditList, DateTime value)
{
return new AnnotationAuditInfoList(annotationAuditList.Where(x => x.DTS >= value).ToList());
}
private void btnRefresh_Click(object sender, EventArgs e)
{
@@ -1060,7 +1125,7 @@ namespace Volian.Controls.Library
set { _AuditList = value; }
}
private AnnotationAuditInfoList _AnnotationList;
public AnnotationAuditInfoList AnnotationList
public AnnotationAuditInfoList AnnotationList
{
get { return _AnnotationList; }
set { _AnnotationList = value; }

View File

@@ -1699,6 +1699,8 @@ namespace Volian.Controls.Library
else lbSrchResultsIncTrans.DisplayMember = _DisplayMember;
if (_SearchResults != null)
{
// record count flag
bool reccnt = true;
// B2021-076: Proms search results are not presented in order when printed to PDF
// B2023-041 - backed out previous change as it was not needed and was preventing the sorting of search results text
if (cbSorted.Checked)
@@ -1713,11 +1715,37 @@ namespace Volian.Controls.Library
// B2021-076: Proms search results are not presented in order when printed to PDF
var sortedResults = _SearchResults.OrderBy(x => x.SearchDefaultSort).ToList();
// if searching for just a "?" remove all the special code matches and leaving only the true matches.
if (SearchString == "\\?")
{
string pat = @"\?";
Regex r = new Regex(pat, RegexOptions.IgnoreCase);
for (int i = 0; i < sortedResults.Count; i++)
{
Match m = r.Match(sortedResults[i].DisplayText);
if (m.Success)
{
continue;
}
else
{
sortedResults.Remove(sortedResults[i]);
i--;
}
}
grpPanSearchResults.Text = string.Format("Search Results Found: {0}", sortedResults.Count);
reccnt = false;
}
if (tabSearchTypes.SelectedTab != tabSearchTypes.Tabs[4]) lbSrchResults.DataSource = sortedResults;
else lbSrchResultsIncTrans.DataSource = sortedResults;
}
grpPanSearchResults.Text = string.Format("Search Results Found: {0}", _SearchResults.Count);
if (reccnt)
{
grpPanSearchResults.Text = string.Format("Search Results Found: {0}", _SearchResults.Count);
}
grpPanSearchResults.Style.BackColor = Color.LightGreen;// Color.YellowGreen; Color.DarkSeaGreen;
}
else
@@ -2076,6 +2104,7 @@ namespace Volian.Controls.Library
//TypesSelected = (typstr != null) ? "Searched Step Types: " + typstr : "Searched All Step Types";
//TypesSelected = "Searched Step Types: " + ((typstr != null) ? typstr : "All Step Types");
SearchResults = ItemInfoList.GetListFromTextSearch(DVISearchList, TypeSearchList, TextSearchString /*.Replace(@"\",@"\u9586?")*/, cbxBooleanTxtSrch.Checked ? 2 : cbxCaseSensitive.Checked ? 1 : 0, cbxIncROTextSrch.Checked ? ItemSearchIncludeLinks.Value : ItemSearchIncludeLinks.Nothing, includeRTFformat, includeSpecialChars, unitPrefix, byWordPrefix, byWordSuffix);
cmbResultsStyleIndex = 3; // display step text in results
//}
}

View File

@@ -95,7 +95,7 @@
</Reference>
<Reference Include="DevComponents.DotNetBar2, Version=14.1.0.37, Culture=neutral, PublicKeyToken=7eb7c3a35b91de04, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.8.1Build\DevComponents.DotNetBar2.dll</HintPath>
<HintPath>..\..\..\..\3rdPartyLibraries\DotNetBar\DotNetBar4.6Build\DevComponents.DotNetBar2.dll</HintPath>
</Reference>
<Reference Include="EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<SpecificVersion>False</SpecificVersion>
@@ -443,6 +443,9 @@
<DependentUpon>DisplayBookMarks.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="DisplayHistory.resx">
<DependentUpon>DisplayHistory.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="DisplayLibDocs.resx">
<DependentUpon>DisplayLibDocs.cs</DependentUpon>
<SubType>Designer</SubType>

View File

@@ -1090,7 +1090,7 @@ namespace Volian.Print.Library
firstCAI = null;
lastCAI = null;
}
else if (firstCAI.ActionWhat == lastCAI.ActionWhat)
else if (firstCAI.ActionWhat == lastCAI.ActionWhat || firstCAI.ActionWhat.StartsWith("As Of:"))
{
auditList1.Add(firstCAI);
auditList1.Add(lastCAI);
@@ -1153,7 +1153,7 @@ namespace Volian.Print.Library
firstCAI = null;
lastCAI = null;
}
else if (firstCAI.ActionWhat == lastCAI.ActionWhat)
else if (firstCAI.ActionWhat == lastCAI.ActionWhat || firstCAI.ActionWhat.StartsWith("As Of:"))
{
auditList1.Add(firstCAI);
auditList1.Add(lastCAI);