<?php

namespace App\Models;

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

class BidHistory extends Model
{
    use HasFactory;

    protected $table = 'bid_history';

    protected $fillable = [
        'bid_id',
        'user_id',
        'action',
        'from_status',
        'to_status',
        'notes',
        'ip_address',
    ];

    public function bid(): BelongsTo
    {
        return $this->belongsTo(Bid::class);
    }

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