<?php

namespace App\Models\Tenant;

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

class SaleReturnItem extends Model
{
    use HasFactory;
    protected $connection = 'tenant';
    protected $guarded = [];

    public function saleReturn()
    {
        return $this->belongsTo(SaleReturn::class);
    }

    public function variant()
    {
        return $this->belongsTo(ProductVariant::class, 'product_variant_id');
    }

    public function productUnit()
    {
        return $this->belongsTo(ProductUnit::class);
    }
}
