예제 #1
0
 /**
  * @description delete node/brunch
  * @return Evil_Object_Fixed_ParentId
  * @author Se#
  * @version 0.0.2
  */
 public function erase()
 {
     parent::erase();
     // delete node itself
     $this->_fixed->delete($this->_fixed->getAdapter()->quoteInto(array('id = ?'), array($this->_id)));
     // get children ids
     $childrenIds = $this->_getChildrenIds($this->_id);
     // delete children
     $this->_fixed->delete('id IN ("' . implode('","', $childrenIds) . '")');
     return $this;
 }