示例#1
0
 private void Obj_PropertyChanged(object sender, PropertyChangedEventArgs e)
 {
     if (e.PropertyName == string.Empty)
     {
         this.Fields = DiffUtility.GetFields(this.Item);
     }
 }
示例#2
0
            public ItemInfo(object dataItem, object destItem)
            {
                this.Item     = dataItem;
                this.destItem = destItem;
                this.Fields   = DiffUtility.GetFields(destItem);

                var dataChildItems = new List <object>();
                var destChildItems = new List <object>();

                foreach (var item in DiffUtility.GetChilds(dataItem))
                {
                    dataChildItems.Add(item);
                }
                foreach (var item in DiffUtility.GetChilds(destItem))
                {
                    destChildItems.Add(item);
                }

                var query = from dataChild in dataChildItems
                            join destChild in destChildItems
                            on $"{DiffUtility.GetListName(dataChild)}{DiffUtility.GetItemKey(dataChild)}"
                            equals $"{DiffUtility.GetListName(destChild)}{DiffUtility.GetItemKey(destChild)}"
                            select new { DataItem = dataChild, DestItem = destChild };

                foreach (var item in query)
                {
                    this.childList.Add(new ItemInfo(item.DataItem, item.DestItem));
                }
            }
示例#3
0
            public ItemInfo(object dataItem)
            {
                this.dataItem = dataItem;
                this.fields   = DiffUtility.GetFields(dataItem);

                foreach (var item in DiffUtility.GetChilds(dataItem))
                {
                    this.childList.Add(new ItemInfo(item));
                }
            }