Closed atmanegara closed 1 year ago
public function beforeSave($insert) { if($this->isNewRecord){ $this->myfieldKey = new \yii\db\Exception('UUID()'); return parent::beforeSave($insert); } }
get error
You should use Expression, not Exception.
What steps will reproduce the problem?
public function beforeSave($insert) { if($this->isNewRecord){ $this->myfieldKey = new \yii\db\Exception('UUID()'); return parent::beforeSave($insert); } }
get error
Additional info