English 中文(简体)
例外类型“ 日历”, 但是在 Symfony 2 下有“ 农药采集” 错误 。
原标题:Excepted type "scalar" but got "PeristentCollection" bug under Symfony2

The form s client data is expected to be of type scalar, but is an instance of class DoctrineORMPersistentCollection. You can avoid this error by setting the "data_class" option to "DoctrineORMPersistentCollection" or by adding a client transformer that transforms DoctrineORMPersistentCollection to scalar.

在这里,我得到了什么 当我使用表格 使用收藏,

我把有关文件放在Gist之下,我删除了所有不必要的代码:https://gist.github.com/2769672

我在研究 TeamType 表格(类 Team ),我有2个收藏字段 " Conditions /Links "。

这个问题发生在我处理作曲家.phar更新(我使用Symfony 2. 1)之后。

我不明白的是 为什么我得到这个 尽管我有"data_data_ class "的选项

谢谢 谢谢

最佳回答
问题回答

暂无回答




相关问题
Zend and static class properties

I m trying to assign a value to a static class property when defining it: namespace Base; abstract class Skeleton { protected static $entityManager = end_Registry::get("EntityManager"); ......

require_once missing doctrine zend framework

I m integrating doctrine with Zend Framework. I ve hit an error thrown from cli. It seems Zend_Application_Bootstrap_Bootstrap does not have a require_once for ...

doctrine: QueryBuilder vs createQuery?

In Doctrine you can create DQL in 2 ways: EntityManager::createQuery: $query = $em->createQuery( SELECT u FROM MyProjectModelUser u WHERE u.id = ?1 ); QueryBuilder: $qb->add( select , u ) ...

热门标签