| @@ 161-176 (lines=16) @@ | ||
| 158 | ); |
|
| 159 | ||
| 160 | // If not main-languages query |
|
| 161 | if (!empty($languageFilter['languages'])) { |
|
| 162 | $condition = $query->expr->lAnd( |
|
| 163 | $condition, |
|
| 164 | $query->expr->gt( |
|
| 165 | $query->expr->bitAnd( |
|
| 166 | $this->handler->quoteColumn('language_mask', 'ezcontentobject'), |
|
| 167 | $query->bindValue( |
|
| 168 | $this->getLanguageMask($languageFilter), |
|
| 169 | null, |
|
| 170 | PDO::PARAM_INT |
|
| 171 | ) |
|
| 172 | ), |
|
| 173 | $query->bindValue(0, null, PDO::PARAM_INT) |
|
| 174 | ) |
|
| 175 | ); |
|
| 176 | } |
|
| 177 | ||
| 178 | return $condition; |
|
| 179 | } |
|
| @@ 146-160 (lines=15) @@ | ||
| 143 | ); |
|
| 144 | ||
| 145 | // If not main-languages query |
|
| 146 | if (!empty($languageFilter['languages'])) { |
|
| 147 | $selectQuery->where( |
|
| 148 | $selectQuery->expr->gt( |
|
| 149 | $selectQuery->expr->bitAnd( |
|
| 150 | $this->handler->quoteColumn('language_mask', 'ezcontentobject'), |
|
| 151 | $selectQuery->bindValue( |
|
| 152 | $this->getLanguageMask($languageFilter), |
|
| 153 | null, |
|
| 154 | PDO::PARAM_INT |
|
| 155 | ) |
|
| 156 | ), |
|
| 157 | $selectQuery->bindValue(0, null, PDO::PARAM_INT) |
|
| 158 | ) |
|
| 159 | ); |
|
| 160 | } |
|
| 161 | ||
| 162 | if ($sortClauses !== null) { |
|
| 163 | $this->sortClauseConverter->applyOrderBy($selectQuery); |
|
| @@ 221-235 (lines=15) @@ | ||
| 218 | ); |
|
| 219 | ||
| 220 | // If not main-languages query |
|
| 221 | if (!empty($languageFilter['languages'])) { |
|
| 222 | $query->where( |
|
| 223 | $query->expr->gt( |
|
| 224 | $query->expr->bitAnd( |
|
| 225 | $this->handler->quoteColumn('language_mask', 'ezcontentobject'), |
|
| 226 | $query->bindValue( |
|
| 227 | $this->getLanguageMask($languageFilter), |
|
| 228 | null, |
|
| 229 | PDO::PARAM_INT |
|
| 230 | ) |
|
| 231 | ), |
|
| 232 | $query->bindValue(0, null, PDO::PARAM_INT) |
|
| 233 | ) |
|
| 234 | ); |
|
| 235 | } |
|
| 236 | ||
| 237 | $statement = $query->prepare(); |
|
| 238 | $statement->execute(); |
|