AnsweredAssumed Answered

Execute a Query in Logic Hook

Question asked by sidhu sidhu on Feb 25, 2016
Latest reply on Feb 26, 2016 by Matt Marum

Hi  All

 

  I am having a requirement where i need to execute a query when the user creates a record.

 

Then when the user edits i need to execute one more query.

 

Can any one help me to achieve this using logic hook

 

In side a logic hook

class test{

function test(&$bean, $event, $arguments){

     if($bean->id !== $bean->fetched_row['id'])//when do we use this condition when creating a new record or updating

                    {}

 

     }

}

Outcomes