Beispiel #1
0
 /**
  * @param SJB_GuestAlert $guestAlert
  * @throws Exception
  */
 public function activate(SJB_GuestAlert $guestAlert)
 {
     if ($guestAlert->getPropertyValue('status') === SJB_GuestAlert::STATUS_UNSUBSCRIBED) {
         throw new Exception('Unsubscribed Guest Alert can not be activated');
     }
     $guestAlert->setStatusActive();
     $guestAlert->update();
 }