You can do this in action:
$this->form->getObject()->setFooId($this->foo->getId())
$this->form->save();
, Peer, - .
, , - .
, Peer:
public function save(PropelPDO $con= null)
{
if ($this->isNew() && !$this->getFooId())
{
$foo= new Foo();
$foo->setBar('bar');
$this->setFoo($foo);
}
}