| 1 | <?php |
||
| 41 | class Comment extends Model implements HasPresenter |
||
| 42 | { |
||
| 43 | use SoftDeletes, ValidatingTrait; |
||
| 44 | |||
| 45 | /** |
||
| 46 | * The fillable properties. |
||
| 47 | * |
||
| 48 | * @var string[] |
||
| 49 | */ |
||
| 50 | protected $fillable = [ |
||
| 51 | 'author_id', |
||
| 52 | 'project_id', |
||
| 53 | 'message', |
||
| 54 | 'target_type', |
||
| 55 | 'target_id', |
||
| 56 | 'created_at', |
||
| 57 | 'updated_at', |
||
| 58 | ]; |
||
| 59 | |||
| 60 | /** |
||
| 61 | * The validation rules. |
||
| 62 | * |
||
| 63 | * @var string[] |
||
| 64 | */ |
||
| 65 | public $rules = [ |
||
| 66 | 'author_id' => 'int', |
||
| 67 | 'project_id' => 'int', |
||
| 68 | 'message' => 'required', |
||
| 69 | 'target_type' => 'string|required', |
||
| 70 | 'target_id' => 'int', |
||
| 71 | ]; |
||
| 72 | |||
| 73 | /** |
||
| 74 | * Get the presenter class. |
||
| 75 | * |
||
| 76 | * @return string |
||
| 77 | */ |
||
| 78 | public function getPresenterClass() |
||
| 82 | } |
||
| 83 |