<?php

namespace App\Models;

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

class Rating extends Model
{
    use HasFactory;

    protected $fillable = [
        'user_id', 'dry_cleaner_id', 'order_id', 'rating', 'review',
    ];

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

    public function dryCleaner()
    {
        return $this->belongsTo(DryCleaner::class);
    }

    public function order()
    {
        return $this->belongsTo(Order::class);
    }
}
