B2023-015 Added Print_ViewableStartingChangeBarDate will get date only if user overrode from context menu of the procedure – used in HasChanges in itemExt.cs
B2023-015 added check for user override of the date to start showing change bars. Logic needed to handle when printing Child procedures.
This commit is contained in:
@@ -3634,7 +3634,14 @@ namespace VEPROMS.CSLA.Library
|
||||
if (ii == null) return false; // when deleting a source step, this was causing a crash (null ii)
|
||||
return (ii.MyContent.DTS > MyProcedure.ChangeBarDate);
|
||||
}
|
||||
// if there is no override & return whether there was a change to the text.
|
||||
// B2023-015 When user sets PROMS to show changebars after a specific date, we store that in the procedure config to Print_ChangeBarDate
|
||||
// (ProcConfig.cs), but it actually get saved to "ChangeBarDate". Also when we get the value of Print_ChangeBarDate when processing a
|
||||
// Child (slave), it returns the ChangeBarDate of the child instead of the date set by the user (to show change bars after a specific
|
||||
// date). Print_ViewableAfterChangeBarDate was created to get only that user specified date, if it exists. If it does exist, we compare
|
||||
// that with the Content datetime, otherwise we proceed as before.
|
||||
DateTime? viewableStartingDateTime = (MyProcedure.MyConfig as ProcedureConfig).Print_ViewableStartingChangeBarDate;
|
||||
if (viewableStartingDateTime != null && viewableStartingDateTime > MyProcedure.ChangeBarDate)
|
||||
return (MyContent.DTS > viewableStartingDateTime);
|
||||
return (MyContent.DTS > MyProcedure.ChangeBarDate);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user