From 0bc90828de5328495d7bf8a843674bd78dd799b7 Mon Sep 17 00:00:00 2001 From: Keith Morgan Date: Mon, 23 Jun 2014 15:18:56 -0500 Subject: [PATCH] Fixed and made consistent a few calls to CRM_Core_Session::setStatus(). --- CRM/Event/Form/Task/Delete.php | 11 ++++------- CRM/Grant/Form/Task/Update.php | 4 ++-- CRM/Pledge/Form/Task/Delete.php | 5 +---- 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/CRM/Event/Form/Task/Delete.php b/CRM/Event/Form/Task/Delete.php index 2f5286e679..69c3869a69 100644 --- a/CRM/Event/Form/Task/Delete.php +++ b/CRM/Event/Form/Task/Delete.php @@ -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:') . '
' . $participantLinks; } - CRM_Core_Session::setStatus($status); + foreach ($status as $text) { + CRM_Core_Session::setStatus($text, '', 'info'); + } } } diff --git a/CRM/Grant/Form/Task/Update.php b/CRM/Grant/Form/Task/Update.php index a27da62598..87d8ace324 100644 --- a/CRM/Grant/Form/Task/Update.php +++ b/CRM/Grant/Form/Task/Update.php @@ -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)); } } diff --git a/CRM/Pledge/Form/Task/Delete.php b/CRM/Pledge/Form/Task/Delete.php index 9d287f5011..8f2d8942d8 100644 --- a/CRM/Pledge/Form/Task/Delete.php +++ b/CRM/Pledge/Form/Task/Delete.php @@ -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'); } } -- 2.25.1