/**
  * Combine all the exportable fields from the lower level objects.
  *
  * @param bool $checkPermission
  *
  * @return array
  *   array of exportable Fields
  */
 public static function &exportableFields($checkPermission = TRUE)
 {
     if (!self::$_exportableFields) {
         if (!self::$_exportableFields) {
             self::$_exportableFields = array();
         }
         $participantFields = CRM_Event_DAO_Participant::export();
         $eventFields = CRM_Event_DAO_Event::export();
         $noteField = array('participant_note' => array('title' => 'Participant Note', 'name' => 'participant_note', 'type' => CRM_Utils_Type::T_STRING));
         $participantStatus = array('participant_status' => array('title' => 'Participant Status', 'name' => 'participant_status', 'type' => CRM_Utils_Type::T_STRING));
         $participantRole = array('participant_role' => array('title' => 'Participant Role', 'name' => 'participant_role', 'type' => CRM_Utils_Type::T_STRING));
         $discountFields = CRM_Core_DAO_Discount::export();
         $fields = array_merge($participantFields, $participantStatus, $participantRole, $eventFields, $noteField, $discountFields);
         // add custom data
         $fields = array_merge($fields, CRM_Core_BAO_CustomField::getFieldsForImport('Participant', FALSE, FALSE, FALSE, $checkPermission));
         self::$_exportableFields = $fields;
     }
     return self::$_exportableFields;
 }