How to create a form to values in the selekt was the value of connectedness(ManyToOne) entities?

there are two entities related to each other
class Cars
{
/**
 * @var int
 * @ORM\Column(name="id" type="integer")
 * @ORM\Id
 * @ORM\GeneratedValue(strategy="AUTO")
*/
 private $id;

/**
 * @ORM\OneToMany(targetEntity="AppBundle\Entity\Price", mappedBy="car")
*/
 private $price;
}

and also related
class Price
{
/**
 * @var int
 * @ORM\Column(name="id" type="integer")
 * @ORM\Id
 * @ORM\GeneratedValue(strategy="AUTO")
*/
 private $id;

/**
*
 * @ORM\ManyToOne(targetEntity="AppBundle\Entity\Cars", inversedBy="price")
 * @ORM\JoinColumn(name="car_alias", referencedColumnName="id")
*/
 private $car;
}

want to when you create/edit the object Price was able to choose from
the earlier created objects Cars

I tried to use field type EntityType, but it seems that it is not very suitable
Please tell me how to solve this issue
my level - Novice, bear with me :)
July 2nd 19 at 17:12
1 answer
July 2nd 19 at 17:14
Solution
$builder->add('car');
He smiled
not well, not so blunt :)
wait a second, I'll check - larue_Jerde commented on July 2nd 19 at 17:17
I spent a few days
something was up
I have no words :) - larue_Jerde commented on July 2nd 19 at 17:20
Thank you very much, didn't get to do
FIHM that the connection has not been spelled out and I went into the jungle EntityType, etc.
everything is much easier - larue_Jerde commented on July 2nd 19 at 17:23

Find more questions by tags Symfony