Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/277.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 轻松管理3。从当前实体中选择_Php_Symfony_Easyadmin3 - Fatal编程技术网

Php 轻松管理3。从当前实体中选择

Php 轻松管理3。从当前实体中选择,php,symfony,easyadmin3,Php,Symfony,Easyadmin3,我正在尝试从答案表1中的所有当前答案中进行选择。所以我可以将它与其他一些表关联 public static function getEntityFqcn(): string { return Answer::class; } /** * @param string $pageName * @return iterable */ public function configureFields(string $pageName): iterable { return [

我正在尝试从答案表1中的所有当前答案中进行选择。所以我可以将它与其他一些表关联

public static function getEntityFqcn(): string
{
    return Answer::class;
}

/**
 * @param string $pageName
 * @return iterable
 */
public function configureFields(string $pageName): iterable
{

    return [
        IdField::new('id')->hideOnForm(),
        Field::new('answer'), <--- HERE 
        AssociationField::new('comment'),
        AssociationField::new('category'),
    ];
}
对于那个特定的字段,我不想添加新字段。但我想从所有答案字段中进行选择,这样我就可以将新的注释和类别关联到注释

如何在easy admin3中实现这一点