#2396 - LogicHook after assign
Hello jason, I have a new question for you (and this time i not manage yet to found a "hacky" solution).
Our project : - We have team close to the example (docs/securitysuite/example-of-a-typical-setup) - We have custom Case that are link with some Compensations - We have a Case custom EditView, that allow adding Compensations on a Case and, if you're a manager you can change the SecurityGroup associated with the Case.
I want the compensation have the same SecurityGroup and assigned_user than the Case. So how to handler the updates ? - In my custom view is quite easy : if i detect a change on a value, i just have to change the linked compensations - But my problem is about the Mass Assign on the ListView... Is it something like an "after_save" logic hook for Security Group update???
If not, how would you handle this case ?
Best regards,
8 years ago
Yes, you would want the after_relationship_add and after_relationship_delete logic hooks. Then you can detect when there is a change and do the same for Compensations. More info here: http://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_7.6/Logic_Hooks/Module_Hooks/after_relationship_delete/
Hope this helps!