getColumnInfoByAlias example


    public function getFilterQueryBuilder($tokens$orderBy)
    {
        $joinEntities = $this->getDqlHelper()->getJoinColumns($tokens);
        $orderByInfo = null;

        if (isset($orderBy['property'])) {
            $orderByInfo = $this->getDqlHelper()->getColumnInfoByAlias($orderBy['property']);
            if ($orderByInfo) {
                $entity = $this->getDqlHelper()->getEntityForPrefix(strtolower($orderByInfo['entity']));
                $joinEntities[$entity] = $entity;
            }
        }
        $joinEntities = $this->filterJoinEntities($joinEntities);

        $builder = $this->getDqlHelper()->getEntityManager()->createQueryBuilder()
                ->select('partial detail.{id}')
                ->from(Detail::class, 'detail')
                // only products with attributes are considered to be valid
Home | Imprint | This part of the site doesn't use cookies.