Added logic to create annotations for transitions to un-numbered steps
Moved code to extension
This commit is contained in:
parent
b7bea9a5f1
commit
45fc9edcd3
@ -108,6 +108,8 @@ namespace DataLoader
|
|||||||
{
|
{
|
||||||
Console.WriteLine("{0} {1}", ex.GetType().Name, ex.Message);
|
Console.WriteLine("{0} {1}", ex.GetType().Name, ex.Message);
|
||||||
}
|
}
|
||||||
|
// Added for transitions to un-numbered steps
|
||||||
|
if (tran.NewTransToUnNumberedItem) item.NewTransToUnNumberedItem = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (updatedText.EndsWith(" ")) updatedText = updatedText.Substring(0, updatedText.Length - 1);
|
if (updatedText.EndsWith(" ")) updatedText = updatedText.Substring(0, updatedText.Length - 1);
|
||||||
@ -129,12 +131,14 @@ namespace DataLoader
|
|||||||
c.Save();
|
c.Save();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// Added for transitions to un-numbered steps
|
||||||
if (item.NewTransToUnNumberedItem)
|
if (item.NewTransToUnNumberedItem)
|
||||||
{
|
{
|
||||||
using (Item itm = item.Get())
|
using (Item itm = item.Get())
|
||||||
{
|
{
|
||||||
ItemAnnotation ia = itm.ItemAnnotations.Add(VerificationRequiredType);
|
ItemAnnotation ia = itm.ItemAnnotations.Add(VerificationRequiredType);
|
||||||
ia.SearchText = "Transition to un-numbered step";
|
ia.SearchText = "Transition to un-numbered step";
|
||||||
|
ia.UserID = "Migration";
|
||||||
itm.Save();
|
itm.Save();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -166,10 +170,9 @@ namespace DataLoader
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
Status = "Done comparing";
|
Status = "Done comparing";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
// Added for transitions to un-numbered steps
|
||||||
private AnnotationType _VerificationRequiredType; // Using this to flag table to grid conversions
|
private AnnotationType _VerificationRequiredType; // Using this to flag table to grid conversions
|
||||||
|
|
||||||
public AnnotationType VerificationRequiredType
|
public AnnotationType VerificationRequiredType
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
|
@ -297,6 +297,12 @@ namespace VEPROMS.CSLA.Library
|
|||||||
#region ItemInfo
|
#region ItemInfo
|
||||||
public partial class ItemInfo:IVEDrillDownReadOnly
|
public partial class ItemInfo:IVEDrillDownReadOnly
|
||||||
{
|
{
|
||||||
|
private bool _NewTransToUnNumberedItem = false;
|
||||||
|
public bool NewTransToUnNumberedItem
|
||||||
|
{
|
||||||
|
get { return _NewTransToUnNumberedItem; }
|
||||||
|
set { _NewTransToUnNumberedItem = value; }
|
||||||
|
}
|
||||||
// put in for debugging
|
// put in for debugging
|
||||||
//public static int CacheCountPrimaryKey
|
//public static int CacheCountPrimaryKey
|
||||||
//{ get { return _CacheByPrimaryKey.Count; } }
|
//{ get { return _CacheByPrimaryKey.Count; } }
|
||||||
|
@ -10,6 +10,12 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
public partial class TransitionInfo
|
public partial class TransitionInfo
|
||||||
{
|
{
|
||||||
|
private bool _NewTransToUnNumberedItem = false;
|
||||||
|
public bool NewTransToUnNumberedItem
|
||||||
|
{
|
||||||
|
get { return _NewTransToUnNumberedItem; }
|
||||||
|
set { _NewTransToUnNumberedItem = value; }
|
||||||
|
}
|
||||||
public string PathTo
|
public string PathTo
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
@ -37,7 +43,10 @@ namespace VEPROMS.CSLA.Library
|
|||||||
//Console.WriteLine("TranType = {0}", TranType);
|
//Console.WriteLine("TranType = {0}", TranType);
|
||||||
//Console.WriteLine("MyItemToID = {0}", MyItemToID);
|
//Console.WriteLine("MyItemToID = {0}", MyItemToID);
|
||||||
//Console.WriteLine("MyItemRangeID = {0}", MyItemRangeID);
|
//Console.WriteLine("MyItemRangeID = {0}", MyItemRangeID);
|
||||||
return ResolvePathTo(item.ActiveFormat, item, TranType, MyItemToID, MyItemRangeID);
|
string retval = ResolvePathTo(item.ActiveFormat, item, TranType, MyItemToID, MyItemRangeID);
|
||||||
|
if (item.NewTransToUnNumberedItem)
|
||||||
|
NewTransToUnNumberedItem = true;
|
||||||
|
return retval;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#region AffectedTransitons
|
#region AffectedTransitons
|
||||||
@ -410,10 +419,10 @@ namespace VEPROMS.CSLA.Library
|
|||||||
if(_AppendMethods==null)
|
if(_AppendMethods==null)
|
||||||
SetupMethods();
|
SetupMethods();
|
||||||
string retval = BuildString(tb);
|
string retval = BuildString(tb);
|
||||||
|
// Added for transitions to un-numbered steps
|
||||||
if (retval == string.Empty)
|
if (retval == string.Empty)
|
||||||
{
|
{
|
||||||
retval = toItem.Ordinal.ToString();
|
retval = toItem.Ordinal.ToString();
|
||||||
if (fromInfo.MyContent.Text.Contains("<CTID="))
|
|
||||||
fromInfo.NewTransToUnNumberedItem = true;
|
fromInfo.NewTransToUnNumberedItem = true;
|
||||||
//Volian.Base.Library.vlnStackTrace.ShowStackLocal("Setting Flag", 3, 10);
|
//Volian.Base.Library.vlnStackTrace.ShowStackLocal("Setting Flag", 3, 10);
|
||||||
//using (Item itm = fromInfo.Get())
|
//using (Item itm = fromInfo.Get())
|
||||||
|
@ -27,12 +27,6 @@ namespace VEPROMS.CSLA.Library
|
|||||||
[TypeConverter(typeof(ItemInfoConverter))]
|
[TypeConverter(typeof(ItemInfoConverter))]
|
||||||
public partial class ItemInfo : ReadOnlyBase<ItemInfo>, IDisposable
|
public partial class ItemInfo : ReadOnlyBase<ItemInfo>, IDisposable
|
||||||
{
|
{
|
||||||
private bool _NewTransToUnNumberedItem = false;
|
|
||||||
public bool NewTransToUnNumberedItem
|
|
||||||
{
|
|
||||||
get { return _NewTransToUnNumberedItem; }
|
|
||||||
set { _NewTransToUnNumberedItem = value; }
|
|
||||||
}
|
|
||||||
public event ItemInfoEvent Changed;
|
public event ItemInfoEvent Changed;
|
||||||
private void OnChange()
|
private void OnChange()
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user