2018-12-23 09:00:22 -05:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Models;
|
|
|
|
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
|
|
|
|
class Checkout extends Model
|
|
|
|
{
|
|
|
|
protected $table = 'checkout';
|
|
|
|
protected $fillable = [
|
|
|
|
'bidder_num',
|
|
|
|
'winnertotal',
|
|
|
|
'payment_method',
|
|
|
|
'check_number',
|
|
|
|
'cc_transaction',
|
|
|
|
'cc_amount'
|
|
|
|
];
|
|
|
|
|
2018-12-23 09:15:59 -05:00
|
|
|
public function bidders()
|
2018-12-23 09:00:22 -05:00
|
|
|
{
|
2018-12-23 09:22:52 -05:00
|
|
|
return $this->belongsTo('App\Models\Bidders', 'bidder_num', 'idbidders')->orderBy('bidder_assigned_number', 'asc');
|
2018-12-23 09:00:22 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
public function paymentMethod()
|
|
|
|
{
|
|
|
|
return $this->hasMany('App\Models\PaymentMethods', 'payment_method', 'pm_id');
|
|
|
|
}
|
|
|
|
}
|