diff --git a/module/stage/model.php b/module/stage/model.php index 46ee238d57..1d5ce8264e 100644 --- a/module/stage/model.php +++ b/module/stage/model.php @@ -68,7 +68,9 @@ class stageModel extends model $stage->createdDate = helper::today(); $this->dao->insert(TABLE_STAGE)->data($stage)->autoCheck()->checkIF($stage->percent != '', 'percent', 'float')->exec(); - + + if(dao::isError()) return false; + $stageID = $this->dao->lastInsertID(); $this->action->create('stage', $stageID, 'Opened'); }