예제 #1
0
 /**
  * Overload canChildItem to make specific checks
  * @since version 0.84
  **/
 function canChildItem($methodItem, $methodNotItem)
 {
     // Original user always have right
     if ($this->fields['users_id'] === Session::getLoginUserID()) {
         return true;
     }
     if (!parent::canChildItem($methodItem, $methodNotItem)) {
         return false;
     }
     $ri = $this->getItem();
     if ($ri === false) {
         return false;
     }
     $item = $ri->getItem();
     if ($item === false) {
         return false;
     }
     return Session::haveAccessToEntity($item->getEntityID());
 }