I have the class User as the base class then i extended Teacher from user class.
When i try to login i get this error
You cannot refresh a user from the EntityUserProvider that does not
contain an identifier. The user object has to be serialized with its
own identifier mapped by Doctrine.
I have serialize/deserialize function in user.php as i have coped that from FOSUserbundle
public function serialize()
{
return serialize(array(
$this->password,
$this->salt,
$this->usernameCanonical,
$this->username,
$this->expired,
$this->locked,
$this->credentialsExpired,
$this->enabled,
));
}
I am not able to find where i can check for error. i am stuck. please help
From the code of
EntityUserProvider.phpit seems that you have to serializeidof the user also.