• BeanFactory::getBean not returning existing record in SugarCRM custom code

    I have a SugarCRM integration. It has the following line in the code $beanToSync = BeanFactory::getBean($moduleToCheck, $beanToSync->id); In $moduleToCheck the module 'Leads' is passed and $beanToSync->id have an ID of an existing Lead in SUgarCRM…
  • After fetch related beans and update some fields and fetch again gives old records

    in_customer_bean = BeanFactory :: getBean ( "IN_Customers" , $customer_id ); if ( $in_customer_bean -> load_relationship ( 'in_locations' )) { $relatedBeans = $in_customer_bean -> in_locations -> getBeans (); foreach( $relatedBeans as key => $value )…