當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CRM_Admin_Form_Setting類代碼示例

本文整理匯總了PHP中CRM_Admin_Form_Setting的典型用法代碼示例。如果您正苦於以下問題:PHP CRM_Admin_Form_Setting類的具體用法?PHP CRM_Admin_Form_Setting怎麽用?PHP CRM_Admin_Form_Setting使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了CRM_Admin_Form_Setting類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: buildQuickForm

 /**
  * Build the form object.
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Misc (Undelete, PDFs, Limits, Logging, Captcha, etc.)'));
     $this->assign('validTriggerPermission', CRM_Core_DAO::checkTriggerViewPermission(FALSE));
     $this->addFormRule(array('CRM_Admin_Form_Setting_Miscellaneous', 'formRule'), $this);
     parent::buildQuickForm();
     $this->addRule('checksum_timeout', ts('Value should be a positive number'), 'positiveInteger');
 }
開發者ID:nielosz,項目名稱:civicrm-core,代碼行數:11,代碼來源:Miscellaneous.php

示例2: buildQuickForm

 /**
  * Build the form object.
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - CiviMail'));
     $check = TRUE;
     // redirect to Administer Section After hitting either Save or Cancel button.
     $session = CRM_Core_Session::singleton();
     $session->pushUserContext(CRM_Utils_System::url('civicrm/admin', 'reset=1'));
     $this->addFormRule(array('CRM_Admin_Form_Setting_Mail', 'formRule'));
     parent::buildQuickForm($check);
 }
開發者ID:nielosz,項目名稱:civicrm-core,代碼行數:13,代碼來源:Mail.php

示例3: buildQuickForm

 /**
  * Build the form object.
  *
  * @return void
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Misc (Undelete, PDFs, Limits, Logging, Captcha, etc.)'));
     $this->assign('validTriggerPermission', CRM_Core_DAO::checkTriggerViewPermission(FALSE));
     $this->addElement('text', 'wkhtmltopdfPath', ts('Path to wkhtmltopdf executable'), array('size' => 64, 'maxlength' => 256));
     $this->addElement('text', 'recaptchaPublicKey', ts('Public Key'), array('size' => 64, 'maxlength' => 64));
     $this->addElement('text', 'recaptchaPrivateKey', ts('Private Key'), array('size' => 64, 'maxlength' => 64));
     $this->addElement('text', 'dashboardCacheTimeout', ts('Dashboard cache timeout'), array('size' => 3, 'maxlength' => 5));
     $this->addElement('text', 'recaptchaOptions', ts('Recaptcha Options'), array('size' => 64, 'maxlength' => 64));
     $this->addFormRule(array('CRM_Admin_Form_Setting_Miscellaneous', 'formRule'), $this);
     parent::buildQuickForm();
     $this->addRule('checksumTimeout', ts('Value should be a positive number'), 'positiveInteger');
 }
開發者ID:scardinius,項目名稱:civicrm-core-api-mailing,代碼行數:18,代碼來源:Miscellaneous.php

示例4: buildQuickForm

 /**
  * Function to build the form
  *
  * @return None
  * @access public
  */
 public function buildQuickForm()
 {
     $outBoundOption = array('0' => ts('SMTP'), '1' => ts('Sendmail'), '2' => ts('Disable Outbound Email'));
     $this->addRadio('outBound_option', ts('Select Mailer'), $outBoundOption);
     CRM_Utils_System::setTitle(ts('Settings - Outbound Mail'));
     $this->add('text', 'sendmail_path', ts('Sendmail Path'));
     $this->add('text', 'sendmail_args', ts('Sendmail Argument'));
     $this->add('text', 'smtpServer', ts('SMTP Server'));
     $this->add('text', 'smtpPort', ts('SMTP Port'));
     $this->addYesNo('smtpAuth', ts('Authentication?'));
     $this->addElement('text', 'smtpUsername', ts('SMTP Username'));
     $this->addElement('password', 'smtpPassword', ts('SMTP Password'));
     $this->_testButtonName = $this->getButtonName('refresh', 'test');
     $this->add('submit', $this->_testButtonName, ts('Save & Send Test Email'));
     $this->addFormRule(array('CRM_Admin_Form_Setting_Smtp', 'formRule'));
     parent::buildQuickForm();
 }
開發者ID:bhirsch,項目名稱:voipdev,代碼行數:23,代碼來源:Smtp.php

