ldc-dam/app/Models/Variante.php

32 lines
582 B
PHP
Raw Permalink Normal View History

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class Variante extends Model
{
2022-04-19 16:07:27 +02:00
/**
* The primary key associated with the table.
*
* @var string
*/
protected $primaryKey = 'codeVariante';
2022-04-19 16:07:27 +02:00
/**
* Get the sujet that owns the variante.
*/
public function sujet()
{
return $this->belongsTo('App\Models\Sujet', 'sujet_id');
}
2022-04-19 16:07:27 +02:00
/**
* Get the typeVue that owns the variante.
*/
public function typeVue()
{
return $this->belongsTo('App\Models\Typevue', 'typevue_id');
}
}