C2016-007 and B2016-097 – Update ProcStep data every time (Westinghouse CPS)

This commit is contained in:
John Jenko 2016-04-20 15:47:28 +00:00
parent a118715c77
commit 71927ea398

View File

@ -27,9 +27,9 @@ namespace Volian.Controls.Library
get { return _ProcItem; } get { return _ProcItem; }
set set
{ {
if (_ProcItem == value) return; //if (_ProcItem == value) return; // Jeff (Westinghouse) requested list to be provided every time fixes both C2016-007 and B2016-097
_ProcItem = value; _ProcItem = value;
CreateProcList(); if (ExeType > 0) CreateProcList();
} }
} }
@ -95,7 +95,7 @@ namespace Volian.Controls.Library
_CurrentItem = value; _CurrentItem = value;
SetupCurrentItemValues(); SetupCurrentItemValues();
SetupConfigEdit(); SetupConfigEdit();
if (_ExeType > 0) SendPromsAnnotationData(); if (ExeType > 0) SendPromsAnnotationData();
} }
} }
private int _FromType; private int _FromType;
@ -116,10 +116,21 @@ namespace Volian.Controls.Library
if (ii == null) return null; if (ii == null) return null;
if (ii.ItemAnnotationCount == 0) return null; if (ii.ItemAnnotationCount == 0) return null;
foreach (AnnotationInfo ai in ii.ItemAnnotations) foreach (AnnotationInfo ai in ii.ItemAnnotations)
if (ai.TypeID == _ExeType) return ai; if (ai.TypeID == ExeType) return ai;
return null; return null;
} }
private void SetupConfigEdit() private void SetupConfigEdit()
{
if (ExeType == 0) ; // initialize ExeType
}
private string _ExePath;
private string _PipeOut;
private string _PipeIn;
// Made _ExeType a lazy load to fix Jeff's (Westinghouse) request that ProcStep data be generated every time - fixes both C2016-007 and B2016-097
private int _ExeType = 0;
public int ExeType
{
get
{ {
if (_ExeType == 0) if (_ExeType == 0)
{ {
@ -139,11 +150,9 @@ namespace Volian.Controls.Library
} }
} }
} }
return _ExeType;
}
} }
private string _ExePath;
private string _PipeOut;
private string _PipeIn;
private int _ExeType=0;
private DisplaySearch _AnnotationSearch; private DisplaySearch _AnnotationSearch;
private AnnotationInfoList _Annotations; private AnnotationInfoList _Annotations;
@ -497,7 +506,7 @@ namespace Volian.Controls.Library
{ {
using(Item myItem = Item.Get(itemID )) using(Item myItem = Item.Get(itemID ))
{ {
using (AnnotationType myType = AnnotationType.Get(_ExeType)) using (AnnotationType myType = AnnotationType.Get(ExeType))
{ {
using (Annotation annotation = Annotation.MakeAnnotation(myItem, myType,null, "New",config)) using (Annotation annotation = Annotation.MakeAnnotation(myItem, myType,null, "New",config))
{ {