| 1 | <?php |
||
| 10 | class PhotoReport extends ChocolateyModel |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * Disable Timestamps. |
||
| 14 | * |
||
| 15 | * @var bool |
||
| 16 | */ |
||
| 17 | public $timestamps = false; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * The table associated with the model. |
||
| 21 | * |
||
| 22 | * @var string |
||
| 23 | */ |
||
| 24 | protected $table = 'chocolatey_users_photos_reported'; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * Primary Key of the Table. |
||
| 28 | * |
||
| 29 | * @var string |
||
| 30 | */ |
||
| 31 | protected $primaryKey = 'id'; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * The Appender(s) of the Model. |
||
| 35 | * |
||
| 36 | * @var array |
||
| 37 | */ |
||
| 38 | protected $appends = ['reason_category']; |
||
| 39 | |||
| 40 | /** |
||
| 41 | * Store a new Photo Report. |
||
| 42 | * |
||
| 43 | * @param int $photoId |
||
| 44 | * @param int $reasonId |
||
| 45 | * @param int $reportedBy |
||
| 46 | * |
||
| 47 | * @return PhotoReport |
||
| 48 | */ |
||
| 49 | public function store(int $photoId, int $reasonId, int $reportedBy): PhotoReport |
||
| 61 | |||
| 62 | /** |
||
| 63 | * Get the Report Category Content. |
||
| 64 | * |
||
| 65 | * @return Builder |
||
| 66 | */ |
||
| 67 | public function getReasonCategoryAttribute() |
||
| 71 | } |
||
| 72 |