public function doSave($data, $form)
    {
        if (!$this->currentRecord) {
            $this->currentRecord = new $this->recordType();
        }
        $form->saveInto($this->currentRecord);
        $this->currentRecord->write();
        $this->redirect($this->Link());
    }
public function doSave($data, $form)
    {
        if (!$this->currentRecord) {
            $this->currentRecord = new $this->recordType();
        }
        $form->saveInto($this->currentRecord);
        $this->currentRecord->write();
        $this->redirect($this->Link());
    }
public function doSave ( $ data , $ form ) { if ( ! $ this -> currentRecord ) { $ this -> currentRecord = new $ this -> recordType ( ) ; } $ form -> saveInto ( $ this -> currentRecord ) ; $ this -> currentRecord -> write ( ) ; $ this -> redirect ( $ this -> Link ( ) ) ; }
Save the record
Save the record