Is it possible to pass information from one hook to another? I often need to know what changed with a record, but I can't know exactly until the afterSave hook triggers. By then, the information I needed from the beforeSave hook is gone. Is it possible to pass an array from one hook to another?
Passing information from beforeSave to afterSave
Collapse
X
-
Create a non-storable field in your entity and use it to pass the information.
Or just create two methods in the entity class: setMyData(array $data), getMyData(): array.If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.
Comment