Hello.
Thanks to Dennis (DevExpress Support) , he give me info about GetPropertiesListForUpdateInsert in ticket T120279
I can exclude some fields by name (code below)
C#
C#public class UpdatedFieldsUnitOfWork : UnitOfWork {
public UpdatedFieldsUnitOfWork(IDataLayer dataLayer) : base(dataLayer) {}
protected override MemberInfoCollection GetPropertiesListForUpdateInsert(object theObject, bool isUpdate, bool addDelayedReference)
{
MemberInfoCollection result = new MemberInfoCollection(this.GetClassInfo(theObject));
foreach (XPMemberInfo mi in base.GetPropertiesListForUpdateInsert(theObject,
isUpdate,addDelayedReference))
{
// DON'T WORK: if (mi is ServiceField || mi.GetModified(theObject))
//WORK BELOW
if (mi is ServiceField || !(mi.Name == "fLastUser"))
result.Add(mi);
}
return result;
}
}
But I want to update only modified fields.
Trying to filter by
C#mi.GetModified(theObject)
But it always return False;
How can I filter it ?