ldc-mesbr-app/app/Calendrier.php
Vincent BRIDIER f0c322c843 - Add API v1
- Add PHPCS
2021-04-27 17:29:47 +02:00

43 lines
695 B
PHP

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Calendrier extends Model
{
/**
* @var string
*/
protected $table = 'calendrier';
/**
* @var bool
*/
public $timestamps = false;
/**
* @var string
*/
protected $primaryKey = 'calendrier_id';
protected $dates = ['calendrier_startdate', 'calendrier_enddate'];
/**
* @var array
*/
protected $fillable = [
'calendrier_startdate',
'calendrier_enddate'
];
/**
* ManyToOne
* Calendrier -> Coupon
*/
public function coupon()
{
return $this->belongsTo('App\Coupon', 'calendrier_couponId');
}
}