I have problem with after save logic hook.
basically i have, relate fields with contact in opporuntiy and accounts
on account edit, when i click save,
following code logic hook will be used to save contact_id_c, contact_id1_c, contact_id2_c of opporunity
simillarly on opporuntiy edit, when i click save,Code:function set_contacts_details() { $this->opportunityObj->contact_id_c = $_REQUEST['contact_id_c']; $this->opportunityObj->contact_id1_c = $_REQUEST['contact_id1_c']; $this->opportunityObj->contact_id2_c = $_REQUEST['contact_id2_c']; $this->opportunityObj->save(); }
following code logic hook will be used to save contact_id_c, contact_id1_c, contact_id2_c of acocunt
But when I do save on any of account of opporunity save, this goes in infinite loop i,e, more than 100 nested calls and apache crashes / goes downCode:function set_contacts_details() { if (!empty($this->accountObj)) { $this->accountObj->contact_id_c = $_REQUEST['contact_id_c']; $this->accountObj->contact_id1_c = $_REQUEST['contact_id1_c']; $this->accountObj->contact_id2_c = $_REQUEST['contact_id2_c']; $this->accountObj->save(); } }
any one knows similar issue...what exactly to be done


LinkBack URL
About LinkBacks



Reply With Quote



Bookmarks