Files
animethemes-server/app/Concerns/Models/Reportable.php
T

22 lines
413 B
PHP

<?php
declare(strict_types=1);
namespace App\Concerns\Models;
use App\Models\User\Report\ReportStep;
use Illuminate\Database\Eloquent\Relations\MorphMany;
trait Reportable
{
/**
* Get the reports made to the model.
*
* @return MorphMany
*/
public function reportsteps(): MorphMany
{
return $this->morphMany(ReportStep::class, ReportStep::ATTRIBUTE_ACTIONABLE);
}
}