Trigger events when removing contacts (change linked custom entities)
Collapse
X
-
Contact -> afterRemove
foreach($memberships as $membership )
$membership->set(['deleted' => 1]) or removeFromDb. https://docs.espocrm.com/development...delete-from-db
Leave a comment:
-
Paid option would be Workflow...
Free option... not sure if it possible. You can change a field call "status" to "delete"; Status: Delete
using formula, but the record will still be there, it can't be automated delete. I suppose you can add in a visibility condition where most user can't see it except for certain group/admin... but the record will still be there!Leave a comment:
-
Trigger events when removing contacts (change linked custom entities)
First things first, Espo CRM is a wonderful CRM. Thanks to the custom modules it can configure to be much more than that... Wonderful.
I ran into an issue though that I hope someone can help me with.
I created a custom entity: Membership. Every contact can have one or more memberships. I would like to be able to update memberships to "deleted" whenever a contact is removed. How would I do that?Tags: None

Leave a comment: