Xboard/app/Models/ServerTrojan.php
2023-11-17 14:44:01 +08:00

29 lines
678 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class ServerTrojan extends Model
{
protected $table = 'v2_server_trojan';
protected $dateFormat = 'U';
protected $guarded = ['id'];
protected $casts = [
'created_at' => 'timestamp',
'updated_at' => 'timestamp',
'group_id' => 'array',
'route_id' => 'array',
'networkSettings' => 'array',
'tags' => 'array',
'excludes' => 'array',
'ips' => 'array'
];
public function parent(): BelongsTo
{
return $this->belongsTo(self::class, 'parent_id', 'id');
}
}