In the never ending quest to figure out how to successfully embed symfony forms I found myself always opening /symfony/lib/plugins/sfDoctrinePlugin/lib/form/sfFormDoctrine.class.php to study the order of operations for saving data against a form object. Finally figured it was time to post it somewhere where I could easily get to it and may help other devs along the way.

Note: This is a living doc and may be updated over time.

  1. sfFormDoctrine::save($con)
    1. $con->beingTransaction()
    2. $this->doSave($con)
      1. $this->updateObject()
        1. $this->processValues()
        2. $this->object->fromArray($values)
        3. $this->updateObjectEmbeddedForms($values)
      2. $this->object->save($con)
      3. $this->saveEmbeddedForms($con)
    3. $con->commit()