示例#1
0
 public function setRegion($region)
 {
     $this->region = $region;
     $subRegions = Region::filter(['parent' => $this->region->id, 'name' => 'column1']);
     foreach ($subRegions as $curRegion) {
         $this->add($curRegion, 'column1');
     }
 }
 /**
  * Gibt die Regionen dieser Seite zurück, denen ein Eintrag zugeordnet wurde
  * @return array
  */
 public function getRegions()
 {
     if ($this->regions === null) {
         $this->regions = Region::filter(array('page' => $this->id));
     }
     return $this->regions;
 }