예제 #1
0
 /**
  * Redefine method to attach ics file to notification email
  */
 public function create_notification_email($notify_user)
 {
     $notify_mail = parent::create_notification_email($notify_user);
     $path = SugarConfig::getInstance()->get('upload_dir', 'upload/') . $this->id;
     require_once "modules/vCals/vCal.php";
     $content = vCal::get_ical_event($this, $GLOBALS['current_user']);
     if (file_put_contents($path, $content)) {
         $notify_mail->AddAttachment($path, 'meeting.ics', 'base64', 'text/calendar');
     }
     return $notify_mail;
 }
예제 #2
0
 /**
  * Redefine method to attach ics file to notification email
  */
 public function create_notification_email($notify_user)
 {
     // reset acceptance status for non organizer if date is changed
     if ($notify_user->id != $GLOBALS['current_user']->id && $this->date_changed) {
         $this->set_accept_status($notify_user, 'none');
     }
     $notify_mail = parent::create_notification_email($notify_user);
     $path = SugarConfig::getInstance()->get('upload_dir', 'upload/') . $this->id;
     require_once "modules/vCals/vCal.php";
     $content = vCal::get_ical_event($this, $GLOBALS['current_user']);
     if (file_put_contents($path, $content)) {
         $notify_mail->AddAttachment($path, 'meeting.ics', 'base64', 'text/calendar');
     }
     return $notify_mail;
 }