2012-08-13 76 views
2

我已經集成了FOS BUndle和Fr3d Bundle與symfony2。這裏是我有Fr3D LDAP叢與symfony2

MappingException錯誤:未找到映射文件名爲「Acme.UserBundle.Entity.User.php」上課「的Acme \ UserBundle \實體\用戶」。

這裏是我的config.yml

fos_user: 
    db_driver: orm # other valid values are 'mongodb', 'couchdb' and 'propel' 
    firewall_name: main 
    user_class: Acme\UserBundle\Entity\User 

fr3d_ldap: 
    client: 

    user: 
     baseDn: cn=admin, dc=test, dc=local 
     filter: (&(ObjectClass=Person)) 
     attributes:   # Specify ldap attributes mapping [ldap attribute, user object method] 

     service: 
      user_manager: fos_user.user_manager   # Overrides default user manager 
      ldap_manager: acme.ldap.ldap_manager # Overrides default ldap manager 

請幫我

回答

2

在你config.yml,你需要fos_user下更新您的user_class設置...

fos_user: 
    user_class: YourVendorName\UserBundle\Entity\User 

製作確保user_class屬性指向一個VA (顯然確保你有一個UserBundle

+0

InvalidConfigurationException:路徑「fos_user」上的子節點「db_driver」必須配置 – 2012-08-16 05:15:03