mirror of
https://github.com/librenms/librenms.git
synced 2024-09-21 18:38:25 +00:00
25 lines
549 B
PHP
25 lines
549 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
|
|
class PortsFdb extends PortRelatedModel
|
|
{
|
|
protected $table = 'ports_fdb';
|
|
protected $primaryKey = 'ports_fdb_id';
|
|
public $timestamps = true;
|
|
|
|
// ---- Define Relationships ----
|
|
|
|
public function device(): BelongsTo
|
|
{
|
|
return $this->belongsTo(\App\Models\Device::class, 'device_id', 'device_id');
|
|
}
|
|
|
|
public function vlan(): BelongsTo
|
|
{
|
|
return $this->belongsTo(\App\Models\Vlan::class, 'vlan_id', 'vlan_id');
|
|
}
|
|
}
|