Update docs

Signed-off-by: Sergey Shliakhov <husband.sergey@gmail.com>

fix: conflicts
This commit is contained in:
Sergey Shliakhov
2020-05-25 09:46:57 +02:00
committed by Julius Härtl
parent eb8a321637
commit fc9fa5dc25
7 changed files with 107 additions and 33 deletions

View File

@@ -146,4 +146,20 @@ class AssignmentMapper extends QBMapper implements IPermissionMapper {
}
return null;
}
/**
* @param $ownerId
* @param $newOwnerId
* @return void
*/
public function transferOwnership($ownerId, $newOwnerId)
{
$params = [
'owner' => $ownerId,
'newOwner' => $newOwnerId
];
$sql = "UPDATE `{$this->tableName}` SET `participant` = :newOwner WHERE `participant` = :owner";
$stmt = $this->execute($sql, $params);
$stmt->closeCursor();
}
}