* scheme. Adding weight is super important and should be done in the
* next week or so, before this can be called complete.
*
+ * @param string $contactType
+ * @param bool $status
+ *
* @return array array of importable Fields
* @access public
* @static
/**
* Delete the indirect records associated with this contribution first
*
- * @return $results no of deleted Contribution on success, false otherwise
- * @access public
+ * @param $id
+ *
+ * @return mixed|null $results no of deleted Contribution on success, false otherwise@access public
* @static
*/
static function deleteContribution($id) {
/**
* takes an associative array and creates a membership object
*
- * @param array $params (reference ) an assoc array of name/value pairs
- * @param array $ids the array that holds all the db ids
- * @param boolean $callFromAPI Is this function called from API?
+ * @param array $params (reference ) an assoc array of name/value pairs
+ * @param array $ids the array that holds all the db ids
+ * @param bool $skipRedirect
+ * @param string $activityType
+ *
+ * @throws CRM_Core_Exception
+ * @internal param bool $callFromAPI Is this function called from API?
*
* @return object CRM_Member_BAO_Membership object
* @access public
// CRM_Contact_BAO_Relationship::relatedMemberships()
if (isset($params['owner_membership_id'])) {
unset($params['max_related']);
- } else {
+ }
+ else {
// if membership allows related, default max_related to value in membership_type
if (!array_key_exists('max_related', $params) && !empty($params['membership_type_id'])) {
$membershipType = CRM_Member_BAO_MembershipType::getMembershipTypeDetails($params['membership_type_id']);
* full featured over a period of time. This is the inverse function of
* create. It also stores all the retrieved values in the default array
*
- * @param array $params (reference ) an assoc array of name/value pairs
+ * @param array $params (reference ) an assoc array of name/value pairs
* @param array $defaults (reference ) an assoc array to hold the name / value pairs
* in a hierarchical manner
- * @param array $ids (reference) the array that holds all the db ids
+ *
+ * @internal param array $ids (reference) the array that holds all the db ids
*
* @return object CRM_Member_BAO_Membership object
* @access public
* function to create memberships for related contacts
* takes into account the maximum related memberships
*
- * @param array $params array of key - value pairs
- * @param object $membership membership object
+ * @param array $params array of key - value pairs
+ * @param $dao
+ *
+ * @internal param object $membership membership object
*
* @return null|relatedMembership array of memberships if created
* @static
if (($params['status_id'] == $deceasedStatusId) || ($params['status_id'] == $expiredStatusId)) {
// related membership is not active so does not count towards maximum
CRM_Member_BAO_Membership::create($params, $relMemIds);
- } else {
+ }
+ else {
// related membership already exists, so this is just an update
if (isset($params['id'])) {
if ($available > 0) {
'is_current_member' => 0,
));
$tmp_statuses = $result['values'];
- $status_ids = array();
+ $status_ids = array();
foreach($tmp_statuses as $cur_stat) {
- $status_ids[] = $cur_stat['id'];
+ $status_ids[] = $cur_stat['id'];
}
if (empty($params['status_id']) || in_array( $params['status_id'] , $status_ids) == false) {
$errors['status_id'] = ts('Please enter a status that does NOT represent a current membership status.');
/**
* Function to send email receipt
*
- * @param object $form form object
- * @param array $values submitted values
+ * @param object $form form object
+ * @param $formValues
* @param object $membership object
*
+ * @internal param array $values submitted values
* @return boolean true if mail was sent successfully
* @static
*/
/** This test case doesn't require DB reset */
public $DBResetRequired = FALSE;
+ protected $_entity;
+
/* they are two types of missing APIs:
- Those that are to be implemented
(in some future version when someone steps in -hint hint-). List the entities in toBeImplemented[ {$action} ]
* sense for which entities support createTestObject
*
* @dataProvider entities_getlimit
- * @param string $entity
+ *
+ * @param $entityName
+ *
+ * @internal param string $entity
*/
function testLimit($entityName) {
$cases = array(); // each case is array(0 => $inputtedApiOptions, 1 => $expectedResultCount)
);
}
-/**
- * @param entityName
- */private function getMockableBAOObjects($entityName, $count = 2) {
+ /**
+ * @param $entityName
+ * @param int $count
+ *
+ * @internal param $entityName
+ *
+ * @return array
+ */
+ private function getMockableBAOObjects($entityName, $count = 2) {
$baoString = _civicrm_api3_get_DAO($entityName);
if (empty($baoString)) {
$this->markTestIncomplete("Entity [$entityName] cannot be mocked - no known DAO");