SugarCRM SOAP set_relationship between Contacts and Prospect lists bug

Posted by AntonioCS on Stack Overflow See other posts from Stack Overflow or by AntonioCS
Published on 2010-06-17T10:00:03Z Indexed on 2010/06/17 10:03 UTC
Read the original article Hit count: 503

Filed under:
|

Hey!

I am trying to create a relationship between a Prospect List (target list) and a Contact.

I create a new contact and get the id of a prospect list all using classes I created which are just wrappers for the soap api calls sugar provides. But the code boils down to this soap call:

$this->_sugarsoap->client->__soapCall('set_relationship', array($this->getSessionid(),$relationship));

$this->getSessionid() Is the session Id and $relationship is an array which holds this:

array
  0 => string 'ProspectLists' (length=13)
  1 => string '180ab1f5-cf7e-d386-50f8-4c18a790e016' (length=36)
  2 => string 'Contacts' (length=8)
  3 => string '76323942-8cbb-3224-f18a-4c19efa80a1b' (length=36)

After I try this I always get this error: (I do a var_dump of the returned values of the soap call)

object(stdClass)[5]
  public 'number' => string '20' (length=2)
  public 'name' => string 'Module Does Not Exist' (length=21)
  public 'description' => string 'This module is not available on this server' (length=43)

This seems like a sugarcrm bug because I do have the contacts module and also the prospect lists module. I know this for a fact because I add a contact via the soap call and also retrieve the id of a prospect list via the soap call.

I found this thread in the sugar forums and I did try the code given there but I still got the same error.

Anyone have a solution for this? I really need to associate a contact to a prospect list (target list) via a soap call.

I am using SugarCRM 5.5.0 (I also tried with sugarcrm 5.5.2 and got the same error) on ubuntu server using mysql.

Thanks!

© Stack Overflow or respective owner

Related posts about php

Related posts about sugarcrm