Regex added for link instead

This commit is contained in:
akemidx 2023-04-24 20:07:21 -04:00
parent 16a5a883e5
commit 9cd2783185
2 changed files with 2 additions and 2 deletions

View file

@ -115,7 +115,7 @@ class ManufacturersController extends Controller
* @since [v1.0]
* @throws \Illuminate\Auth\Access\AuthorizationException
*/
public function update(SaveManufacturerRequest $request, $manufacturerId = null)
public function update(ImageUploadRequest $request, $manufacturerId = null)
{
$this->authorize('update', Manufacturer::class);
// Check if the manufacturer exists

View file

@ -23,8 +23,8 @@ class Manufacturer extends SnipeModel
protected $rules = [
'name' => 'required|min:2|max:255|unique:manufacturers,name,NULL,id,deleted_at,NULL',
'url' => 'url|nullable',
'support_url' => 'url|nullable',
'support_email' => 'email|nullable',
'support_url' => ['regex:/.+:\/\/.+/','nullable'],
];
protected $hidden = ['user_id'];