/**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store(ModelNewRequest $request)
 {
     try {
         $model = new Department($request->all());
         try {
             DB::beginTransaction();
             $department_id = $request->input('department_id', null);
             $model->department_id = $department_id;
             $model->save();
             DB::commit();
             Flash::info(trans($this->resource_name . 'saved', ['model' => $this->model_name]));
             return redirect(route($this->show_route, [$model->id]));
         } catch (Exception $e) {
             DB::rollBack();
             throw $e;
         }
     } catch (Exception $e) {
         $errors = [];
         if ($e instanceof PDOException) {
             Flash::error($e->errorInfo[2]);
         } else {
             Flash::error($e->getMessage());
         }
         return $request->response($errors);
     }
 }