app/Http/Requests/StoreSurveyRequest.php
/**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
Get the validation rules that apply to the request.
@return array
Get the validation rules that apply to the request . @return array
public function rules()
    {
        return [
            'user_id' => 'exists:users,id',
            'image' => 'nullable|string',
            'title' => 'required|string',
            'status' => 'required|boolean',
            'description' => 'nullable|string',
            'expired_at' => 'nullable|date|after:tomorrow',
            'questions' => 'array',
        ];
    }
public function rules ( ) { return [ 'user_id' => 'exists:users,id' , 'image' => 'nullable|string' , 'title' => 'required|string' , 'status' => 'required|boolean' , 'description' => 'nullable|string' , 'expired_at' => 'nullable|date|after:tomorrow' , 'questions' => 'array' , ] ; }
Get the validation rules that apply to the request.
Get the validation rules that apply to the request .