| @@ 313-324 (lines=12) @@ | ||
| 310 | * |
|
| 311 | * @param Circle $circle |
|
| 312 | */ |
|
| 313 | public function destroy(Circle $circle) { |
|
| 314 | $qb = $this->db->getQueryBuilder(); |
|
| 315 | $qb->delete(self::TABLENAME) |
|
| 316 | ->where( |
|
| 317 | $qb->expr() |
|
| 318 | ->eq( |
|
| 319 | 'id', $qb->createNamedParameter($circle->getId()) |
|
| 320 | ) |
|
| 321 | ); |
|
| 322 | ||
| 323 | $qb->execute(); |
|
| 324 | } |
|
| 325 | ||
| 326 | } |
|
| 327 | ||
| @@ 217-229 (lines=13) @@ | ||
| 214 | * |
|
| 215 | * @return bool |
|
| 216 | */ |
|
| 217 | public function removeAllFromCircle(Circle $circle) { |
|
| 218 | $qb = $this->db->getQueryBuilder(); |
|
| 219 | $qb->delete(self::TABLENAME) |
|
| 220 | ->where( |
|
| 221 | $qb->expr() |
|
| 222 | ->eq('circle_id', $qb->createNamedParameter($circle->getId())) |
|
| 223 | ); |
|
| 224 | ||
| 225 | $qb->execute(); |
|
| 226 | ||
| 227 | return true; |
|
| 228 | ||
| 229 | } |
|
| 230 | } |
|
| 231 | ||
| 232 | ||