ldc-mesbr-app/app/PanierContent.php
Thibault Richy dec7bd1328 Fix Stats
2019-07-10 14:36:55 +02:00

51 lines
912 B
PHP

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class PanierContent extends Model
{
/**
* @var string
*/
protected $table = 'panier_content';
/**
* @var string
*/
protected $primaryKey = 'panier_content_id';
/**
* @var bool
*/
public $timestamps = false;
/**
* ManyToOne
* PanierContent -> Panier
*/
public function panier()
{
return $this->belongsTo('App\Panier', 'panier_content_panierId', 'panier_id');
}
/**
* ManyToOne
* PanierContent -> Coupon
*/
public function coupon()
{
return $this->belongsTo('App\Coupon', 'panier_content_couponId');
}
/**
* @var array
*/
protected $fillable = [
'panier_content_panierId',
'panier_content_couponId',
'panier_content_quantity',
'panier_content_printed'
];
}