I have updated my registration form, added a few fields. Registration works properly, nowever when i go to Profile/edit page, i do not see the new fields. Even I manually try to add
{{ form_widget(form.country) }}
it does not work, can not find country. Which file i need to update to be able to update the profile edit page?
Entity\User
protected $position;
/**
* Set position
*
* @param string $position
* @return User
*/
public function setPosition($position)
{
$this->position = $position;
return $this;
}
/**
* Get position
*
* @return string
*/
public function getPosition()
{
return $this->position;
}
You need to override the
ProfileFormTypeclass following something similar to this. Also, for validation, FOSUserBundle uses 2 validation groups: Registration and Profile. You need to add the Profile validation group to your property.