C2021-027: Procedure level PC/PC
This commit is contained in:
@@ -987,7 +987,10 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
set
|
||||
{
|
||||
_Xp["MasterSlave", "Applicability"] = value.FlagList;
|
||||
if (value != null)
|
||||
_Xp["MasterSlave", "Applicability"] = value.FlagList;
|
||||
else
|
||||
_Xp["MasterSlave", "Applicability"] = null;
|
||||
OnPropertyChanged("MasterSlave_Applicability");
|
||||
}
|
||||
}
|
||||
|
@@ -2740,7 +2740,11 @@ namespace VEPROMS.CSLA.Library
|
||||
return true;
|
||||
ItemInfo parent = this.ActiveParent as ItemInfo;
|
||||
IItemConfig cfg = this.MyConfig as IItemConfig;
|
||||
return (this.IsProcedure || parent.IsApplicable(apple)) && (cfg.MasterSlave_Applicability.GetFlags().Count == 0 || cfg.MasterSlave_Applicability.GetFlags().Contains(apple));
|
||||
if (IsProcedure) // C2021-027: Procedure level PC/PC. if procedure, don't go to parent.
|
||||
{
|
||||
return (cfg.MasterSlave_Applicability.GetFlags().Count == 0 || cfg.MasterSlave_Applicability.GetFlags().Contains(apple));
|
||||
}
|
||||
return (parent.IsApplicable(apple)) && (cfg.MasterSlave_Applicability.GetFlags().Count == 0 || cfg.MasterSlave_Applicability.GetFlags().Contains(apple));
|
||||
}
|
||||
//end jcb added inherited applicability
|
||||
public string FormattedDisplayText
|
||||
@@ -5282,6 +5286,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
if (_SectionCheckOffHeader == null)
|
||||
{
|
||||
if (ActiveSection == null) return _SectionCheckOffHeader;
|
||||
// first check if format has checkoff data, including checkoffheaders.
|
||||
ProcData pd = ActiveFormat.PlantFormat.FormatData.ProcData;
|
||||
if (pd.CheckOffData == null || pd.CheckOffData.CheckOffHeaderList == null || pd.CheckOffData.CheckOffHeaderList.MaxIndex <= 1) _SectionCheckOffHeader = string.Empty;
|
||||
@@ -6906,6 +6911,34 @@ namespace VEPROMS.CSLA.Library
|
||||
[Serializable()]
|
||||
public partial class ProcedureInfo : ItemInfo, IVEDrillDownReadOnly
|
||||
{
|
||||
// C2021-027: Procedure level PC/PC. these 2 methods determine whether a procedure is included, either by an integer index
|
||||
// or by a string name of the unit
|
||||
public bool ApplInclude(int ApplicabilityIndex)
|
||||
{
|
||||
if (ActiveFormat.PlantFormat.FormatData.ProcData.ProcAppl)
|
||||
{
|
||||
ProcedureConfig cfg = MyConfig as ProcedureConfig;
|
||||
return (cfg.MasterSlave_Applicability.GetFlags().Count == 0 || cfg.MasterSlave_Applicability.GetFlags().Contains(ApplicabilityIndex));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
public bool ApplIncludeFromStr(string s)
|
||||
{
|
||||
// s is the unitname, find this name in list of applicabilities & then see if this one is used
|
||||
if (ActiveFormat.PlantFormat.FormatData.ProcData.ProcAppl)
|
||||
{
|
||||
// get index
|
||||
int i = 1;
|
||||
foreach (string str in MyDocVersion.UnitNames)
|
||||
{
|
||||
if (str == s) break;
|
||||
i++;
|
||||
}
|
||||
ProcedureConfig cfg = MyConfig as ProcedureConfig;
|
||||
return (cfg.MasterSlave_Applicability.GetFlags().Count == 0 || cfg.MasterSlave_Applicability.GetFlags().Contains(i));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
private bool? _ProcHasSupInfoData = null;
|
||||
public bool ProcHasSupInfoData
|
||||
{
|
||||
|
@@ -1395,6 +1395,14 @@ namespace VEPROMS.CSLA.Library
|
||||
return LazyLoad(ref _NotesToFootnotes, "@NotesToFootnotes");
|
||||
}
|
||||
}
|
||||
private LazyLoad<bool> _ProcAppl;
|
||||
public bool ProcAppl // C2021-027: Procedure level PC/PC
|
||||
{
|
||||
get
|
||||
{
|
||||
return LazyLoad(ref _ProcAppl, "@ProcAppl");
|
||||
}
|
||||
}
|
||||
private LazyLoad<bool> _CountFoldoutPages;
|
||||
public bool CountFoldoutPages
|
||||
{
|
||||
|
Reference in New Issue
Block a user