Changeset f457265 for app/Http/Requests/Dashboard/NewUserRequest.php
- Timestamp:
- 02/24/21 21:58:42 (4 years ago)
- Branches:
- master
- Children:
- ff9da8b
- Parents:
- 0c07a90
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
app/Http/Requests/Dashboard/NewUserRequest.php
r0c07a90 rf457265 25 25 public function rules() 26 26 { 27 return[27 $rules = [ 28 28 "name" => "required|alpha|min:2|max:255", 29 29 "surname" => "required|alpha|min:2|max:255", … … 32 32 "email" => "required|string|email|max:255|unique:users", 33 33 "username" => "required|alpha_dash|min:8|unique:users,username", 34 "userRole" => "required|exists:roles,id"35 34 ]; 35 36 if (!$this->has("company_id")) { 37 $rules["userRole"] = "required|exists:roles,id"; 38 } 39 40 return $rules; 36 41 } 37 42
Note:
See TracChangeset
for help on using the changeset viewer.