static function sendBalanceInvoiceEmail($cutoff = 10) { $details = self::balanceDetails(); require_once 'SFS/Utils/Mail.php'; foreach ($details as $id => &$value) { if ($value['balanceDue'] < $cutoff) { continue; } // now send a message to the parents about what they did SFS_Utils_Mail::sendMailToParents($id, 'SFS/Mail/ExtendedCare/InvoiceSubject.tpl', 'SFS/Mail/ExtendedCare/InvoiceMessage.tpl', $value, null); } }
function sendConferenceEmail($activityID, $advisorID, $childID, $dateTime = null) { require_once 'SFS/Utils/Query.php'; $templateVars = array(); list($templateVars['advisorName'], $templateVars['advisorEmail']) = SFS_Utils_Query::getNameAndEmail($advisorID); if ($dateTime == null) { $dateTime = CRM_Core_DAO::getFieldValue('CRM_Activity_DAO_Activity', $activityID, 'activity_date_time'); } $templateVars['dateTime'] = CRM_Utils_Date::customFormat($dateTime, "%l:%M %P on %b %E%f"); // now send a message to the parents about what they did require_once 'SFS/Utils/Mail.php'; SFS_Utils_Mail::sendMailToParents($childID, 'SFS/Mail/Conference/Subject.tpl', 'SFS/Mail/Conference/Message.tpl', $templateVars); }