Change Manager

This commit is contained in:
Rich
2011-08-01 20:16:23 +00:00
parent a38f0b0909
commit 14e3e15537
9 changed files with 1726 additions and 2 deletions

View File

@@ -179,10 +179,13 @@ namespace VEPROMS.CSLA.Library
}
}
}
public static event ItemInfoEvent ItemDeleted;
public event ItemInfoEvent Deleted;
internal void OnDeleted(object sender)
{
if (Deleted != null) Deleted(sender);
if (ItemDeleted != null) ItemDeleted(sender);
if (MyParent != null)
{
MyParent.OnChildrenDeleted(sender);
@@ -411,7 +414,10 @@ namespace VEPROMS.CSLA.Library
{
content.FixTransitionText(tran);
if (content.IsDirty)
{
content.DTS = DateTime.Now;
content.Save();
}
else // Update ContentInfo objects to reflect the change in the transition
ContentInfo.Refresh(content);
}
@@ -776,6 +782,7 @@ namespace VEPROMS.CSLA.Library
//Console.WriteLine("\r\n\r\n'Deleting Item {0}'\r\n{0}'Type ','ParentID','ParentUnique','ItemID','Unique'",itemID);
foreach (ItemInfo item in items)
{
item.IsDeleted = true;
item.OnDeleted(item);
item.DeleteItemInfoAndChildren(" ");
}