Created
May 31, 2018 00:44
-
-
Save maxca/8ff7fcf9e2ffd9d701b5bc37f670fc32 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @author samark chaisanguan | |
* @email [email protected] | |
*/ | |
namespace App\Http\Requests\Good; | |
use Lumpineevill\Request\APIRequest; | |
class GetGoodRequest extends APIRequest | |
{ | |
/** | |
* 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. | |
* simple rule below this. | |
* required | exists | required_if | email | interger | date| date_format | between | array | json | boolean | | |
* max | min | confirmed | differece | alpha | alpha_numeric | acitve(url) | accepted |distinct | file | same | |
* size | string | timezone | unique | url | nullable | not_in| digits | digits_between | mime_type | mime_type_by_file_extension | |
* in_array | ip_address | image | regex:patten | | |
* @return array | |
*/ | |
public function rules() | |
{ | |
return [ | |
# 'id' => 'required|exists:good,id', | |
# 'email' => 'unique:good,email', | |
]; | |
} | |
/** | |
* If need to overiding message of node | |
* @return array | |
*/ | |
public function messages() | |
{ | |
return []; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment