first commit
This commit is contained in:
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Concerns\HasUlids;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
|
||||
class Event extends Model
|
||||
{
|
||||
use HasUlids;
|
||||
|
||||
const UPDATED_AT = null;
|
||||
|
||||
protected $fillable = [
|
||||
'issue_id',
|
||||
'project_id',
|
||||
'event_id',
|
||||
'level',
|
||||
'message',
|
||||
'platform',
|
||||
'timestamp',
|
||||
'server_name',
|
||||
'release',
|
||||
'environment',
|
||||
'exception',
|
||||
'breadcrumbs',
|
||||
'contexts',
|
||||
'tags',
|
||||
'extra',
|
||||
'user_context',
|
||||
'request_context',
|
||||
'sdk',
|
||||
'raw_payload',
|
||||
];
|
||||
|
||||
protected function casts(): array
|
||||
{
|
||||
return [
|
||||
'timestamp' => 'datetime',
|
||||
'exception' => 'array',
|
||||
'breadcrumbs' => 'array',
|
||||
'contexts' => 'array',
|
||||
'tags' => 'array',
|
||||
'extra' => 'array',
|
||||
'user_context' => 'array',
|
||||
'request_context' => 'array',
|
||||
'sdk' => 'array',
|
||||
'raw_payload' => 'array',
|
||||
];
|
||||
}
|
||||
|
||||
public function issue(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(Issue::class);
|
||||
}
|
||||
|
||||
public function project(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(Project::class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user