update
This commit is contained in:
52
app/Models/OLDLMS/Rujukan.php
Normal file
52
app/Models/OLDLMS/Rujukan.php
Normal file
@@ -0,0 +1,52 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models\OLDLMS;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Casts\Attribute;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Rujukan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $fillable = [
|
||||
'nIDLivechat',
|
||||
'sNoRujukan',
|
||||
'nIDHealthcare',
|
||||
'sDepartement',
|
||||
];
|
||||
|
||||
|
||||
// public $sStatusNames = [
|
||||
// 0 => 'Menunggu Konfirmasi',
|
||||
// 1 => 'Diterima',
|
||||
// 2 => 'Ditolak',
|
||||
// 3 => 'Selesai',
|
||||
// 4 => 'Expired',
|
||||
// ];
|
||||
|
||||
const CREATED_AT = 'dCreateOn';
|
||||
const UPDATED_AT = 'dUpdateOn';
|
||||
const DELETED_AT = 'dDeleteOn';
|
||||
|
||||
protected $connection = 'oldlms';
|
||||
|
||||
protected $table = 'tx_rujukan';
|
||||
|
||||
protected $primaryKey = 'nID';
|
||||
|
||||
// protected $appends = [
|
||||
// 'status_name',
|
||||
// ];
|
||||
|
||||
public function livechat(){
|
||||
return $this->belongsTo(Livechat::class, 'nIDLivechat', 'nID');
|
||||
}
|
||||
|
||||
public function healthcare(){
|
||||
return $this->belongsTo(Healthcare::class, 'nIDHealthcare', 'nID');
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user