Make queries work with the new base mapper

Signed-off-by: Julius Härtl <jus@bitgrid.net>

fix: conflicts
This commit is contained in:
Julius Härtl
2020-11-10 12:54:36 +01:00
parent c0886cfc7a
commit a8c22482f6
4 changed files with 23 additions and 20 deletions

View File

@@ -678,14 +678,12 @@ class BoardService {
return $newBoard;
}
/**
* @param $ownerId
* @param $newOwnerId
* @return void
*/
public function transferOwnership($owner, $newOwner) {
public function transferOwnership(string $owner, string $newOwner): void {
$boards = $this->boardMapper->findAllByUser($owner);
foreach ($boards as $board) {
$this->aclMapper->transferOwnership($board->getId(), $owner, $newOwner);
}
$this->boardMapper->transferOwnership($owner, $newOwner);
$this->aclMapper->transferOwnership($owner, $newOwner);
$this->assignedUsersMapper->transferOwnership($owner, $newOwner);
$this->cardMapper->transferOwnership($owner, $newOwner);
}
@@ -721,4 +719,8 @@ class BoardService {
public function getBoardUrl($endpoint) {
return $this->urlGenerator->linkToRouteAbsolute('deck.page.index') . '#' . $endpoint;
}
private function clearBoardsCache() {
$this->boardsCache = null;
}
}