Skip to content

Does apply changes automatically set the Entity States of an Entity Object and its children? #231

Description

@adrianpzamora

Hello,

I am trying to implement audit fields in my system by using the DBContext ChangeTracker, getting the list of "Added" and "Modified" entities, and setting the audit fields appropriately. In my Put request function I am calling DbContext.applychanges(object). My assumption is that this will automatically set the entity states of the object and its children. However, it does not seem like it is doing that as the object's state remains "Unchanged" even when I change one of the values of the object or its children. Do I have a fundamental flaw in my understanding of this? Any help would be appreciated.

Thank you

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions