Jarves\Admin\ObjectCrud::getParent PHP Method

getParent() public method

public getParent ( $pk, $fields = null )
    public function getParent($pk, $fields = null)
    {
        $storageController = $this->objects->getStorageController($this->getObject());
        $pk = $storageController->normalizePrimaryKey($pk);
        $options['fields'] = $this->getItemSelection($fields);
        $options['permissionCheck'] = $this->getPermissionCheck();
        $aclRequest = ACLRequest::create($this->getObject(), $pk)->onlyViewMode();
        if ($this->getPermissionCheck() && !$this->acl->check($aclRequest)) {
            return null;
        }
        $item = $storageController->getParent($pk, $options);
        return $item;
    }
ObjectCrud