28 lines
587 B
PHP
28 lines
587 B
PHP
<?php
|
|
|
|
namespace app\api\validate;
|
|
|
|
use think\Validate;
|
|
|
|
class PlayValidate extends Validate
|
|
{
|
|
protected $rule = [
|
|
'id' => 'require',
|
|
'sid' => 'require',
|
|
'limit' => 'between:1,100'
|
|
];
|
|
|
|
protected $message = [
|
|
'id.require' => '集ID不能为空',
|
|
'sid.require' => '视频ID不能为空',
|
|
'limit.between' => '内容条数只能在1-100之间'
|
|
];
|
|
|
|
protected $scene = [
|
|
'list' => ['sid', 'page', 'limit'],
|
|
'videoUnlock' => ['sid'],
|
|
'bingeWatching' => ['sid'],
|
|
'videoPlay' => ['sid']
|
|
];
|
|
}
|