mirror of
				https://github.com/v2board/v2board.git
				synced 2025-11-01 01:41:47 +08:00 
			
		
		
		
	update
This commit is contained in:
		| @@ -28,4 +28,17 @@ class NoticeController extends Controller | ||||
|             'data' => true | ||||
|         ]); | ||||
|     } | ||||
|  | ||||
|     public function update (NoticeSave $request) { | ||||
|         $data = $request->only([ | ||||
|             'title', | ||||
|             'content' | ||||
|         ]); | ||||
|         if (!Notice::where('id', $request->input('id'))->update($data)) { | ||||
|             abort(500, '保存失败'); | ||||
|         } | ||||
|         return response([ | ||||
|             'data' => true | ||||
|         ]); | ||||
|     } | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user