51 lines
768 B
PHP
51 lines
768 B
PHP
<?php
|
|
|
|
/**
|
|
* Created by Reliese Model.
|
|
*/
|
|
|
|
namespace App\Models;
|
|
|
|
use Carbon\Carbon;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* Class TourFlight
|
|
*
|
|
* @property int $id
|
|
* @property int $tour_id
|
|
* @property int $flight_id
|
|
* @property Carbon $created_at
|
|
* @property Carbon $updated_at
|
|
*
|
|
* @property Flight $flight
|
|
* @property Tour $tour
|
|
*
|
|
* @package App\Models
|
|
*/
|
|
class TourFlight extends Model
|
|
{
|
|
protected $table = 'tour_flights';
|
|
public static $snakeAttributes = false;
|
|
|
|
protected $casts = [
|
|
'tour_id' => 'int',
|
|
'flight_id' => 'int'
|
|
];
|
|
|
|
protected $fillable = [
|
|
'tour_id',
|
|
'flight_id'
|
|
];
|
|
|
|
public function flight()
|
|
{
|
|
return $this->belongsTo(Flight::class);
|
|
}
|
|
|
|
public function tour()
|
|
{
|
|
return $this->belongsTo(Tour::class);
|
|
}
|
|
}
|