改进 管理员 Host 编辑页面

This commit is contained in:
iVampireSP.com 2023-01-13 18:18:49 +08:00
parent e88b437e18
commit f945f11791
No known key found for this signature in database
GPG Key ID: 2F7B001CA27A8132

View File

@ -59,9 +59,9 @@ public function edit(Host $host): View
public function update(Request $request, Host $host): RedirectResponse
{
$request->validate([
'name' => 'required|string|max:255',
'status' => 'required|in:running,stopped,error,suspended,pending',
'price' => 'required|numeric',
'name' => 'sometimes|string|max:255',
'status' => 'sometimes|in:running,stopped,error,suspended,pending',
'price' => 'sometimes|numeric',
'managed_price' => 'nullable|numeric',
]);