33 lines
491 B
PHP
33 lines
491 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
namespace App;
|
||
|
|
|
||
|
|
use Illuminate\Database\Eloquent\Model;
|
||
|
|
|
||
|
|
class Notification extends Model
|
||
|
|
{
|
||
|
|
/**
|
||
|
|
* @var string
|
||
|
|
*/
|
||
|
|
protected $table = 'notification';
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @var string
|
||
|
|
*/
|
||
|
|
protected $primaryKey = 'notif_id';
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @var bool
|
||
|
|
*/
|
||
|
|
public $timestamps = false;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* ManyToOne
|
||
|
|
* Notification -> Campagne
|
||
|
|
*/
|
||
|
|
public function campagne()
|
||
|
|
{
|
||
|
|
return $this->belongsTo('App\Campagne', 'notif_campId');
|
||
|
|
}
|
||
|
|
}
|