Esempio n. 1
0
 /**
  * Build Registration Block.
  *
  * @param CRM_Core_Form $form
  *
  */
 public function buildRegistrationBlock(&$form)
 {
     $attributes = CRM_Core_DAO::getAttribute('CRM_Event_DAO_Event', 'intro_text') + array('class' => 'collapsed');
     $form->add('wysiwyg', 'intro_text', ts('Introductory Text'), $attributes);
     $form->add('wysiwyg', 'footer_text', ts('Footer Text'), $attributes);
     extract(self::getProfileSelectorTypes());
     //CRM-15427
     $form->addProfileSelector('custom_pre_id', ts('Include Profile') . '<br />' . ts('(top of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('custom_post_id', ts('Include Profile') . '<br />' . ts('(bottom of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('additional_custom_pre_id', ts('Profile for Additional Participants') . '<br />' . ts('(top of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('additional_custom_post_id', ts('Profile for Additional Participants') . '<br />' . ts('(bottom of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
 }
 /**
  * Build Registration Block.
  *
  * @param CRM_Core_Form $form
  *
  */
 public function buildRegistrationBlock(&$form)
 {
     $attributes = CRM_Core_DAO::getAttribute('CRM_Event_DAO_Event');
     $attributes['intro_text']['click_wysiwyg'] = TRUE;
     $form->addWysiwyg('intro_text', ts('Introductory Text'), $attributes['intro_text']);
     // FIXME: This hack forces height of editor to 175px. Need to modify QF classes for editors to allow passing
     // explicit height and width.
     $footerAttribs = array('rows' => 2, 'cols' => 40, 'click_wysiwyg' => TRUE);
     $form->addWysiwyg('footer_text', ts('Footer Text'), $footerAttribs);
     extract(self::getProfileSelectorTypes());
     //CRM-15427
     $form->addProfileSelector('custom_pre_id', ts('Include Profile') . '<br />' . ts('(top of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('custom_post_id', ts('Include Profile') . '<br />' . ts('(bottom of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('additional_custom_pre_id', ts('Profile for Additional Participants') . '<br />' . ts('(top of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
     $form->addProfileSelector('additional_custom_post_id', ts('Profile for Additional Participants') . '<br />' . ts('(bottom of page)'), $allowCoreTypes, $allowSubTypes, $profileEntities, TRUE);
 }