alcalyn / flush-on-kernel-terminate-bundle
只需添加一个监听器,即可在响应发送后自动刷新未刷新的实体。
v0.9.1
2014-09-02 16:13 UTC
Requires
- php: >=5.3.2
- symfony/symfony: 2.x
This package is not auto-updated.
Last update: 2024-09-24 07:22:28 UTC
README
只需在内核终止时执行 EntityManager::flush()。
如果一个实体可以等待刷新,则不要刷新它,并让此包在响应发送后刷新它。
安装
步骤 1: 使用 composer 下载
{ "require": { "alcalyn/flush-on-kernel-terminate": "1.x" } }
更新你的 composer。
php composer.phar update
步骤 2: 注册 Bundle
<?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new Alcalyn\FlushOnKernelTerminateBundle\AlcalynFlushOnKernelTerminateBundle(), ); }
许可证
此包位于 MIT 许可证之下。查看完整的许可证