<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class StatisticMonth extends Model
{
    //
	use SoftDeletes;

    protected $fillable = [
        'month',
        'year',
        'amount',
        'current_paid',
        'hostel_id',
        'room_id',
        'contract_id',
        'created_at',
        'updated_at',
        'deleted_at',
        'start_date',
        'end_date',
        'money_info_id'
    ];

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

    public function contract()
    {
        return $this->belongsTo(Contract::class)->withTrashed();
    }

}
