MIF_E31222881/app/Models/DetailPayment.php

24 lines
447 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class DetailPayment extends Model
{
use HasFactory;
protected $guarded = ['id'];
public function payment()
{
return $this->belongsTo(Payment::class, 'payment_id', 'id');
}
public function paymentType()
{
return $this->belongsTo(PaymentType::class, 'type_id', 'id');
}
}