app/Http/Requests/UpdateServiceRequest.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 [
            'service_title' => 'required|unique:mysql2.services,service_title,'.$this->service->id,
            'service_description',
            'service_image' => 'nullable|max:1048|mimes:png,svg',
            'service_seo_title' => 'nullable',
            'service_seo_description' => 'nullable',
            'service_seo_keyword' => 'nullable',
        ];
    }
public function rules ( ) { return [ 'service_title' => 'required|unique:mysql2.services,service_title,' . $ this -> service -> id , 'service_description' , 'service_image' => 'nullable|max:1048|mimes:png,svg' , 'service_seo_title' => 'nullable' , 'service_seo_description' => 'nullable' , 'service_seo_keyword' => 'nullable' , ] ; }
Get the validation rules that apply to the request.
Get the validation rules that apply to the request .