When I install FOSUserBundle (official documentation), I try to generate my table fos_user
using this command:
php app/console doctrine:schema:update --force
But console returns the following message
Nothing to update - your database is already in sync with the current entity metadata
I use Symfony 2.1 and the last version to FOSUserBundle.
app/AppKernel.php contains
new FOS\UserBundle\FOSUserBundle(),
app/config/config.yml contains
fos_user:
db_driver: orm # other valid values are 'mongodb', 'couchdb' and 'propel'
firewall_name: main
user_class: Krpano\UserBundle\Entity\User
src/Krpano/UserBundle/Entity/User.php contains
namespace Krpano\UserBundle\Entity;
use FOS\UserBundle\Entity\User as BaseUser;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity
* @ORM\Table(name="pouet")
*/
class User extends BaseUser
{
/**
* @ORM\Id
* @ORM\Column(type="integer")
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
public function __construct()
{
parent::__construct();
// your own logic
}
}
And when I try to access to my website I have this error:
MappingException: The class 'Krpano\UserBundle\Entity\User' was not found in the chain configured namespaces FOS\UserBundle\Entity, Krpano\ServicesBundle\Entity
Can you help me?