Use doctrine dbal consistently
This commit is contained in:
@@ -27,6 +27,7 @@ namespace EP\EpTheme\DataProcessing;
|
||||
* This copyright notice MUST APPEAR in all copies of the script!
|
||||
***************************************************************/
|
||||
|
||||
use EP\EpProducts\Utility\DbUtility;
|
||||
use TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer;
|
||||
use TYPO3\CMS\Frontend\ContentObject\DataProcessorInterface;
|
||||
|
||||
@@ -67,11 +68,16 @@ class ContextProcessor implements DataProcessorInterface
|
||||
*/
|
||||
private function getContextRecord($uid, $table)
|
||||
{
|
||||
$where = $GLOBALS['TSFE']->sys_page->enableFields($table);
|
||||
return $GLOBALS['TYPO3_DB']->exec_SELECTgetSingleRow(
|
||||
'*',
|
||||
$table,
|
||||
$table . '.uid=' . $uid . $where
|
||||
);
|
||||
$qb = DbUtility::getDbConnection()->createQueryBuilder();
|
||||
$query = $qb
|
||||
->select('*')
|
||||
->from($table)
|
||||
->where('uid = :uid')
|
||||
->andWhere('deleted = 0')
|
||||
->andWhere('hidden = 0')
|
||||
->setParameter('uid', $uid)
|
||||
;
|
||||
|
||||
return $query->execute()->fetch();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user