Exemplo n.º 1
0
 function back()
 {
     UserDataService::removeLastRoom();
     $userData = UserDataService::getUserData();
     if ($userData->hotelId > 0) {
         $hotel = HotelService::getHotel($userData->hotelId);
         $link = JHotelUtil::getHotelLink($hotel);
     } else {
         $link = JRoute::_('index.php?option=com_jhotelreservation&task=excursionslisting.searchExcursions', false);
         UserDataService::initializeExcursions();
     }
     $this->setRedirect($link);
 }
 protected function populateState()
 {
     $app = JFactory::getApplication('site');
     // Load state from the request.
     $pk = JRequest::getInt('hotel_id');
     $this->setState('hotel.id', $pk);
     $tabId = JRequest::getInt('tabId', 1);
     $this->setState('hotel.tabId', $tabId);
     $offset = JRequest::getUInt('limitstart');
     $this->setState('list.offset', $offset);
     UserDataService::updateUserData();
     $redirect = JRequest::getVar("excursionRedirect", 0);
     if ($redirect == 0) {
         UserDataService::initializeExcursions();
     }
 }