You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
willaengine/app/SpFacility.php

25 lines
480 B

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class SpFacility extends Model{
public function templates()
{
return $this->belongsToMany('App\SpTemplate','facility_template','facility_id','template_id');
}
public function user_facilities()
{
return $this->hasMany('App\\SpUserFacility');
}
public function facility_type()
{
return $this->belongsTo('App\\SpFacilityType', 'sp_facility_type_id');
}
}