Add buttons to 'Cleanup caches and update paths' in standard way
[civicrm-core.git] / CRM / Admin / Form / Setting / Smtp.php
index fea23ddd2badbf7728b5628d86ed8d9aa50e3c28..cebf70c8ca4d739a60e2168019cdbaf6d5d0a77d 100644 (file)
@@ -36,6 +36,9 @@
  */
 class CRM_Admin_Form_Setting_Smtp extends CRM_Admin_Form_Setting {
   protected $_testButtonName;
+  protected $_settings = [
+    'allow_mail_from_logged_in_contact' => CRM_Core_BAO_Setting::DIRECTORY_PREFERENCES_NAME,
+  ];
 
   /**
    * Build the form object.
@@ -52,7 +55,6 @@ class CRM_Admin_Form_Setting_Smtp extends CRM_Admin_Form_Setting {
     $this->addRadio('outBound_option', ts('Select Mailer'), $outBoundOption);
 
     CRM_Utils_System::setTitle(ts('Settings - Outbound Mail'));
-    $this->add('checkbox', 'allow_mail_from_logged_in_contact', ts('Allow Mail to be sent from logged in contact\'s email address'));
     $this->add('text', 'sendmail_path', ts('Sendmail Path'));
     $this->add('text', 'sendmail_args', ts('Sendmail Argument'));
     $this->add('text', 'smtpServer', ts('SMTP Server'));