예제 #1
0
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store()
 {
     $input = Input::all();
     $validation = Validator::make($input, Skill::$rules);
     if ($validation->passes()) {
         $this->skill->create($input);
         return Redirect::route('skills.index');
     }
     return Redirect::route('skills.create')->withInput()->withErrors($validation)->with('message', 'There were validation errors.');
 }
예제 #2
0
 function addskill($_post)
 {
     $user->id = $this->getuser();
     $profile = new Skill($user->id);
     $result = $profile->create($_post);
     return $result;
 }