Calendar Doctrine
Available versions:
Installation
composer require aeon-php/calendar-doctrine
Description
This library provides Aeon Doctrine DBAL types.
Usage PHP
<?php
use Doctrine\DBAL\Types\Type;
use Aeon\Doctrine\Calendar\Gregorian\DayType;
use Aeon\Doctrine\Calendar\Gregorian\DateTimeType;
use Aeon\Doctrine\Calendar\Gregorian\DateTimeTzType;
Type::addType(DayType::NAME, DayType::class); // aeon_day
Type::addType(DateTimeType::NAME, DateTimeType::class); // aeon_datetime
Type::addType(DateTimeTzType::NAME, DateTimeTzType::class); // aeon_datetime_tz
Usage Symfony
# config/packages/doctrine.yaml
doctrine:
dbal:
types:
aeon_dat: Aeon\Doctrine\Calendar\Gregorian\DayType
aeon_datetime: Aeon\Doctrine\Calendar\Gregorian\DateTimeType
aeon_datetime_tz: Aeon\Doctrine\Calendar\Gregorian\DateTimeTzType