22 lines
380 B
PHP
22 lines
380 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class Siswa extends Model
|
|
{
|
|
protected $table = 'siswa';
|
|
protected $guarded = ['id'];
|
|
|
|
public function Programs()
|
|
{
|
|
return $this->belongsTo(Programs::class, 'program_id');
|
|
}
|
|
|
|
public function Sekolah()
|
|
{
|
|
return $this->belongsTo(Sekolah::class, 'sekolah_id');
|
|
}
|
|
}
|