ldc-boutique-cnc/app/Models/Timeslot.php

41 lines
759 B
PHP
Raw Permalink Normal View History

2021-03-29 15:10:07 +02:00
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Timeslot extends Model
{
use HasFactory;
2022-09-03 16:56:16 +02:00
/**
* The attributes that are mass assignable.
*
* @var array
*/
2021-03-29 15:10:07 +02:00
protected $fillable = [
'order_id', 'magasin_id'
2021-03-29 15:10:07 +02:00
];
2022-09-03 16:56:16 +02:00
/**
* BelongsTo order relation
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
2021-03-29 15:10:07 +02:00
public function order()
{
return $this->belongsTo(Order::class);
}
2022-09-03 16:56:16 +02:00
/**
* BelongsTo magasin relation
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public function magasin()
{
return $this->belongsTo(Magasin::class);
}
2021-03-29 15:10:07 +02:00
}