update final log
This commit is contained in:
@@ -44,6 +44,9 @@ class File extends Model
|
||||
'claim-diagnosis' => 'claim/',
|
||||
'claim-kondisi' => 'claim/',
|
||||
'claim-invoice' => 'claim/',
|
||||
'final-log-result' => 'final-log/',
|
||||
'final-log-diagnosis' => 'final-log/',
|
||||
'final-log-kondisi' => 'final-log/',
|
||||
'docs' => 'docs/',
|
||||
];
|
||||
|
||||
@@ -54,7 +57,7 @@ class File extends Model
|
||||
|
||||
public static function getDirectory($type)
|
||||
{
|
||||
return self::$file_directories[$type] ?? 'any';
|
||||
return self::$file_directories[$type] ?? 'any/';
|
||||
}
|
||||
|
||||
public static function getFileName($type, $id)
|
||||
|
||||
20
app/Models/OrganizationUser.php
Normal file
20
app/Models/OrganizationUser.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class OrganizationUser extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
protected $table = 'organization_user';
|
||||
protected $connection = 'mysql';
|
||||
protected $fillable = [
|
||||
'organization_id',
|
||||
];
|
||||
|
||||
public function organization(){
|
||||
return $this->hasOne(Organization::class, 'id', 'organization_id');
|
||||
}
|
||||
}
|
||||
@@ -24,7 +24,9 @@ class RequestLog extends Model
|
||||
'payment_type',
|
||||
'service_code',
|
||||
'policy_id',
|
||||
'final_log',
|
||||
'status',
|
||||
'status_final_log',
|
||||
'source',
|
||||
'claim_id',
|
||||
'organization_id',
|
||||
|
||||
27
app/Models/RequestLogBenefit.php
Normal file
27
app/Models/RequestLogBenefit.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class RequestLogBenefit extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'request_log_benefits';
|
||||
|
||||
public $fillable = [
|
||||
'request_log_id',
|
||||
'benefit_id',
|
||||
'amount_incurred',
|
||||
'amount_approved',
|
||||
'amount_not_approved',
|
||||
'excess_paid',
|
||||
'keterangan',
|
||||
];
|
||||
|
||||
public function benefit(){
|
||||
return $this->belongsTo(Benefit::class, 'benefit_id', 'id');
|
||||
}
|
||||
}
|
||||
@@ -105,4 +105,9 @@ class User extends Authenticatable
|
||||
{
|
||||
return $this->morphMany(NotificationToken::class, 'notifiabletoken');
|
||||
}
|
||||
|
||||
public function getOrganization()
|
||||
{
|
||||
return $this->hasOne(OrganizationUser::class, 'user_id');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user