public function addEdit() { $fsList = new FileSetList(); $sets = $fsList->get(); $options = array(); foreach ($sets as $fs) { $options[$fs->fsID] = $fs->fsName; } $this->set('sets', $options); }
public function view() { Loader::model('file_set'); $fsl = new FileSetList(); if (isset($_REQUEST['fsKeywords'])) { $fsl->filterByKeywords($_REQUEST['fsKeywords']); } if (isset($_REQUEST['fsType'])) { $fsl->filterByType($_REQUEST['fsType']); $this->set('fsType', $_REQUEST['fsType']); } else { $fsl->filterByType(FileSet::TYPE_PUBLIC); $this->set('fsType', FileSet::TYPE_PUBLIC); } $fileSets = $fsl->getPage(); $this->set('fileSets',$fileSets); $this->set('fsl', $fsl); }