<?php

namespace Modules\Base\Http\Requests;

class AuthorizationRequest extends BaseRequest
{
    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            'phone' => 'bail|required|regex:/^1[345789][0-9]{9}$/|exists:users',
            'password' => 'required|string|min:6',
        ];
    }
}
