コード例 #1
0
 public function getDelete($id = '')
 {
     if ($id == '') {
         return Redirect::to($this->route)->with('msg_error', Lang::get('messages.participants_display_err'));
     } else {
         $participant = ORGParticipants::find($id);
         $delete = ORGParticipants::destroy($id);
         if (!$delete) {
             return Redirect::to($this->route)->with('msg_error', Lang::get('messages.participants_delete_err', array('title' => $participant->title)));
         } else {
             return Redirect::to($this->route)->with('msg_success', Lang::get('messages.participants_delete', array('title' => $participant->title)));
         }
     }
 }