12345678910111213141516171819202122232425262728293031323334 |
- <?php
- namespace App\Repositories\Validators\Course;
- use \Prettus\Validator\Contracts\ValidatorInterface;
- use \Prettus\Validator\LaravelValidator;
- /**
- * Class CourseCommentValidator.
- *
- * @package namespace App\Repositories\Validators;
- */
- class CommentValidator extends LaravelValidator
- {
- /**
- * Validation Rules
- *
- * @var array
- */
- protected $rules = [
- ValidatorInterface::RULE_CREATE => [
- 'course_id' => 'required|integer',
- 'points' => 'required|integer',
- 'course_video_id' => 'required|integer',
- 'content' => 'required',
- ],
- ValidatorInterface::RULE_UPDATE => [
- 'course_id' => 'required|integer',
- 'points' => 'required|integer',
- 'course_video_id' => 'required|integer',
- 'content' => 'required',
- ],
- ];
- }
|