<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class RechargeSummery extends Model
{
    use HasFactory;
    protected $table = 'recharge_summery';
    protected $fillable = [
        'user_id',
        'ref_no',
        'amount',
        'type',
        'status'
    ];

    public function user()
    {
        return $this->belongsTo(User::class);
    }

    public function scopeStatus($query)
    {
        return $query->where('status', '=', 1);
    }

}

