Esempio n. 1
0
 protected function execute()
 {
     if ($this->state->get('paging', false)) {
         $limit = $this->state->get('limit');
         $filters = $this->state->get('filters');
         $count = $this->state->get('count', false);
         $appState = new Joomla\Registry\Registry(['limit' => $limit, 'count' => $count, 'filters' => $filters]);
         /** @var Sp4kAppsCoachApp $registrationApp */
         $app = Sp4kAppsCoachApp::getInstance($appState);
         $appCollection = $app->getCollection();
         $this->count = $appCollection->count;
         $this->items = $appCollection->items;
     } else {
         $this->items = Sp4kAppsCoachApp::getInstance(new Joomla\Registry\Registry($this->state->toObject()))->getItems();
     }
 }
Esempio n. 2
0
 public function execute()
 {
     $app = new Sp4kAppsCoachApp(new Joomla\Registry\Registry($this->state->toObject()));
     $this->item = $app->getItem();
 }