| 12345678910111213141516171819202122232425262728293031323334353637 |
- <?php
- namespace ghs\models\lakala;
- use ghs\models\BaseForm;
- /**
- * 拉卡拉资料图片上传表单模型
- */
- class UploadFileForm extends BaseForm
- {
- public $id;
- public $content;
- public $imgType;
- public $isOcr;
- public function rules()
- {
- return [
- [['id', 'content', 'imgType'], 'required', 'message' => '请填写{attribute}'],
- ['id', 'integer', 'min' => 1, 'message' => '申请ID格式错误', 'tooSmall' => '申请ID格式错误'],
- ['content', 'string'],
- ['imgType', 'string', 'max' => 64],
- ['isOcr', 'default', 'value' => 0],
- ['isOcr', 'boolean', 'message' => '是否OCR格式错误'],
- ];
- }
- public function attributeLabels()
- {
- return [
- 'id' => '申请ID',
- 'content' => '图片内容',
- 'imgType' => '图片类型',
- 'isOcr' => '是否OCR',
- ];
- }
- }
|