mirror of
https://github.com/pelican-dev/panel.git
synced 2025-05-19 17:34:45 +02:00

* Remove old admin * Remove controller test * Remove unused exceptions * Remove unused files * More small tweaks * Fix doc block * Remove unused service * Restore these * Add back autoDeploy * Revert "Add back autoDeploy" This reverts commit 630c1e08acf8056ce8e612f376fcd00c23d90aea. * Add these back * Add back exception * Remove ApiController again --------- Co-authored-by: RMartinOscar <40749467+RMartinOscar@users.noreply.github.com> Co-authored-by: Boy132 <mail@boy132.de> Co-authored-by: notCharles <charles@pelican.dev>
44 lines
1.2 KiB
PHP
44 lines
1.2 KiB
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
use Illuminate\Database\Eloquent\Relations\MorphTo;
|
|
use Illuminate\Database\Eloquent\Relations\Pivot;
|
|
use Illuminate\Database\Eloquent\SoftDeletingScope;
|
|
|
|
/**
|
|
* \App\Models\ActivityLogSubject.
|
|
*
|
|
* @property int $id
|
|
* @property int $activity_log_id
|
|
* @property int $subject_id
|
|
* @property string $subject_type
|
|
* @property \App\Models\ActivityLog|null $activityLog
|
|
* @property \Illuminate\Database\Eloquent\Model|\Eloquent $subject
|
|
*
|
|
* @method static \Illuminate\Database\Eloquent\Builder|ActivityLogSubject newModelQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|ActivityLogSubject newQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|ActivityLogSubject query()
|
|
*/
|
|
class ActivityLogSubject extends Pivot
|
|
{
|
|
public $incrementing = true;
|
|
|
|
public $timestamps = false;
|
|
|
|
protected $table = 'activity_log_subjects';
|
|
|
|
protected $guarded = ['id'];
|
|
|
|
public function activityLog(): BelongsTo
|
|
{
|
|
return $this->belongsTo(ActivityLog::class);
|
|
}
|
|
|
|
public function subject(): MorphTo
|
|
{
|
|
return $this->morphTo()->withoutGlobalScope(SoftDeletingScope::class);
|
|
}
|
|
}
|