Merge pull request #4627 from colemanw/docblocks
[civicrm-core.git] / CRM / Campaign / Form / Task / Reserve.php
index ff519ce89e96d5ec7f23d2af6358a1d83143ea4c..f56416c21ee862cdc0201b2bc206c2ff90510fb6 100644 (file)
@@ -153,7 +153,7 @@ class CRM_Campaign_Form_Task_Reserve extends CRM_Campaign_Form_Task {
   }
 
   /**
-   * Build the form
+   * Build the form object
    *
    * @access public
    *
@@ -164,12 +164,12 @@ class CRM_Campaign_Form_Task_Reserve extends CRM_Campaign_Form_Task {
     $this->addElement('text', 'ActivityType', ts('Activity Type'));
     $this->addElement('text', 'newGroupName', ts('Name for new group'));
     $this->addElement('text', 'newGroupDesc', ts('Description of new group'));
-    $groups = CRM_Core_PseudoConstant::group();
+    $groups = CRM_Core_PseudoConstant::nestedGroup();
     $hasExistingGroups = FALSE;
     if (is_array($groups) && !empty($groups)) {
       $hasExistingGroups = TRUE;
       $this->addElement('select', 'groups', ts('Add respondent(s) to existing group(s)'),
-        $groups, array('multiple' => "multiple", 'size' => 5)
+        $groups, array('multiple' => "multiple", 'class' => 'crm-select2')
       );
     }
     $this->assign('hasExistingGroups', $hasExistingGroups);
@@ -303,6 +303,11 @@ class CRM_Campaign_Form_Task_Reserve extends CRM_Campaign_Form_Task {
     }
   }
 
+  /**
+   * @param $contactIds
+   *
+   * @return array
+   */
   private function _addRespondentToGroup($contactIds) {
     $groupAdditions = array();
     if (empty($contactIds)) {