Cakephp 3.X 具有多个字段的身份验证组件登录

Cakephp 3.X Auth Component Signin with multiple fields

我想让用户登录有两个字段,即用户名和电子邮件。检查用户名或电子邮件是否匹配并验证密码。可以吗

使用此插件中的 MultiColumn 身份验证适配器:

https://github.com/friendsofcake/authenticate#multicolumnauthenticate