コード例 #1
0
 public function ItemActions($item)
 {
     $actions = parent::ItemActions($item);
     if ($this->getOption('AllowEdit') && $item->canEdit()) {
         $actions->push(new ItemSetField_Action($this, 'Edit', 'Edit'));
     }
     if ($this->getOption('AllowRemove')) {
         $actions->push(new ItemSetField_Action($this, 'Remove', 'Remove', true));
     }
     if ($this->getOption('AllowDelete') && $item->canDelete()) {
         $actions->push(new ItemSetField_Action($this, 'Delete', 'Delete', true));
     }
     return $actions;
 }
コード例 #2
0
 function __construct($class, $name, $title = null, $options = null)
 {
     parent::__construct($name, $title, $options);
     $this->searchClass = $class;
 }