public function postOrder(Request $request) { try { $obj = \App\Models\Order::createFromInput($request); return \Redirect::action(PuzzleController::actionString('anyOrderSuccess'))->with('create-success', true); } catch (\App\Exceptions\Validation $ex) { return \Redirect::back()->withErrors($ex->validator)->withInput(); } catch (\Exception $ex) { return \Redirect::back()->withErrors($ex->getMessage())->withInput(); } }