Details
-
Type: Improvement
-
Status: Done/Fixed
-
Priority: Minor
-
Resolution: Won't Fix
-
Affects Version/s: 3.1, 3.1.1, 3.1.2, 3.1.3, 3.1.4, 3.1.5, 3.1.6, 3.2, 3.2.1, 3.2.2
-
Fix Version/s: Unscheduled
-
Component/s: CiviCRM API
-
Labels:None
Description
Can you please add the following to api/Contribution.php so that we can easily grab contribution types:
/**
- Get all the contribution types
- @return $contributionType Array of contribution types
- @access public
*/
function civicrm_contribution_type_get( ) {
$contributionType = array();
require_once 'CRM/Contribute/DAO/ContributionType.php';
$dao =& new CRM_Contribute_DAO_ContributionType();
$dao->orderBy('name');
$dao->find();
while ($dao->fetch())
{ $contributionType[$dao->id] = array(); CRM_Core_DAO::storeValues( $dao, $contributionType[$dao->id]); } return $contributionType;
}