Пример #1
0
 /**
  * Overload insert's method to check some data before insert
  *
  * @param array $data
  * @return integer the last insert ID.
  */
 public function insert(array $data)
 {
     $this->checkGroupName($data['groups_name']);
     return parent::insert($data);
 }
Пример #2
0
 /**
  * Overload insert's method to check some data before insert
  *
  * @param array $data
  * @return integer the last insert ID.
  */
 public function insert(array $data)
 {
     if (!isset($data['projects_start_date']) || !$data['projects_start_date']) {
         $data['projects_start_date'] = date("Y-m-d H:i:s");
     }
     return parent::insert($data);
 }
Пример #3
0
 /**
  * Overload insert's method to check some data before insert
  *
  * @param array $data
  * @return integer the last insert ID.
  */
 public function insert(array $data)
 {
     return parent::insert($this->_cleanData($data));
 }