Files
monica/app/Offspring.php
T
2018-02-04 15:44:26 -05:00

30 lines
474 B
PHP

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
/**
* An offspring is the child of a contact.
*/
class Offspring extends Model
{
protected $table = 'offsprings';
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'account_id',
'contact_id',
'is_the_child_of',
];
public function contact()
{
return $this->belongsTo(Contact::class);
}
}