private function insertBlockElement($info) { $row = new CcBlockcontents(); $row->setDbBlockId($this->id); $row->setDbFileId($info["id"]); $row->setDbPosition($info["pos"]); $row->setDbCliplength($info["cliplength"]); $row->setDbCuein($info["cuein"]); $row->setDbCueout($info["cueout"]); $row->setDbFadein($info["fadein"]); $row->setDbFadeout($info["fadeout"]); $row->save($this->con); // above save result update on cc_block table on length column. // but $this->block doesn't get updated automatically // so we need to manually grab it again from DB so it has updated values // It is something to do FORMAT_ON_DEMAND( Lazy Loading ) $this->block = CcBlockQuery::create()->findPK($this->id); }