Delete Child entities if parent record deleted using end point.

How can I delete child entities using end point ,  If I delete parent record (via end point ) in sugarcrm?

delete child parent endpoints

Parents Reply
  • Let me start by saying that I do not normally recommendation deletion of records. It is often more useful to mark them as Inactive so user can see still the history.

    Depends upon your actual business use case, there are a few options but all will require coding:

    1) Create a custom API end point for this. 

    2) Use a logic hook on the parent module that will perform the clean up on a before_delete/after_delete event. 

    3) Use a custom job/scheduler task to do this on a regular basis.

Children