OneToMany关系未列出元素

时间:2019-04-24 09:14:04

标签: php symfony symfony4 symfony2-easyadmin easyadmin

我试图通过使用具有OneToMany关系的简单管理员捆绑商品来获取列表。

我的Member实体:

/**
 * @ORM\OneToMany(targetEntity="Declaration", mappedBy="user")
 */
private $declarations;

我的会员Yaml文件:

list:
    fields:
        - { property: 'declarations', label: 'Label', template: 'type.html.twig'}

但是我得到了错误

  

[语义错误]第0行,“声明”附近的第60行:错误:无效   PathExpression。 StateFieldPathExpression或   应该是SingleValuedAssociationField。

0 个答案:

没有答案
相关问题