first commit
This commit is contained in:
32
application/common/validate/Storage.php
Normal file
32
application/common/validate/Storage.php
Normal file
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
// +------------------------------------------------+
|
||||
// |http://www.cjango.com |
|
||||
// +------------------------------------------------+
|
||||
// | 修复BUG不是一朝一夕的事情,等我喝醉了再说吧! |
|
||||
// +------------------------------------------------+
|
||||
// | Author: 小陈叔叔 <Jason.Chen> |
|
||||
// +------------------------------------------------+
|
||||
namespace app\common\validate;
|
||||
|
||||
use think\Validate;
|
||||
|
||||
class Storage extends Validate
|
||||
{
|
||||
/**
|
||||
* 验证规则
|
||||
* @var array
|
||||
*/
|
||||
protected $rule = [
|
||||
'image' => 'file|image:|fileExt:jpg,png,gif,jpeg,bmp|fileSize:2097152',
|
||||
'file' => 'file|fileExt:doc,docx,xls,xlsx,ppt,pptx,zip,rar,jpg,png,gif,jpeg,bmp|fileSize:5242880',
|
||||
'video' => 'file|fileExt:mp4,flv,swf|fileSize:52428800',
|
||||
'audio' => 'file|fileExt:mp3|fileSize:52428800',
|
||||
];
|
||||
|
||||
/**
|
||||
* 错误提示消息
|
||||
* @var array
|
||||
*/
|
||||
protected $message = [
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user