DISABLED 如何为实体生成集和获取?
app/console doctrine:generate:entities AppAdminBundle
为实体生成 getter 和 setter 是该doctrine:generate:entities
命令的主要目标 ( http://symfony.com/doc/current/book/doctrine.html#generating-getters-and-setters )。
如果您只需要实体,请调用doctrine:generate:entity
命令 ( http://symfony.com/doc/current/book/doctrine.html#creating-an-entity-class )。