初始化本地仓库
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace app\adminapi\validate\system;
|
||||
|
||||
use core\base\BaseValidate;
|
||||
|
||||
class FeedbackValidate extends BaseValidate
|
||||
{
|
||||
protected array $rule = [
|
||||
'id' => 'require',
|
||||
'type' => 'require|in:bug,suggestion,correction',
|
||||
'content' => 'require|max:2000',
|
||||
'contact' => 'max:100',
|
||||
'images' => 'array',
|
||||
'source' => 'require|in:app,web',
|
||||
'reply_content' => 'max:2000',
|
||||
];
|
||||
|
||||
protected array $message = [
|
||||
'type.require' => '请选择反馈类型',
|
||||
'type.in' => '反馈类型不正确',
|
||||
'content.require' => '请填写问题描述',
|
||||
'content.max' => '问题描述不能超过2000个字符',
|
||||
'contact.max' => '联系方式不能超过100个字符',
|
||||
'images.array' => '截图附件格式不正确',
|
||||
'source.require' => '请选择反馈来源',
|
||||
'source.in' => '反馈来源不正确',
|
||||
'reply_content.max' => '回复内容不能超过2000个字符',
|
||||
];
|
||||
|
||||
protected array $scene = [
|
||||
'store' => ['type', 'content', 'contact', 'images', 'source'],
|
||||
'update' => ['id', 'type', 'content', 'contact', 'images', 'source'],
|
||||
'reply' => ['id', 'reply_content'],
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user