-
-
Notifications
You must be signed in to change notification settings - Fork 263
Closed
Labels
Description
User Entity:
/**
* User
*
* @ORM\Entity
* @ORM\Table(
* name="dbtuser",
* options={
* "collate"="utf8_general_ci"
* }
* )
*/
class User
{
/**
* @ORM\Id
* @ORM\Column(type="string", length=20)
*
* @var string
*/
protected $userId;
/**
* @ORM\Column(type="string", length=20)
*
* @var string
*/
protected $loginId;
/**
* @ORM\Column(type="string", length=20)
*
* @var string
*/
protected $pw;Login Action
public function loginAction()
{
$request = $this->getRequest();
$form = $this->getLoginForm();
$error = null;
if ($request->isPost()) {
$form->setData($request->getPost());
if ($form->isValid()) {
$data = $form->getData();
$authService = $this->getAuthenticationService();
$adapter = $authService->getAdapter();
$adapter->setIdentityValue($data['loginId']);
$adapter->setCredentialValue($data['pw']);
$authResult = $authService->authenticate();
if ($result = $authResult->isValid()) {
var_dump($authResult->getMessages());
} else {
var_dump($authResult->getMessages());
}
}
}
return array(
'error' => $error,
'form' => $form,
);
}LoginId is admin and PW is 000000
Is this a bug?



