Skip to content

Instantly share code, notes, and snippets.

@uno-de-piera
Created May 31, 2020 08:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save uno-de-piera/5cbd9ed01f415d7f40d3bec3239c5bd3 to your computer and use it in GitHub Desktop.
Save uno-de-piera/5cbd9ed01f415d7f40d3bec3239c5bd3 to your computer and use it in GitHub Desktop.
<?php
namespace App\Http\Requests;
use Illuminate\Foundation\Http\FormRequest;
class FrameworksRequest extends FormRequest
{
/**
* Determine if the user is authorized to make this request.
*
* @return bool
*/
public function authorize()
{
return true;
}
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
return [
'name' => 'required|unique:frameworks|max:30',
];
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment