Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Discover field changed

Hi, i have a simple ask! How i can discover what field was changed in model class?

Thanks so much!



7.1k
Accepted
answer

You have to enable snapshots and then you can use methods like getChangedFields or hasChanged

https://docs.phalconphp.com/en/latest/reference/models.html#record-snapshots