Files
librenms-librenms/app/Models/PortStack.php
T
0d201c44c9 Fix Port Channel (#16227)
* Fix expandable sizing

* Temp fix: port_id_{low,high} is actually ifIndex

* new PortsStack discovery module, store actual port_ids

* Show 4 rows of ports by default

* Add test data

* Fix up the single port view too

* Apply fixes from StyleCI

* Update db_schema.yaml

* Update base migration because sqlite cannot add primary keys

* Fix phpstan failures

---------

Co-authored-by: Tony Murray <[email protected]>
2024-07-25 23:39:36 -05:00

26 lines
550 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use LibreNMS\Interfaces\Models\Keyable;
class PortStack extends DeviceRelatedModel implements Keyable
{
use HasFactory;
protected $table = 'ports_stack';
public $timestamps = false;
protected $fillable = [
'high_ifIndex',
'high_port_id',
'low_ifIndex',
'low_port_id',
'ifStackStatus',
];
public function getCompositeKey()
{
return $this->high_ifIndex . '-' . $this->low_ifIndex;
}
}