我在将电子邮件更改为用户名时遇到一些问题。
protected $username = 'username';
似乎不适合我。
在哪里可以更改数据库注册查询和数据库登录查询?
如果您想使用用户名而不是电子邮件登录,请使用此
$credentials = $request->only('username', 'password');
而不是
$credentials = $request->only('email', 'password');
在此处检查凭证attempt($credentials)
在AuthenticateController.php
中