<?php

namespace App\Models;

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

class ProductSize extends Model
{
    // Simpan ukuran di database terpisah untuk memudahkan skala
    protected $connection = 'sizes_db';
    protected $fillable = ['product_id', 'size', 'stock'];

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