Nextcloud-App/lib/Db/MatrixTicket.php

45 lines
1.3 KiB
PHP
Raw Normal View History

<?php
2023-10-11 19:55:03 +00:00
declare(strict_types=1);
// SPDX-FileCopyrightText: BVSC e.V. <no@example.com>
// SPDX-License-Identifier: AGPL-3.0-or-later
namespace OCA\UPschooling\Db;
use JsonSerializable;
2023-10-11 19:55:03 +00:00
use OCP\AppFramework\Db\Entity;
2023-10-11 19:55:03 +00:00
/**
* @method getId(): int
* @method getMatrixControlRoom(): string
* @method setMatrixControlRoom(string $roomId): void
* @method getMatrixAssistedUser(): string
* @method setMatrixAssistedUser(string $userId): void
* @method getMatrixHelperUser(): ?string
* @method setMatrixHelperUser(?string $userId): void
* @method getStatus(): string
* @method setStatus(string $status): void
* @method getVersion(): int
* @method setVersion(int $version): void
*/
class MatrixTicket extends Entity implements JsonSerializable
{
2023-10-11 19:55:03 +00:00
protected string $matrixControlRoom = '';
protected string $matrixAssistedUser = ''; // The ID of the person who created the ticket. Usually the person who needs help.
protected ?string $matrixHelperUser = null;
protected string $status = '';
protected int $version = 0;
public function jsonSerialize(): array
{
return [
'id' => $this->id,
'matrixControlRoom' => $this->matrixControlRoom,
'matrixAssistedUser' => $this->matrixAssistedUser,
'matrixHelperUser' => $this->matrixHelperUser,
'status' => $this->status,
'version' => $this->version,
];
}
}