コード例 #1
0
 /**
  * Add filter elements to the panel.
  *
  * @param PanelRowInterface $row The row to which the element shall get added to.
  *
  * @return void
  */
 protected function parsePanelFilter(PanelRowInterface $row)
 {
     foreach ($this->getFromDca('fields') as $property => $value) {
         if (isset($value['filter'])) {
             $element = new DefaultFilterElementInformation();
             $element->setPropertyName($property);
             if (!$row->hasElement($element->getName())) {
                 $row->addElement($element);
             }
         }
     }
 }
コード例 #2
0
ファイル: Builder.php プロジェクト: zonky2/core
 /**
  * Add filter elements to the panel.
  *
  * @param PanelRowInterface $row The row to which the element shall get added to.
  *
  * @return void
  */
 protected function parsePanelFilter(PanelRowInterface $row)
 {
     foreach ($this->getInputScreenDetails()->getProperties() as $property => $value) {
         if (!empty($value['info']['filter'])) {
             $element = new DefaultFilterElementInformation();
             $element->setPropertyName($property);
             if (!$row->hasElement($element->getName())) {
                 $row->addElement($element);
             }
         }
     }
 }