Esempio n. 1
0
 /**
  * Gets a list of venues.  If the $_REQUEST['archived'] attribute
  * is true, will return the archived list.  Else will return the list
  * of non-archived venues.
  * @param object $mainframe The Joomla specific page object
  * @return bean the venues summary page model bean
  */
 private function setSummaryModel($mainframe)
 {
     global $logger;
     $logger->debug(get_class($this) . '::setSummaryModel()');
     $service = $this->getVenueService();
     $model = new SummaryPageModel();
     $pubStates = null;
     if (isset($_REQUEST['archived'])) {
         $pubStates = array(PublicationState::ARCHIVED);
     }
     $logger->debug("Size of pubStates array: " . count($pubStates));
     $list = $service->getVenuesByPubState($pubStates);
     $logger->debug("Size of venues array: " . count($list));
     // TODO Get Related Events
     $model->setVenues($list);
     return $model;
 }