Hello , I am working on a project with mongoDB. One of the fields of my collections is called locked_props and is of type [string] in which I want to store the names of the fields that are updated from forest.
Is there any possibility to achieve this?
For example I have my Users collection in which the fields are First name, Last name, Email and Locked_props. If in forest I update the name, for example I change from usr1 to user1, I would like to add to the locked_props field “name”.
Is there any way to achieve this?
thank you for your help!
Thank you!
I think it was using hooks, but the problem is that is not working because i wanna use when i update a field and as its says on the documentation: *Pre and post ‘save()’ hooks are not executed on update(), findOneAndUpdate(), etc.
Is there any other posibility to achive the objective?