Exemplo n.º 1
0
 public function action_delete($id = null)
 {
     if ($selfgeneration = Model_Selfgeneration::find($id)) {
         $selfgeneration->delete();
         Session::set_flash('success', 'Deleted selfgeneration #' . $id);
     } else {
         Session::set_flash('error', 'Could not delete selfgeneration #' . $id);
     }
     Response::redirect('selfgeneration');
 }
Exemplo n.º 2
0
 private function is_dupe($firstname, $telephone)
 {
     $check = \Model_Selfgeneration::find()->where('telephone', $telephone)->where('fname', $firstname);
     return $check->count() > 0 ? true : false;
 }