示例5: buildQuickForm

 /**
  * Function to build the form
  *
  * @return void
  * @access public
  */
 public function buildQuickForm()
 {
     $outBoundOption = array(CRM_Mailing_Config::OUTBOUND_OPTION_MAIL => ts('mail()'), CRM_Mailing_Config::OUTBOUND_OPTION_SMTP => ts('SMTP'), CRM_Mailing_Config::OUTBOUND_OPTION_SENDMAIL => ts('Sendmail'), CRM_Mailing_Config::OUTBOUND_OPTION_DISABLED => ts('Disable Outbound Email'), CRM_Mailing_Config::OUTBOUND_OPTION_REDIRECT_TO_DB => ts('Redirect to Database'));
     $this->addRadio('outBound_option', ts('Select Mailer'), $outBoundOption);
     CRM_Utils_System::setTitle(ts('Settings - Outbound Mail'));
     $this->add('text', 'sendmail_path', ts('Sendmail Path'));
     $this->add('text', 'sendmail_args', ts('Sendmail Argument'));
     $this->add('text', 'smtpServer', ts('SMTP Server'));
     $this->add('text', 'smtpPort', ts('SMTP Port'));
     $this->addYesNo('smtpAuth', ts('Authentication?'));
     $this->addElement('text', 'smtpUsername', ts('SMTP Username'));
     $this->addElement('password', 'smtpPassword', ts('SMTP Password'));
     $this->_testButtonName = $this->getButtonName('refresh', 'test');
     $this->add('submit', $this->_testButtonName, ts('Save & Send Test Email'));
     $this->addFormRule(array('CRM_Admin_Form_Setting_Smtp', 'formRule'));
     parent::buildQuickForm();
 }
開發者ID:archcidburnziso,項目名稱:civicrm-core,代碼行數:23,代碼來源:Smtp.php

