public function postEdit($id) { $input = Input::only(['name', 'description']); $validator = Validator::make($input, ['name' => 'Required']); if ($validator->fails()) { $e = new InvalidArgumentHttpException(); $e->setMessage($validator->errors()->first()); throw $e; } XeDB::beginTransaction(); try { $group = $this->groups->find($id); $group->fill($input); $this->groups->update($group); } catch (Exception $e) { XeDB::rollBack(); throw $e; } XeDB::commit(); return redirect()->route('manage.group.index')->with('alert', ['type' => 'success', 'message' => '수정되었습니다.']); }