Results 1 to 2 of 2

Thread: set_relationship via SOAP in 5.1

  1. #1
    josh.sweeney is offline Sugar Community Member
    Join Date
    Apr 2008
    Location
    Ga
    Posts
    339

    Default set_relationship via SOAP in 5.1

    In 5.0 the set_relationship was for many to many relationships. Now OOTB we supply relationships like one-to-many. I have been working on trying to set a one-to-many relationship via SOAP in 5.1 and have been unsuccessful.

    Scenario:
    I have a custom module called test_ContactCompany. Records in this module can be related to Contacts.

    Here is what I have tried so far.

    Setting the field during the set_entry call:
    Code:
    $set_entry_params = array(
    			'session'=>$sessionid,
    			'module_name'=>'test_ContactCompany',
    			'name_value_list'=>array(array('name'=>'name','value'=>"test soap call 7"),array('name'=>'callernumber','value'=>$callerNumber),array('name'=>'parent_id','value'=>$accountId),
    array('name'=>'parent_type','value'=>'Accounts'))
    		
    		);


    Settings the relationship with set_relationship:
    Code:
    		'set_relationship_values' => array(
    								'module1'=> 'test_ContactCompany',
    								'module1_id'=> $callId,
    								'module2' => 'Contact',
    								'module2_id'=> $contactId,
    								
    								)
    In this snippet I have also tried switching the modules around and tried contacts, contact, and Contacts


    Any suggestions?

  2. #2
    tuitai is offline Member
    Join Date
    Aug 2008
    Posts
    11

    Default Re: set_relationship via SOAP in 5.1

    I have the same problem, using SOAP to call set_relationship on Contacts and a custom module. Error says Module does not exist.

    have you found any workaround? Is the implementation to simply add a record in the relationshps database table (the one created by studio when the relationship was set?)
    Thanks,

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. SOAP login() - Invalid Username/Password.
    By dsandor in forum Developer Help
    Replies: 12
    Last Post: 2010-12-07, 09:13 AM
  2. nusoap vs. soap: which to use and why?
    By hanmari in forum General Discussion
    Replies: 6
    Last Post: 2008-05-12, 05:20 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •