From 82887d03612eb502d45358a28a6b036a4736c261 Mon Sep 17 00:00:00 2001 From: "Jose M. Alonso M" Date: Sun, 12 Oct 2014 20:31:33 +0200 Subject: [PATCH] Update QueryBuilder reference documentation. - Updated the signature of methods "from", "innerJoin" and "leftJoin" since it does not match the actual implementation. - Added reference to the "join" method. --- docs/en/reference/query-builder.rst | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/docs/en/reference/query-builder.rst b/docs/en/reference/query-builder.rst index fba2d75ec..ee0e6e4d7 100644 --- a/docs/en/reference/query-builder.rst +++ b/docs/en/reference/query-builder.rst @@ -139,15 +139,23 @@ Here is a complete list of helper methods available in ``QueryBuilder``: public function set($key, $value); // Example - $qb->from('Phonenumber', 'p') - public function from($from, $alias = null); + // Example - $qb->from('Phonenumber', 'p', 'p.id') + public function from($from, $alias, $indexBy = null); + + // Example - $qb->join('u.Group', 'g', Expr\Join::WITH, $qb->expr()->eq('u.status_id', '?1')) + // Example - $qb->join('u.Group', 'g', 'WITH', 'u.status = ?1') + // Example - $qb->join('u.Group', 'g', 'WITH', 'u.status = ?1', 'g.id') + public function join($join, $alias, $conditionType = null, $condition = null, $indexBy = null); // Example - $qb->innerJoin('u.Group', 'g', Expr\Join::WITH, $qb->expr()->eq('u.status_id', '?1')) // Example - $qb->innerJoin('u.Group', 'g', 'WITH', 'u.status = ?1') - public function innerJoin($join, $alias = null, $conditionType = null, $condition = null); + // Example - $qb->innerJoin('u.Group', 'g', 'WITH', 'u.status = ?1', 'g.id') + public function innerJoin($join, $alias, $conditionType = null, $condition = null, $indexBy = null); // Example - $qb->leftJoin('u.Phonenumbers', 'p', Expr\Join::WITH, $qb->expr()->eq('p.area_code', 55)) // Example - $qb->leftJoin('u.Phonenumbers', 'p', 'WITH', 'p.area_code = 55') - public function leftJoin($join, $alias = null, $conditionType = null, $condition = null); + // Example - $qb->leftJoin('u.Phonenumbers', 'p', 'WITH', 'p.area_code = 55', 'p.id') + public function leftJoin($join, $alias, $conditionType = null, $condition = null, $indexBy = null); // NOTE: ->where() overrides all previously set conditions //