When approval is performed the change bars should be able to be refreshed. While they will not be refreshed in an open edit window, the properties are refreshed, so that if you close and re-open a procedure in the edit window, the change bars are refreshed to reflect the approval.

This commit is contained in:
Rich 2014-06-26 17:52:06 +00:00
parent c74dd9f7ac
commit 78384ce643

View File

@ -690,7 +690,8 @@ namespace VEPROMS.CSLA.Library
{ {
get get
{ {
SectionConfig scfg = (SectionConfig)ActiveSection.MyConfig; if (IsProcedure) return false;
SectionConfig scfg = ActiveSection.MyConfig as SectionConfig;
if (MyDocStyle.StructureStyle.Style == null || scfg == null) return false; if (MyDocStyle.StructureStyle.Style == null || scfg == null) return false;
bool PlacekeepOption = ((ActiveFormat.PlantFormat.FormatData.PurchaseOptions & E_PurchaseOptions.AutoPlacekeeper) == E_PurchaseOptions.AutoPlacekeeper) bool PlacekeepOption = ((ActiveFormat.PlantFormat.FormatData.PurchaseOptions & E_PurchaseOptions.AutoPlacekeeper) == E_PurchaseOptions.AutoPlacekeeper)
&& scfg.Section_Placekeeper.Equals("Y"); && scfg.Section_Placekeeper.Equals("Y");
@ -846,6 +847,8 @@ namespace VEPROMS.CSLA.Library
else if(item.IsRNOPart) else if(item.IsRNOPart)
{ {
level = (item.ActiveParent as ItemInfo).StepLevel + item.RNOLevel - item.ColumnMode; level = (item.ActiveParent as ItemInfo).StepLevel + item.RNOLevel - item.ColumnMode;
// RHM Change 20140522
//level = (item.ActiveParent as ItemInfo).StepLevel;// +item.RNOLevel - item.ColumnMode;
} }
return level; return level;
} }
@ -2259,7 +2262,7 @@ namespace VEPROMS.CSLA.Library
return false; // No Change ID - No Change Bar return false; // No Change ID - No Change Bar
if (sc.Step_CBOverride == null) if (sc.Step_CBOverride == null)
return chg; return chg;
return (sc.Step_CBOverride == "On"); return (sc.Step_CBOverride == "On");
} }
} }
public bool HasChanges public bool HasChanges
@ -3135,9 +3138,10 @@ namespace VEPROMS.CSLA.Library
} }
} }
} }
if ((MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_SkipOneStepLevel) == E_DocStructStyle.DSS_SkipOneStepLevel)
if (MyDocStyle != null && (MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_SkipOneStepLevel) == E_DocStructStyle.DSS_SkipOneStepLevel)
level++; level++;
if ((MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_SkipTwoStepLevels) == E_DocStructStyle.DSS_SkipTwoStepLevels && level == 0) if (MyDocStyle != null && (MyDocStyle.StructureStyle.Style & E_DocStructStyle.DSS_SkipTwoStepLevels) == E_DocStructStyle.DSS_SkipTwoStepLevels && level == 0)
level += 2; level += 2;
if (level < 0) level = 0; if (level < 0) level = 0;
return level; return level;
@ -4788,6 +4792,8 @@ namespace VEPROMS.CSLA.Library
{ {
base.RefreshFields(tmp); base.RefreshFields(tmp);
ExtensionRefreshFields(tmp); ExtensionRefreshFields(tmp);
_ChangeBarDate = null;
_ProcedureConfig = null;
} }
#if ItemWithContent #if ItemWithContent
public ProcedureInfo(SafeDataReader dr) : base(dr, true) { } public ProcedureInfo(SafeDataReader dr) : base(dr, true) { }