initial commit
This commit is contained in:
25
app/Models/PatientPlan.php
Normal file
25
app/Models/PatientPlan.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class PatientPlan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
protected $table = 'patient_plan';
|
||||
protected $fillable = [
|
||||
'patient_id',
|
||||
'plan_id'
|
||||
];
|
||||
|
||||
public function patient()
|
||||
{
|
||||
return $this->belongsTo(Patient::class, 'patient_id', 'id');
|
||||
}
|
||||
public function plan()
|
||||
{
|
||||
return $this->belongsTo(Plan::class, 'plan_id');
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user