- VmProvisionException/VmProvisionRefund xử lý lỗi cấp phát VM - QueueJobInspector + QueueMonitorController xem chi tiết job - Thêm service uuid cho ticket, thời lượng cho activity_logs - Migration chuẩn hoá RAM addon sang MB, trạng thái deleting cho snapshot Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
46 lines
949 B
PHP
46 lines
949 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class ActivityLog extends Model
|
|
{
|
|
public $timestamps = false;
|
|
|
|
protected $table = 'activity_logs';
|
|
|
|
protected $fillable = [
|
|
'log_name',
|
|
'event',
|
|
'description',
|
|
'subject_type',
|
|
'subject_id',
|
|
'causer_type',
|
|
'causer_id',
|
|
'causer_name',
|
|
'old_values',
|
|
'new_values',
|
|
'ip_address',
|
|
'user_agent',
|
|
'started_at',
|
|
'finished_at',
|
|
'created_at',
|
|
];
|
|
|
|
protected $casts = [
|
|
'old_values' => 'array',
|
|
'new_values' => 'array',
|
|
'started_at' => 'datetime:Y-m-d\TH:i:s.v\Z',
|
|
'finished_at' => 'datetime:Y-m-d\TH:i:s.v\Z',
|
|
'created_at' => 'datetime',
|
|
];
|
|
|
|
protected static function booting(): void
|
|
{
|
|
static::creating(function (self $model) {
|
|
$model->created_at ??= now();
|
|
});
|
|
}
|
|
}
|