inital commit
This commit is contained in:
26
app/Http/Requests/EmployeeRegistrationRequest.php
Normal file
26
app/Http/Requests/EmployeeRegistrationRequest.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Requests;
|
||||
|
||||
|
||||
use Illuminate\Validation\Rule;
|
||||
|
||||
class EmployeeRegistrationRequest extends BaseRequest
|
||||
{
|
||||
|
||||
/**
|
||||
* Get the validation rules that apply to the request.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function rules()
|
||||
{
|
||||
return [
|
||||
"first_name" => "required|string",
|
||||
"last_name" => "required|string",
|
||||
'email' => ['required', 'email',Rule::unique('users', 'email')->withoutTrashed()],
|
||||
'password' => 'required',
|
||||
'userRole' => 'required'
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user