Esempio n. 1
0
 /**
  * Attaches the content to the container
  * @param boolean $isNew
  */
 private function AttachContainerContent($isNew)
 {
     $provider = new ContainerContentTreeProvider($this->Container());
     $tree = new TreeBuilder($provider);
     $containerContent = $this->Content()->GetContainerContent();
     if (!$containerContent) {
         $containerContent = new ContainerContent();
         $containerContent->SetContainer($this->Container());
         $provider->AttachContent($containerContent, $this->Content());
     }
     if ($isNew) {
         $tree->Insert($containerContent, $this->ParentItem(), $this->PreviousItem());
     }
 }