Location should be validated on creation of a server,

This commit is contained in:
Emmet Young 2017-01-25 22:01:57 +11:00
parent a137e6ed72
commit 58de6125c2

View file

@ -92,6 +92,7 @@ class ServerRepository
'disk' => 'required|numeric|min:0', 'disk' => 'required|numeric|min:0',
'service' => 'required|numeric|min:1|exists:services,id', 'service' => 'required|numeric|min:1|exists:services,id',
'option' => 'required|numeric|min:1|exists:service_options,id', 'option' => 'required|numeric|min:1|exists:service_options,id',
'location' => 'required|numeric|min:1|exists:locations,id',
'pack' => 'sometimes|nullable|numeric|min:0', 'pack' => 'sometimes|nullable|numeric|min:0',
'startup' => 'string', 'startup' => 'string',
'custom_image_name' => 'required_if:use_custom_image,on', 'custom_image_name' => 'required_if:use_custom_image,on',