Fixed and made consistent a few calls to CRM_Core_Session::setStatus().
authorKeith Morgan <keith@wellebee.com>
Mon, 23 Jun 2014 20:18:56 +0000 (15:18 -0500)
committerKeith Morgan <keith@wellebee.com>
Mon, 23 Jun 2014 20:18:56 +0000 (15:18 -0500)
CRM/Event/Form/Task/Delete.php
CRM/Grant/Form/Task/Update.php
CRM/Pledge/Form/Task/Delete.php

index 2f5286e6793142b8d02734c1c218d144893949c6..69c3869a69846f10c8c519629a4f6a4f6d7dbb57 100644 (file)
@@ -126,16 +126,13 @@ class CRM_Event_Form_Task_Delete extends CRM_Event_Form_Task {
       $deletedParticipants += $additionalCount;
     }
 
-    $status = array(
-      ts('Participant(s) Deleted: %1', array(1 => $deletedParticipants)),
-      ts('Total Selected Participant(s): %1', array(1 => $deletedParticipants)),
-    );
-
-
+    $status = array(ts('Participant(s) Deleted: %1 (Total Selected: %2)', array(1 => $deletedParticipants, 2 => count($this->_participantIds))));
     if (!empty($participantLinks)) {
       $status[] = ts('The following participants no longer have an event fee recorded. You can edit their registration and record a replacement contribution by clicking the links below:') . '<br>' . $participantLinks;
     }
-    CRM_Core_Session::setStatus($status);
+    foreach ($status as $text) {
+      CRM_Core_Session::setStatus($text, '', 'info');
+    }
   }
 }
 
index a27da6259835c0891e313ee657216f680cc31cc6..87d8ace324e0c4bcb2f74007e57d747b17e6f048 100644 (file)
@@ -108,8 +108,8 @@ class CRM_Grant_Form_Task_Update extends CRM_Grant_Form_Task {
       }
     }
 
-    CRM_Core_Session::setStatus(ts('Updated Grant(s): %1', array(1 => $updatedGrants)), '', 'info');
-    CRM_Core_Session::setStatus(ts('Total Selected Grant(s): %1', array(1 => count($this->_grantIds))), '', 'info');
+    $status = ts('Updated Grant(s): %1 (Total Selected: %2)', array(1 => $updatedGrants, 2 => count($this->_grantIds)));
+    CRM_Core_Session::setStatus($status, '', 'info');
     CRM_Utils_System::redirect(CRM_Utils_System::url('civicrm/grant/search', 'force=1&qfKey=' . $qfKey));
   }
 }
index 9d287f5011661721e388abdcabdb6f589101edd5..8f2d8942d8060a9e106fb3b90279983307cc7f7c 100644 (file)
@@ -87,10 +87,7 @@ class CRM_Pledge_Form_Task_Delete extends CRM_Pledge_Form_Task {
       }
     }
 
-    $status = array(
-      ts('Deleted Pledge(s): %1', array(1 => $deletedPledges)),
-      ts('Total Selected Pledge(s): %1', array(1 => count($this->_pledgeIds))),
-    );
+    $status = ts('Deleted Pledge(s): %1 (Total Selected: %2) ', array(1 => $deletedPledges, 2 => count($this->_pledgeIds)));
     CRM_Core_Session::setStatus($status, '', 'info');
   }
 }