From 7b007e615f41faf27002999b09224c10d22ce289 Mon Sep 17 00:00:00 2001 From: yashodha Date: Tue, 29 Apr 2014 08:19:01 +0530 Subject: [PATCH] CRM-14418: fix scheduled reminder UI --- CRM/Admin/Form/ScheduleReminders.php | 1 + CRM/Core/BAO/ActionSchedule.php | 3 +-- templates/CRM/Admin/Form/ScheduleReminders.tpl | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CRM/Admin/Form/ScheduleReminders.php b/CRM/Admin/Form/ScheduleReminders.php index 1c5cbb67d2..cb962cf944 100644 --- a/CRM/Admin/Form/ScheduleReminders.php +++ b/CRM/Admin/Form/ScheduleReminders.php @@ -139,6 +139,7 @@ class CRM_Admin_Form_ScheduleReminders extends CRM_Admin_Form { $isActive = ts('Send email'); $recordActivity = ts('Record activity for automated email'); if ($providersCount) { + $this->assign('sms', $providersCount); $title = ts('Email or SMS'); $isActive = ts('Send email or SMS'); $recordActivity = ts('Record activity for automated email or SMS'); diff --git a/CRM/Core/BAO/ActionSchedule.php b/CRM/Core/BAO/ActionSchedule.php index 38b11b833d..17983d2ed3 100755 --- a/CRM/Core/BAO/ActionSchedule.php +++ b/CRM/Core/BAO/ActionSchedule.php @@ -282,7 +282,7 @@ class CRM_Core_BAO_ActionSchedule extends CRM_Core_DAO_ActionSchedule { * @access public */ static function &getList($namesOnly = FALSE, $entityValue = NULL, $id = NULL) { - $activity_type = CRM_Core_PseudoConstant::activityType(FALSE) + CRM_Core_PseudoConstant::activityType(FALSE, TRUE); + $activity_type = CRM_Core_PseudoConstant::activityType(TRUE, TRUE); $activity_status = CRM_Core_PseudoConstant::activityStatus(); $event_type = CRM_Event_PseudoConstant::eventType(); @@ -293,7 +293,6 @@ class CRM_Core_BAO_ActionSchedule extends CRM_Core_DAO_ActionSchedule { $auto_renew_options = CRM_Core_OptionGroup::values('auto_renew_options'); $civicrm_membership_type = CRM_Member_PseudoConstant::membershipType(); - asort($activity_type); $entity = array( 'civicrm_activity' => 'Activity', 'civicrm_participant' => 'Event', diff --git a/templates/CRM/Admin/Form/ScheduleReminders.tpl b/templates/CRM/Admin/Form/ScheduleReminders.tpl index 16fa99a19f..1ef667c393 100644 --- a/templates/CRM/Admin/Form/ScheduleReminders.tpl +++ b/templates/CRM/Admin/Form/ScheduleReminders.tpl @@ -112,7 +112,7 @@
{include file="CRM/Contact/Form/Task/EmailCommon.tpl" upload=1 noAttach=1}
-
{include file="CRM/Contact/Form/Task/SMSCommon.tpl" upload=1 noAttach=1}
+ {if $sms}
{include file="CRM/Contact/Form/Task/SMSCommon.tpl" upload=1 noAttach=1}
{/if} {include file="CRM/common/showHideByFieldValue.tpl" -- 2.25.1