40 lines
1.6 KiB
PHP
40 lines
1.6 KiB
PHP
<?php
|
|
|
|
//declare(strict_types=1);
|
|
|
|
namespace OCA\Gestion\AppInfo;
|
|
|
|
use OCA\DAV\Events\CalendarObjectCreatedEvent;
|
|
use OCA\DAV\Events\CalendarObjectMovedEvent;
|
|
use OCA\DAV\Events\CalendarObjectMovedToTrashEvent;
|
|
use OCA\DAV\Events\CalendarObjectUpdatedEvent;
|
|
use OCA\Gestion\Listener\CalendarObjectCreatedListener;
|
|
use OCA\Gestion\Listener\CalendarObjectMovedListener;
|
|
use OCA\Gestion\Listener\CalendarObjectMovedToTrashListener;
|
|
use OCA\Gestion\Listener\CalendarObjectUpdatedListener;
|
|
use OCP\AppFramework\App;
|
|
use OCP\AppFramework\Bootstrap\IBootstrap;
|
|
use OCP\AppFramework\Bootstrap\IRegistrationContext;
|
|
use OCP\AppFramework\Bootstrap\IBootContext;
|
|
// use OCP\Notification\IManager;
|
|
|
|
class Application extends App implements IBootstrap {
|
|
public const APP_ID = 'gestion';
|
|
|
|
public function __construct() {
|
|
parent::__construct(self::APP_ID);
|
|
}
|
|
|
|
public function register(IRegistrationContext $context): void {
|
|
$context->registerEventListener(CalendarObjectCreatedEvent::class, CalendarObjectCreatedListener::class);
|
|
$context->registerEventListener(CalendarObjectMovedToTrashEvent::class, CalendarObjectMovedToTrashListener::class);
|
|
$context->registerEventListener(CalendarObjectUpdatedEvent::class, CalendarObjectUpdatedListener::class);
|
|
$context->registerEventListener(CalendarObjectMovedEvent::class,CalendarObjectMovedListener::class);
|
|
}
|
|
|
|
public function boot(IBootContext $context): void {
|
|
// require_once '/var/www/html/apps/gestion/vendor/autoload.php';
|
|
require_once '/var/www/html/custom_apps/gestion/vendor/autoload.php';
|
|
}
|
|
|
|
} |