[symfony-users] Re: sfGuard/sfGuardDoctrine and form population

2008-12-10 Thread Jonathan Wage
You need to provide the Profile object that the ProfileForm is bound to. class UserEditForm extends sfGuardUserForm { public function configure() { parent::configure(); $profileForm = new ProfileForm($this->object->getProfile()); unset($profileForm['id'], $profileForm['sf_guar

[symfony-users] Re: sfGuard/sfGuardDoctrine and form population

2008-12-10 Thread Thomas Rabaix
Please keep in mind that all the form logic should be done inside the form, the form is self dependant So this code should be avoid : $this->form->setDefaults($this->getUser()->getProfile()); you can provide to your UserEditForm the sfUser Object, and then overwrite the method updateDefaultsFromO