Skip to content

Track modified fields for ActiveRecord #124

@themightychris

Description

@themightychris
  • Create a new state property for ActiveRecord like originalValues called modifiedValues, but that gets cleared upon success save
  • Replace the use of originalValues with modifiedValues in isFieldDirty
  • Store the contents of modifiedValues into a function-scope variable at the top of save, and pass it to the afterRecordSave event (since it won't be available within the model instance anymore at that point)

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