diff --git a/lib/Db/AppointmentConfig.php b/lib/Db/AppointmentConfig.php index 2bdd4778f..b2a72cb8b 100644 --- a/lib/Db/AppointmentConfig.php +++ b/lib/Db/AppointmentConfig.php @@ -11,6 +11,7 @@ use JsonSerializable; use OCP\AppFramework\Db\Entity; +use OCP\DB\Types; use ReturnTypeWillChange; use function json_decode; use function json_encode; @@ -122,16 +123,16 @@ class AppointmentConfig extends Entity implements JsonSerializable { public const VISIBILITY_PRIVATE = 'PRIVATE'; public function __construct() { - $this->addType('start', 'int'); - $this->addType('end', 'int'); - $this->addType('length', 'int'); - $this->addType('increment', 'int'); - $this->addType('preparationDuration', 'int'); - $this->addType('followupDuration', 'int'); - $this->addType('timeBeforeNextSlot', 'int'); - $this->addType('dailyMax', 'int'); - $this->addType('futureLimit', 'int'); - $this->addType('createTalkRoom', 'boolean'); + $this->addType('start', Types::INTEGER); + $this->addType('end', Types::INTEGER); + $this->addType('length', Types::INTEGER); + $this->addType('increment', Types::INTEGER); + $this->addType('preparationDuration', Types::INTEGER); + $this->addType('followupDuration', Types::INTEGER); + $this->addType('timeBeforeNextSlot', Types::INTEGER); + $this->addType('dailyMax', Types::INTEGER); + $this->addType('futureLimit', Types::INTEGER); + $this->addType('createTalkRoom', Types::BOOLEAN); } /** diff --git a/lib/Db/Booking.php b/lib/Db/Booking.php index d3bfe6dd0..54c92cd22 100644 --- a/lib/Db/Booking.php +++ b/lib/Db/Booking.php @@ -9,6 +9,7 @@ use JsonSerializable; use OCP\AppFramework\Db\Entity; +use OCP\DB\Types; use ReturnTypeWillChange; /** @@ -74,12 +75,12 @@ class Booking extends Entity implements JsonSerializable { private $talkUrl; public function __construct() { - $this->addType('id', 'integer'); - $this->addType('apptConfigId', 'integer'); - $this->addType('createdAt', 'integer'); - $this->addType('start', 'integer'); - $this->addType('end', 'integer'); - $this->addType('confirmed', 'boolean'); + $this->addType('id', Types::INTEGER); + $this->addType('apptConfigId', Types::INTEGER); + $this->addType('createdAt', Types::INTEGER); + $this->addType('start', Types::INTEGER); + $this->addType('end', Types::INTEGER); + $this->addType('confirmed', Types::BOOLEAN); } #[ReturnTypeWillChange]