Merge remote-tracking branch 'origin/4.5' into 4.5-master-2015-02-24-17-24-05
[civicrm-core.git] / CRM / PCP / Form / Campaign.php
index d41a85154d72a1c89f1c3bb3b6331e2825fddf46..b84bae80aec248fded2363b6123037c96b23c999 100644 (file)
@@ -142,6 +142,9 @@ class CRM_PCP_Form_Campaign extends CRM_Core_Form {
     }
 
     $this->addElement('checkbox', 'is_active', ts('Active'));
+    if ($this->_context == 'dashboard') {
+      CRM_Core_Session::singleton()->pushUserContext(CRM_Utils_System::url('civicrm/admin/pcp', 'reset=1'));
+    }
 
     $this->addButtons(
       array(
@@ -191,7 +194,7 @@ class CRM_PCP_Form_Campaign extends CRM_Core_Form {
    */
   public function postProcess() {
     $params = $this->controller->exportValues($this->_name);
-    $checkBoxes = array('is_thermometer', 'is_honor_roll', 'is_active');
+    $checkBoxes = array('is_thermometer', 'is_honor_roll', 'is_active', 'is_notify');
 
     foreach ($checkBoxes as $key) {
       if (!isset($params[$key])) {