clrghouz/app/Models/Nodelist.php

26 lines
457 B
PHP
Raw Normal View History

2021-06-25 11:31:57 +00:00
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
2021-06-25 11:31:57 +00:00
class Nodelist extends Model
{
use SoftDeletes;
protected $casts = [
'date' => 'datetime:Y-m-d H:i:s'
];
2021-06-25 11:31:57 +00:00
protected $fillable = ['date','domain_id'];
2021-06-26 00:34:49 +00:00
public const definitions = ['Zone','Region','Host','Hub','Pvt','Hold','Down'];
2021-06-25 11:31:57 +00:00
/* RELATIONS */
public function addresses()
{
return $this->belongsToMany(Address::class);
}
}