Merge branch 'master' into fix/vote-list

Signed-off-by: René Gieling <github@dartcafe.de>
This commit is contained in:
René Gieling 2024-04-05 18:41:02 +02:00 коммит произвёл GitHub
Родитель 2db295d796 77db5f1ba5
Коммит 6c1b2c96e9
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
2 изменённых файлов: 5 добавлений и 4 удалений

Просмотреть файл

@ -5,6 +5,7 @@ All notable changes to this project will be documented in this file.
### Fix ### Fix
- Archive, restore and delete polls in poll list was missing, braught the options back to the action menu - Archive, restore and delete polls in poll list was missing, braught the options back to the action menu
- fix a situation, where votes of a non existing poll are requested - fix a situation, where votes of a non existing poll are requested
- Fix getting group members
### New ### New
- Added an endpoint to the Api to be able to fetch the acl of a poll - Added an endpoint to the Api to be able to fetch the acl of a poll
## [7.0.2] - 2024-03-29 ## [7.0.2] - 2024-03-29

Просмотреть файл

@ -49,7 +49,7 @@ class Group extends UserBase {
} }
private function setUp(): void { private function setUp(): void {
$this->group = Container::queryClass(IGroupManager::class)->get($this->id); $this->group = $this->groupManager->get($this->id);
$this->displayName = $this->group->getDisplayName(); $this->displayName = $this->group->getDisplayName();
} }
@ -58,10 +58,10 @@ class Group extends UserBase {
*/ */
public function getMembers(): array { public function getMembers(): array {
$members = []; $members = [];
$usersInGroup = Container::queryClass(IGroupManager::class)->displayNamesInGroup($this->id); $usersIdsInGroup = array_keys($this->groupManager->displayNamesInGroup($this->id));
foreach ($usersInGroup as $user) { foreach ($usersIdsInGroup as $userId) {
$newMember = new User((string) key($user)); $newMember = new User($userId);
if ($newMember->IsEnabled()) { if ($newMember->IsEnabled()) {
$members[] = $newMember; $members[] = $newMember;