tmcycyit / notification-bundle
2.0.4
2023-05-30 13:58 UTC
Requires
README
安装
步骤1: 使用composer下载NotificationBundle
在composer.json中添加NotificationBundle
{ "require": { "yit/notification-bundle": "dev-master", } }
现在更新composer。
Composer会将bundle安装到项目中的vendor/yit
目录。
步骤2: 启用bundle
在kernel中启用bundle
<?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new Yit\NotificationBundle\YitNotificationBundle(), ); }
步骤3: 配置NotificationBundle
将以下配置添加到您的config.yml
文件中
# app/config/config.yml yit_notification: note_user: pathToYourUserBundle\Entity\User
###步骤4: 导入NotificationBundle路由文件
# app/config/routing.yml yit_notification: resource: "@YitNotificationBundle/Controller/" type: annotation prefix: /
步骤5: 更新数据库模式
现在bundle已配置,您需要做的最后一件事是更新数据库模式。