<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Extra extends Model
{
    //
    protected $fillable = [
        'amount',
        'date_action',
        'note',
        'name',
        'pay',
        'created_at',
        'updated_at',
        'deleted_at',
        'hostel_id',
        'room_id'
    ];

    protected $dates = [
        'date_action',
        'created_at',
        'updated_at',
        'deleted_at'
    ];

    public function hostel()
    {
        return $this->belongsTo('App\Models\Hostel');
    }

    public function room()
    {
        return $this->belongsTo('App\Models\Room');
    }
}
