Skip to content

Commit

Permalink
Merge pull request #15120 from mattwire/apimembershiptype_defaultdomain
Browse files Browse the repository at this point in the history
Add default domain to membershiptype API
  • Loading branch information
eileenmcnaughton authored Aug 23, 2019
2 parents 938ed56 + 5d449aa commit 4dedb6d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions api/v3/MembershipType.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,18 @@ function civicrm_api3_membership_type_get($params) {
return $results;
}

/**
* Adjust Metadata for Get action.
*
* The metadata is used for setting defaults, documentation & validation.
*
* @param array $params
* Array of parameters determined by getfields.
*/
function _civicrm_api3_membership_type_get_spec(&$params) {
$params['domain_id']['api.default'] = CRM_Core_Config::domainID();
}

/**
* Adjust input for getlist action.
*
Expand Down

0 comments on commit 4dedb6d

Please sign in to comment.