Attendize/app/Http/Requests/HelpTopicRequest.php

58 lines
1.0 KiB
PHP
Raw Normal View History

2020-04-29 11:48:01 +00:00
<?php
namespace App\Http\Requests;
use App\Http\Requests\Request;
use Illuminate\Foundation\Http\FormRequest;
2020-04-30 12:39:58 +00:00
class HelpTopicRequest extends FormRequest
2020-04-29 11:48:01 +00:00
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
// only allow updates if the user is logged in
return backpack_auth()->check();
}
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
return [
'title_tk' => 'required|min:5|max:255',
'title_ru' => 'required|min:5|max:255'
];
}
/**
* Get the validation attributes that apply to the request.
*
* @return array
*/
public function attributes()
{
return [
//
];
}
/**
* Get the validation messages that apply to the request.
*
* @return array
*/
public function messages()
{
return [
//
];
}
}