示例6: buildQuickForm

 /**
  * Build the form object.
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Search Preferences'));
     // @todo remove the following adds in favour of setting via the settings array (above).
     $this->addYesNo('includeWildCardInName', ts('Automatic Wildcard'));
     $this->addYesNo('includeEmailInName', ts('Include Email'));
     $this->addYesNo('includeNickNameInName', ts('Include Nickname'));
     $this->addYesNo('includeAlphabeticalPager', ts('Include Alphabetical Pager'));
     $this->addYesNo('includeOrderByClause', ts('Include Order By Clause'));
     $this->addElement('text', 'smartGroupCacheTimeout', ts('Smart group cache timeout'), array('size' => 3, 'maxlength' => 5));
     $types = array('Contact', 'Individual', 'Organization', 'Household');
     $profiles = CRM_Core_BAO_UFGroup::getProfiles($types);
     $this->add('select', 'defaultSearchProfileID', ts('Default Contact Search Profile'), array('' => ts('- none -')) + $profiles, FALSE, array('class' => 'crm-select2 huge'));
     // Autocomplete for Contact Search (quick search etc.)
     $options = array(ts('Contact Name') => 1) + array_flip(CRM_Core_OptionGroup::values('contact_autocomplete_options', FALSE, FALSE, TRUE));
     $this->addCheckBox('autocompleteContactSearch', ts('Autocomplete Contact Search'), $options, NULL, NULL, NULL, NULL, array('  '));
     $element = $this->getElement('autocompleteContactSearch');
     $element->_elements[0]->_flagFrozen = TRUE;
     // Autocomplete for Contact Reference (custom fields)
     $optionsCR = array(ts('Contact Name') => 1) + array_flip(CRM_Core_OptionGroup::values('contact_reference_options', FALSE, FALSE, TRUE));
     $this->addCheckBox('autocompleteContactReference', ts('Contact Reference Options'), $optionsCR, NULL, NULL, NULL, NULL, array('  '));
     $element = $this->getElement('autocompleteContactReference');
     $element->_elements[0]->_flagFrozen = TRUE;
     parent::buildQuickForm();
 }
開發者ID:nganivet,項目名稱:civicrm-core,代碼行數:28,代碼來源:Search.php

示例7: buildQuickForm

 /**
  * Function to build the form
  *
  * @return void
  * @access public
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts(' Settings - Debugging and Error Handling '));
     if (CRM_Core_Config::singleton()->userSystem->supports_UF_Logging == '1') {
         $this->_settings['userFrameworkLogging'] = CRM_Core_BAO_Setting::DEVELOPER_PREFERENCES_NAME;
     }
     parent::buildQuickForm();
 }
開發者ID:prashantgajare,項目名稱:civicrm-core,代碼行數:14,代碼來源:Debugging.php

示例8: buildQuickForm

 /**
  * Function to build the form
  *
  * @return None
  * @access public
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Mapping Provider'));
     $map = CRM_Core_SelectValues::mapProvider();
     $this->addElement('select', 'mapProvider', ts('Map Provider'), array('' => '- select -') + $map);
     $this->add('text', 'mapAPIKey', ts('Provider Key'), null);
     parent::buildQuickForm();
 }
開發者ID:hampelm,項目名稱:Ginsberg-CiviDemo,代碼行數:14,代碼來源:Mapping.php

示例9: buildQuickForm

 /**
  * Function to build the form
  *
  * @return void
  * @access public
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Simple donate form'));
     $attributes = array('entity' => 'Contribution', 'field' => 'contribution_page_id', 'option_url' => NULL);
     $this->addSelect('simpleDonation', $attributes, TRUE);
     $this->addElement('checkbox', "ziptastic", ts('Is Ziptastic enabled?'));
     parent::buildQuickForm();
 }
開發者ID:rohankatkar,項目名稱:com.webaccessglobal.simpledonate,代碼行數:14,代碼來源:SimpleDonationSetting.php

示例10: setDefaultValues

 public function setDefaultValues()
 {
     $defaults = parent::setDefaultValues();
     $defaults['selected_profile'] = 'Default';
     $defaults['pdfinfo_path'] = CRM_Donrec_Logic_Settings::get('donrec_pdfinfo_path');
     $defaults['packet_size'] = CRM_Donrec_Logic_Settings::get('donrec_packet_size');
     return $defaults;
 }
開發者ID:systopia,項目名稱:de.systopia.donrec,代碼行數:8,代碼來源:DonrecSettings.php

示例11: buildQuickForm

 /**
  * Function to build the form
  *
  * @return None
  * @access public
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Miscellaneous'));
     $this->addYesNo('versionCheck', ts('Version Check & Statistics Reporting'));
     $this->addElement('text', 'maxAttachments', ts('Maximum Attachments'), array('size' => 2, 'maxlength' => 8));
     $this->addElement('text', 'recaptchaPublicKey', ts('Public Key'), array('size' => 64, 'maxlength' => 64));
     $this->addElement('text', 'recaptchaPrivateKey', ts('Private Key'), array('size' => 64, 'maxlength' => 64));
     parent::buildQuickForm();
 }
開發者ID:ksecor,項目名稱:civicrm,代碼行數:15,代碼來源:Miscellaneous.php

示例12: postProcess

 public function postProcess()
 {
     parent::postProcess();
     // handle logging
     // FIXME: do it only if the setting changed
     require_once 'CRM/Logging/Schema.php';
     $values = $this->exportValues();
     $logging = new CRM_Logging_Schema();
     $values['logging'] ? $logging->enableLogging() : $logging->disableLogging();
 }
開發者ID:hampelm,項目名稱:Ginsberg-CiviDemo,代碼行數:10,代碼來源:Miscellaneous.php

示例13: buildQuickForm

 /**
  * Build the form object.
  *
  * @return void
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Date'));
     $this->addElement('text', 'dateformatDatetime', ts('Complete Date and Time'));
     $this->addElement('text', 'dateformatFull', ts('Complete Date'));
     $this->addElement('text', 'dateformatPartial', ts('Month and Year'));
     $this->addElement('text', 'dateformatYear', ts('Year Only'));
     $this->addElement('text', 'dateformatTime', ts('Time Only'));
     parent::buildQuickForm();
 }
開發者ID:scardinius,項目名稱:civicrm-core-api-mailing,代碼行數:15,代碼來源:Date.php

示例14: buildQuickForm

 /**
  * Function to build the form
  *
  * @return None
  * @access public
  */
 public function buildQuickForm()
 {
     CRM_Utils_System::setTitle(ts('Settings - Mapping and Geocoding Providers'));
     $map = CRM_Core_SelectValues::mapProvider();
     $geo = CRM_Core_SelectValues::geoProvider();
     $this->addElement('select', 'mapProvider', ts('Mapping Provider'), array('' => '- select -') + $map, array('onChange' => 'showHideMapAPIkey( this.value );'));
     $this->add('text', 'mapAPIKey', ts('Map Provider Key'), NULL);
     $this->addElement('select', 'geoProvider', ts('Geocoding Provider'), array('' => '- select -') + $geo, array('onChange' => 'showHideGeoAPIkey( this.value );'));
     $this->add('text', 'geoAPIKey', ts('Geo Provider Key'), NULL);
     parent::buildQuickForm();
 }
開發者ID:peteainsworth,項目名稱:civicrm-4.2.9-drupal,代碼行數:17,代碼來源:Mapping.php

示例15: postProcess

 public function postProcess()
 {
     // if extensions url is set, lets clear session status messages to avoid
     // a potentially spurious message which might already have been set. This
     // is a bit hackish
     // CRM-10629
     $session = CRM_Core_Session::singleton();
     $session->getStatus(TRUE);
     parent::postProcess();
     parent::rebuildMenu();
 }
開發者ID:hguru,項目名稱:224Civi,代碼行數:11,代碼來源:Url.php


注:本文中的CRM_Admin_Form_Setting類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。