public function sendNotification()
    {
        if (($from = self::config()->get('mail_sender')) && empty($from)) {
            $from = Config::inst()->get('Email', 'admin_email');
        }

        if (($to = self::config()->get('mail_receiver')) && empty($to)) {
            $to = Config::inst()->get('Email', 'admin_email');
        }

        $email = new Email();
        $email->setSubject(_t(
            'NotificationMail.TITLE',
            'Nieuwe reservering voor {event}',
            null, array('event' => $this->Event()->Title)
        ));

        $email->setFrom($from);
        $email->setTo($to);
        $email->setTemplate('NotificationMail');
        $email->populateTemplate($this);
        $this->extend('updateNotificationMail', $email);
        return $email->send();
    }
public function sendNotification()
    {
        if (($from = self::config()->get('mail_sender')) && empty($from)) {
            $from = Config::inst()->get('Email', 'admin_email');
        }

        if (($to = self::config()->get('mail_receiver')) && empty($to)) {
            $to = Config::inst()->get('Email', 'admin_email');
        }

        $email = new Email();
        $email->setSubject(_t(
            'NotificationMail.TITLE',
            'Nieuwe reservering voor {event}',
            null, array('event' => $this->Event()->Title)
        ));

        $email->setFrom($from);
        $email->setTo($to);
        $email->setTemplate('NotificationMail');
        $email->populateTemplate($this);
        $this->extend('updateNotificationMail', $email);
        return $email->send();
    }
public function sendNotification ( ) { if ( ( $ from = self :: config ( ) -> get ( 'mail_sender' ) ) && empty ( $ from ) ) { $ from = Config :: inst ( ) -> get ( 'Email' , 'admin_email' ) ; } if ( ( $ to = self :: config ( ) -> get ( 'mail_receiver' ) ) && empty ( $ to ) ) { $ to = Config :: inst ( ) -> get ( 'Email' , 'admin_email' ) ; } $ email = new Email ( ) ; $ email -> setSubject ( _t ( 'NotificationMail.TITLE' , 'Nieuwe reservering voor {event}' , null , array ( 'event' => $ this -> Event ( ) -> Title ) ) ) ; $ email -> setFrom ( $ from ) ; $ email -> setTo ( $ to ) ; $ email -> setTemplate ( 'NotificationMail' ) ; $ email -> populateTemplate ( $ this ) ; $ this -> extend ( 'updateNotificationMail' , $ email ) ; return $ email -> send ( ) ; }
Send a booking notification to the ticket mail sender or the site admin
@return mixed
Send a booking notification to the ticket mail sender or the site admin