Domain\Classroom\Http\Requests\StoreRequest::rules PHP Method

rules() public method

Get the validation rules that apply to the request.
public rules ( ) : array
return array
    public function rules()
    {
        return ['name' => 'required|max:40|unique:classrooms', 'teacher_id' => 'required|integer|exists:teachers,id,deleted_at,NULL', 'schedule_id' => 'required|integer|exists:schedules,id', 'matters.*.id' => 'integer|exists:matters,id', 'students.*.id' => 'integer|exists:students,id'];
    }
StoreRequest