Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-9547

GroupContact doesn't understand group_id variable

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.0.8
    • Fix Version/s: 4.2.0
    • Component/s: CiviCRM API
    • Labels:
      None

      Description

      I'm using GroupContact to work out whether someone is a member of a group, e.g.

      http://sandbox.drupal.civicrm.org/civicrm/ajax/rest?json=1&debug=1&version=3&entity=GroupContact&action=get&group_id=2&contact_id=28 (I defined group_id=2&contact_id=28)

      I am expecting either 0 or 1 results i.e. yes they are in the group or no they aren't.

      But instead I get 2. I also don't get the contact_id in the result.

      In fact it looks like I am calling the wrong API here. It looks like it is calling Group, not GroupContact.

      When I do

      http://sandbox.drupal.civicrm.org/civicrm/ajax/rest?json=1&debug=1&version=3&entity=GroupContact&action=get&Group_id=2

      I get something that looks much more like what I would want.

        Attachments

          Activity

            People

            • Assignee:
              xavier xavier dutoit
              Reporter:
              michaelmcandrew Michael McAndrew
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: