mdjaman/mdjaman-common

为 ZF2/ZF3 & Doctrine 应用程序提供通用功能库的模块

6.1.2 2023-04-10 00:37 UTC

README

简介

为与 doctrine ORM 或 ODM 集成的 ZF2/ZF3 应用程序提供通用功能库和代码的模块。

安装

使用 Composer(推荐且唯一方式)

Mdjaman\MdjamanCommon 通过 composer 提供。将 "mdjaman/mdjaman-common" 添加到您的 composer.json 列表中。

为 zf2 选择最新的 v2 标签

"mdjaman/mdjaman-common": "2.*"

为 zf3 选择最新的 v3 标签

"mdjaman/mdjaman-common": "3.*"

在您的 config/application.config.php 文件中启用此模块。将 MdjamanCommon 添加到已启用的模块列表中。

使用方法

为了使 MdjamanCommon 处理 Gedmo\Blameable 扩展,请确保您的 AuthenticationService 实现了 Zend\Authenticate\AuthenticationServiceInterface,并在 module.config.php 中的 service_manager 下的 aliases 部分添加此别名 mdjaman_auth_service

'service_manager' => [
        'aliases' => [
            'mdjaman_auth_service' => <MyGreatAuthenticationService>,
        ],
        ...
    ]
],

更多内容即将到来!