Getting event after record creation (afterCreate not working here)
I have 2 tables
contacts
and contacts_profile
. I have a form to create a contact (and also fill in contact profile fields as well in that same form).
I want to perform something after contact creation.
I added afterCreate
in ContactCreate.php
but problem is that afterCreate
gets called before record get saved in contacts_profile
.
Is there any event/hook/anything which I can use to perform something after a resource's all data (including relationship tables) get saved?3 Replies
Maybe this can help you
https://github.com/chelout/laravel-relationship-events
GitHub
GitHub - chelout/laravel-relationship-events: Missing relationship ...
Missing relationship events for Laravel. Contribute to chelout/laravel-relationship-events development by creating an account on GitHub.
Thanks, I wil llook into it
thank you bro, you saved me