Files
kiarash-airline/app/Models/TourDetail.php
T

57 lines
948 B
PHP

<?php
/**
* Created by Reliese Model.
*/
namespace App\Models;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
/**
* Class TourDetail
*
* @property int $id
* @property int $tour_id
* @property Carbon $start_date
* @property Carbon $end_date
* @property int $price
* @property int $capacity
* @property int $status
* @property Carbon $created_at
* @property Carbon $updated_at
*
* @property Tour $tour
*
* @package App\Models
*/
class TourDetail extends Model
{
use SoftDeletes;
protected $table = 'tour_details';
protected $casts = [
'tour_id' => 'int',
'start_date' => 'datetime',
'end_date' => 'datetime',
'price' => 'int',
'capacity' => 'int',
'status' => 'int'
];
protected $fillable = [
'tour_id',
'start_date',
'end_date',
'price',
'capacity',
'status'
];
public function tour()
{
return $this->belongsTo(Tour::class);
}
}