Beispiel #1
0
 /**
  * @param SJB_GuestAlert $guestAlert
  * @param SJB_TemplateProcessor $tp
  */
 public function saveNewGuestAlert(SJB_GuestAlert $guestAlert, SJB_TemplateProcessor $tp)
 {
     $guestAlert->addDataProperty(serialize($this->criteriaData));
     $guestAlert->addListingTypeIDProperty($this->listingTypeID);
     $guestAlert->save();
     $listingTypeSID = SJB_ListingTypeManager::getListingTypeSIDByID($this->listingTypeID);
     SJB_GuestAlertStatistics::saveEventSubscribed($listingTypeSID, $guestAlert->getSID());
     SJB_Notifications::sendConfirmationEmailForGuest($guestAlert);
     $tp->assign('email', $guestAlert->getAlertEmail());
     $this->template = 'alert_created.tpl';
 }