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

civicrm_membership_contact_get() does not respect 'is_test'

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Won't Fix
    • Affects Version/s: 3.1.5
    • Fix Version/s: 4.1.0
    • Component/s: CiviCRM API
    • Labels:
      None

      Description

      This code doesn't work. Test memberships are still returned.

      require_once('api/v2/Membership.php');
      $params = array(
      'contact_id' => $contactID,
      'is_test' => 0, //using 'member_is_test' doesn't work either
      );
      $allMemberships = civicrm_membership_contact_get($params);

      I'd suggest that the default behavior of the function should be to exclude test membership; this would be consistent with the UI behavior. i.e., a developer would have to explicity supply a param if test memberships are desired.

        Attachments

          Activity

            People

            • Assignee:
              eileen Eileen McNaughton
              Reporter:
              mchapman2000 Matt Chapman
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: