45 lines
1.3 KiB
PHP
45 lines
1.3 KiB
PHP
<?php
|
|
|
|
/**
|
|
* Created by Reliese Model.
|
|
*/
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* Class PaymentOptionReference
|
|
*
|
|
* @property int $parent_payment_option_id
|
|
* @property int $child_payment_option_id
|
|
* @property PaymentOption $payment_option
|
|
* @package App\Models
|
|
* @method static \Illuminate\Database\Eloquent\Builder|PaymentOptionReference newModelQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|PaymentOptionReference newQuery()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|PaymentOptionReference query()
|
|
* @method static \Illuminate\Database\Eloquent\Builder|PaymentOptionReference whereChildPaymentOptionId($value)
|
|
* @method static \Illuminate\Database\Eloquent\Builder|PaymentOptionReference whereParentPaymentOptionId($value)
|
|
* @mixin \Eloquent
|
|
*/
|
|
class PaymentOptionReference extends Model
|
|
{
|
|
protected $table = 'payment_option_reference';
|
|
public $incrementing = false;
|
|
public $timestamps = false;
|
|
|
|
protected $casts = [
|
|
'parent_payment_option_id' => 'int',
|
|
'child_payment_option_id' => 'int'
|
|
];
|
|
|
|
protected $fillable = [
|
|
'parent_payment_option_id',
|
|
'child_payment_option_id'
|
|
];
|
|
|
|
public function payment_option()
|
|
{
|
|
return $this->belongsTo(PaymentOption::class, 'parent_payment_option_id');
|
|
}
|
|
}
|