staffim / datetime-bundle
为 Symfony2 提供对 DateTime 的改进的 Bundle
2.1
2018-05-22 08:41 UTC
Requires
- php: ^7.0.0
- staffim/datetime: ^2.0
Requires (Dev)
- doctrine/common: ^2.8
- phpunit/phpunit: ~4.8
- symfony/framework-bundle: ~2.6|~3.0
- symfony/security-bundle: ~2.6|~3.0
Suggests
- doctrine/mongodb-odm-bundle: Allows storing dates with milliseconds in MongoDB
- jms/serializer-bundle: Provides handler for DateTime
This package is auto-updated.
Last update: 2024-09-05 18:18:15 UTC
README
StaffimDateTime(StaffimDateTime)用于 Symfony。Bundle 为模型提供 Timestampable 接口/特性,为 Serializer 处理器,以及 Staffim\DateTime 类的 Doctrine MongoDB 类型处理器。
安装
安装 StaffimDateTimeBundle
安装此 Bundle 的首选方法是依赖 Composer。只需在 Packagist 上检查您想安装的版本,并将其添加到您的 composer.json
文件中。
{ "require": { // ... "staffim/datetime-bundle": "1.0" } }
在 Kernel 中启用 Bundle
<?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new Staffim\DateTimeBundle\StaffimDateTimeBundle(), ); }