/**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store()
 {
     $input = Input::all();
     $validation = Validator::make($input, Chung_loai::$rules);
     if ($validation->passes()) {
         $model = $this->chung_loai->create($input);
         Logfileadmin::addData("Thêm", "Chủng Loại", $model->id, $model->tenchungloai);
         return Redirect::route('chung_loais.index');
     }
     return Redirect::route('chung_loais.create')->withInput()->withErrors($validation)->with('message', 'There were validation errors.');
 }