tagService->findAllIncludingGroupfolder("organization_folder"); foreach ($tags as $tag) { $result[] = new OrganizationFolder($tag["group_folder_id"], $tag["mount_point"], $tag["quota"]); } return $result; } public function create(string $name, int $quota, ?string $organizationProvider = null,?int $organizationId = null) { $this->atomic(function () use ($name, $quota) { $groupfolderId = $this->folderManager->createFolder($name); $this->folderManager->setFolderQuota($groupfolderId, $quota); $this->folderManager->setFolderACL($groupfolderId, true); $this->tagService->update($groupfolderId, "organization_folder"); if(isset($organizationProvider) && $this->organizationProviderManager->hasOrganizationProvider($organizationProvider) && isset($organizationId)) { $organization = $this->organizationProviderManager->getOrganizationProvider($organizationProvider)->getOrganization($organizationId); $this->tagService->update($groupfolderId, "organization_provider", $organizationProvider); $this->tagService->update($groupfolderId, "organization_id", $organization->getId()); } // TODO: return Model object }, $this->db); } public function applyPermissions(int $id) { } }